Interface XmlFactory<T>
- Type Parameters:
- T- the object type to read/write
- All Superinterfaces:
- Service
- All Known Subinterfaces:
- ModelXmlFactory,- PluginXmlFactory,- SettingsXmlFactory,- ToolchainsXmlFactory
Generic interface to read/write objects to/from XML.
- Since:
- 4.0.0
- 
Method SummaryModifier and TypeMethodDescriptiondefault TfromXmlString(String xml) Simply parse the given xml string.default Tread(InputStream input) default Tread(InputStream input, boolean strict) default Tdefault Tdefault Tdefault Tread(XmlReaderRequest request) default StringtoXmlString(T content) Simply converts the given content to an xml string.voidwrite(XmlWriterRequest<T> request) default voidwrite(T content, OutputStream outputStream) default voiddefault void
- 
Method Details- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
read- Throws:
- XmlReaderException
 
- 
write- Throws:
- XmlWriterException
 
- 
writedefault void write(@Nonnull T content, @Nonnull OutputStream outputStream) throws XmlWriterException - Throws:
- XmlWriterException
 
- 
write- Throws:
- XmlWriterException
 
- 
write- Throws:
- XmlWriterException
 
- 
fromXmlStringSimply parse the given xml string.- Parameters:
- xml- the input xml string
- Returns:
- the parsed object
- Throws:
- XmlReaderException- if an error occurs during the parsing
- See Also:
 
- 
toXmlStringSimply converts the given content to an xml string.- Parameters:
- content- the object to convert
- Returns:
- the xml string representation
- Throws:
- XmlWriterException- if an error occurs during the transformation
- See Also:
 
 
-