|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectedu.ksu.cis.cadena.core.adapter.BaseCadenaAdapter
public abstract class BaseCadenaAdapter
Implementation base for Cadena adapters. Provides methods for iterating
across all CadenaAdapter's adapting a particular model node,
and collecting referrers who would be affected by a structural change.
| Field Summary | |
|---|---|
static java.lang.String |
REFERENCED_OBJECT_IN_TRASH_ERROR
|
| Constructor Summary | |
|---|---|
BaseCadenaAdapter()
|
|
| Method Summary | |
|---|---|
void |
addAffectedReferrers(Notification notification,
EObject notifyingObject,
EStructuralFeature notifyingObjectFeature,
java.util.Set<Triple<CadenaAdapter,EObject,EStructuralFeature>> referrers)
Calculate the set of model objects whose well-formedness could be affected by a structural change to element. |
void |
addNotificationValues(Notification notification,
java.util.Set<Pair<EObject,EStructuralFeature>> returnVal)
Adds a notification's old and new values (if they are instances of EObject) to an affected set. |
void |
checkNode(EObject node)
Called when a complete check of the model is performed. |
abstract void |
forwardReferenceChanged(Notification notification,
EObject notifyingObject,
EStructuralFeature notifyingObjectFeature)
|
java.util.Set<? extends EObject> |
getAffectedValues(Notification notification)
|
Notifier |
getTarget()
|
boolean |
isAdapterForType(java.lang.Object type)
|
void |
notifyChanged(Notification notification)
|
static void |
setMarkers(java.lang.Object markedObject,
java.lang.String markerType,
java.lang.String... messages)
|
void |
setTarget(Notifier newTarget)
|
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String REFERENCED_OBJECT_IN_TRASH_ERROR
| Constructor Detail |
|---|
public BaseCadenaAdapter()
| Method Detail |
|---|
public final void addAffectedReferrers(Notification notification,
EObject notifyingObject,
EStructuralFeature notifyingObjectFeature,
java.util.Set<Triple<CadenaAdapter,EObject,EStructuralFeature>> referrers)
CadenaAdapter
Calculate the set of model objects whose well-formedness could be
affected by a structural change to element.
In order to prevent infinite, circular call sequences, the protocol for adding a referrer should be as follows:
Triple<CadenaAdapter, EObject, Integer> client = ...;
if (!referrers.contains(client))
{
referrers.add(client);
List<Adapter> adapters = client.second.eAdapters();
for (Adapter a : adapters)
{
if (a instanceof CadenaAdapter)
{
((CadenaAdapter)a).addAffectedReferrers(
client.second,
a,
client.third);
}
}
}
addAffectedReferrers in interface CadenaAdapterpublic void checkNode(EObject node)
CadenaAdapter
checkNode in interface CadenaAdapternode - The current node being checked.public void notifyChanged(Notification notification)
public abstract void forwardReferenceChanged(Notification notification,
EObject notifyingObject,
EStructuralFeature notifyingObjectFeature)
forwardReferenceChanged in interface CadenaAdapterpublic void setTarget(Notifier newTarget)
public Notifier getTarget()
public boolean isAdapterForType(java.lang.Object type)
public java.util.Set<? extends EObject> getAffectedValues(Notification notification)
public void addNotificationValues(Notification notification,
java.util.Set<Pair<EObject,EStructuralFeature>> returnVal)
public static void setMarkers(java.lang.Object markedObject,
java.lang.String markerType,
java.lang.String... messages)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||