|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.mit.sketch.ddg.DomainObjectGraph
public class DomainObjectGraph
A graph representing a hierarchy of domain objects and shapes. Each shape can have a number of subclasses and superclasses.
A subclass is an object that has the same number of primitives but more constraints between them.
A superclass is an object that has the same number of primitives but fewer constraints between them.
| Nested Class Summary | |
|---|---|
class |
DomainObjectGraph.MatchIterator
An iterater for matching objects from the bottom up the graph. |
| Constructor Summary | |
|---|---|
DomainObjectGraph()
Constructs an empty graph |
|
| Method Summary | |
|---|---|
void |
addObject(DomainObjectGraphNode node)
Add an object for which all the parents have already been found and linked and that has no children // TODO - what if an object already exists |
void |
addObject(DomainObjectGraphNode addedNode,
java.util.Vector parentNames)
Add an object for finding the parents according to their names // TODO - what if an object already exists |
void |
clear()
Clear all the objects |
DomainObjectGraphNode |
getObject(java.lang.String name)
Get an object node with a given name |
boolean |
isEmpty()
Returns true if there are no objects in the graph |
DomainObjectGraph.MatchIterator |
matchIterator(DomainObjectGraph graph)
Return the match iterator for this graph |
java.util.Vector |
objectList()
Return a list of all object descriptions in the in level order |
void |
printNames(java.io.PrintStream out)
Print the names of the objects in level order not showing the graph structure |
void |
removeObject(DomainObjectGraphNode removedNode)
Remove a given object. |
void |
removeObject(java.lang.String name)
Remove an object with a given name. |
int |
size()
The number of objects in the graph |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public DomainObjectGraph()
| Method Detail |
|---|
public boolean isEmpty()
public int size()
public void clear()
public java.util.Vector objectList()
public DomainObjectGraphNode getObject(java.lang.String name)
throws ObjectNotFoundException
ObjectNotFoundException
public void addObject(DomainObjectGraphNode node)
throws InvalidParameterException
InvalidParameterException
public void addObject(DomainObjectGraphNode addedNode,
java.util.Vector parentNames)
public void removeObject(java.lang.String name)
public void removeObject(DomainObjectGraphNode removedNode)
public void printNames(java.io.PrintStream out)
public DomainObjectGraph.MatchIterator matchIterator(DomainObjectGraph graph)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||