Class OptionalStructureWrapper

  • All Implemented Interfaces:
    IComponent, ILinkable

    public class OptionalStructureWrapper
    extends PassThroughComponent
    Component decorator for optional structure with associated property. This just handles necessary glue code generation for the marshalling operations, where the presence of the structure needs to be tested before actually handling tag generation.
    • Constructor Detail

      • OptionalStructureWrapper

        public OptionalStructureWrapper​(IComponent wrap,
                                        PropertyDefinition prop,
                                        boolean load)
        Constructor.
        Parameters:
        wrap - wrapped binding component
        load - flag for need to load object for marshalling code
        prop - Property Definition
    • Method Detail

      • genAttributeMarshal

        public void genAttributeMarshal​(ContextMethodBuilder mb)
                                 throws org.jibx.runtime.JiBXException
        Description copied from interface: IComponent
        Generate attribute marshalling code. This is called within the code generation for the marshaller of the class associated with the containing element. It needs to generate the necessary code for handling the marshalling operation, consuming the marshalled object reference from the stack.
        Specified by:
        genAttributeMarshal in interface IComponent
        Overrides:
        genAttributeMarshal in class PassThroughComponent
        Parameters:
        mb - method builder
        Throws:
        org.jibx.runtime.JiBXException - if error in configuration
      • genContentMarshal

        public void genContentMarshal​(ContextMethodBuilder mb)
                               throws org.jibx.runtime.JiBXException
        Description copied from interface: IComponent
        Generate element or text marshalling code. This is called within the code generation for the marshaller of the class associated with the containing element. It needs to generate the necessary code for handling the marshalling operation, consuming the marshalled object reference from the stack.
        Specified by:
        genContentMarshal in interface IComponent
        Overrides:
        genContentMarshal in class PassThroughComponent
        Parameters:
        mb - method builder
        Throws:
        org.jibx.runtime.JiBXException - if error in configuration