public class IlvPrototypeInstance extends IlvGroup
IlvPrototypeInstance
class represents the instances
(or clones) of a prototype.
An IlvPrototypeInstance
is a full copy of its prototype.
Prototype instances are able to determine the differences between the values
they handle and the original values of the prototype. This means that when a
prototype instance is saved to a file, only the differences with the original
is saved, not its full definition. If you change the definition of a
prototype, all its instances will be modified accordingly.
IlvPrototype
,
Serialized Formindeterminate
Constructor and Description |
---|
IlvPrototypeInstance(IlvInputStream in)
Reads the prototype instance from an
IlvInputStream stream. |
IlvPrototypeInstance(IlvPrototypeInstance source)
Creates a new prototype instance by copying an existing one.
|
IlvPrototypeInstance(IlvPrototype prototype,
String name)
Creates a new instance of the specified prototype.
|
Modifier and Type | Method and Description |
---|---|
IlvGroupElement |
copy()
Returns a copy of this prototype instance.
|
void |
copy(IlvGroup source)
Makes this prototype instance a copy of another prototype instance.
|
IlvPrototype |
getPrototype()
Returns the prototype of this instance.
|
void |
write(IlvOutputStream out)
Writes the prototype instance to an
IlvOutputStream . |
addBehavior, addElement, clear, findElement, getBehaviors, getElements, getGroupBag, getGroupFrame, getTopGroup, getValueNames, isABehaviorValue, isOutput, isPrivate, removeBehavior, removeElement, renameValue, setMessageWriter, setPrivate, swapBehaviors, traverse, unsubscribe
applyTransform, applyTransform, boundingBox, boundingBox, get, get, get, getBoolean, getDouble, getFloat, getInt, getLong, getName, getParent, getRelativePath, getString, getSubscribers, getSubscriptionValues, move, pushValue, pushValues, set, set, set, set, set, set, set, setName, subscribe
public IlvPrototypeInstance(IlvPrototype prototype, String name) throws IlvValueException
prototype
- the prototype to be instantiated.name
- the name of the new instance.IlvValueException
- if an error occurred while initializing the values of the new
instance.public IlvPrototypeInstance(IlvPrototypeInstance source) throws IlvValueException
source
- The object to be copied.IlvValueException
public IlvPrototypeInstance(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 void write(IlvOutputStream out) throws IOException
IlvOutputStream
.write
in interface IlvPersistentObject
write
in class IlvGroup
out
- The output stream.IOException
- if an I/O error or a value error occurred.IlvGroup.write(ilog.views.io.IlvOutputStream)
public IlvGroupElement copy() throws IlvValueException
copy
in class IlvGroup
IlvValueException
- if an error occurred while initializing the values of the new
instance.IlvGroup.copy(ilog.views.prototypes.IlvGroup)
public void copy(IlvGroup source) throws IlvValueException
copy
in class IlvGroup
source
- the source prototype instance.IlvValueException
- if an error occurred while copying the prototype.public IlvPrototype getPrototype()
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.