Lines 1-5
Link Here
|
1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
2 |
* Copyright (c) 2008 IBM Corporation and others. |
2 |
* Copyright (c) 2008, 2009 IBM Corporation and others. |
3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
Lines 13-19
Link Here
|
13 |
/** |
13 |
/** |
14 |
* Delta model objects are of type IBundle, IService, IExtension, IExtensionPoint |
14 |
* Delta model objects are of type IBundle, IService, IExtension, IExtensionPoint |
15 |
*/ |
15 |
*/ |
16 |
public class ModelChangeDelta { |
16 |
public class ModelChangeDelta extends ModelObject { |
17 |
|
17 |
|
18 |
public static final int ADDED = 0; |
18 |
public static final int ADDED = 0; |
19 |
public static final int UPDATED = 1; |
19 |
public static final int UPDATED = 1; |
Lines 25-33
Link Here
|
25 |
public static final int RESOLVED = 7; |
25 |
public static final int RESOLVED = 7; |
26 |
public static final int UNRESOLVED = 8; |
26 |
public static final int UNRESOLVED = 8; |
27 |
|
27 |
|
|
|
28 |
// TODO SWITCH from HEAVY ModelChangeDelta carrying whole object, to LIGHT delta - name, type (Bundle/Service/Ext/ExtPt), id |
28 |
private ModelObject fObject; |
29 |
private ModelObject fObject; |
29 |
private int fFlag; |
30 |
private int fFlag; |
30 |
|
31 |
|
|
|
32 |
public ModelChangeDelta() { |
33 |
// empty |
34 |
} |
35 |
|
31 |
public ModelChangeDelta(ModelObject object, int flag) { |
36 |
public ModelChangeDelta(ModelObject object, int flag) { |
32 |
fObject = object; |
37 |
fObject = object; |
33 |
fFlag = flag; |
38 |
fFlag = flag; |
Lines 40-43
Link Here
|
40 |
public int getFlag() { |
45 |
public int getFlag() { |
41 |
return fFlag; |
46 |
return fFlag; |
42 |
} |
47 |
} |
|
|
48 |
|
49 |
public void addChild(ModelObject o) { |
50 |
setModelObject(o); |
51 |
} |
52 |
|
53 |
public ModelObject[] getChildren() { |
54 |
return new ModelObject[] {fObject}; |
55 |
} |
56 |
|
57 |
public void setModelObject(ModelObject fObject) { |
58 |
this.fObject = fObject; |
59 |
} |
60 |
|
61 |
public void setFlag(int flag) { |
62 |
this.fFlag = flag; |
63 |
} |
43 |
} |
64 |
} |