public class IlvAttachmentLayout extends Object implements IlvLayoutManager
IlvAttachmentLayout
class is a flexible layout manager
that attaches graphic objects.
Each object managed by an IlvAttachmentLayout
is associated
with an instance of
IlvAttachmentConstraint
. The
constraints object specifies where a graphic objects should be located.
One particular object is identified by the constant REFERENCE
.
This object will not be moved the layout. Its attachment rectangle is used by
the other objects in their attachment locations.
IlvAttachmentConstraint
,
Serialized FormModifier and Type | Field and Description |
---|---|
static String |
ANCHOR
The anchor layout constraint
|
Constructor and Description |
---|
IlvAttachmentLayout()
Creates an
IlvAttachmentLayout instance. |
IlvAttachmentLayout(IlvInputStream stream)
Reads the object from an
IlvInputStream . |
Modifier and Type | Method and Description |
---|---|
void |
attach(IlvAttachable target)
Sets the constraints.
|
Object |
clone()
Creates a copy of this object.
|
IlvAttachable |
getAnchor()
Returns the anchor of this object.The anchor object is the
IlvAttachable instance used to attach the other elements. |
void |
layoutGroup(IlvAttachable parent)
Lays out the specified
IlvAttachable container. |
void |
removeConstraints(IlvAttachable element)
Removes the specified
IlvAttachable from the layout. |
void |
reset()
Removes all the constraints.
|
boolean |
resizeFirstChildOnly()
Returns always
true . |
void |
setAnchor(IlvAttachable anchor)
Sets the anchor.
|
void |
setConstraints(IlvAttachable element,
Object constraints)
Adds the specified
IlvAttachable to the layout, using the
specified constraint object. |
void |
write(IlvOutputStream stream)
Writes the attributes of a persistent object.
|
public static final String ANCHOR
public IlvAttachmentLayout()
IlvAttachmentLayout
instance.public IlvAttachmentLayout(IlvInputStream stream) throws IlvReadFileException
IlvInputStream
.stream
- The input stream.IlvReadFileException
- if the format is not correct.public void setConstraints(IlvAttachable element, Object constraints)
IlvAttachable
to the layout, using the
specified constraint object.setConstraints
in interface IlvLayoutManager
element
- the IlvAttachable
to be addedconstraints
- This must be an IlvAttachmentConstraint
instance or
the string "Anchor".setAnchor(ilog.views.graphic.composite.layout.IlvAttachable)
,
IlvAttachmentConstraint
public void removeConstraints(IlvAttachable element)
IlvAttachable
from the layout.removeConstraints
in interface IlvLayoutManager
element
- the IlvAttachable>/code> object to be removed.
public void layoutGroup(IlvAttachable parent)
IlvAttachable
container.layoutGroup
in interface IlvLayoutManager
parent
- the container to be laid outpublic void attach(IlvAttachable target)
attach
in interface IlvLayoutManager
target
- the container to be laid outIlvAttachable.getAttachables()
,
IlvAttachable.getConstraints()
public void setAnchor(IlvAttachable anchor)
IlvAttachable
instance used to attach the other elements.public IlvAttachable getAnchor()
IlvAttachable
instance used to attach the other elements.public void reset()
reset
in interface IlvLayoutManager
public Object clone()
clone
in interface IlvLayoutManager
clone
in class Object
public boolean resizeFirstChildOnly()
true
.resizeFirstChildOnly
in interface IlvLayoutManager
public void write(IlvOutputStream stream) throws IOException
write
in interface IlvPersistentObject
stream
- the output streamIOException
- thrown when an exception occurs during the write operation for
this object.© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.