org.jhotdraw.samples.odg.io
Class ODGStylesReader
- java.lang.Object
-
- org.jhotdraw.samples.odg.io.ODGStylesReader
-
public class ODGStylesReader extends java.lang.ObjectODGStylesReader reads an ODG <document-styles> element, and creates a map of AttributeKey's and values.
-
-
Constructor Summary
Constructors Constructor and Description ODGStylesReader()Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description java.util.Map<AttributeKey,java.lang.Object>getAttributes(java.lang.String styleName, java.lang.String familyName)voidread(java.io.File file)Reads a <document-styles> element from the specified XML file.voidread(java.io.InputStream in)Reads a <document-styles> element from the specified input stream.voidread(IXMLElement root)Reads a <document-styles> element from the specified XML element.
-
-
-
Method Detail
-
getAttributes
public java.util.Map<AttributeKey,java.lang.Object> getAttributes(java.lang.String styleName, java.lang.String familyName)
-
read
public void read(java.io.File file) throws java.io.IOExceptionReads a <document-styles> element from the specified XML file.- Parameters:
file- A XML file with a <document> root element or with a <document-styles> root element.- Throws:
java.io.IOException
-
read
public void read(java.io.InputStream in) throws java.io.IOExceptionReads a <document-styles> element from the specified input stream.- Parameters:
in- A input stream with a <document> root element or with a <document-styles> root element.- Throws:
java.io.IOException
-
read
public void read(IXMLElement root) throws java.io.IOException
Reads a <document-styles> element from the specified XML element.- Parameters:
root- A <document> element or a <document-styles> element.- Throws:
java.io.IOException
-
-
DataMelt 3.0 © DataMelt by jWork.ORG