Package org.apache.cxf.databinding
Interface DataWriter<T>
- 
- Type Parameters:
- T- The type of sink. Each data binding defines the set of sink types that it supports.
 - All Known Implementing Classes:
- NodeDataWriter,- StaxDataBinding.XMLStreamDataWriter,- XMLStreamDataWriter
 
 public interface DataWriter<T>The 'write' side of the data binding abstraction of CXF. A DataWriter<T> serializes objects to a 'sink' of type T.
- 
- 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description voidsetAttachments(Collection<Attachment> attachments)Attach a collection of attachments to this writer.voidsetProperty(String key, Object value)Set a property for the writer.voidsetSchema(Schema s)Attach a schema to the writer.voidwrite(Object obj, MessagePartInfo part, T output)Write an object to an output sink, including extra processing based on the WSDL service model for a particular message part.voidwrite(Object obj, T output)Write an object to an output sink.
 
- 
- 
- 
Field Detail- 
ENDPOINTstatic final String ENDPOINT 
 
- 
 - 
Method Detail- 
setSchemavoid setSchema(Schema s) Attach a schema to the writer. If the binding supports validation, it will validate the XML that it produces (assuming that it produces XML).- Parameters:
- s- the schema.
 
 - 
setAttachmentsvoid setAttachments(Collection<Attachment> attachments) Attach a collection of attachments to this writer.- Parameters:
- attachments-
 
 - 
setPropertyvoid setProperty(String key, Object value) Set a property for the writer.- Parameters:
- key- property key
- value- property value.
 
 - 
writevoid write(Object obj, T output) Write an object to an output sink.- Parameters:
- obj- the object to write.
- output- the output sink.
 
 - 
writevoid write(Object obj, MessagePartInfo part, T output) Write an object to an output sink, including extra processing based on the WSDL service model for a particular message part.- Parameters:
- obj- The object to write.
- part- the message part.
- output- the output sink.
 
 
- 
 
-