blob: 5818d54fb5de1d0b071581eff501073fae8075cf (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
|
/*******************************************************************************
* Copyright (c) 2010 Boeing.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Boeing - initial API and implementation
*******************************************************************************/
package org.eclipse.osee.framework.core.model.mocks;
import org.eclipse.osee.framework.core.data.IArtifactType;
import org.eclipse.osee.framework.core.data.IOseeBranch;
import org.eclipse.osee.framework.core.data.NamedIdentity;
import org.eclipse.osee.framework.core.enums.BranchState;
import org.eclipse.osee.framework.core.enums.BranchType;
import org.eclipse.osee.framework.core.model.Branch;
import org.eclipse.osee.framework.core.model.IBasicArtifact;
import org.eclipse.osee.framework.core.model.type.ArtifactType;
/**
* @author Jeff C. Phillips
*/
public class MockArtifact extends NamedIdentity implements IBasicArtifact<Object> {
private final Branch branch;
private final ArtifactType artifactType;
private final int artId;
public MockArtifact(String guid, String name, IOseeBranch branch, IArtifactType artifactType, int artId) {
super(guid, name);
this.branch = new Branch(branch.getGuid(), branch.getName(), BranchType.WORKING, BranchState.MODIFIED, false);
this.artifactType = new ArtifactType(artifactType.getGuid(), artifactType.getName(), false);
this.artId = artId;
}
@Override
public int getArtId() {
return artId;
}
@Override
public Branch getBranch() {
return branch;
}
@Override
public ArtifactType getArtifactType() {
return artifactType;
}
@Override
public Object getFullArtifact() {
return null;
}
}
|