Custom inbound pipe: Create the pipe
To create the pipe, perform the following procedure:
- Create a new class and name it
XmlDocument
. You use the XmlDocument
class to store an xml document:
- Create a new class and name it
XmlInboundPipe
.
- Add the following namespaces:
- Change the class definition to:
- Define the pipe properties by pasting the following code:
- To deserialize the xml document into
XmlDocument
objects, add the following method:
- To convert the
XmlDocument
object into WrapperObject
, add the following method:
- To load the wrapper objects when pushing them to the publishing point, add the following method:
- To generate default mappings and definitions for the custom pipe, add the following method:
- To generate item hash when converting to wrapper object, add the following method:
First, you create the XmlDocument
class that you use to store an xml document. Then, you create the pipe class, inherit the interfaces and specify the pipe control designer. You create the control designer in Custom inbound pipe: Create the pipe control designer. You define the properties and method that you use to convert the xml string into separate documents and convert the documents to wrapper object. Finally, you define the default mappings and definitions of the pipe.