ilog.views.prototypes
Class IlvActionBehavior

java.lang.Object
  extended by ilog.views.prototypes.IlvBehavior
      extended by ilog.views.prototypes.IlvSingleBehavior
          extended by ilog.views.prototypes.IlvActionBehavior
All Implemented Interfaces:
IlvPersistentObject, Serializable

Deprecated. You should use the class IlvEventBehavior rather than this one to handle user events in a prototype.

public class IlvActionBehavior
extends IlvSingleBehavior

The class IlvActionBehavior defines an output value that is generated when an action event is fired for a specified graphic object which is part of a group.

When an IlvActionBehavior object is added to a group, it installs an action listener for a specified graphic element in the group. Once the listener has been installed, when the user clicks on the graphic element, the value defined by the IlvActionBehavior is generated.

An object interactor (usually an IlvButtonInteractor) must be installed on the graphic object to fire the action event.

See Also:
IlvEventBehavior, IlvGroup, IlvButtonInteractor, IlvManager.setObjectInteractor(ilog.views.IlvGraphic, ilog.views.IlvObjectInteractor), Serialized Form

Constructor Summary
IlvActionBehavior(IlvActionBehavior source)
          Deprecated. Creates a new behavior object by copying an existing one.
IlvActionBehavior(IlvInputStream in)
          Deprecated. Reads the behavior from an IlvInputStream stream.
IlvActionBehavior(String name, String elementName, String outputValue)
          Deprecated. Creates a new action behavior object.
IlvActionBehavior(String name, String elementName, String outputValue, int actionType)
          Deprecated. Creates a new action behavior object.
 
Method Summary
protected  void attach(IlvGroup group)
          Deprecated. Adds an action listener to the graphic element specified by the elementName parameter passed to the constructor.
 IlvBehavior copy()
          Deprecated. Returns a copy of the behavior.
protected  void detach(IlvGroup group)
          Deprecated. Removes the action listener from the graphic element specified by the elementName parameter passed to the constructor.
 int getActionType()
          Deprecated. Gets the actionType parameter for this behavior object.
 String getElementName()
          Deprecated. Returns the elementName parameter for this behavior object.
 String getOutputValue()
          Deprecated. Gets the outputValue parameter for this behavior object.
 boolean isOutput()
          Deprecated. Returns true
 boolean isReadable()
          Deprecated. Returns false
 boolean isWritable()
          Deprecated. Returns false
 void setActionType(int actionType)
          Deprecated. Sets the actionType parameter for this behavior object.
 void setElementName(String elementName)
          Deprecated. Sets the elementName parameter for this behavior object.
 void setOutputValue(String outputValue)
          Deprecated. Sets the outputValue parameter for this behavior object.
 String toString()
          Deprecated. Returns a short text describing this behavior object.
 void write(IlvOutputStream out)
          Deprecated. Writes the behavior to an IlvOutputStream.
 
Methods inherited from class ilog.views.prototypes.IlvSingleBehavior
get, get, getName, getValueNames, set, set, setName
 
Methods inherited from class ilog.views.prototypes.IlvBehavior
getParameter
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

IlvActionBehavior

public IlvActionBehavior(String name,
                         String elementName,
                         String outputValue,
                         int actionType)
Deprecated. 
Creates a new action behavior object.

Parameters:
name - the name of the property that will be generated when the action is fired.
elementName - the name of the graphic element to which an action listener will be added.
outputValue - when the action is fired, the value that is fetched and copied to the generated value. This value can be either a direct value (represented by a string), the name of another property, or an expression.
actionType - the type of action generated by the object interactor installed on the graphic element. Possible values are IlvButtonInteractor.ACTIVATE, IlvButtonInteractor.ARM, IlvButtonInteractor.DISARM, or -1 to fire an event for any action type.

IlvActionBehavior

public IlvActionBehavior(String name,
                         String elementName,
                         String outputValue)
Deprecated. 
Creates a new action behavior object. This constructor calls the first constructor with an actionType of -1, which means that the event will be fired for any action type.

Parameters:
name - the name of the property that will be generated when the action is fired.
elementName - the name of the graphic element to which an action listener will be added.
outputValue - when the action is fired, the value that is fetched and copied to the generated value. This value can be either a direct value (represented by a string), the name of another property, or an expression.

IlvActionBehavior

public IlvActionBehavior(IlvActionBehavior source)
Deprecated. 
Creates a new behavior object by copying an existing one.

Parameters:
source - the behavior object to be copied.

IlvActionBehavior

public IlvActionBehavior(IlvInputStream in)
                  throws IlvReadFileException
Deprecated. 
Reads the behavior from an IlvInputStream stream. This constructor must be called by the input constructors of subclasses.

Parameters:
in - The input stream.
Throws:
IlvReadFileException - if the stream format is not correct.
Method Detail

write

public void write(IlvOutputStream out)
           throws IOException
Deprecated. 
Writes the behavior to an IlvOutputStream.

Specified by:
write in interface IlvPersistentObject
Overrides:
write in class IlvSingleBehavior
Parameters:
out - The output stream.
Throws:
IOException - thrown when an exception occurs during the write operation for this object.

copy

public IlvBehavior copy()
Deprecated. 
Returns a copy of the behavior.

Specified by:
copy in class IlvBehavior

toString

public String toString()
Deprecated. 
Returns a short text describing this behavior object. This text can be used by GUI editors to display the behavior description.

Specified by:
toString in class IlvBehavior

isReadable

public boolean isReadable()
Deprecated. 
Returns false

Overrides:
isReadable in class IlvBehavior

isWritable

public boolean isWritable()
Deprecated. 
Returns false

Overrides:
isWritable in class IlvBehavior

isOutput

public boolean isOutput()
Deprecated. 
Returns true

Overrides:
isOutput in class IlvBehavior

attach

protected void attach(IlvGroup group)
Deprecated. 
Adds an action listener to the graphic element specified by the elementName parameter passed to the constructor.

Overrides:
attach in class IlvBehavior
Parameters:
group - the group to which this behavior object is attached.
See Also:
IlvGroup.addBehavior(ilog.views.prototypes.IlvBehavior)

detach

protected void detach(IlvGroup group)
Deprecated. 
Removes the action listener from the graphic element specified by the elementName parameter passed to the constructor.

Overrides:
detach in class IlvBehavior
Parameters:
group - the group to which this behavior object is attached.
See Also:
IlvGroup.removeBehavior(ilog.views.prototypes.IlvBehavior)

setElementName

public void setElementName(String elementName)
Deprecated. 
Sets the elementName parameter for this behavior object.


getElementName

public String getElementName()
Deprecated. 
Returns the elementName parameter for this behavior object.


setOutputValue

public void setOutputValue(String outputValue)
Deprecated. 
Sets the outputValue parameter for this behavior object.


getOutputValue

public String getOutputValue()
Deprecated. 
Gets the outputValue parameter for this behavior object.


setActionType

public void setActionType(int actionType)
Deprecated. 
Sets the actionType parameter for this behavior object.


getActionType

public int getActionType()
Deprecated. 
Gets the actionType parameter for this behavior object.



Copyright © 1996-2007 ILOG S.A. All rights reserved.   Documentation homepage.