public class IlvExportOutputBehavior extends IlvConnectBehavior
IlvExportOutputBehavior
propagates
a value generated by
a group element to the whole group.
This class is particularly useful when you want to include a value source in a prototype because it allows you to export the values generated by the source.
Example:
Let us suppose that you define a group containing a clock value source
named clock
. To define a time
property
that will be generated when the clock generates its own values, you
have to add an IlvExportOutputBehavior
object like this:
group.addBehavior(new IlvExportOutputBehavior("time", "clock.time"));You can then connect the
time
value of your group
to an input property of another object.Constructor and Description |
---|
IlvExportOutputBehavior(IlvExportOutputBehavior source)
Creates a new behavior object by copying an existing one.
|
IlvExportOutputBehavior(IlvInputStream in)
Reads the behavior from an
IlvInputStream stream. |
IlvExportOutputBehavior(String name,
String outputProperty)
Creates a new export output behavior object.
|
Modifier and Type | Method and Description |
---|---|
IlvBehavior |
copy()
Returns a copy of the behavior.
|
boolean |
isOutput()
Returns
true |
boolean |
isReadable()
Returns
false |
boolean |
isWritable()
Returns
false |
protected void |
set(IlvGroup group,
String name,
Object value)
Since this class is a subclass of
IlvConnectBehavior ,
this method will be called when the group element generates the output
value. |
String |
toString()
Returns a short text describing this behavior object.
|
attach, detach, getOutputProperty, setName, setOutputProperty, write
get, get, getName, getValueNames, set
getParameter
public IlvExportOutputBehavior(String name, String outputProperty)
name
- the name of the behavior object. This name is that of the
property of the group, which will be generated when the
property of the group element is generated.outputProperty
- the full name of the value handled by the group element. This name
is composed of the access path to the element and the value name, which are separated
by a dot (.
) character.public IlvExportOutputBehavior(IlvExportOutputBehavior source)
source
- The behavior object to be copied.public IlvExportOutputBehavior(IlvInputStream in) throws IlvReadFileException
IlvInputStream
stream.
This constructor must be called by the
input constructors of subclasses.in
- The input stream.IlvReadFileException
- if the stream format is not correct.public IlvBehavior copy()
copy
in class IlvConnectBehavior
public String toString()
toString
in class IlvConnectBehavior
public boolean isReadable()
false
isReadable
in class IlvConnectBehavior
public boolean isWritable()
false
isWritable
in class IlvConnectBehavior
public boolean isOutput()
true
isOutput
in class IlvBehavior
protected void set(IlvGroup group, String name, Object value) throws IlvValueException
IlvConnectBehavior
,
this method will be called when the group element generates the output
value. To generate the value, this method simply calls the pushValue
method with the name of this behavior object as its argument.set
in class IlvSingleBehavior
group
- the group to which this behavior object is attached.name
- the name of this behavior object.value
- the new value.IlvValueException
- if an error occurred while setting a property.IlvSingleBehavior.set(ilog.views.prototypes.IlvGroup,
java.lang.String[], java.lang.Object[], boolean[])
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.