|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.mindfusion.diagramming.Theme
public class Theme
Represents a set of Style
objects for different diagram item types.
Constructor Summary | |
---|---|
Theme()
Initializes a new instance of the Theme class. |
Method Summary | |
---|---|
void |
addThemeListener(ThemeListener listener)
Registers listener so that it will receive events when
the theme changes. |
void |
loadFromString(java.lang.String xml)
Loads the theme from an XML string. |
void |
loadFromXml(java.lang.String fileName)
Loads the theme from an XML file. |
void |
readExternal(java.io.ObjectInput in)
Externalizable.readExternal(java.io.ObjectInput) implementation. |
void |
registerStyle(java.lang.Class type,
Style style)
Registers the specified Style object for the items of the specified type. |
void |
removeThemeListener(ThemeListener listener)
Unregisters listener so that it will no longer
receive theme events. |
java.lang.String |
saveToString()
Loads the theme from an XML string. |
void |
saveToXml(java.lang.String fileName)
Saves the theme to an XML file. |
void |
unregisterStyle(java.lang.Class type)
Unregisters the Style object associated with the specified type. |
void |
writeExternal(java.io.ObjectOutput out)
Externalizable.writeExternal(java.io.ObjectOutput) implementation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Theme()
Theme
class.
Method Detail |
---|
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
Externalizable.writeExternal(java.io.ObjectOutput)
implementation.
writeExternal
in interface java.io.Externalizable
java.io.IOException
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
Externalizable.readExternal(java.io.ObjectInput)
implementation.
readExternal
in interface java.io.Externalizable
java.io.IOException
java.lang.ClassNotFoundException
public void saveToXml(java.lang.String fileName) throws XmlException
fileName
- The name of the file to save to.
XmlException
public java.lang.String saveToString() throws XmlException, java.io.UnsupportedEncodingException
XmlException
java.io.UnsupportedEncodingException
public void loadFromXml(java.lang.String fileName) throws XmlException, org.xml.sax.SAXException, java.io.IOException, javax.xml.transform.TransformerException
fileName
- The name of the file to load from.
XmlException
org.xml.sax.SAXException
java.io.IOException
javax.xml.transform.TransformerException
public void loadFromString(java.lang.String xml) throws XmlException, org.xml.sax.SAXException, java.io.IOException, javax.xml.transform.TransformerException
xml
- The string to load from.
XmlException
org.xml.sax.SAXException
java.io.IOException
javax.xml.transform.TransformerException
public void registerStyle(java.lang.Class type, Style style)
type
- The runtime type to register.style
- The style to associate with the specified type.
The previously associated style, if any, is discarded.public void unregisterStyle(java.lang.Class type)
type
- The runtime type to unregister.public void addThemeListener(ThemeListener listener)
listener
so that it will receive events when
the theme changes.
listener
- An object implementing the ThemeListener
interface.public void removeThemeListener(ThemeListener listener)
listener
so that it will no longer
receive theme events.
listener
- An object implementing the ThemeListener
interface.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |