SEdit
Class ElementDesc

java.lang.Object
  extended bySEdit.ElementDesc
Direct Known Subclasses:
ArrowDesc, NodeDesc

public abstract class ElementDesc
extends Object

Abstract class of the meta-elements of the model elements.

Author:
Jacques Ferber and Olivier Gutknecht
See Also:
StructureEditor, StructureAgent

Field Summary
static int ACTIONPROPERTIES
           
 Hashtable actions
           
 String category
           
static boolean debug
           
 String elementClass
          class name for a graphic element
 String graphicClass
           
static int GRAPHICPROPERTIES
           
 String icon
          nom de l'icone dans la barre des elements a creer
static int PROPERTIES
           
 
Constructor Summary
ElementDesc()
           
ElementDesc(String n, String desc, String classname, String iconLocation)
           
 
Method Summary
 void addActionDesc(ActionDesc a)
           
 void addActionDesc(String call, String name)
           
 ActionDesc getAction(String s)
           
 Hashtable getActions()
           
 String getCategory()
           
 String getDefaultLabel()
          Get the value of defaultLabel.
 String getDescription()
          Get the value of description.
 String getElementClass()
           
 Formalism getFormalism()
          Get the value of formalism.
 String getGraphicClass()
           
 Hashtable getGraphicProperties()
          Get the value of graphicProperties.
 String getIcon()
           
 String getName()
          Get the value of name.
 Hashtable getProperties()
          Get the value of properties.
 boolean hasActions()
           
 boolean hasIcon()
           
 boolean isDefaultValue(String name, String value, int type)
          Test if a pair is a default value of the table.
 boolean isStandardDefaultValue(String name, String value, int type)
           
 SElement makeElement(Hashtable properties)
          A factory method that builds a new element according to the description
 void setActions(Hashtable v)
           
 void setCategory(String s)
           
 void setDefaultLabel(String v)
          Set the value of defaultLabel.
 void setElementClass(String s)
           
 void setFormalism(Formalism v)
          Set the value of formalism.
 void setGraphicClass(String i)
           
 void setGraphicProperties(Hashtable v)
          Set the value of graphicProperties.
 void setIcon(String location)
           
 void setName(String v)
          Set the value of name.
 void setProperties(Hashtable v)
          Set the value of properties.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

PROPERTIES

public static final int PROPERTIES
See Also:
Constant Field Values

GRAPHICPROPERTIES

public static final int GRAPHICPROPERTIES
See Also:
Constant Field Values

ACTIONPROPERTIES

public static final int ACTIONPROPERTIES
See Also:
Constant Field Values

debug

public static boolean debug

icon

public String icon
nom de l'icone dans la barre des elements a creer


elementClass

public String elementClass
class name for a graphic element


category

public String category

graphicClass

public String graphicClass

actions

public Hashtable actions
Constructor Detail

ElementDesc

public ElementDesc()

ElementDesc

public ElementDesc(String n,
                   String desc,
                   String classname,
                   String iconLocation)
Method Detail

getFormalism

public Formalism getFormalism()
Get the value of formalism.

Returns:
Value of formalism.

setFormalism

public void setFormalism(Formalism v)
Set the value of formalism.

Parameters:
v - Value to assign to formalism.

getName

public String getName()
Get the value of name.

Returns:
Value of name.

setName

public void setName(String v)
Set the value of name.

Parameters:
v - Value to assign to name.

getDefaultLabel

public String getDefaultLabel()
Get the value of defaultLabel.

Returns:
Value of defaultLabel.

setDefaultLabel

public void setDefaultLabel(String v)
Set the value of defaultLabel.

Parameters:
v - Value to assign to defaultLabel.

getDescription

public String getDescription()
Get the value of description.

Returns:
Value of description.

getGraphicClass

public String getGraphicClass()

setGraphicClass

public void setGraphicClass(String i)

getProperties

public Hashtable getProperties()
Get the value of properties.

Returns:
Value of properties.

setProperties

public void setProperties(Hashtable v)
Set the value of properties.

Parameters:
v - Value to assign to properties.

getGraphicProperties

public Hashtable getGraphicProperties()
Get the value of graphicProperties.

Returns:
Value of graphicProperties.

setGraphicProperties

public void setGraphicProperties(Hashtable v)
Set the value of graphicProperties.

Parameters:
v - Value to assign to graphicProperties.

isDefaultValue

public boolean isDefaultValue(String name,
                              String value,
                              int type)
Test if a pair is a default value of the table.

Parameters:
name - name of the key
value - value of the pair

isStandardDefaultValue

public boolean isStandardDefaultValue(String name,
                                      String value,
                                      int type)

setIcon

public void setIcon(String location)

getIcon

public String getIcon()

hasIcon

public boolean hasIcon()

getCategory

public String getCategory()

setCategory

public void setCategory(String s)

getElementClass

public String getElementClass()

setElementClass

public void setElementClass(String s)

toString

public String toString()

hasActions

public boolean hasActions()

setActions

public void setActions(Hashtable v)

getActions

public Hashtable getActions()

getAction

public ActionDesc getAction(String s)

addActionDesc

public void addActionDesc(ActionDesc a)

addActionDesc

public void addActionDesc(String call,
                          String name)

makeElement

public SElement makeElement(Hashtable properties)
A factory method that builds a new element according to the description



Copyright © J. Ferber, O. Gutknecht All Rights Reserved.