Interface IInstanceDefinition
- All Superinterfaces:
Serializable
- All Known Implementing Classes:
InstanceDefinition
This interface defines the methods that can be used to retrieve information about a static instance.
- Since:
- 5.0
- Author:
- O. Kerpershoek
-
Method Summary
Modifier and TypeMethodDescriptionThis method will return the definition of the type of the instance.This method returns the unique ID of the instance definition.This method will return the name of instance.getInstances
(String attribute) This method can be used to retrieve the reference definitions to determine which instances are referred by the specified attribute.This method can be used to retrieve a value of an attribute.
-
Method Details
-
getInstanceId
GUID getInstanceId()This method returns the unique ID of the instance definition.- Returns:
- the unique ID of the instance definition.
-
getInstanceName
String getInstanceName()This method will return the name of instance. The name of an instance uniquely identifies an instance within all instances of the same type.- Returns:
- The name of the instance.
-
getEntityDefinition
IEntityDefinition getEntityDefinition()This method will return the definition of the type of the instance.- Returns:
- Entity definition of the instance.
-
getValue
This method can be used to retrieve a value of an attribute. This method is only applicable for non-relation attributes. For relation attributes use the getInstances method to determine which instances are referred by the relation attribute.- Parameters:
attribute
- The name of the attribute for which the value is requested.- Returns:
- The value for the specified attribute.
- Throws:
UnknownAttributeException
- This exception is raised when the attribute name passed to this method is invalid.
-
getInstances
This method can be used to retrieve the reference definitions to determine which instances are referred by the specified attribute. When the attribute does not refer to any instance, an empty array will be returned.- Parameters:
attribute
- The name of the attribute for which the references are requested.- Returns:
- Array containing information about the instances that are referred by the specified attribute.
- Throws:
UnknownAttributeException
- This exception is raised when the attribute name passed to this method is invalid.
-