|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectedu.northwestern.at.utils.swing.styledtext.StyleInfo
public class StyleInfo
Style information.
This lightweight class wraps an array of StyleRun objects. It
represents saved style information from an
XTextPane.
The intent is for this class and the StyleRun class to
represent style information in a simple and efficient format which is
neutral with respect to the type of client which may need to use the
information (e.g., a Swing client vs. an HTML web client etc.), but which
is easily converted to and from the formats used by the clients.
The runs should be in non-decreasing order by starting offset. If a run intersects some other run it should either be for exactly the same range or the earlier run should completely contain the later run. That is, runs should not "overlap".
| Field Summary | |
|---|---|
StyleRun[] |
info
The array of style run information. |
(package private) static long |
serialVersionUID
Serial version UID. |
| Constructor Summary | |
|---|---|
StyleInfo()
Constructs a new empty StyleInfo object. |
|
StyleInfo(java.util.ArrayList list)
Constructs a new StyleInfo object from an arraylist of run info. |
|
| Method Summary | |
|---|---|
java.lang.Object |
clone()
Returns a copy of the style information. |
boolean |
equals(java.lang.Object obj)
Compares this style info to other style info. |
void |
readExternal(java.io.DataInputStream in)
Reads the style information from a data input stream. |
void |
readExternal(java.io.ObjectInput in)
Reads the style information on deserialization. |
java.lang.String |
toString()
Returns a string representation of the style information. |
void |
writeExternal(java.io.DataOutputStream out)
Writes the style information to a data output stream. |
void |
writeExternal(java.io.ObjectOutput out)
Writes the style information on serialization. |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
static final long serialVersionUID
public StyleRun[] info
| Constructor Detail |
|---|
public StyleInfo()
public StyleInfo(java.util.ArrayList list)
list - Array list of style run information. | Method Detail |
|---|
public java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.Objectobj - The other style info.
public void writeExternal(java.io.ObjectOutput out)
throws java.io.IOException
writeExternal in interface java.io.Externalizableout - Object output stream.
java.io.IOException
public void readExternal(java.io.ObjectInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
readExternal in interface java.io.Externalizablein - Object input stream.
java.io.IOException
java.lang.ClassNotFoundException
public void writeExternal(java.io.DataOutputStream out)
throws java.io.IOException
out - Object output stream.
java.io.IOException
public void readExternal(java.io.DataInputStream in)
throws java.io.IOException,
java.lang.ClassNotFoundException
in - Object input stream.
java.io.IOException
java.lang.ClassNotFoundException public java.lang.Object clone()
clone in class java.lang.Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||