gov.sandia.ccaffeine.dc.user_iface.MVC.event
Class ComponentPropertiesEvent

java.lang.Object
  extended by java.util.EventObject
      extended by gov.sandia.ccaffeine.dc.user_iface.MVC.event.ComponentPropertiesEvent
All Implemented Interfaces:
java.io.Serializable

public class ComponentPropertiesEvent
extends java.util.EventObject

Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property.

A view entity might respond by either displaying the current value of one or more component properties or by setting the value of one component properties.

An example of a component property is "name" of component, the component's "key" value, and "value" of the component.

See Also:
Serialized Form

Field Summary
protected  java.lang.String componentInstanceName
          The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number.
protected  int numberOfArguments
           
protected  java.lang.String propertyName
           
protected  java.lang.String propertyValue
           
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
ComponentPropertiesEvent(java.lang.Object source, int numberOfArguments, java.lang.String componentInstanceName)
          Used to notify components that an entity wants to either retrieve the values of all the properties that are contained inside of a component.
ComponentPropertiesEvent(java.lang.Object source, int numberOfArguments, java.lang.String componentInstanceName, java.lang.String propertyName)
          Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property.
ComponentPropertiesEvent(java.lang.Object source, int numberOfArguments, java.lang.String componentInstanceName, java.lang.String propertyName, java.lang.String propertyValue)
          Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property.
ComponentPropertiesEvent(java.lang.Object source, java.lang.String componentInstanceName)
          Used to notify components that an entity wants to either retrieve the values of all the properties that are contained inside of a component.
ComponentPropertiesEvent(java.lang.Object source, java.lang.String componentInstanceName, java.lang.String propertyName)
          Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property.
 
Method Summary
 java.lang.String getComponentInstanceName()
          Get the name of the cca component that contains the property.
 int getNumberOfArguments()
          Get the number of arguments in the "properties" command.
 java.lang.String getPropertyName()
          If we are getting or setting the value of a specific property then we need the name of the property.
 java.lang.String getPropertyValue()
          If we are setting the value of a property then we need the new value.
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

numberOfArguments

protected int numberOfArguments

componentInstanceName

protected java.lang.String componentInstanceName
The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"


propertyName

protected java.lang.String propertyName

propertyValue

protected java.lang.String propertyValue
Constructor Detail

ComponentPropertiesEvent

public ComponentPropertiesEvent(java.lang.Object source,
                                java.lang.String componentInstanceName)
Used to notify components that an entity wants to either retrieve the values of all the properties that are contained inside of a component. A view entity might respond by displaying the current values of the component properties.

Parameters:
source - The entity that created this event.
componentInstanceName - The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"

ComponentPropertiesEvent

public ComponentPropertiesEvent(java.lang.Object source,
                                int numberOfArguments,
                                java.lang.String componentInstanceName)
Used to notify components that an entity wants to either retrieve the values of all the properties that are contained inside of a component. A view entity might respond by displaying the current values of the component properties.

Parameters:
source - The entity that created this event.
numberOfArguments - The number of arguments in the "properties" command.
componentInstanceName - The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"

ComponentPropertiesEvent

public ComponentPropertiesEvent(java.lang.Object source,
                                java.lang.String componentInstanceName,
                                java.lang.String propertyName)
Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property. A view entity might respond by either displaying the current value of a component property or by setting the value of a component property.

Parameters:
source - The entity that created this event.
componentInstanceName - The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"
propertyName - If we want to get or set the value of a specific port property, then we need the name of the property.

ComponentPropertiesEvent

public ComponentPropertiesEvent(java.lang.Object source,
                                int numberOfArguments,
                                java.lang.String componentInstanceName,
                                java.lang.String propertyName)
Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property. A view entity might respond by either displaying the current value of a component property or by setting the value of a component property.

Parameters:
source - The entity that created this event.
numberOfArguments - The number of arguments in the "properties" command.
componentInstanceName - The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"
propertyName - If we want to get or set the value of a specific component property, then we need the name of the property.

ComponentPropertiesEvent

public ComponentPropertiesEvent(java.lang.Object source,
                                int numberOfArguments,
                                java.lang.String componentInstanceName,
                                java.lang.String propertyName,
                                java.lang.String propertyValue)
Used to notify components that an entity wants to either retrieve the value of a component property or wants to set the value of a component property. A view entity might respond by either displaying the current value of a component property or by setting the value of a component property.

An example of a component property is "name" of component, the component's "key" value, and "value" of the component.

Parameters:
source - The entity that created this event.
numberOfArguments - The number of arguments in the "properties" command.
componentInstanceName - The name of the component that contains the property The name is usually the java class name of the component (without the package name) concatenated with an index number. Example: "StartComponent0"
propertyName - If we want to get or set the value of a specific component property, then we need the name of the property.
propertyValue - If we are setting the value of a specific component property, then we need the value of the property.
Method Detail

getNumberOfArguments

public int getNumberOfArguments()
Get the number of arguments in the "properties" command.


getComponentInstanceName

public java.lang.String getComponentInstanceName()
Get the name of the cca component that contains the property.

Returns:
the name of the compoonent that contains the property.

getPropertyName

public java.lang.String getPropertyName()
If we are getting or setting the value of a specific property then we need the name of the property.

Returns:
The name of the property.

getPropertyValue

public java.lang.String getPropertyValue()
If we are setting the value of a property then we need the new value.

Returns:
The value of the property.