java.lang.Object | ||
↳ | javax.swing.text.AbstractDocument.AbstractElement | |
↳ | javax.swing.text.AbstractDocument.BranchElement |
![]() |
Implements a composite element that contains other elements.
Warning:
Serialized objects of this class will not be compatible with
future Swing releases. The current serialization support is
appropriate for short term storage or RMI between applications running
the same version of Swing. As of 1.4, support for long term storage
of all JavaBeansTM
has been added to the java.beans
package.
Please see XMLEncoder
.
[Expand]
Inherited Fields | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() |
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Constructs a composite element that initially contains
no children.
|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Returns the children of the receiver as an
Enumeration . | |||||||||||
Returns true if the receiver allows children.
| |||||||||||
Gets a child element.
| |||||||||||
Gets the number of children for the element.
| |||||||||||
Gets the child element index closest to the given model offset.
| |||||||||||
Gets the ending offset in the model for the element.
| |||||||||||
Gets the element name.
| |||||||||||
Gets the starting offset in the model for the element.
| |||||||||||
Checks whether the element is a leaf.
| |||||||||||
Gets the child element that contains
the given model position.
| |||||||||||
Replaces content with a new set of elements.
| |||||||||||
Converts the element to a string.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() | |||||||||||
![]() |
Constructs a composite element that initially contains no children.
parent | The parent element |
---|---|
a | the attributes for the element |
Returns the children of the receiver as an
Enumeration
.
Returns true if the receiver allows children.
Gets a child element.
index | the child index, >= 0 && < getElementCount() |
---|
Gets the number of children for the element.
Gets the child element index closest to the given model offset.
offset | the offset >= 0 |
---|
Gets the ending offset in the model for the element.
NullPointerException | if this element has no children |
---|
Gets the starting offset in the model for the element.
Checks whether the element is a leaf.
Gets the child element that contains the given model position.
pos | the position >= 0 |
---|
Replaces content with a new set of elements.
offset | the starting offset >= 0 |
---|---|
length | the length to replace >= 0 |
elems | the new elements |