public class OdfOfficeAutomaticStyles extends OfficeAutomaticStylesElement
ELEMENT_NAME
mPackageDocument
localName, namespaceURI
attributes, name
firstChild, fNodeListCache, ownerDocument
nextSibling, previousSibling
DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_IS_CONTAINED, DOCUMENT_POSITION_PRECEDING, ELEMENT_DEFINITION_NODE, FIRSTCHILD, flags, HASSTRING, ID, IGNORABLEWS, NORMALIZED, OWNED, ownerNode, READONLY, SPECIFIED, SYNCCHILDREN, SYNCDATA, TREE_POSITION_ANCESTOR, TREE_POSITION_DESCENDANT, TREE_POSITION_DISCONNECTED, TREE_POSITION_EQUIVALENT, TREE_POSITION_FOLLOWING, TREE_POSITION_PRECEDING, TREE_POSITION_SAME_NODE
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
DERIVATION_EXTENSION, DERIVATION_LIST, DERIVATION_RESTRICTION, DERIVATION_UNION
Constructor and Description |
---|
OdfOfficeAutomaticStyles(OdfFileDom ownerDoc) |
Modifier and Type | Method and Description |
---|---|
Iterable<OdfStyle> |
getAllStyles()
Returns an iterator for all
OdfStyleStyle elements. |
NumberBooleanStyleElement |
getBooleanStyle(String name)
Returns the
NumberBooleanStyleElement element with the given name. |
Iterable<NumberBooleanStyleElement> |
getBooleanStyles()
Returns an iterator for all
OdfNumberBooleanStyle elements. |
OdfNumberCurrencyStyle |
getCurrencyStyle(String name)
Returns the
OdfNumberCurrencyStyle element with the given name. |
Iterable<OdfNumberCurrencyStyle> |
getCurrencyStyles()
Returns an iterator for all
OdfNumberCurrencyStyle elements. |
OdfNumberDateStyle |
getDateStyle(String name)
Returns the
OdfNumberDateStyle element with the given name. |
Iterable<OdfNumberDateStyle> |
getDateStyles()
Returns an iterator for all
OdfNumberDateStyle elements. |
OdfTextListStyle |
getListStyle(String name)
Returns the
OdfTextListStyle element with the given name. |
Iterable<OdfTextListStyle> |
getListStyles()
Returns an iterator for all
OdfTextListStyle elements. |
OdfNumberStyle |
getNumberStyle(String name)
Returns the
OdfNumberNumberStyle element with the given name. |
Iterable<OdfNumberStyle> |
getNumberStyles()
Returns an iterator for all
OdfNumberNumberStyle elements. |
OdfStylePageLayout |
getPageLayout(String name)
Returns the
OdfStylePageLayout element with the given name. |
OdfNumberPercentageStyle |
getPercentageStyle(String name)
Returns the
OdfNumberPercentageStyle element with the given name. |
Iterable<OdfNumberPercentageStyle> |
getPercentageStyles()
Returns an iterator for all
OdfNumberPercentageStyle elements. |
OdfStyle |
getStyle(String name,
OdfStyleFamily familyType)
Returns the
OdfStyleStyle element with the given name and family. |
Iterable<OdfStyle> |
getStylesForFamily(OdfStyleFamily familyType)
Returns an iterator for all
OdfStyleStyle elements for the given family. |
NumberTextStyleElement |
getTextStyle(String name)
Returns the
NumberTextStyleElement element with the given name. |
Iterable<NumberTextStyleElement> |
getTextStyles()
Returns an iterator for all
NumberTextStyleElement elements. |
OdfNumberTimeStyle |
getTimeStyle(String name)
Returns the
OdfNumberTimeStyle element with the given name. |
Iterable<OdfNumberTimeStyle> |
getTimeStyles()
Returns an iterator for all
OdfNumberTimeStyle elements. |
OdfStyle |
makeStyleUnique(OdfStyle referenceStyle)
This method makes the style unique
|
OdfTextListStyle |
newListStyle()
Create an
OdfTextListStyle element |
OdfStyle |
newStyle(OdfStyleFamily styleFamily)
Create an
OdfStyle element with style family |
protected void |
onOdfNodeInserted(OdfElement node,
Node refNode)
override this method to get notified about element insertion
|
protected void |
onOdfNodeRemoved(OdfElement node)
override this method to get notified about element insertion
|
void |
optimize()
This methods removes all automatic styles that are currently not used by
any styleable element.
|
accept, getOdfName, newNumberBooleanStyleElement, newNumberCurrencyStyleElement, newNumberDateStyleElement, newNumberNumberStyleElement, newNumberPercentageStyleElement, newNumberTextStyleElement, newNumberTimeStyleElement, newStylePageLayoutElement, newStyleStyleElement, newTextListStyleElement
insertBefore, removeChild, replaceChild
cloneNode, equals, findFirstChildNode, findNextChildNode, findPreviousChildNode, getAncestorAs, getOdfAttribute, getOdfAttribute, getOdfAttributeValue, getParentAs, hasOdfAttribute, onInsertNode, onInsertNode, onRemoveNode, onRemoveNode, setOdfAttribute, setOdfAttributeValue, toString
getBaseURI, getLocalName, getNamespaceURI, getPrefix, getTypeName, getTypeNamespace, isDerivedFrom, setPrefix, setType, setValues
getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getAttributes, getDefaultAttributes, getElementsByTagName, getElementsByTagNameNS, getNodeName, getNodeType, getSchemaTypeInfo, getTagName, getXercesAttribute, hasAttribute, hasAttributeNS, hasAttributes, isEqualNode, normalize, reconcileDefaultAttributes, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setOwnerDocument, setReadOnly, setupDefaultAttributes, setXercesAttributeNode, synchronizeData
getChildNodes, getChildNodesUnoptimized, getFirstChild, getLastChild, getLength, getOwnerDocument, getTextContent, hasChildNodes, item, setTextContent, synchronizeChildren
getNextSibling, getParentNode, getPreviousSibling
addEventListener, appendChild, changed, changes, compareDocumentPosition, compareTreePosition, dispatchEvent, getContainer, getFeature, getNodeNumber, getNodeValue, getReadOnly, getUserData, getUserData, getUserDataRecord, isDefaultNamespace, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, needsSyncChildren, removeEventListener, setNodeValue, setUserData, setUserData
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
appendChild, compareDocumentPosition, getChildNodes, getFeature, getFirstChild, getLastChild, getNextSibling, getNodeValue, getOwnerDocument, getParentNode, getPreviousSibling, getTextContent, getUserData, hasChildNodes, isDefaultNamespace, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, setNodeValue, setTextContent, setUserData
public OdfOfficeAutomaticStyles(OdfFileDom ownerDoc)
public OdfStyle newStyle(OdfStyleFamily styleFamily)
OdfStyle
element with style familystyleFamily
- The OdfStyleFamily
elementOdfStyle
elementpublic OdfTextListStyle newListStyle()
OdfTextListStyle
elementOdfTextListStyle
elementpublic OdfStylePageLayout getPageLayout(String name)
OdfStylePageLayout
element with the given name.name
- is the name of the page layoutpublic OdfStyle getStyle(String name, OdfStyleFamily familyType)
OdfStyleStyle
element with the given name and family.name
- is the name of the stylefamilyType
- is the family of the stylepublic Iterable<OdfStyle> getStylesForFamily(OdfStyleFamily familyType)
OdfStyleStyle
elements for the given family.familyType
- OdfStyleStyle
elements for the given familypublic Iterable<OdfStyle> getAllStyles()
OdfStyleStyle
elements.OdfStyleStyle
elementspublic OdfTextListStyle getListStyle(String name)
OdfTextListStyle
element with the given name.name
- is the name of the list stylepublic Iterable<OdfTextListStyle> getListStyles()
OdfTextListStyle
elements.OdfTextListStyle
elementspublic OdfNumberStyle getNumberStyle(String name)
OdfNumberNumberStyle
element with the given name.name
- is the name of the number stylepublic Iterable<OdfNumberStyle> getNumberStyles()
OdfNumberNumberStyle
elements.OdfNumberNumberStyle
elementspublic OdfNumberDateStyle getDateStyle(String name)
OdfNumberDateStyle
element with the given name.name
- is the name of the date stylepublic Iterable<OdfNumberDateStyle> getDateStyles()
OdfNumberDateStyle
elements.OdfNumberDateStyle
elementspublic OdfNumberPercentageStyle getPercentageStyle(String name)
OdfNumberPercentageStyle
element with the given name.name
- is the name of the percentage stylepublic Iterable<OdfNumberPercentageStyle> getPercentageStyles()
OdfNumberPercentageStyle
elements.OdfNumberPercentageStyle
elementspublic OdfNumberCurrencyStyle getCurrencyStyle(String name)
OdfNumberCurrencyStyle
element with the given name.name
- is the name of the currency stylepublic Iterable<OdfNumberCurrencyStyle> getCurrencyStyles()
OdfNumberCurrencyStyle
elements.OdfNumberCurrencyStyle
elementspublic OdfNumberTimeStyle getTimeStyle(String name)
OdfNumberTimeStyle
element with the given name.name
- is the name of the time stylepublic Iterable<OdfNumberTimeStyle> getTimeStyles()
OdfNumberTimeStyle
elements.OdfNumberTimeStyle
elementspublic NumberBooleanStyleElement getBooleanStyle(String name)
NumberBooleanStyleElement
element with the given name.name
- is the name of the boolean stylepublic Iterable<NumberBooleanStyleElement> getBooleanStyles()
OdfNumberBooleanStyle
elements.OdfNumberBooleanStyle
elementspublic NumberTextStyleElement getTextStyle(String name)
NumberTextStyleElement
element with the given name.name
- is the name of the text stylepublic Iterable<NumberTextStyleElement> getTextStyles()
NumberTextStyleElement
elements.NumberTextStyleElement
elementsprotected void onOdfNodeInserted(OdfElement node, Node refNode)
OdfContainerElementBase
onOdfNodeInserted
in class OdfContainerElementBase
protected void onOdfNodeRemoved(OdfElement node)
OdfContainerElementBase
onOdfNodeRemoved
in class OdfContainerElementBase
public void optimize()
Copyright © 2008-2013 The Apache Software Foundation. All Rights Reserved.