Package cz.vutbr.fit.layout.io
Class XMLOutputOperator
- java.lang.Object
-
- cz.vutbr.fit.layout.impl.BaseService
-
- cz.vutbr.fit.layout.impl.BaseParametrizedOperation
-
- cz.vutbr.fit.layout.impl.BaseOperator
-
- cz.vutbr.fit.layout.io.XMLOutputOperator
-
- All Implemented Interfaces:
AreaTreeOperator,ParametrizedOperation,Service
public class XMLOutputOperator extends BaseOperator
This operator serializes the area tree to an XML file.- Author:
- burgetr
-
-
Field Summary
Fields Modifier and Type Field Description protected StringfilenamePath to the output file/protected booleanproduceHeaderShould we produce the XML header?
-
Constructor Summary
Constructors Constructor Description XMLOutputOperator()XMLOutputOperator(String filename, boolean produceHeader)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidapply(AreaTree atree)voidapply(AreaTree atree, Area root)StringcolorString(String spec)Converts the CSS specification rgb(r,g,b) to #rrggbbList<Parameter>defineParams()voiddumpTo(AreaTree tree, PrintWriter out)Formats the complete tag tree to an output streamStringgetCategory()StringgetDescription()StringgetFilename()StringgetId()StringgetName()booleangetProduceHeader()voidsetFilename(String filename)voidsetProduceHeader(boolean produceHeader)-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseOperator
toString
-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseParametrizedOperation
getParam, getParams, getParamString, setParam
-
Methods inherited from class cz.vutbr.fit.layout.impl.BaseService
getServiceManager, setServiceManager
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface cz.vutbr.fit.layout.api.ParametrizedOperation
getParam, getParams, getParamString, setParam
-
Methods inherited from interface cz.vutbr.fit.layout.api.Service
setServiceManager
-
-
-
-
Field Detail
-
produceHeader
protected boolean produceHeader
Should we produce the XML header?
-
filename
protected String filename
Path to the output file/
-
-
Constructor Detail
-
XMLOutputOperator
public XMLOutputOperator()
-
XMLOutputOperator
public XMLOutputOperator(String filename, boolean produceHeader)
-
-
Method Detail
-
getId
public String getId()
-
getName
public String getName()
-
getDescription
public String getDescription()
-
getCategory
public String getCategory()
-
defineParams
public List<Parameter> defineParams()
- Overrides:
defineParamsin classBaseParametrizedOperation
-
getProduceHeader
public boolean getProduceHeader()
-
setProduceHeader
public void setProduceHeader(boolean produceHeader)
-
getFilename
public String getFilename()
-
setFilename
public void setFilename(String filename)
-
apply
public void apply(AreaTree atree)
-
dumpTo
public void dumpTo(AreaTree tree, PrintWriter out)
Formats the complete tag tree to an output stream
-
-