Algernon Software

org.algernon.app.j2p
Class J2PSlot

java.lang.Object
  extended byjavax.swing.tree.DefaultMutableTreeNode
      extended byorg.algernon.app.j2p.J2PFrame
          extended byorg.algernon.app.j2p.J2PSlot
All Implemented Interfaces:
Cloneable, MutableTreeNode, Serializable, TreeNode

public class J2PSlot
extends J2PFrame

J2PSlot stores a slot definition for Java2Protege

See Also:
Serialized Form

Nested Class Summary
 
Nested classes inherited from class javax.swing.tree.DefaultMutableTreeNode
 
Field Summary
private  String f_cardinality
           
private  String f_domain
           
private  String f_javaAddMethod
           
private  String f_javaGetMethod
           
private  String f_javaSetMethod
           
private  String f_range
           
 
Fields inherited from class org.algernon.app.j2p.J2PFrame
CHILD_ERROR_COLOR, ERROR_COLOR, MAX_NAME_LENGTH
 
Fields inherited from class javax.swing.tree.DefaultMutableTreeNode
allowsChildren, children, EMPTY_ENUMERATION, parent, userObject
 
Constructor Summary
J2PSlot(String name, String originalName)
           
 
Method Summary
 Enumeration children()
          Returns an enumeration of the children of this class.
 String getCardinality()
           
 String getDomain()
          Gets the domain.
 String getJavaAddMethod()
          Stores the original method name so other programs can know the mapping from method to slot name.
 String getJavaGetMethod()
          Stores the original method name so other programs can know the mapping from method to slot name.
 String getJavaSetMethod()
          Stores the original method name so other programs can know the mapping from method to slot name.
 String getRange()
          Returns the range.
 void setCardinality(String cardinality)
           
 void setDomain(String domain)
          Sets the domain.
 void setJavaAddMethod(String methodName)
          Stores the original method name so other programs can know the mapping from method to slot name.
 void setJavaGetMethod(String methodName)
          Stores the original method name so other programs can know the mapping from method to slot name.
 void setJavaSetMethod(String methodName)
          Stores the original method name so other programs can know the mapping from method to slot name.
 void setRange(String range)
           
 Object[] toArray()
          Returns an array of information about the slot.
 
Methods inherited from class org.algernon.app.j2p.J2PFrame
childHasError, getAllowsChildren, getChildAt, getChildCount, getError, getIndex, getName, getOriginalName, getParent, hasError, isIgnored, isLeaf, setError, setIsIgnored, setName, setOriginalName, toString
 
Methods inherited from class javax.swing.tree.DefaultMutableTreeNode
add, breadthFirstEnumeration, clone, depthFirstEnumeration, getChildAfter, getChildBefore, getDepth, getFirstChild, getFirstLeaf, getLastChild, getLastLeaf, getLeafCount, getLevel, getNextLeaf, getNextNode, getNextSibling, getPath, getPathToRoot, getPreviousLeaf, getPreviousNode, getPreviousSibling, getRoot, getSharedAncestor, getSiblingCount, getUserObject, getUserObjectPath, insert, isNodeAncestor, isNodeChild, isNodeDescendant, isNodeRelated, isNodeSibling, isRoot, pathFromAncestorEnumeration, postorderEnumeration, preorderEnumeration, remove, remove, removeAllChildren, removeFromParent, setAllowsChildren, setParent, setUserObject
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

f_domain

private String f_domain

f_range

private String f_range

f_cardinality

private String f_cardinality

f_javaAddMethod

private String f_javaAddMethod

f_javaGetMethod

private String f_javaGetMethod

f_javaSetMethod

private String f_javaSetMethod
Constructor Detail

J2PSlot

public J2PSlot(String name,
               String originalName)
Method Detail

getCardinality

public String getCardinality()

setCardinality

public void setCardinality(String cardinality)

getDomain

public String getDomain()
Gets the domain. Returns null if the domain has not been set.


setDomain

public void setDomain(String domain)
Sets the domain.


getRange

public String getRange()
Returns the range. Will return null if it hasn't been set.

Returns:
The range as a string.

setRange

public void setRange(String range)

setJavaGetMethod

public void setJavaGetMethod(String methodName)
Stores the original method name so other programs can know the mapping from method to slot name.


setJavaSetMethod

public void setJavaSetMethod(String methodName)
Stores the original method name so other programs can know the mapping from method to slot name.


setJavaAddMethod

public void setJavaAddMethod(String methodName)
Stores the original method name so other programs can know the mapping from method to slot name.


getJavaGetMethod

public String getJavaGetMethod()
Stores the original method name so other programs can know the mapping from method to slot name.


getJavaSetMethod

public String getJavaSetMethod()
Stores the original method name so other programs can know the mapping from method to slot name.


getJavaAddMethod

public String getJavaAddMethod()
Stores the original method name so other programs can know the mapping from method to slot name.


children

public Enumeration children()
Returns an enumeration of the children of this class. Since there are no children of a slot, this returns an enumeration over the empty list.

Specified by:
children in interface TreeNode
Specified by:
children in class J2PFrame
Returns:
an Enumeration of this node's children

toArray

public Object[] toArray()
Returns an array of information about the slot.


Algernon Software