Package com.cosylab.vdct.vdb
Class VDBTemplate
- java.lang.Object
-
- com.cosylab.vdct.vdb.VDBTemplate
-
- All Implemented Interfaces:
Descriptable,Inspectable,Commentable,MonitoredPropertyListener
public class VDBTemplate extends Object implements Inspectable, Commentable, Descriptable, MonitoredPropertyListener
Data object representing EPICS DB template. All data is obtained from DB file.Groupcontains template structure.- Author:
- Matej
-
-
Field Summary
Fields Modifier and Type Field Description protected Stringdescriptionprotected StringfileNameprotected Groupgroupprotected Stringidprotected Stringiocprotected Hashtablemacrosprotected VectormacrosVprotected longmodificationTimeprotected Hashtableportsprotected VectorportsVprotected static Randomrandomprotected Stringversion
-
Constructor Summary
Constructors Constructor Description VDBTemplate(String id, String fileName)Constructor for VDBTemplate.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description VDBMacroaddMacro()voidaddMacro(VDBMacro vdbMacro)VDBMacroaddMacro(String name)VDBPortaddPort()voidaddPort(VDBPort vdbPort)VDBPortaddPort(String name)voidaddProperty()StringgetComment()Returns the comment.InspectablePropertygetCommentProperty()StringgetDescription()Returns the description.ObjectgetDsId()StringgetFileName()Returns the fileName.GroupgetGroup()Returns the group.IcongetIcon()Insert the method's description here.StringgetId()Returns the id.StringgetIoc()HashtablegetMacros()Returns the macros.longgetMacrosGeneratedID()Returns the macrosGeneratedID.static GUISeparatorgetMacrosSeparator()Insert the method's description here.VectorgetMacrosV()Returns the macrosV.ArrayListgetModeNames()Obtains list of all mode names for this particular property.longgetModificationTime()StringgetName()Insert the method's description here.HashtablegetPorts()Returns the ports.longgetPortsGeneratedID()Returns the portsGeneratedID.static GUISeparatorgetPortsSeparator()Insert the method's description here.VectorgetPortsV()Returns the portsV.InspectableProperty[]getProperties(int mode, boolean spreadsheet)StringgetRealDescription()Returns the description.static GUISeparatorgetTemplateSeparator()Insert the method's description here.StringgetVersion()voidpropertyChanged(InspectableProperty property)voidremoveMacro(VDBMacro macro)voidremoveMacro(String name)voidremovePort(VDBPort port)voidremovePort(String name)voidremoveProperty(InspectableProperty property)voidrenameMacro(VDBMacro macro, String newName)voidrenameMacroProperty(InspectableProperty property)voidrenamePort(VDBPort port, String newName)voidrenamePortProperty(InspectableProperty property)voidrenameProperty(InspectableProperty property)voidsetComment(String comment)Sets the comment.voidsetDescription(String description)Sets the description.voidsetFileName(String fileName)Sets the fileName.voidsetGroup(Group group)Sets the group.voidsetId(Object dsId, String id)Sets the id.voidsetIoc(String ioc)voidsetMacros(Hashtable macros)Sets the macros.voidsetMacrosV(Vector macrosV)Sets the macrosV.voidsetModificationTime(long modificationTime)voidsetPorts(Hashtable ports)Sets the ports.voidsetPortsV(Vector portsV)Sets the portsV.voidsetVersion(String version)StringtoString()Insert the method's description here.
-
-
-
Field Detail
-
id
protected String id
-
fileName
protected String fileName
-
description
protected String description
-
modificationTime
protected long modificationTime
-
version
protected String version
-
ioc
protected String ioc
-
ports
protected Hashtable ports
-
portsV
protected Vector portsV
-
macros
protected Hashtable macros
-
macrosV
protected Vector macrosV
-
group
protected Group group
-
random
protected static Random random
-
-
Method Detail
-
getDescription
public String getDescription()
Returns the description.- Specified by:
getDescriptionin interfaceDescriptable- Returns:
- String
-
getRealDescription
public String getRealDescription()
Returns the description.- Returns:
- String
-
getGroup
public Group getGroup()
Returns the group.- Returns:
- Group
-
setDescription
public void setDescription(String description)
Sets the description.- Specified by:
setDescriptionin interfaceDescriptable- Parameters:
description- The description to set
-
setGroup
public void setGroup(Group group)
Sets the group.- Parameters:
group- The group to set
-
getFileName
public String getFileName()
Returns the fileName.- Returns:
- String
-
getId
public String getId()
Returns the id.- Returns:
- String
-
getModificationTime
public long getModificationTime()
- Returns:
- the modificationTime
-
setModificationTime
public void setModificationTime(long modificationTime)
- Parameters:
modificationTime- the modificationTime to set
-
getCommentProperty
public InspectableProperty getCommentProperty()
- Specified by:
getCommentPropertyin interfaceInspectable- Returns:
- com.cosylab.vdct.inspector.InspectableProperty
- See Also:
Inspectable.getCommentProperty()
-
getIcon
public Icon getIcon()
Description copied from interface:InspectableInsert the method's description here. Creation date: (10.1.2001 15:14:56)- Specified by:
getIconin interfaceInspectable- Returns:
- javax.swing.Icon
- See Also:
Inspectable.getIcon()
-
getModeNames
public ArrayList getModeNames()
Description copied from interface:InspectableObtains list of all mode names for this particular property. Modes are numbered from 0-n. Creation date: (11.1.2001 21:30:04)- Specified by:
getModeNamesin interfaceInspectable- Returns:
- java.util.ArrayList array of mode names - obtained using toString().
- See Also:
Inspectable.getModeNames()
-
getName
public String getName()
Description copied from interface:InspectableInsert the method's description here. Creation date: (10.1.2001 14:47:43)- Specified by:
getNamein interfaceCommentable- Specified by:
getNamein interfaceInspectable- Returns:
- java.lang.String
- See Also:
Inspectable.getName()
-
getTemplateSeparator
public static GUISeparator getTemplateSeparator()
Insert the method's description here. Creation date: (3.2.2001 13:07:04)- Returns:
- com.cosylab.vdct.vdb.GUISeparator
-
getProperties
public InspectableProperty[] getProperties(int mode, boolean spreadsheet)
- Specified by:
getPropertiesin interfaceInspectable- Parameters:
mode- modespreadsheet- spreadsheet- Returns:
- com.cosylab.vdct.inspector.InspectableProperty[]
- See Also:
Inspectable.getProperties(int, boolean spreadsheet)
-
toString
public String toString()
Insert the method's description here. Creation date: (10.1.2001 14:49:50)- Specified by:
toStringin interfaceInspectable- Overrides:
toStringin classObject- Returns:
- java.lang.String
-
getComment
public String getComment()
Returns the comment.- Specified by:
getCommentin interfaceCommentable- Returns:
- String
-
setComment
public void setComment(String comment)
Sets the comment.- Specified by:
setCommentin interfaceCommentable- Parameters:
comment- The comment to set
-
getPorts
public Hashtable getPorts()
Returns the ports.- Returns:
- Hashtable
-
getPortsV
public Vector getPortsV()
Returns the portsV.- Returns:
- Vector
-
getMacros
public Hashtable getMacros()
Returns the macros.- Returns:
- Hashtable
-
getMacrosV
public Vector getMacrosV()
Returns the macrosV.- Returns:
- Vector
-
setPorts
public void setPorts(Hashtable ports)
Sets the ports.- Parameters:
ports- The ports to set
-
setPortsV
public void setPortsV(Vector portsV)
Sets the portsV.- Parameters:
portsV- The portsV to set
-
setMacros
public void setMacros(Hashtable macros)
Sets the macros.- Parameters:
macros- The macros to set
-
setMacrosV
public void setMacrosV(Vector macrosV)
Sets the macrosV.- Parameters:
macrosV- The macrosV to set
-
getPortsSeparator
public static GUISeparator getPortsSeparator()
Insert the method's description here. Creation date: (3.2.2001 13:07:04)- Returns:
- com.cosylab.vdct.vdb.GUISeparator
-
getMacrosSeparator
public static GUISeparator getMacrosSeparator()
Insert the method's description here. Creation date: (3.2.2001 13:07:04)- Returns:
- com.cosylab.vdct.vdb.GUISeparator
-
addPort
public void addPort(VDBPort vdbPort)
- Parameters:
vdbPort- vdbPort
-
addMacro
public void addMacro(VDBMacro vdbMacro)
- Parameters:
vdbMacro- vdbMacro
-
removePort
public void removePort(String name)
- Parameters:
name- name
-
removeMacro
public void removeMacro(String name)
- Parameters:
name- name
-
removePort
public void removePort(VDBPort port)
- Parameters:
port- port
-
removeMacro
public void removeMacro(VDBMacro macro)
- Parameters:
macro- macro
-
renamePort
public void renamePort(VDBPort port, String newName)
- Parameters:
port- portnewName- newName
-
renameMacro
public void renameMacro(VDBMacro macro, String newName)
- Parameters:
macro- macronewName- newName
-
addProperty
public void addProperty()
- Specified by:
addPropertyin interfaceMonitoredPropertyListener- See Also:
MonitoredPropertyListener.addProperty()
-
addPort
public VDBPort addPort()
- Returns:
- something
-
addMacro
public VDBMacro addMacro()
- Returns:
- something
-
propertyChanged
public void propertyChanged(InspectableProperty property)
- Specified by:
propertyChangedin interfaceMonitoredPropertyListener- Parameters:
property- property- See Also:
MonitoredPropertyListener.propertyChanged(InspectableProperty)
-
removeProperty
public void removeProperty(InspectableProperty property)
- Specified by:
removePropertyin interfaceMonitoredPropertyListener- Parameters:
property- property- See Also:
MonitoredPropertyListener.removeProperty(InspectableProperty)
-
renameProperty
public void renameProperty(InspectableProperty property)
- Specified by:
renamePropertyin interfaceMonitoredPropertyListener- Parameters:
property- property- See Also:
MonitoredPropertyListener.renameProperty(InspectableProperty)
-
renamePortProperty
public void renamePortProperty(InspectableProperty property)
- Parameters:
property- property- See Also:
MonitoredPropertyListener.renameProperty(InspectableProperty)
-
renameMacroProperty
public void renameMacroProperty(InspectableProperty property)
- Parameters:
property- property- See Also:
MonitoredPropertyListener.renameProperty(InspectableProperty)
-
setFileName
public void setFileName(String fileName)
Sets the fileName.- Parameters:
fileName- The fileName to set
-
setId
public void setId(Object dsId, String id)
Sets the id.- Parameters:
dsId- dsIdid- The id to set
-
getPortsGeneratedID
public long getPortsGeneratedID()
Returns the portsGeneratedID.- Returns:
- long
-
getMacrosGeneratedID
public long getMacrosGeneratedID()
Returns the macrosGeneratedID.- Returns:
- long
-
getVersion
public String getVersion()
- Returns:
- something
-
setVersion
public void setVersion(String version)
- Parameters:
version- version
-
getIoc
public String getIoc()
- Returns:
- something
-
setIoc
public void setIoc(String ioc)
- Parameters:
ioc- ioc
-
getDsId
public Object getDsId()
- Specified by:
getDsIdin interfaceCommentable- Specified by:
getDsIdin interfaceInspectable- Returns:
- something
-
-