Examples with Generated Source

The examples and generated files as of xsd2cpp(XmlPlus) 0.2 .
Many examples have been ommited to avoid verbosity.
(code generator: xsd2cpp)

examples/helloWorld


examples/helloWorld/helloWorld.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
 
 <xsd:element name="msg" type="xsd:string"/>

</xsd:schema>



examples/helloWorld/valid.xml

<?xml version="1.0"?>
<msg>Hello World</msg>


examples/helloWorld/include/NoNS/msg.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __NoNS_msg_H__
#define  __NoNS_msg_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"



using namespace XPlus;

namespace NoNS {
    
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> msg;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {http://www.w3.org/2001/XMLSchema}msg
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > msg_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* msg_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> msg; 
  
} // end namespace NoNS 
    
#endif


examples/helloWorld/include/NoNS/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __NoNS_DOCUMENT_H__
#define  __NoNS_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "NoNS/msg.h"
    

using namespace XPlus;
using namespace FSM;


namespace NoNS {
    

class Document : public XMLSchema::TDocument
{
  private:
  
  
  msg_ptr _msg;
    
  AutoPtr<XsdFSM<msg_ptr> > _fsm_msg;
    
  
  // attributes, elements
  
  msg_ptr create_msg(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  msg_p element_msg();
    
    
  void initFSM();
};

} // end namespace NoNS 
    
#endif
  


examples/helloWorld/include/NoNS/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __NoNS_ALL_INCLUDE_H__
#define  __NoNS_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "NoNS/Document.h"

#include "NoNS/msg.h"    
  

using namespace XPlus;


#endif 
  


examples/helloWorld/main.cpp

#include <iostream>
#include <string>

#include "XSD/UserOps.h"
#include "NoNS/all-include.h"

void populateDocument(NoNS::Document* xsdDoc);
void updateOrConsumeDocument(NoNS::Document* xsdDoc);
    

int main (int argc, char**argv)
{
  XSD::UserOps<NoNS::Document>::UserOpsCbStruct cbStruct;
  cbStruct.cbPopulateDocument           =  populateDocument;
  cbStruct.cbUpdateOrConsumeDocument    =  updateOrConsumeDocument;
  

  XSD::UserOps<NoNS::Document> opHandle(cbStruct);
  opHandle.run(argc, argv);
}

//
// Following functions are use case templates.
// You need to put "code" in the respective contexts.
//

    

// template function to populate the Tree with values
// write code to populate the Document here
void populateDocument(NoNS::Document* xsdDoc)
{
  xsdDoc->element_msg()->stringValue("Hello World");
}

// write code to operate(update/consume/test etc.) on the Document, which is already
// populated(eg. read from an input xml file)
void updateOrConsumeDocument(NoNS::Document* xsdDoc)
{

}

  


examples/helloWorld/src/NoNS/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "NoNS/Document.h"


namespace NoNS {
    

  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(false);
    DOM::Document::elementDefaultQualified(false);
    
    if(buildTree()) 
    {
      
      DOMStringPtr nsUriPtr = NULL;   
      XsdEvent event(nsUriPtr, NULL, DOMString("msg"), XsdEvent::ELEMENT_START);
      if(this->createSample()) {
        event.cbOptions.isSampleCreate = true;
      }
      _fsm->processEventThrow(event); 
      
    }
    
  }

  void Document::initFSM()
  {
  
    _fsm_msg = new XsdFSM<msg_ptr>( Particle(NULL,  DOMString("msg"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<msg_ptr, Document, FsmCbOptions>(this, &Document::create_msg));
  
    XsdFsmBasePtr elemFsms[] = {
    _fsm_msg,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  


  /* element functions  */
  

  msg_ptr Document::create_msg(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("msg");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    msg_p node = XSD::createElementTmpl<msg, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _msg = node;
      
    return node;
  }

  
  msg_p Document::element_msg()
  {
    FSM::warnNullNode(_msg, "msg", "{http://www.w3.org/2001/XMLSchema}msg", 1);
    return _msg;
  }
    
} // end namespace NoNS 
    



examples/simplest


examples/simplest/simplest.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  targetNamespace="http://www.example.com/simplest"
  elementFormDefault="qualified"
  >

  <xsd:element name="items">
    <xsd:complexType mixed="true">
      <xsd:sequence>
        <xsd:element name="item" type="xsd:string" minOccurs="0" maxOccurs="5"/>
      </xsd:sequence>
      <xsd:attribute name="id" type="xsd:string" default="102" use="optional"/>
    </xsd:complexType>
  </xsd:element>

</xsd:schema>



examples/simplest/nsaliases.xml

<nsaliases>
  <alias uri="http://www.example.com/simplest" toUrn="urn:simplest"/>
</nsaliases>


examples/simplest/valid.xml

<?xml version="1.0"?>
<ns1:items xmlns:ns1="http://www.example.com/simplest">
  text content1
  <ns1:item>one</ns1:item>
  text content2
  <ns1:item>two</ns1:item>
</ns1:items>


examples/simplest/include/simplest/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __simplest_DOCUMENT_H__
#define  __simplest_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "simplest/items.h"
    

using namespace XPlus;
using namespace FSM;


namespace simplest{


class Document : public XMLSchema::TDocument
{
  private:
  
  
  items_ptr _items;
    
  AutoPtr<XsdFSM<items_ptr> > _fsm_items;
    
  
  // attributes, elements
  
  items_ptr create_items(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  items_p element_items();
    
    
  void initFSM();
};

} // end namespace      
    
#endif
  


examples/simplest/include/simplest/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __simplest_ALL_INCLUDE_H__
#define  __simplest_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "simplest/Document.h"

#include "simplest/items.h"    
  

using namespace XPlus;


#endif 
  


examples/simplest/include/simplest/items.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __simplest_items_H__
#define  __simplest_items_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"



using namespace XPlus;

namespace simplest{


/// The class for element {}items with following structure: 
/// \n complexType->ModelGroup-or-ModelGroupDefinition
/// Read more on structures/methods inside ...
class items : public XMLSchema::XmlElement<XMLSchema::Types::anyType>
{
  public:

    /// constructor for the element node
    items(ElementCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > item_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* item_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> item; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_string> > attr_id_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_string>* attr_id_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_string> attr_id; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(items* that);

    

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Returns the list of the element nodes
    ///  @return the list of element nodes fetched
    List<item_ptr> elements_item();

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Returns the element node at supplied index
    ///  @param idx index of the element to fetch 
    ///  @return the element node fetched
    item_p element_item_at(unsigned int idx);

        
        

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Sets the value of the element at the supplied index with the supplied value
    ///  @param idx index of the element 
    ///  @param val the value(as DOMString) to set with 
    void set_item(unsigned int idx, DOMString val);

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Returns the value of the element at the supplied index with the supplied value.
    ///  @param idx index of the element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_item_string(unsigned int idx);


          

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Adds one element to the end of the "list of the element nodes"
    ///  @return the pointer to the added element
    item_p add_node_item();

    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Sizes-up the "list of the element nodes" with the supplied size
    ///  @param size the request size(unsigned int) of the list
    ///  @return the list of "pointer-to-element-node"
    List<item_ptr> set_count_item(unsigned int size);


      
      
    ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
    ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
    ///  @param val the value(as DOMString) to set with 
    void add_item_string(DOMString val);
      
        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    items*      _that;
  }; // end sequence
  

  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Returns the list of the element nodes
  ///  @return the list of element nodes fetched
  List<item_ptr> elements_item();

  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Returns the element node at supplied index
  ///  @param idx index of the element to fetch 
  ///  @return the element node fetched
  item_p element_item_at(unsigned int idx);

  

  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Sets the value of the element at the supplied index with the supplied value
  ///  @param idx index of the element 
  ///  @param val the value(as DOMString) to set with 
  void set_item(unsigned int idx, DOMString val);

  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Returns the value of the element at the supplied index with the supplied value.
  ///  @param idx index of the element 
  ///  @return the value(as DOMString) of the element 
  DOMString get_item_string(unsigned int idx);

        

  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Adds one element to the end of the "list of the element nodes"
  ///  @return the pointer to the added element
  item_p add_node_item();
  
  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Sizes-up the "list of the element nodes" with the supplied size
  ///  @param size the request size(unsigned int) of the list
  ///  @return the list of "pointer-to-element-node"
  List<item_ptr> set_count_item(unsigned int size);

      
      
  ///  For vector-element with QName "{http://www.w3.org/2001/XMLSchema}item" :
  ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
  ///  @param val the value(as DOMString) to set with 
  void add_item_string(DOMString val);
      
        

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_id_p attribute_attr_id();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_id(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_id_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  Marks the attribute as present 
  void mark_present_attr_id();

  

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  List<item_ptr> _list_item;
            
  attr_id_ptr _attr_id;
          

  /// initialize the FSM
  void initFSM();

  
  item_ptr create_item(FsmCbOptions& options);

  attr_id_ptr create_attr_id(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END



}; //end class items

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {}items
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<items > items_ptr;
  /// typedef for the Plain pointer to the node
  typedef items* items_p;
  
} // end namespace      
    
#endif


examples/simplest/main.cpp


#include <iostream>
#include <string>

extern "C" {
#include <getopt.h>
}
#include "simplest/all-include.h"

void populateDocument(simplest::Document xsdDoc);
void updateOrConsumeDocument(simplest::Document xsdDoc);
void writePopulatedDoc();
void writeSample();
void readUpdateWriteFile(string inFilePath);
void roundtripFile(string inFilePath);
void validateFile(string inFilePath);

void writePopulatedDoc()
{
  cout << "Going to populate Document and write xml file..." << endl;
  string outFile="t.xml";
  try 
  {
    simplest::Document xsdDoc(true);
    xsdDoc.prettyPrint(true);
    populateDocument(xsdDoc);
    ofstream ofs(outFile.c_str());
    ofs << xsdDoc;
    cout << "  => wrote file:" << outFile << " (using DOM Document)" 
      << endl << endl;

  }
  catch(XPlus::Exception& ex) {
    cerr << "  => write failed" << endl;
    cerr << endl << "{" << endl;
    cerr << ex.msg();
    cerr << endl << "}" << endl;
    exit(1);
  }
}

void writeSample()
{
  cout << "writeSample:" << endl;
  string outFile = "sample.xml";

  try
  {
    //write the Document back to a file
    simplest::Document xsdDoc(true, true);
    xsdDoc.prettyPrint(true);
    ofstream ofs(outFile.c_str());
    ofs << xsdDoc;
    cout << "  => wrote file:" << outFile << " (using DOM Document)" 
      << endl << endl;
  }
  catch(XPlus::Exception& ex) {
    cerr << "  => write failed" << endl;
    cerr << endl << "{" << endl;
    cerr << ex.msg();
    cerr << endl << "}" << endl;
    exit(1);
  }


}

void readUpdateWriteFile(string inFilePath)
{
  cout << "readUpdateWriteFile:" << inFilePath << endl;
  cout << "Going to: \n"
    << "  1) read input-xml-file\n"
    "  2) update the read Document with user-supplied function updateOrConsumeDocument()\n"
    "  3) write xml file..." 
    << endl << endl;
  string outFile = inFilePath+ ".row.xml";
  try 
  {
    //read the file into the Document
    ifstream is(inFilePath.c_str());
    simplest::Document xsdDoc(false);
    is >> xsdDoc; 

    xsdDoc.prettyPrint(true);
    updateOrConsumeDocument(xsdDoc);
    
    //write the Document back to a file
    ofstream ofs(outFile.c_str());
    ofs << xsdDoc;
    cout << "  => wrote file:" << outFile << " (using DOM Document)" 
    << endl << endl;
  }
  catch(XPlus::Exception& ex) {
    cerr << "  => write failed" << endl;
    cerr << endl << "{" << endl;
    cerr << ex.msg();
    cerr << endl << "}" << endl;
    exit(1);
  }
}

void roundtripFile(string inFilePath)
{
  cout << "Going to roundtrip file:" << inFilePath << endl;
  try 
  {
    //read the file into the Document
    ifstream is(inFilePath.c_str());
    simplest::Document xsdDoc(false);
    is >> xsdDoc; 

    //write the Document back to a file
    xsdDoc.prettyPrint(true);
    string outFile = inFilePath + ".rt.xml";
    ofstream ofs(outFile.c_str());
    ofs << xsdDoc;

    cout << "  => wrote file:" << outFile << " (using DOM Document)" 
      << endl << endl;
  }
  catch(XPlus::Exception& ex) {
    cerr << "Error:\n" << ex.msg() << endl;
    exit(1);
  }
}

void validateFile(string inFilePath)
{
  cout << "validating file:" << inFilePath << endl;
  // this is one way of validation:
  // when the Document is built from a xml-file, the file
  // does get validated. Any errors(exception) thrown, would
  // be reported in the catch block
  try
  {
    //read the file into the Document
    ifstream is(inFilePath.c_str());
    simplest::Document xsdDoc(false);
    is >> xsdDoc; 
  }
  catch(XPlus::Exception& ex)
  {
    ex.setContext("file", inFilePath);
    cerr << "  => validation failed" << endl;
    cerr << endl << "Error: {" << endl;
    cerr << ex.msg();
    cerr << endl << "}" << endl;
    exit(1);
  }
  catch(std::exception& ex) {
    cerr << " unknown error" << endl;
  }
  catch(...) {
    cerr << " unknown error" << endl;
  }
  cout << "  => validated successfully"
    << endl << endl;

}

void printHelp(string argv0)
{
  cout << "Usage: " << argv0 << " [options] XMLfiles ..." << endl;
  cout << "Options:" << endl;  
  cout << " -s, --sample\n"
    << "            create a schema-driven sample xml-file\n" 
    << "            Note: optional fields are omitted"
    << endl;
  cout << " -w, --write\n"
    << "            write a xml-file using populated Document\n" 
    << "            Note: populateDocument() function in main.cpp template,\n"
    << "            must be used to populate the Document"
    << endl;
  cout << " -v, --validate\n"
    << "            validate input xml-file(against compiled schema)"
    << endl;
  cout << " -r, --roundtrip\n"
    << "            roundtrip (read->write) input xml-file"
    << endl;
  cout << " -u, --row\n"
    << "         perform read->update->write operations on input xml-file"
    << endl;
  cout << " -h, --help\n"
    << "         print help"
    << endl;
  cout << endl;
}


int main (int argc, char**argv)
{
  int c;

  /* Flag set by ‘--verbose’. */
  int verbose_flag=0;
  string inFile;

  while (1)
  {
    static struct option long_options[] =
    {
      /* These options set a flag. */
      {"verbose", no_argument,       &verbose_flag, 1},
      /* These options don't set a flag.
         We distinguish them by their indices. */
      {"help",   no_argument,        0, 'h'},
      {"sample",     no_argument,       0, 's'},
      {"write",      no_argument,       0, 'w'},
      {"validate",   required_argument, 0, 'v'},
      {"roundtrip",  required_argument, 0, 'r'},
      {"row",        required_argument, 0, 'u'},
      {0, 0, 0, 0}
    };
    /* getopt_long stores the option index here. */
    int option_index = 0;

    c = getopt_long (argc, argv, "hr:su:v:w",
        long_options, &option_index);

    /* Detect the end of the options. */
    if (c == -1)
      break;

    switch (c)
    {
      case 0:
        /* If this option set a flag, do nothing else now. */
        if (long_options[option_index].flag != 0)
          break;
        printf ("option %s", long_options[option_index].name);
        if (optarg)
          printf (" with arg %s", optarg);
        printf ("\n");
        break;

      case 'h':
        printHelp(argv[0]);
        break;

      case 's':
        writeSample();
        break;

      case 'w':
        writePopulatedDoc();
        break;

      case 'r':
        inFile = optarg;
        roundtripFile(inFile);
        break;

      case 'v':
        inFile = optarg;
        validateFile(inFile);
        break;

      case 'u':
        inFile = optarg;
        readUpdateWriteFile(inFile);
        break;

      case '?':
        /* getopt_long already printed an error message. */
        break;

      default:
        abort();
    }
  }

  if (verbose_flag) {
    //cout << "verbose flag is set" << endl;;
  }

  if (optind < argc)
  {
    cout << "Invalid arguments: " << endl;
    while (optind < argc)
      cout <<  argv[optind++] << " ";

    cout << endl;
    exit(1);
  }
}



//
// Following functions are templates.
// You need to put code in the context
//



// template function to populate the Tree with values
void populateDocument(simplest::Document xsdDoc)
{
  // write code to populate the Document here
  simplest::items *pItems = xsdDoc.element_items();
  pItems->setTextAmongChildrenAt("text content1", 0);

  if(1)
  {
    pItems->add_item_string("one");
    pItems->add_item_string("two");
  }
  else
  {
    XPlus::List<simplest::items::item_ptr>  list_items2 = pItems->set_count_item(2);
    list_items2.at(0)->stringValue("one");
    list_items2.at(1)->stringValue("two");
  }
  pItems->setTextAmongChildrenAt("text content2", 2);
}

void updateOrConsumeDocument(simplest::Document xsdDoc)
{
  // write code to update the populated-Document here
  simplest::items *pItems = xsdDoc.element_items();
  pItems->replaceTextAt("updated text content2", 1);
}









examples/simplest/src/simplest/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "simplest/Document.h"


namespace simplest{


  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(false);
    DOM::Document::elementDefaultQualified(true);
    
    if(buildTree()) 
    {
      
      DOMStringPtr nsUriPtr = new DOMString("http://www.example.com/simplest");   
      XsdEvent event(nsUriPtr, NULL, DOMString("items"), XsdEvent::ELEMENT_START);
      if(this->createSample()) {
        event.cbOptions.isSampleCreate = true;
      }
      _fsm->processEventThrow(event); 
      
    }
    
  }

  void Document::initFSM()
  {
  
    _fsm_items = new XsdFSM<items_ptr>( Particle(new DOMString("http://www.example.com/simplest"),  DOMString("items"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<items_ptr, Document, FsmCbOptions>(this, &Document::create_items));
  
    XsdFsmBasePtr elemFsms[] = {
    _fsm_items,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  


  /* element functions  */
  

  items_ptr Document::create_items(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("items");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/simplest");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false);
    items_p node = XSD::createElementTmpl<items, void*>(t);
          
    _items = node;
      
    return node;
  }

  
  items_p Document::element_items()
  {
    FSM::warnNullNode(_items, "items", "{}items", 1);
    return _items;
  }
    
} // end namespace      
    


examples/simplest/src/simplest/items.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "simplest/items.h"

namespace simplest{


  //constructor
  
  items::items(ElementCreateArgs args):
      XMLSchema::XmlElement<anyType>(args),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_MIXED);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree())
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void items::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  new XsdFSM<attr_id_ptr>( Particle(NULL, DOMString("id"), 0, 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_id_ptr, items, FsmCbOptions>(this, &items::create_attr_id)),
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  items::item_ptr items::create_item(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("item");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/simplest");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    items::item_p node = XSD::createElementTmpl<item, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _list_item.push_back(node);
      
    return node;
  }

  
  items::item_p items::element_item_at(unsigned int idx)
  {
    if(idx > _list_item.size()-1) {
      throw IndexOutOfBoundsException("IndexOutOfBoundsException");
    }

    return _list_item.at(idx);
  }
    
  List<items::item_ptr> items::elements_item()
  {
    return _list_item;
  }
    
  items::item_p items::add_node_item()
  {
    return get_sequence()->add_node_item();
  }

  List<items::item_ptr> items::set_count_item(unsigned int size)
  {
    return get_sequence()->set_count_item(size);
  }

        
      
    void items::add_item_string(DOMString val)
    {
      get_sequence()->add_item_string(val);
    }

          
  void items::set_item(unsigned int idx, DOMString val)
  {
    get_sequence()->set_item(idx, val);
  }

  DOMString items::get_item_string(unsigned int idx)
  {
    return get_sequence()->get_item_string(idx);
  }

            

  /* attribute  functions  */
  

  items::attr_id_ptr items::create_attr_id(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("id");
    static DOMStringPtr myNsUri = NULL;
    
    if(_attr_id) {
      return _attr_id;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    items::attr_id_p node = XSD::createAttributeTmpl<attr_id>(t);
      
    node->defaultValue("102");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_id = node;
      
    return node;
  }

  
  void items::mark_present_attr_id()
  {
    if(!_attr_id)
    {
      XsdEvent event(NULL, NULL, DOMString("id"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void items::set_attr_id(DOMString val)
    {
        
      mark_present_attr_id();
        
      attribute_attr_id()->stringValue(val);
    }

    DOMString items::get_attr_id_string()
    {
       
      return attribute_attr_id()->stringValue();
    }

    
  items::attr_id_p items::attribute_attr_id()
  {
    FSM::warnNullNode(_attr_id, "attr_id", "{http://www.w3.org/2001/XMLSchema}id", 0);
    return _attr_id;
  }
    
  //constructor
  items::sequence::sequence(items* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<item_ptr>( Particle(new DOMString("http://www.example.com/simplest"), DOMString("item"), 0, 5), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<item_ptr, items, FsmCbOptions>(_that, &items::create_item)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  List<items::item_ptr> items::sequence::elements_item()
  {
      
    List<item_ptr> nodeList;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<item_ptr> *unitFsm = dynamic_cast<XsdFSM<item_ptr> *>(fsm_p);
      if(unitFsm) {
        //nodeList = unitFsm->nodeList().stl_list(); 
        nodeList = unitFsm->nodeList(); 
      }
    }
    return nodeList;
        
  }
  
  
  items::item_p items::sequence::element_item_at(unsigned int idx)
  {
    return elements_item().at(idx);
  }

    
  void items::sequence::set_item(unsigned int idx, DOMString val)
  {
    element_item_at(idx)->stringValue(val);
  }

  DOMString items::sequence::get_item_string(unsigned int idx)
  {
    return element_item_at(idx)->stringValue();
  }
      
  items::item_p items::sequence::add_node_item()
  {
    DOMStringPtr nsUriPtr = new DOMString("http://www.example.com/simplest");
    XsdEvent event(nsUriPtr, NULL, DOMString("item"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
    return elements_item().back();
  }

  List<items::item_ptr> items::sequence::set_count_item(unsigned int size)
  {
    if( (size > 5) || (size < 0)) {
      ostringstream oss;
      oss << "set_count_item: size should be in range: [" << 0
        << "," << 5 << "]";
      throw IndexOutOfBoundsException(oss.str());
    }

    unsigned int prevSize = elements_item().size();
    if(size < prevSize) {
      //FIXME: allow later:
      throw XPlus::RuntimeException("resize lesser than current size not allowed");
    }

    for(unsigned int j=prevSize; j<size; j++) 
    {
      // pretend docBuilding to avoid computation of adding after first loop
      XsdEvent event(new DOMString("http://www.example.com/simplest"), NULL, DOMString("item"), XsdEvent::ELEMENT_START, false);
      this->processEventThrow(event); 
    }
    
    return elements_item();
  }

        
    
  void items::sequence::add_item_string(DOMString val)
  {
    this->add_node_item()->stringValue(val);
  }
          
} // end namespace      
    



examples/simpleTypesDemo


examples/simpleTypesDemo/simpleTypesDemo.xsd

<?xml version="1.0" encoding="UTF-8" ?>

<!--
// This file is part of XmlPlus package
// 
// Copyright (C)   2010-2011   Satya Prakash Tripathi
// All rights reserved.
//
-->

<xsd:schema
elementFormDefault="qualified"
attributeFormDefault="qualified"
targetNamespace="http://www.example.com/STDemo"
xmlns:tns="http://www.example.com/STDemo"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>

  <!-- 
            1. global element/attribute declarations 
  -->

  <xsd:element name="myComplexTypeElem" type="tns:MyComplexType"/>
  <xsd:element name="globalWaterTemp" type="tns:CelciusWaterTemp"/>
  <xsd:attribute name="globalStringAttr">
    <xsd:simpleType>
      <xsd:restriction base='xsd:string'>
        <xsd:length value='3'/>
      </xsd:restriction>
    </xsd:simpleType>
  </xsd:attribute>


  <!-- 
          2. global simpleType/complexType declarations
  -->

  <xsd:complexType name="MyComplexType" mixed="true">
    <xsd:sequence>
      
      <!-- 2.1 atomic, builtin simpleTypes  -->
      <xsd:element name="xBoolean" type="xsd:boolean" fixed="false"/>
      <xsd:element name="xDecimal" type="xsd:decimal" default="-1.23e-6"/>
      <xsd:element name="xFloat" type="xsd:float" default="-1.23e-3"/>
      <xsd:element name="xDouble" type="xsd:double" default="-1.23e-5"/>
      <xsd:element name="xInteger" type="xsd:integer" default="-12678967543233"/>
      <xsd:element name="xPositiveInteger" type="xsd:positiveInteger" default="12678967543233"/>
      <xsd:element name="xNonPositiveInteger" type="xsd:nonPositiveInteger" default="-12678967543233"/>
      <xsd:element name="xNegativeInteger" type="xsd:negativeInteger" default="-12678967543233"/>
      <xsd:element name="xNonNegativeInteger" type="xsd:nonNegativeInteger" default="12678967543233"/>
      <xsd:element name="xLong" type="xsd:long" default="-9223372036854775808"/>
      <xsd:element name="xInt" type="xsd:int" default="-2147483648"/>
      <xsd:element name="xShort" type="xsd:short" default="-32768"/>
      <xsd:element name="xByte" type="xsd:byte" default="-127"/>
      <xsd:element name="xUnsignedLong" type="xsd:unsignedLong" default="18446744073709551615"/>
      <xsd:element name="xUnsignedInt" type="xsd:unsignedInt" default="4294967295"/>
      <xsd:element name="xUnsignedShort" type="xsd:unsignedShort" default="65535"/>
      <xsd:element name="xUnsignedByte" type="xsd:unsignedByte" default="255"/>
      <xsd:element name="xHexBinary" type="xsd:hexBinary" default="FEFF"/>
      <xsd:element name="xBase64Binary" type="xsd:base64Binary" default="aGVsbG8gd29ybGQ="/>
      <xsd:element name="xUri" type="xsd:anyURI" default="http://www.example.com/xmlplus"/>
      <xsd:element name="xNormalizedString" type="xsd:normalizedString" default="no CR LF TAB"/>
      <xsd:element name="xToken" type="xsd:token" default=" xs:hexBinary "/>
      <xsd:element name="xLanguage" type="xsd:language" default="english"/>
      <xsd:element name="xName" type="xsd:Name" default=":colonToken"/>
      <xsd:element name="xNCName" type="xsd:NCName" default="noColonToken"/>
      <xsd:element name="xQName" type="xsd:QName" default="xsi:schemaLocation"/>
      <xsd:element name="xDateTime" type="xsd:dateTime" default="2001-07-04T14:50:59Z"/>
      <xsd:element name="xDate" type="xsd:date" default="2010-01-04"/>
      <xsd:element name="xYearMonth" type="xsd:gYearMonth" default="1980-11"/>
      <xsd:element name="xYear" type="xsd:gYear" default="1978"/>
      <xsd:element name="xMonthDay" type="xsd:gMonthDay" default="12-30"/>
      <xsd:element name="xMonth" type="xsd:gMonth" default="7"/>
      <xsd:element name="xDay" type="xsd:gDay" default="30"/>
      <xsd:element name="xTime" type="xsd:time" default="14:59:57"/>
      <xsd:element name="xDuration" type="xsd:duration" default="P1Y2M3DT10H30M40S"/>

      <!-- 2.2 atomic, derived(non-builtin) simpleTypes  -->
      <xsd:element name="anIntMax10" minOccurs="3" maxOccurs="5">
        <xsd:simpleType>
          <xsd:restriction base='xsd:int'>
            <xsd:maxInclusive value='10'/>
          </xsd:restriction>
        </xsd:simpleType>
      </xsd:element>
      <xsd:element name="anIntMax5k" type="tns:IntMax5k"/>
      <xsd:element ref="tns:globalWaterTemp"/>
      <xsd:element name="aSKU" type="tns:SKU"/>
      <xsd:element name="aDateTime" type="tns:DateTimeInARange"/>
      <xsd:element name="aDate" type="tns:DateInARange" default="2010-01-04"/>
      <xsd:element name="aYear" type="tns:YearInARange"/>
      <xsd:element name="aCommonName">
        <xsd:simpleType>
          <xsd:restriction base='xsd:string'>
            <xsd:length value='5'/>
          </xsd:restriction>
        </xsd:simpleType>
      </xsd:element>

      <!-- 2.3 list simpleTypes -->
      <xsd:element name="aListOfIntMax5k" type="tns:ListOfIntMax5k"/>
      <xsd:element name="aListOfFourIntMax500" type="tns:ListOfFourIntMax500"/>
      <xsd:element name="aListOfTwoIntMax3k" type="tns:ListOfTwoIntMax3k"/>

      <!-- 2.4 union simpleTypes -->
      <xsd:element name="aFont" type="tns:Font"/>
      <xsd:element name="anotherFont" type="tns:Font"/>

    </xsd:sequence>

    <xsd:attribute name="xID" type="xsd:ID" default="NMTOKENS.minLength" use="optional"/>
    <xsd:attribute name="xIDREF" type="xsd:IDREF" use="optional"/>
    <xsd:attribute name="xIDREFS" type="xsd:IDREFS" use="optional"/>
    <xsd:attribute name="xENTITY" type="xsd:ENTITY" use="optional"/>
    <xsd:attribute name="xENTITIES" type="xsd:ENTITIES" use="optional"/>
    <xsd:attribute name="xNMTOKEN" type="xsd:NMTOKEN" default="prohibited" use="optional"/>
    <xsd:attribute name="xNMTOKENS" type="xsd:NMTOKENS" default="optional prohibited required" use="optional"/>
    <xsd:attribute ref="tns:globalStringAttr" use="required"/>
    <xsd:attribute name="aNOTATION" type="tns:PictureNotationType"/>
    <xsd:attribute name="aNNI" type="tns:EnumNNI" use="required"/>
    <xsd:attribute name="anotherNNI" type="tns:EnumNNI" use="required"/>
    <xsd:attribute name="aCommonName" use="required">
      <xsd:simpleType>
        <xsd:restriction base='xsd:string'>
          <xsd:length value='5'/>
        </xsd:restriction>
      </xsd:simpleType>
    </xsd:attribute>
  </xsd:complexType>

  <xsd:simpleType name="CelciusWaterTemp">
   <xsd:restriction base="xsd:decimal">
    <xsd:fractionDigits value="2"/>
    <xsd:minExclusive value="0.00"/>
    <xsd:maxExclusive value="100.00"/>
   </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="SKU">
    <xsd:restriction base="xsd:string">
      <xsd:pattern value="\d{3}-[A-Z]{2}"/>
    </xsd:restriction>
  </xsd:simpleType>


  <xsd:simpleType name="DateTimeInARange">
   <xsd:restriction base="xsd:dateTime">
    <xsd:minInclusive value="2010-01-01T12:00:00Z"/>
    <xsd:maxInclusive value="2010-05-31T23:00:00Z"/>
   </xsd:restriction>
  </xsd:simpleType>
  
  <xsd:simpleType name="DateInARange">
   <xsd:restriction base="xsd:date">
    <xsd:minInclusive value="2010-01-01Z"/>
    <xsd:maxInclusive value="2010-01-31Z"/>
   </xsd:restriction>
  </xsd:simpleType>
  
  
  <xsd:simpleType name="YearInARange">
   <xsd:restriction base="xsd:gYear">
    <xsd:minExclusive value="2005"/>
    <xsd:maxInclusive value="2010"/>
   </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name='IntMax5k'>
    <xsd:restriction base='xsd:int'>
      <xsd:maxExclusive value='5000'/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name='ListOfIntMax5k'>
    <xsd:list itemType='tns:IntMax5k'/>
  </xsd:simpleType>

  <xsd:simpleType name='ListOfIntMax500'>
    <xsd:list>
      <xsd:simpleType>
        <xsd:restriction base='xsd:int'>
          <xsd:maxExclusive value='500'/>
        </xsd:restriction>
      </xsd:simpleType>
    </xsd:list>  
  </xsd:simpleType>

  <xsd:simpleType name='ListOfFourIntMax500'>
    <xsd:restriction base='tns:ListOfIntMax500'>
      <xsd:maxLength value='4'/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name='ListOfIntMax3k'>
    <xsd:list>
      <xsd:simpleType>
        <xsd:restriction>
          <xsd:simpleType>
            <xsd:restriction base='tns:IntMax5k'>
              <xsd:maxExclusive value='4000'/>
            </xsd:restriction>
          </xsd:simpleType>
          <xsd:maxExclusive value='3000'/>
        </xsd:restriction>
      </xsd:simpleType>
    </xsd:list>  
  </xsd:simpleType>

  <xsd:simpleType name='ListOfTwoIntMax3k'>
    <xsd:restriction base='tns:ListOfIntMax3k'>
      <xsd:maxLength value='2'/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="Font">
    <xsd:union memberTypes="tns:Fontbynumber tns:Fontbystringname"/>
  </xsd:simpleType>

  <xsd:simpleType name="Fontbynumber">
    <xsd:restriction base="xsd:positiveInteger">
      <xsd:maxInclusive value="72"/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="Fontbystringname">
    <xsd:restriction base="xsd:string">
      <xsd:enumeration value="small"/>
      <xsd:enumeration value="medium"/>
      <xsd:enumeration value="large"/>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:simpleType name="EnumNNI">
    <xsd:union memberTypes="xsd:nonNegativeInteger">
     <xsd:simpleType>
      <xsd:restriction base="xsd:NMTOKEN">
       <xsd:enumeration value="unbounded"/>
      </xsd:restriction>
     </xsd:simpleType>
    </xsd:union>
  </xsd:simpleType>


  <xsd:notation name="jpeg" public="JPG"/>
  <xsd:notation name="gif" public="GIF"/>
  <xsd:simpleType name="PictureNotationType">
    <xsd:restriction base="xsd:NOTATION">
      <xsd:enumeration value="jpeg"/>
      <xsd:enumeration value="gif"/>
    </xsd:restriction>
  </xsd:simpleType>


</xsd:schema>


examples/simpleTypesDemo/nsaliases.xml

<nsaliases>
  <alias uri="http://www.example.com/STDemo" toUrn="urn:STDemo"/>
</nsaliases>


examples/simpleTypesDemo/valid.xml

<?xml version="1.0"?>
<ns1:myComplexTypeElem ns1:globalStringAttr="abc" ns1:aNNI="unbounded" ns1:anotherNNI="100" ns1:aCommonName="abcde" xmlns:ns1="http://www.example.com/STDemo">
  Here you will see some examples of simpleType elements

    Following are examples of -atomic- simpleType elements
  <ns1:xBoolean>false</ns1:xBoolean>
      <ns1:xDecimal>-1.23e-6</ns1:xDecimal>
  <ns1:xFloat>-1.23e-3</ns1:xFloat>
  <ns1:xDouble>-1.23e-5</ns1:xDouble>
  <ns1:xInteger>-12678967543233</ns1:xInteger>
  <ns1:xPositiveInteger>12678967543233</ns1:xPositiveInteger>
  <ns1:xNonPositiveInteger>-12678967543233</ns1:xNonPositiveInteger>
  <ns1:xNegativeInteger>-12678967543233</ns1:xNegativeInteger>
  <ns1:xNonNegativeInteger>12678967543233</ns1:xNonNegativeInteger>
  <ns1:xLong>-9223372036854775808</ns1:xLong>
  <ns1:xInt>-2147483648</ns1:xInt>
  <ns1:xShort>-32768</ns1:xShort>
  <ns1:xByte>-127</ns1:xByte>
  <ns1:xUnsignedLong>18446744073709551615</ns1:xUnsignedLong>
  <ns1:xUnsignedInt>4294967295</ns1:xUnsignedInt>
  <ns1:xUnsignedShort>65535</ns1:xUnsignedShort>
  <ns1:xUnsignedByte>255</ns1:xUnsignedByte>
  <ns1:xHexBinary>FEFF</ns1:xHexBinary>
  <ns1:xBase64Binary>ZXF+NAQF/d</ns1:xBase64Binary>
  <ns1:xUri>http://www.example.com/xmlplus</ns1:xUri>
  <ns1:xNormalizedString>no CR LF TAB</ns1:xNormalizedString>
  <ns1:xToken>xs:hexBinary</ns1:xToken>
  <ns1:xLanguage>english</ns1:xLanguage>
  <ns1:xName>:colonToken</ns1:xName>
  <ns1:xNCName>noColonToken</ns1:xNCName>
  <ns1:xQName>xsi:schemaLocation</ns1:xQName>
  <ns1:xDateTime>2001-07-04T14:50:59Z</ns1:xDateTime>
  <ns1:xDate>2010-01-04</ns1:xDate>
  <ns1:xYearMonth>1980-11</ns1:xYearMonth>
  <ns1:xYear>1978</ns1:xYear>
  <ns1:xMonthDay>12-30</ns1:xMonthDay>
  <ns1:xMonth>7</ns1:xMonth>
  <ns1:xDay>30</ns1:xDay>
  <ns1:xTime>14:59:57</ns1:xTime>
  <ns1:xDuration>P1Y2M3DT10H30M40S</ns1:xDuration>
  <ns1:anIntMax10>10</ns1:anIntMax10>
  <ns1:anIntMax10>10</ns1:anIntMax10>
  <ns1:anIntMax10>10</ns1:anIntMax10>
  <ns1:anIntMax5k>4999</ns1:anIntMax5k>
  <ns1:globalWaterTemp>30</ns1:globalWaterTemp>
  <ns1:aSKU>123-AB</ns1:aSKU>
  <ns1:aDateTime>2010-01-04T12:00:00Z</ns1:aDateTime>
  <ns1:aDate>2010-01-04</ns1:aDate>
  <ns1:aYear>2009</ns1:aYear>
  <ns1:aCommonName>abcde</ns1:aCommonName>
    End of -atomic- simpleType elements

    Following are examples of -list- simpleType elements
  <ns1:aListOfIntMax5k>0 1000 2000 3000 4000</ns1:aListOfIntMax5k>
  <ns1:aListOfFourIntMax500>100 200 300 400</ns1:aListOfFourIntMax500>
  <ns1:aListOfTwoIntMax3k>1000 2000</ns1:aListOfTwoIntMax3k>
    End of -list- simpleType elements

    Following are examples of -union- simpleType elements
  <ns1:aFont>medium</ns1:aFont>
  <ns1:anotherFont>72</ns1:anotherFont>
    End of -union- simpleType elements

  End of all example elements
</ns1:myComplexTypeElem>


examples/simpleTypesDemo/include/STDemo/myComplexTypeElem.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_myComplexTypeElem_H__
#define  __STDemo_myComplexTypeElem_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "STDemo/Types/MyComplexType.h"
      

using namespace XPlus;

namespace STDemo{

  typedef XMLSchema::XmlElement<STDemo::Types::MyComplexType> myComplexTypeElem;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {http://www.example.com/STDemo}myComplexTypeElem
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::MyComplexType> > myComplexTypeElem_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::MyComplexType>* myComplexTypeElem_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::MyComplexType> myComplexTypeElem; 
  
} // end namespace      
    
#endif


examples/simpleTypesDemo/include/STDemo/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_DOCUMENT_H__
#define  __STDemo_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "STDemo/myComplexTypeElem.h"
    
#include "STDemo/globalWaterTemp.h"
    
#include "STDemo/attr_globalStringAttr.h"
    

using namespace XPlus;
using namespace FSM;


namespace STDemo{


class Document : public XMLSchema::TDocument
{
  private:
  
  
  myComplexTypeElem_ptr _myComplexTypeElem;
    
  AutoPtr<XsdFSM<myComplexTypeElem_ptr> > _fsm_myComplexTypeElem;
  
  globalWaterTemp_ptr _globalWaterTemp;
    
  AutoPtr<XsdFSM<globalWaterTemp_ptr> > _fsm_globalWaterTemp;
    
  
  // attributes, elements
  
  myComplexTypeElem_ptr create_myComplexTypeElem(FsmCbOptions& options);

  globalWaterTemp_ptr create_globalWaterTemp(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  void set_root_myComplexTypeElem();
    
  void set_root_globalWaterTemp();
    
  myComplexTypeElem_p element_myComplexTypeElem();
  
  globalWaterTemp_p element_globalWaterTemp();
    
    
  void initFSM();
};

} // end namespace      
    
#endif
  


examples/simpleTypesDemo/include/STDemo/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_ALL_INCLUDE_H__
#define  __STDemo_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "STDemo/Document.h"

#include "STDemo/myComplexTypeElem.h"    
  
#include "STDemo/globalWaterTemp.h"    
  
#include "STDemo/attr_globalStringAttr.h"    
  
#include "STDemo/Types/MyComplexType.h"    
  
#include "STDemo/Types/CelciusWaterTemp.h"    
  
#include "STDemo/Types/SKU.h"    
  
#include "STDemo/Types/DateTimeInARange.h"    
  
#include "STDemo/Types/DateInARange.h"    
  
#include "STDemo/Types/YearInARange.h"    
  
#include "STDemo/Types/IntMax5k.h"    
  
#include "STDemo/Types/ListOfIntMax5k.h"    
  
#include "STDemo/Types/ListOfIntMax500.h"    
  
#include "STDemo/Types/ListOfFourIntMax500.h"    
  
#include "STDemo/Types/ListOfIntMax3k.h"    
  
#include "STDemo/Types/ListOfTwoIntMax3k.h"    
  
#include "STDemo/Types/Font.h"    
  
#include "STDemo/Types/Fontbynumber.h"    
  
#include "STDemo/Types/Fontbystringname.h"    
  
#include "STDemo/Types/EnumNNI.h"    
  
#include "STDemo/Types/PictureNotationType.h"    
  

using namespace XPlus;


#endif 
  


examples/simpleTypesDemo/include/STDemo/globalWaterTemp.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_globalWaterTemp_H__
#define  __STDemo_globalWaterTemp_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "STDemo/Types/CelciusWaterTemp.h"
      

using namespace XPlus;

namespace STDemo{

  typedef XMLSchema::XmlElement<STDemo::Types::CelciusWaterTemp> globalWaterTemp;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {http://www.example.com/STDemo}globalWaterTemp
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::CelciusWaterTemp> > globalWaterTemp_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::CelciusWaterTemp>* globalWaterTemp_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::CelciusWaterTemp> globalWaterTemp; 
  
} // end namespace      
    
#endif


examples/simpleTypesDemo/include/STDemo/attr_globalStringAttr.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_attr_globalStringAttr_H__
#define  __STDemo_attr_globalStringAttr_H__


using namespace XPlus;


namespace STDemo{
  

  /// class for simpleType with restriction on base
  class _attr_globalStringAttr : public XMLSchema::Types::bt_string
  {
  public:
    /// constructor  
    _attr_globalStringAttr(AnyTypeCreateArgs args)
    
        : bt_string(args)
      
    {
    
      _lengthCFacet.stringValue("3");
      
      this->appliedCFacets( appliedCFacets() | CF_LENGTH );
    }
    
  protected:
    
  };

  //types which this class needs, as INNER CLASSES


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<_attr_globalStringAttr> > attr_globalStringAttr_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<_attr_globalStringAttr>* attr_globalStringAttr_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<_attr_globalStringAttr> attr_globalStringAttr; 
  
} // end namespace      
    
#endif


examples/simpleTypesDemo/include/STDemo/Types/YearInARange.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_YearInARange_H__ 
#define __STDemo_YearInARange_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class YearInARange : public XMLSchema::Types::bt_gYear
  {
  public:
    /// constructor  
    YearInARange(AnyTypeCreateArgs args)
    
        : bt_gYear(args)
      
    {
    
      minExclusiveCFacet().stringValue("2005");
          
      maxInclusiveCFacet().stringValue("2010");
          
      this->appliedCFacets( appliedCFacets() | CF_MINEXCLUSIVE| CF_MAXINCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/IntMax5k.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_IntMax5k_H__ 
#define __STDemo_IntMax5k_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class IntMax5k : public XMLSchema::Types::bt_int
  {
  public:
    /// constructor  
    IntMax5k(AnyTypeCreateArgs args)
    
        : bt_int(args)
      
    {
    
      maxExclusiveCFacet().stringValue("5000");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXEXCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/Font.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_Font_H__ 
#define __STDemo_Font_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"
 
#include "XSD/SimpleTypeUnionTmpl.h"      
      
#include "STDemo/Types/Fontbynumber.h"
  
#include "STDemo/Types/Fontbystringname.h"
  

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
  
  /// class for simpleType of variety union
  

  class Font : public XMLSchema::Types::SimpleTypeUnionTmpl
  {
  public:
    

    /// constructor  
    Font(AnyTypeCreateArgs args):
      XMLSchema::Types::SimpleTypeUnionTmpl(args)
    {
      
       _unionMembers.push_back(new STDemo::Types::Fontbynumber(AnyTypeCreateArgs()));

       _unionMembers.push_back(new STDemo::Types::Fontbystringname(AnyTypeCreateArgs()));

    }

    virtual DOMString stringValue() {
      return _value;
    }

    virtual void stringValue(DOMString val)
    {
      SimpleTypeUnionTmpl::stringValue(val);
    }

    virtual inline DOMString sampleValue() 
    {
      return SimpleTypeUnionTmpl::sampleValue();
    }

  protected:

    
  };
  
} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/ListOfTwoIntMax3k.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_ListOfTwoIntMax3k_H__ 
#define __STDemo_ListOfTwoIntMax3k_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"

#include "STDemo/Types/ListOfIntMax3k.h"      
      

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class ListOfTwoIntMax3k : public STDemo::Types::ListOfIntMax3k
  {
  public:
    /// constructor  
    ListOfTwoIntMax3k(AnyTypeCreateArgs args)
    
        : ListOfIntMax3k(args)
      
    {
    
      _maxLengthCFacet.stringValue("2");
      
      this->appliedCFacets( appliedCFacets() | CF_MAXLENGTH );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/DateInARange.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_DateInARange_H__ 
#define __STDemo_DateInARange_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class DateInARange : public XMLSchema::Types::bt_date
  {
  public:
    /// constructor  
    DateInARange(AnyTypeCreateArgs args)
    
        : bt_date(args)
      
    {
    
      minInclusiveCFacet().stringValue("2010-01-01Z");
          
      maxInclusiveCFacet().stringValue("2010-01-31Z");
          
      this->appliedCFacets( appliedCFacets() | CF_MININCLUSIVE| CF_MAXINCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/PictureNotationType.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_PictureNotationType_H__ 
#define __STDemo_PictureNotationType_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class PictureNotationType : public XMLSchema::Types::bt_NOTATION
  {
  public:
    /// constructor  
    PictureNotationType(AnyTypeCreateArgs args)
    
        : bt_NOTATION(args)
      
    {
    
      vector<DOMString> enums;
    
      enums.push_back("jpeg");
    
      enums.push_back("gif");
    
      _enumerationCFacet.value(enums);
  
      this->appliedCFacets( appliedCFacets() | CF_ENUMERATION| CF_ENUMERATION );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/Fontbystringname.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_Fontbystringname_H__ 
#define __STDemo_Fontbystringname_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class Fontbystringname : public XMLSchema::Types::bt_string
  {
  public:
    /// constructor  
    Fontbystringname(AnyTypeCreateArgs args)
    
        : bt_string(args)
      
    {
    
      vector<DOMString> enums;
    
      enums.push_back("small");
    
      enums.push_back("medium");
    
      enums.push_back("large");
    
      _enumerationCFacet.value(enums);
  
      this->appliedCFacets( appliedCFacets() | CF_ENUMERATION| CF_ENUMERATION| CF_ENUMERATION );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/ListOfIntMax500.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_ListOfIntMax500_H__ 
#define __STDemo_ListOfIntMax500_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"
 
#include "XSD/SimpleTypeListTmpl.h"      
      

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class ListOfIntMax500_list_simpleType1 : public XMLSchema::Types::bt_int
  {
  public:
    /// constructor  
    ListOfIntMax500_list_simpleType1(AnyTypeCreateArgs args)
    
        : bt_int(args)
      
    {
    
      maxExclusiveCFacet().stringValue("500");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXEXCLUSIVE );
    }
    
  protected:
    
  };

  typedef XMLSchema::Types::SimpleTypeListTmpl<ListOfIntMax500_list_simpleType1> ListOfIntMax500;
        
} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/SKU.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_SKU_H__ 
#define __STDemo_SKU_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class SKU : public XMLSchema::Types::bt_string
  {
  public:
    /// constructor  
    SKU(AnyTypeCreateArgs args)
    
        : bt_string(args)
      
    {
    
      _patternCFacet.value("\\d{3}-[A-Z]{2}");
      
      this->appliedCFacets( appliedCFacets() | CF_PATTERN );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/MyComplexType.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __STDemo_types_MyComplexType_H__
#define  __STDemo_types_MyComplexType_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "STDemo/Types/IntMax5k.h"
      
#include "STDemo/globalWaterTemp.h"
      
#include "STDemo/Types/SKU.h"
      
#include "STDemo/Types/DateTimeInARange.h"
      
#include "STDemo/Types/DateInARange.h"
      
#include "STDemo/Types/YearInARange.h"
      
#include "STDemo/Types/ListOfIntMax5k.h"
      
#include "STDemo/Types/ListOfFourIntMax500.h"
      
#include "STDemo/Types/ListOfTwoIntMax3k.h"
      
#include "STDemo/Types/Font.h"
      
#include "STDemo/Types/Font.h"
      
#include "STDemo/attr_globalStringAttr.h"
      
#include "STDemo/Types/PictureNotationType.h"
      
#include "STDemo/Types/EnumNNI.h"
      
#include "STDemo/Types/EnumNNI.h"
      
using namespace XPlus; 



namespace STDemo{

namespace Types 
{
  
/// The class for complexType MyComplexType
/// \n Refer to documentation on structures/methods inside ...
class MyComplexType : public XMLSchema::Types::anyType
{
  public:
  //constructor
  MyComplexType(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_boolean> > xBoolean_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_boolean>* xBoolean_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_boolean> xBoolean; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_decimal> > xDecimal_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_decimal>* xDecimal_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_decimal> xDecimal; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_float> > xFloat_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_float>* xFloat_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_float> xFloat; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_double> > xDouble_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_double>* xDouble_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_double> xDouble; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_integer> > xInteger_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_integer>* xInteger_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_integer> xInteger; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_positiveInteger> > xPositiveInteger_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_positiveInteger>* xPositiveInteger_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_positiveInteger> xPositiveInteger; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_nonPositiveInteger> > xNonPositiveInteger_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_nonPositiveInteger>* xNonPositiveInteger_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_nonPositiveInteger> xNonPositiveInteger; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_negativeInteger> > xNegativeInteger_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_negativeInteger>* xNegativeInteger_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_negativeInteger> xNegativeInteger; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_nonNegativeInteger> > xNonNegativeInteger_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_nonNegativeInteger>* xNonNegativeInteger_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_nonNegativeInteger> xNonNegativeInteger; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_long> > xLong_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_long>* xLong_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_long> xLong; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_int> > xInt_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_int>* xInt_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_int> xInt; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_short> > xShort_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_short>* xShort_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_short> xShort; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_byte> > xByte_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_byte>* xByte_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_byte> xByte; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedLong> > xUnsignedLong_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedLong>* xUnsignedLong_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedLong> xUnsignedLong; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedInt> > xUnsignedInt_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedInt>* xUnsignedInt_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedInt> xUnsignedInt; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedShort> > xUnsignedShort_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedShort>* xUnsignedShort_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedShort> xUnsignedShort; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedByte> > xUnsignedByte_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedByte>* xUnsignedByte_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_unsignedByte> xUnsignedByte; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary> > xHexBinary_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary>* xHexBinary_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary> xHexBinary; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_base64Binary> > xBase64Binary_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_base64Binary>* xBase64Binary_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_base64Binary> xBase64Binary; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_anyURI> > xUri_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_anyURI>* xUri_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_anyURI> xUri; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_normalizedString> > xNormalizedString_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_normalizedString>* xNormalizedString_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_normalizedString> xNormalizedString; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_token> > xToken_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_token>* xToken_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_token> xToken; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_language> > xLanguage_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_language>* xLanguage_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_language> xLanguage; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_Name> > xName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_Name>* xName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_Name> xName; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_NCName> > xNCName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_NCName>* xNCName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_NCName> xNCName; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_QName> > xQName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_QName>* xQName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_QName> xQName; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_dateTime> > xDateTime_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_dateTime>* xDateTime_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_dateTime> xDateTime; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_date> > xDate_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_date>* xDate_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_date> xDate; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_gYearMonth> > xYearMonth_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gYearMonth>* xYearMonth_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gYearMonth> xYearMonth; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_gYear> > xYear_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gYear>* xYear_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gYear> xYear; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_gMonthDay> > xMonthDay_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gMonthDay>* xMonthDay_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gMonthDay> xMonthDay; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_gMonth> > xMonth_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gMonth>* xMonth_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gMonth> xMonth; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_gDay> > xDay_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gDay>* xDay_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_gDay> xDay; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_time> > xTime_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_time>* xTime_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_time> xTime; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_duration> > xDuration_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_duration>* xDuration_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_duration> xDuration; 
  
  class _anIntMax10;
    

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<_anIntMax10> > anIntMax10_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<_anIntMax10>* anIntMax10_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<_anIntMax10> anIntMax10; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::IntMax5k> > anIntMax5k_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::IntMax5k>* anIntMax5k_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::IntMax5k> anIntMax5k; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<STDemo::globalWaterTemp > globalWaterTemp_ptr;
  /// typedef for the Plain pointer to the node
  typedef STDemo::globalWaterTemp* globalWaterTemp_p;
  
  /// typedef for the node
  typedef STDemo::globalWaterTemp globalWaterTemp; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::SKU> > aSKU_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::SKU>* aSKU_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::SKU> aSKU; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::DateTimeInARange> > aDateTime_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::DateTimeInARange>* aDateTime_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::DateTimeInARange> aDateTime; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::DateInARange> > aDate_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::DateInARange>* aDate_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::DateInARange> aDate; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::YearInARange> > aYear_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::YearInARange>* aYear_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::YearInARange> aYear; 
  
#ifndef __MyComplexType_aCommonName_typedefs
#define __MyComplexType_aCommonName_typedefs
      
  class _aCommonName;
    

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<_aCommonName> > aCommonName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<_aCommonName>* aCommonName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<_aCommonName> aCommonName; 
  
#endif // __MyComplexType_aCommonName_typedefs
      

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::ListOfIntMax5k> > aListOfIntMax5k_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfIntMax5k>* aListOfIntMax5k_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfIntMax5k> aListOfIntMax5k; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::ListOfFourIntMax500> > aListOfFourIntMax500_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfFourIntMax500>* aListOfFourIntMax500_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfFourIntMax500> aListOfFourIntMax500; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::ListOfTwoIntMax3k> > aListOfTwoIntMax3k_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfTwoIntMax3k>* aListOfTwoIntMax3k_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::ListOfTwoIntMax3k> aListOfTwoIntMax3k; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::Font> > aFont_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::Font>* aFont_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::Font> aFont; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<STDemo::Types::Font> > anotherFont_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<STDemo::Types::Font>* anotherFont_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<STDemo::Types::Font> anotherFont; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_ID> > attr_xID_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ID>* attr_xID_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ID> attr_xID; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREF> > attr_xIDREF_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREF>* attr_xIDREF_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREF> attr_xIDREF; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREFS> > attr_xIDREFS_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREFS>* attr_xIDREFS_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_IDREFS> attr_xIDREFS; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITY> > attr_xENTITY_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITY>* attr_xENTITY_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITY> attr_xENTITY; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITIES> > attr_xENTITIES_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITIES>* attr_xENTITIES_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_ENTITIES> attr_xENTITIES; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKEN> > attr_xNMTOKEN_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKEN>* attr_xNMTOKEN_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKEN> attr_xNMTOKEN; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKENS> > attr_xNMTOKENS_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKENS>* attr_xNMTOKENS_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_NMTOKENS> attr_xNMTOKENS; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<STDemo::attr_globalStringAttr > attr_globalStringAttr_ptr;
  /// typedef for the Plain pointer to the node
  typedef STDemo::attr_globalStringAttr* attr_globalStringAttr_p;
  
  /// typedef for the node
  typedef STDemo::attr_globalStringAttr attr_globalStringAttr; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<STDemo::Types::PictureNotationType> > attr_aNOTATION_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::PictureNotationType>* attr_aNOTATION_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::PictureNotationType> attr_aNOTATION; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<STDemo::Types::EnumNNI> > attr_aNNI_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::EnumNNI>* attr_aNNI_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::EnumNNI> attr_aNNI; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<STDemo::Types::EnumNNI> > attr_anotherNNI_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::EnumNNI>* attr_anotherNNI_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<STDemo::Types::EnumNNI> attr_anotherNNI; 
  
#ifndef __MyComplexType_attr_aCommonName_typedefs
#define __MyComplexType_attr_aCommonName_typedefs
      
  class _attr_aCommonName;
    

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<_attr_aCommonName> > attr_aCommonName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<_attr_aCommonName>* attr_aCommonName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<_attr_aCommonName> attr_aCommonName; 
  
#endif // __MyComplexType_attr_aCommonName_typedefs
      
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(MyComplexType* that);

    

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xBoolean_p element_xBoolean();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xBoolean(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xBoolean_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as bool) to set with 
    void set_xBoolean(bool val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as bool) of the element 
    bool get_xBoolean();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDecimal_p element_xDecimal();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDecimal(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDecimal_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as double) to set with 
    void set_xDecimal(double val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as double) of the element 
    double get_xDecimal();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xFloat_p element_xFloat();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xFloat(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xFloat_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as float) to set with 
    void set_xFloat(float val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as float) of the element 
    float get_xFloat();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDouble_p element_xDouble();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDouble(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDouble_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as double) to set with 
    void set_xDouble(double val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as double) of the element 
    double get_xDouble();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xInteger_p element_xInteger();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xInteger(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xInteger_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Int64) to set with 
    void set_xInteger(XPlus::Int64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Int64) of the element 
    XPlus::Int64 get_xInteger();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xPositiveInteger_p element_xPositiveInteger();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xPositiveInteger(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xPositiveInteger_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::UInt64) to set with 
    void set_xPositiveInteger(XPlus::UInt64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::UInt64) of the element 
    XPlus::UInt64 get_xPositiveInteger();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xNonPositiveInteger_p element_xNonPositiveInteger();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xNonPositiveInteger(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xNonPositiveInteger_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Int64) to set with 
    void set_xNonPositiveInteger(XPlus::Int64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Int64) of the element 
    XPlus::Int64 get_xNonPositiveInteger();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xNegativeInteger_p element_xNegativeInteger();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xNegativeInteger(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xNegativeInteger_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Int64) to set with 
    void set_xNegativeInteger(XPlus::Int64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Int64) of the element 
    XPlus::Int64 get_xNegativeInteger();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xNonNegativeInteger_p element_xNonNegativeInteger();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xNonNegativeInteger(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xNonNegativeInteger_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::UInt64) to set with 
    void set_xNonNegativeInteger(XPlus::UInt64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::UInt64) of the element 
    XPlus::UInt64 get_xNonNegativeInteger();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xLong_p element_xLong();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xLong(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xLong_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Int64) to set with 
    void set_xLong(XPlus::Int64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Int64) of the element 
    XPlus::Int64 get_xLong();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xInt_p element_xInt();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xInt(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xInt_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as int) to set with 
    void set_xInt(int val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as int) of the element 
    int get_xInt();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xShort_p element_xShort();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xShort(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xShort_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as short) to set with 
    void set_xShort(short val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as short) of the element 
    short get_xShort();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xByte_p element_xByte();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xByte(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xByte_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as char) to set with 
    void set_xByte(char val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as char) of the element 
    char get_xByte();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xUnsignedLong_p element_xUnsignedLong();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xUnsignedLong(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xUnsignedLong_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::UInt64) to set with 
    void set_xUnsignedLong(XPlus::UInt64 val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::UInt64) of the element 
    XPlus::UInt64 get_xUnsignedLong();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xUnsignedInt_p element_xUnsignedInt();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xUnsignedInt(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xUnsignedInt_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as unsigned int) to set with 
    void set_xUnsignedInt(unsigned int val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as unsigned int) of the element 
    unsigned int get_xUnsignedInt();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xUnsignedShort_p element_xUnsignedShort();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xUnsignedShort(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xUnsignedShort_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as unsigned short) to set with 
    void set_xUnsignedShort(unsigned short val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as unsigned short) of the element 
    unsigned short get_xUnsignedShort();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xUnsignedByte_p element_xUnsignedByte();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xUnsignedByte(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xUnsignedByte_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as unsigned char) to set with 
    void set_xUnsignedByte(unsigned char val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as unsigned char) of the element 
    unsigned char get_xUnsignedByte();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xHexBinary_p element_xHexBinary();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xHexBinary(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xHexBinary_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xBase64Binary_p element_xBase64Binary();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xBase64Binary(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xBase64Binary_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xUri_p element_xUri();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xUri(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xUri_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xNormalizedString_p element_xNormalizedString();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xNormalizedString(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xNormalizedString_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xToken_p element_xToken();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xToken(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xToken_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xLanguage_p element_xLanguage();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xLanguage(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xLanguage_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xName_p element_xName();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xName(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xName_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xNCName_p element_xNCName();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xNCName(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xNCName_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xQName_p element_xQName();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xQName(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xQName_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDateTime_p element_xDateTime();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDateTime(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDateTime_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::DateTime) to set with 
    void set_xDateTime(XPlus::DateTime val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::DateTime) of the element 
    XPlus::DateTime get_xDateTime();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDate_p element_xDate();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDate(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDate_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Date) to set with 
    void set_xDate(XPlus::Date val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Date) of the element 
    XPlus::Date get_xDate();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xYearMonth_p element_xYearMonth();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xYearMonth(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xYearMonth_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::YearMonth) to set with 
    void set_xYearMonth(XPlus::YearMonth val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::YearMonth) of the element 
    XPlus::YearMonth get_xYearMonth();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xYear_p element_xYear();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xYear(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xYear_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Year) to set with 
    void set_xYear(XPlus::Year val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Year) of the element 
    XPlus::Year get_xYear();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xMonthDay_p element_xMonthDay();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xMonthDay(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xMonthDay_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::MonthDay) to set with 
    void set_xMonthDay(XPlus::MonthDay val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::MonthDay) of the element 
    XPlus::MonthDay get_xMonthDay();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xMonth_p element_xMonth();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xMonth(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xMonth_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Month) to set with 
    void set_xMonth(XPlus::Month val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Month) of the element 
    XPlus::Month get_xMonth();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDay_p element_xDay();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDay(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDay_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Day) to set with 
    void set_xDay(XPlus::Day val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Day) of the element 
    XPlus::Day get_xDay();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xTime_p element_xTime();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xTime(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xTime_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Time) to set with 
    void set_xTime(XPlus::Time val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Time) of the element 
    XPlus::Time get_xTime();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    xDuration_p element_xDuration();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_xDuration(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_xDuration_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Duration) to set with 
    void set_xDuration(XPlus::Duration val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Duration) of the element 
    XPlus::Duration get_xDuration();

          

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Returns the list of the element nodes
    ///  @return the list of element nodes fetched
    List<anIntMax10_ptr> elements_anIntMax10();

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Returns the element node at supplied index
    ///  @param idx index of the element to fetch 
    ///  @return the element node fetched
    anIntMax10_p element_anIntMax10_at(unsigned int idx);

        
        

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Sets the value of the element at the supplied index with the supplied value
    ///  @param idx index of the element 
    ///  @param val the value(as DOMString) to set with 
    void set_anIntMax10(unsigned int idx, DOMString val);

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Returns the value of the element at the supplied index with the supplied value.
    ///  @param idx index of the element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_anIntMax10_string(unsigned int idx);


          

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Sets the value of the element at the supplied index with the supplied value.
    ///  @param idx index of the element 
    ///  @param val the value (as int) to set with 
    void set_anIntMax10(unsigned int idx, int val);

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Returns the value of the element at the supplied index with supplied value.
    ///  @param idx index of the element 
    ///  @return the value(as int) of the element 
    int get_anIntMax10(unsigned int idx);

          

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Adds one element to the end of the "list of the element nodes"
    ///  @return the pointer to the added element
    anIntMax10_p add_node_anIntMax10();

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Sizes-up the "list of the element nodes" with the supplied size
    ///  @param size the request size(unsigned int) of the list
    ///  @return the list of "pointer-to-element-node"
    List<anIntMax10_ptr> set_count_anIntMax10(unsigned int size);


      
      
    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
    ///  @param val the value(as DOMString) to set with 
    void add_anIntMax10_string(DOMString val);
      
        

    ///  For vector-element with QName "{}anIntMax10" :
    ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied type value
    ///  @param val the value(as int) to set with 
    void add_anIntMax10(int val);  
        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    anIntMax5k_p element_anIntMax5k();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_anIntMax5k(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_anIntMax5k_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as int) to set with 
    void set_anIntMax5k(int val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as int) of the element 
    int get_anIntMax5k();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    globalWaterTemp_p element_globalWaterTemp();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_globalWaterTemp(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_globalWaterTemp_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as double) to set with 
    void set_globalWaterTemp(double val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as double) of the element 
    double get_globalWaterTemp();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aSKU_p element_aSKU();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aSKU(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aSKU_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aDateTime_p element_aDateTime();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aDateTime(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aDateTime_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::DateTime) to set with 
    void set_aDateTime(XPlus::DateTime val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::DateTime) of the element 
    XPlus::DateTime get_aDateTime();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aDate_p element_aDate();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aDate(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aDate_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Date) to set with 
    void set_aDate(XPlus::Date val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Date) of the element 
    XPlus::Date get_aDate();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aYear_p element_aYear();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aYear(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aYear_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Year) to set with 
    void set_aYear(XPlus::Year val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Year) of the element 
    XPlus::Year get_aYear();

          

    ///  For the scalar-element with QName "{}aCommonName" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aCommonName_p element_aCommonName();

        

    ///  For the scalar-element with QName "{}aCommonName" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aCommonName(DOMString val);

    ///  For the scalar-element with QName "{}aCommonName" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aCommonName_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aListOfIntMax5k_p element_aListOfIntMax5k();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aListOfIntMax5k(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aListOfIntMax5k_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aListOfFourIntMax500_p element_aListOfFourIntMax500();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aListOfFourIntMax500(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aListOfFourIntMax500_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aListOfTwoIntMax3k_p element_aListOfTwoIntMax3k();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aListOfTwoIntMax3k(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aListOfTwoIntMax3k_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    aFont_p element_aFont();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_aFont(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_aFont_string();

          

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    anotherFont_p element_anotherFont();

        

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_anotherFont(DOMString val);

    ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_anotherFont_string();

          

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    MyComplexType*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xBoolean_p element_xBoolean();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xBoolean(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xBoolean_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as bool) to set with 
  void set_xBoolean(bool val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBoolean" :
  ///  \n Returns the value of the element
  ///  @return the value(as bool) of the element 
  bool get_xBoolean();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDecimal_p element_xDecimal();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDecimal(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDecimal_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as double) to set with 
  void set_xDecimal(double val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDecimal" :
  ///  \n Returns the value of the element
  ///  @return the value(as double) of the element 
  double get_xDecimal();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xFloat_p element_xFloat();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xFloat(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xFloat_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as float) to set with 
  void set_xFloat(float val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xFloat" :
  ///  \n Returns the value of the element
  ///  @return the value(as float) of the element 
  float get_xFloat();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDouble_p element_xDouble();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDouble(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDouble_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as double) to set with 
  void set_xDouble(double val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDouble" :
  ///  \n Returns the value of the element
  ///  @return the value(as double) of the element 
  double get_xDouble();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xInteger_p element_xInteger();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xInteger(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xInteger_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Int64) to set with 
  void set_xInteger(XPlus::Int64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInteger" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Int64) of the element 
  XPlus::Int64 get_xInteger();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xPositiveInteger_p element_xPositiveInteger();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xPositiveInteger(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xPositiveInteger_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::UInt64) to set with 
  void set_xPositiveInteger(XPlus::UInt64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xPositiveInteger" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::UInt64) of the element 
  XPlus::UInt64 get_xPositiveInteger();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xNonPositiveInteger_p element_xNonPositiveInteger();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xNonPositiveInteger(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xNonPositiveInteger_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Int64) to set with 
  void set_xNonPositiveInteger(XPlus::Int64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Int64) of the element 
  XPlus::Int64 get_xNonPositiveInteger();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xNegativeInteger_p element_xNegativeInteger();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xNegativeInteger(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xNegativeInteger_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Int64) to set with 
  void set_xNegativeInteger(XPlus::Int64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNegativeInteger" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Int64) of the element 
  XPlus::Int64 get_xNegativeInteger();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xNonNegativeInteger_p element_xNonNegativeInteger();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xNonNegativeInteger(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xNonNegativeInteger_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::UInt64) to set with 
  void set_xNonNegativeInteger(XPlus::UInt64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::UInt64) of the element 
  XPlus::UInt64 get_xNonNegativeInteger();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xLong_p element_xLong();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xLong(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xLong_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Int64) to set with 
  void set_xLong(XPlus::Int64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLong" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Int64) of the element 
  XPlus::Int64 get_xLong();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xInt_p element_xInt();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xInt(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xInt_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as int) to set with 
  void set_xInt(int val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xInt" :
  ///  \n Returns the value of the element
  ///  @return the value(as int) of the element 
  int get_xInt();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xShort_p element_xShort();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xShort(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xShort_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as short) to set with 
  void set_xShort(short val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xShort" :
  ///  \n Returns the value of the element
  ///  @return the value(as short) of the element 
  short get_xShort();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xByte_p element_xByte();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xByte(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xByte_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as char) to set with 
  void set_xByte(char val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xByte" :
  ///  \n Returns the value of the element
  ///  @return the value(as char) of the element 
  char get_xByte();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xUnsignedLong_p element_xUnsignedLong();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xUnsignedLong(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xUnsignedLong_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::UInt64) to set with 
  void set_xUnsignedLong(XPlus::UInt64 val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedLong" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::UInt64) of the element 
  XPlus::UInt64 get_xUnsignedLong();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xUnsignedInt_p element_xUnsignedInt();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xUnsignedInt(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xUnsignedInt_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as unsigned int) to set with 
  void set_xUnsignedInt(unsigned int val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedInt" :
  ///  \n Returns the value of the element
  ///  @return the value(as unsigned int) of the element 
  unsigned int get_xUnsignedInt();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xUnsignedShort_p element_xUnsignedShort();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xUnsignedShort(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xUnsignedShort_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as unsigned short) to set with 
  void set_xUnsignedShort(unsigned short val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedShort" :
  ///  \n Returns the value of the element
  ///  @return the value(as unsigned short) of the element 
  unsigned short get_xUnsignedShort();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xUnsignedByte_p element_xUnsignedByte();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xUnsignedByte(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xUnsignedByte_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as unsigned char) to set with 
  void set_xUnsignedByte(unsigned char val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUnsignedByte" :
  ///  \n Returns the value of the element
  ///  @return the value(as unsigned char) of the element 
  unsigned char get_xUnsignedByte();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xHexBinary_p element_xHexBinary();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xHexBinary(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xHexBinary" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xHexBinary_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xBase64Binary_p element_xBase64Binary();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xBase64Binary(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xBase64Binary" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xBase64Binary_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xUri_p element_xUri();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xUri(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xUri" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xUri_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xNormalizedString_p element_xNormalizedString();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xNormalizedString(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNormalizedString" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xNormalizedString_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xToken_p element_xToken();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xToken(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xToken" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xToken_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xLanguage_p element_xLanguage();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xLanguage(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xLanguage" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xLanguage_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xName_p element_xName();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xName(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xName" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xName_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xNCName_p element_xNCName();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xNCName(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xNCName" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xNCName_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xQName_p element_xQName();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xQName(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xQName" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xQName_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDateTime_p element_xDateTime();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDateTime(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDateTime_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::DateTime) to set with 
  void set_xDateTime(XPlus::DateTime val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDateTime" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::DateTime) of the element 
  XPlus::DateTime get_xDateTime();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDate_p element_xDate();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDate(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDate_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Date) to set with 
  void set_xDate(XPlus::Date val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDate" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Date) of the element 
  XPlus::Date get_xDate();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xYearMonth_p element_xYearMonth();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xYearMonth(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xYearMonth_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::YearMonth) to set with 
  void set_xYearMonth(XPlus::YearMonth val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYearMonth" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::YearMonth) of the element 
  XPlus::YearMonth get_xYearMonth();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xYear_p element_xYear();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xYear(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xYear_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Year) to set with 
  void set_xYear(XPlus::Year val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xYear" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Year) of the element 
  XPlus::Year get_xYear();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xMonthDay_p element_xMonthDay();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xMonthDay(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xMonthDay_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::MonthDay) to set with 
  void set_xMonthDay(XPlus::MonthDay val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonthDay" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::MonthDay) of the element 
  XPlus::MonthDay get_xMonthDay();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xMonth_p element_xMonth();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xMonth(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xMonth_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Month) to set with 
  void set_xMonth(XPlus::Month val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xMonth" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Month) of the element 
  XPlus::Month get_xMonth();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDay_p element_xDay();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDay(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDay_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Day) to set with 
  void set_xDay(XPlus::Day val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDay" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Day) of the element 
  XPlus::Day get_xDay();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xTime_p element_xTime();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xTime(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xTime_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Time) to set with 
  void set_xTime(XPlus::Time val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xTime" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Time) of the element 
  XPlus::Time get_xTime();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  xDuration_p element_xDuration();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_xDuration(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_xDuration_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Duration) to set with 
  void set_xDuration(XPlus::Duration val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}xDuration" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Duration) of the element 
  XPlus::Duration get_xDuration();

        

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Returns the list of the element nodes
  ///  @return the list of element nodes fetched
  List<anIntMax10_ptr> elements_anIntMax10();

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Returns the element node at supplied index
  ///  @param idx index of the element to fetch 
  ///  @return the element node fetched
  anIntMax10_p element_anIntMax10_at(unsigned int idx);

  

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Sets the value of the element at the supplied index with the supplied value
  ///  @param idx index of the element 
  ///  @param val the value(as DOMString) to set with 
  void set_anIntMax10(unsigned int idx, DOMString val);

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Returns the value of the element at the supplied index with the supplied value.
  ///  @param idx index of the element 
  ///  @return the value(as DOMString) of the element 
  DOMString get_anIntMax10_string(unsigned int idx);

        

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Sets the value of the element at the supplied index with the supplied value.
  ///  @param idx index of the element 
  ///  @param val the value (as int) to set with 
  void set_anIntMax10(unsigned int idx, int val);

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Returns the value of the element at the supplied index with supplied value.
  ///  @param idx index of the element 
  ///  @return the value(as int) of the element 
  int get_anIntMax10(unsigned int idx);

        

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Adds one element to the end of the "list of the element nodes"
  ///  @return the pointer to the added element
  anIntMax10_p add_node_anIntMax10();
  
  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Sizes-up the "list of the element nodes" with the supplied size
  ///  @param size the request size(unsigned int) of the list
  ///  @return the list of "pointer-to-element-node"
  List<anIntMax10_ptr> set_count_anIntMax10(unsigned int size);

      
      
  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
  ///  @param val the value(as DOMString) to set with 
  void add_anIntMax10_string(DOMString val);
      
        

  ///  For vector-element with QName "{}anIntMax10" :
  ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied type value
  ///  @param val the value(as int) to set with 
  void add_anIntMax10(int val);  
        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  anIntMax5k_p element_anIntMax5k();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_anIntMax5k(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_anIntMax5k_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as int) to set with 
  void set_anIntMax5k(int val);

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anIntMax5k" :
  ///  \n Returns the value of the element
  ///  @return the value(as int) of the element 
  int get_anIntMax5k();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  globalWaterTemp_p element_globalWaterTemp();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_globalWaterTemp(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_globalWaterTemp_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as double) to set with 
  void set_globalWaterTemp(double val);

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}globalWaterTemp" :
  ///  \n Returns the value of the element
  ///  @return the value(as double) of the element 
  double get_globalWaterTemp();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aSKU_p element_aSKU();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aSKU(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aSKU" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aSKU_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aDateTime_p element_aDateTime();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aDateTime(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aDateTime_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::DateTime) to set with 
  void set_aDateTime(XPlus::DateTime val);

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDateTime" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::DateTime) of the element 
  XPlus::DateTime get_aDateTime();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aDate_p element_aDate();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aDate(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aDate_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Date) to set with 
  void set_aDate(XPlus::Date val);

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aDate" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Date) of the element 
  XPlus::Date get_aDate();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aYear_p element_aYear();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aYear(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aYear_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Year) to set with 
  void set_aYear(XPlus::Year val);

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aYear" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Year) of the element 
  XPlus::Year get_aYear();

        
#ifndef __MyComplexType_aCommonName_member_public_fns
#define __MyComplexType_aCommonName_member_public_fns
      

  ///  For the scalar-element with QName "{}aCommonName" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aCommonName_p element_aCommonName();
      

  ///  For the scalar-element with QName "{}aCommonName" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aCommonName(DOMString val);
  
  ///  For the scalar-element with QName "{}aCommonName" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aCommonName_string();

        
#endif // __MyComplexType_aCommonName_member_public_fns
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aListOfIntMax5k_p element_aListOfIntMax5k();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aListOfIntMax5k(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfIntMax5k" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aListOfIntMax5k_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aListOfFourIntMax500_p element_aListOfFourIntMax500();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aListOfFourIntMax500(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfFourIntMax500" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aListOfFourIntMax500_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aListOfTwoIntMax3k_p element_aListOfTwoIntMax3k();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aListOfTwoIntMax3k(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aListOfTwoIntMax3k" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aListOfTwoIntMax3k_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  aFont_p element_aFont();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_aFont(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}aFont" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_aFont_string();

        

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  anotherFont_p element_anotherFont();
      

  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_anotherFont(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.example.com/STDemo}anotherFont" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_anotherFont_string();

        

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xID" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xID_p attribute_attr_xID();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xID" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xID(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xID" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xID_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xID" :
  ///  Marks the attribute as present 
  void mark_present_attr_xID();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREF" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xIDREF_p attribute_attr_xIDREF();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREF" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xIDREF(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREF" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xIDREF_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREF" :
  ///  Marks the attribute as present 
  void mark_present_attr_xIDREF();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREFS" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xIDREFS_p attribute_attr_xIDREFS();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREFS" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xIDREFS(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREFS" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xIDREFS_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xIDREFS" :
  ///  Marks the attribute as present 
  void mark_present_attr_xIDREFS();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITY" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xENTITY_p attribute_attr_xENTITY();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITY" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xENTITY(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITY" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xENTITY_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITY" :
  ///  Marks the attribute as present 
  void mark_present_attr_xENTITY();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITIES" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xENTITIES_p attribute_attr_xENTITIES();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITIES" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xENTITIES(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITIES" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xENTITIES_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xENTITIES" :
  ///  Marks the attribute as present 
  void mark_present_attr_xENTITIES();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKEN" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xNMTOKEN_p attribute_attr_xNMTOKEN();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKEN" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xNMTOKEN(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKEN" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xNMTOKEN_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKEN" :
  ///  Marks the attribute as present 
  void mark_present_attr_xNMTOKEN();

  

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKENS" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_xNMTOKENS_p attribute_attr_xNMTOKENS();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKENS" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_xNMTOKENS(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKENS" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_xNMTOKENS_string();

        

  ///  For the optional scalar attribute with QName "{http://www.w3.org/2001/XMLSchema}xNMTOKENS" :
  ///  Marks the attribute as present 
  void mark_present_attr_xNMTOKENS();

  

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}globalStringAttr" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_globalStringAttr_p attribute_attr_globalStringAttr();
      

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}globalStringAttr" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_globalStringAttr(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}globalStringAttr" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_globalStringAttr_string();

        

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNOTATION" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_aNOTATION_p attribute_attr_aNOTATION();
      

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNOTATION" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_aNOTATION(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNOTATION" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_aNOTATION_string();

        

  ///  For the optional scalar attribute with QName "{http://www.example.com/STDemo}aNOTATION" :
  ///  Marks the attribute as present 
  void mark_present_attr_aNOTATION();

  

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNNI" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_aNNI_p attribute_attr_aNNI();
      

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNNI" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_aNNI(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}aNNI" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_aNNI_string();

        

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}anotherNNI" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_anotherNNI_p attribute_attr_anotherNNI();
      

  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}anotherNNI" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_anotherNNI(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.example.com/STDemo}anotherNNI" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_anotherNNI_string();

        
#ifndef __MyComplexType_attr_aCommonName_member_public_fns
#define __MyComplexType_attr_aCommonName_member_public_fns
      

  ///  For the scalar-attribute with QName "{}aCommonName" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_aCommonName_p attribute_attr_aCommonName();
      

  ///  For the scalar-attribute with QName "{}aCommonName" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_aCommonName(DOMString val);
  
  ///  For the scalar-attribute with QName "{}aCommonName" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_aCommonName_string();

        
#endif // __MyComplexType_attr_aCommonName_member_public_fns
      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  xBoolean_ptr _xBoolean;
            
  xDecimal_ptr _xDecimal;
            
  xFloat_ptr _xFloat;
            
  xDouble_ptr _xDouble;
            
  xInteger_ptr _xInteger;
            
  xPositiveInteger_ptr _xPositiveInteger;
            
  xNonPositiveInteger_ptr _xNonPositiveInteger;
            
  xNegativeInteger_ptr _xNegativeInteger;
            
  xNonNegativeInteger_ptr _xNonNegativeInteger;
            
  xLong_ptr _xLong;
            
  xInt_ptr _xInt;
            
  xShort_ptr _xShort;
            
  xByte_ptr _xByte;
            
  xUnsignedLong_ptr _xUnsignedLong;
            
  xUnsignedInt_ptr _xUnsignedInt;
            
  xUnsignedShort_ptr _xUnsignedShort;
            
  xUnsignedByte_ptr _xUnsignedByte;
            
  xHexBinary_ptr _xHexBinary;
            
  xBase64Binary_ptr _xBase64Binary;
            
  xUri_ptr _xUri;
            
  xNormalizedString_ptr _xNormalizedString;
            
  xToken_ptr _xToken;
            
  xLanguage_ptr _xLanguage;
            
  xName_ptr _xName;
            
  xNCName_ptr _xNCName;
            
  xQName_ptr _xQName;
            
  xDateTime_ptr _xDateTime;
            
  xDate_ptr _xDate;
            
  xYearMonth_ptr _xYearMonth;
            
  xYear_ptr _xYear;
            
  xMonthDay_ptr _xMonthDay;
            
  xMonth_ptr _xMonth;
            
  xDay_ptr _xDay;
            
  xTime_ptr _xTime;
            
  xDuration_ptr _xDuration;
            
  List<anIntMax10_ptr> _list_anIntMax10;
            
  anIntMax5k_ptr _anIntMax5k;
            
  globalWaterTemp_ptr _globalWaterTemp;
            
  aSKU_ptr _aSKU;
            
  aDateTime_ptr _aDateTime;
            
  aDate_ptr _aDate;
            
  aYear_ptr _aYear;
            
#ifndef __MyComplexType_aCommonName_member_variables
#define __MyComplexType_aCommonName_member_variables
      
  aCommonName_ptr _aCommonName;
            
#endif // __MyComplexType_aCommonName_member_variables
      
  aListOfIntMax5k_ptr _aListOfIntMax5k;
            
  aListOfFourIntMax500_ptr _aListOfFourIntMax500;
            
  aListOfTwoIntMax3k_ptr _aListOfTwoIntMax3k;
            
  aFont_ptr _aFont;
            
  anotherFont_ptr _anotherFont;
            
  attr_xID_ptr _attr_xID;
        
  attr_xIDREF_ptr _attr_xIDREF;
        
  attr_xIDREFS_ptr _attr_xIDREFS;
        
  attr_xENTITY_ptr _attr_xENTITY;
        
  attr_xENTITIES_ptr _attr_xENTITIES;
        
  attr_xNMTOKEN_ptr _attr_xNMTOKEN;
        
  attr_xNMTOKENS_ptr _attr_xNMTOKENS;
        
  attr_globalStringAttr_ptr _attr_globalStringAttr;
        
  attr_aNOTATION_ptr _attr_aNOTATION;
        
  attr_aNNI_ptr _attr_aNNI;
        
  attr_anotherNNI_ptr _attr_anotherNNI;
        
#ifndef __MyComplexType_attr_aCommonName_member_variables
#define __MyComplexType_attr_aCommonName_member_variables
      
  attr_aCommonName_ptr _attr_aCommonName;
        
#endif // __MyComplexType_attr_aCommonName_member_variables
        

  /// initialize the FSM
  void initFSM();

  
  xBoolean_ptr create_xBoolean(FsmCbOptions& options);

  xDecimal_ptr create_xDecimal(FsmCbOptions& options);

  xFloat_ptr create_xFloat(FsmCbOptions& options);

  xDouble_ptr create_xDouble(FsmCbOptions& options);

  xInteger_ptr create_xInteger(FsmCbOptions& options);

  xPositiveInteger_ptr create_xPositiveInteger(FsmCbOptions& options);

  xNonPositiveInteger_ptr create_xNonPositiveInteger(FsmCbOptions& options);

  xNegativeInteger_ptr create_xNegativeInteger(FsmCbOptions& options);

  xNonNegativeInteger_ptr create_xNonNegativeInteger(FsmCbOptions& options);

  xLong_ptr create_xLong(FsmCbOptions& options);

  xInt_ptr create_xInt(FsmCbOptions& options);

  xShort_ptr create_xShort(FsmCbOptions& options);

  xByte_ptr create_xByte(FsmCbOptions& options);

  xUnsignedLong_ptr create_xUnsignedLong(FsmCbOptions& options);

  xUnsignedInt_ptr create_xUnsignedInt(FsmCbOptions& options);

  xUnsignedShort_ptr create_xUnsignedShort(FsmCbOptions& options);

  xUnsignedByte_ptr create_xUnsignedByte(FsmCbOptions& options);

  xHexBinary_ptr create_xHexBinary(FsmCbOptions& options);

  xBase64Binary_ptr create_xBase64Binary(FsmCbOptions& options);

  xUri_ptr create_xUri(FsmCbOptions& options);

  xNormalizedString_ptr create_xNormalizedString(FsmCbOptions& options);

  xToken_ptr create_xToken(FsmCbOptions& options);

  xLanguage_ptr create_xLanguage(FsmCbOptions& options);

  xName_ptr create_xName(FsmCbOptions& options);

  xNCName_ptr create_xNCName(FsmCbOptions& options);

  xQName_ptr create_xQName(FsmCbOptions& options);

  xDateTime_ptr create_xDateTime(FsmCbOptions& options);

  xDate_ptr create_xDate(FsmCbOptions& options);

  xYearMonth_ptr create_xYearMonth(FsmCbOptions& options);

  xYear_ptr create_xYear(FsmCbOptions& options);

  xMonthDay_ptr create_xMonthDay(FsmCbOptions& options);

  xMonth_ptr create_xMonth(FsmCbOptions& options);

  xDay_ptr create_xDay(FsmCbOptions& options);

  xTime_ptr create_xTime(FsmCbOptions& options);

  xDuration_ptr create_xDuration(FsmCbOptions& options);

  anIntMax10_ptr create_anIntMax10(FsmCbOptions& options);

  anIntMax5k_ptr create_anIntMax5k(FsmCbOptions& options);

  globalWaterTemp_ptr create_globalWaterTemp(FsmCbOptions& options);

  aSKU_ptr create_aSKU(FsmCbOptions& options);

  aDateTime_ptr create_aDateTime(FsmCbOptions& options);

  aDate_ptr create_aDate(FsmCbOptions& options);

  aYear_ptr create_aYear(FsmCbOptions& options);

#ifndef __MyComplexType_aCommonName_private_fns
#define __MyComplexType_aCommonName_private_fns
      
  aCommonName_ptr create_aCommonName(FsmCbOptions& options);

#endif // __MyComplexType_aCommonName_private_fns
      
  aListOfIntMax5k_ptr create_aListOfIntMax5k(FsmCbOptions& options);

  aListOfFourIntMax500_ptr create_aListOfFourIntMax500(FsmCbOptions& options);

  aListOfTwoIntMax3k_ptr create_aListOfTwoIntMax3k(FsmCbOptions& options);

  aFont_ptr create_aFont(FsmCbOptions& options);

  anotherFont_ptr create_anotherFont(FsmCbOptions& options);

  attr_xID_ptr create_attr_xID(FsmCbOptions& options);

  attr_xIDREF_ptr create_attr_xIDREF(FsmCbOptions& options);

  attr_xIDREFS_ptr create_attr_xIDREFS(FsmCbOptions& options);

  attr_xENTITY_ptr create_attr_xENTITY(FsmCbOptions& options);

  attr_xENTITIES_ptr create_attr_xENTITIES(FsmCbOptions& options);

  attr_xNMTOKEN_ptr create_attr_xNMTOKEN(FsmCbOptions& options);

  attr_xNMTOKENS_ptr create_attr_xNMTOKENS(FsmCbOptions& options);

  attr_globalStringAttr_ptr create_attr_globalStringAttr(FsmCbOptions& options);

  attr_aNOTATION_ptr create_attr_aNOTATION(FsmCbOptions& options);

  attr_aNNI_ptr create_attr_aNNI(FsmCbOptions& options);

  attr_anotherNNI_ptr create_attr_anotherNNI(FsmCbOptions& options);

#ifndef __MyComplexType_attr_aCommonName_private_fns
#define __MyComplexType_attr_aCommonName_private_fns
      
  attr_aCommonName_ptr create_attr_aCommonName(FsmCbOptions& options);

#endif // __MyComplexType_attr_aCommonName_private_fns
        

public:

  //types which this class needs, as INNER CLASSES
    

  /// class for simpleType with restriction on base
  class _anIntMax10 : public XMLSchema::Types::bt_int
  {
  public:
    /// constructor  
    _anIntMax10(AnyTypeCreateArgs args)
    
        : bt_int(args)
      
    {
    
      maxInclusiveCFacet().stringValue("10");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXINCLUSIVE );
    }
    
  protected:
    
  };
  

  /// class for simpleType with restriction on base
  class _aCommonName : public XMLSchema::Types::bt_string
  {
  public:
    /// constructor  
    _aCommonName(AnyTypeCreateArgs args)
    
        : bt_string(args)
      
    {
    
      _lengthCFacet.stringValue("5");
      
      this->appliedCFacets( appliedCFacets() | CF_LENGTH );
    }
    
  protected:
    
  };
  

  /// class for simpleType with restriction on base
  class _attr_aCommonName : public XMLSchema::Types::bt_string
  {
  public:
    /// constructor  
    _attr_aCommonName(AnyTypeCreateArgs args)
    
        : bt_string(args)
      
    {
    
      _lengthCFacet.stringValue("5");
      
      this->appliedCFacets( appliedCFacets() | CF_LENGTH );
    }
    
  protected:
    
  };

  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<MyComplexType> >   s_typeRegistry;
}; //end class MyComplexType
} // end namespace Types


} // end namespace      
    
#endif
  


examples/simpleTypesDemo/include/STDemo/Types/DateTimeInARange.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_DateTimeInARange_H__ 
#define __STDemo_DateTimeInARange_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class DateTimeInARange : public XMLSchema::Types::bt_dateTime
  {
  public:
    /// constructor  
    DateTimeInARange(AnyTypeCreateArgs args)
    
        : bt_dateTime(args)
      
    {
    
      minInclusiveCFacet().stringValue("2010-01-01T12:00:00Z");
          
      maxInclusiveCFacet().stringValue("2010-05-31T23:00:00Z");
          
      this->appliedCFacets( appliedCFacets() | CF_MININCLUSIVE| CF_MAXINCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/EnumNNI.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_EnumNNI_H__ 
#define __STDemo_EnumNNI_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"
 
#include "XSD/SimpleTypeUnionTmpl.h"      
      

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
  
  /// class for simpleType of variety union
  

  class EnumNNI : public XMLSchema::Types::SimpleTypeUnionTmpl
  {
  public:
      

  /// class for simpleType with restriction on base
  class EnumNNI_union_simpleType1 : public XMLSchema::Types::bt_NMTOKEN
  {
  public:
    /// constructor  
    EnumNNI_union_simpleType1(AnyTypeCreateArgs args)
    
        : bt_NMTOKEN(args)
      
    {
    
      vector<DOMString> enums;
    
      enums.push_back("unbounded");
    
      _enumerationCFacet.value(enums);
  
      this->appliedCFacets( appliedCFacets() | CF_ENUMERATION );
    }
    
  protected:
    
  };


    /// constructor  
    EnumNNI(AnyTypeCreateArgs args):
      XMLSchema::Types::SimpleTypeUnionTmpl(args)
    {
      
       _unionMembers.push_back(new XMLSchema::Types::bt_nonNegativeInteger(AnyTypeCreateArgs()));

      _unionMembers.push_back(new EnumNNI_union_simpleType1(AnyTypeCreateArgs()));
    
    }

    virtual DOMString stringValue() {
      return _value;
    }

    virtual void stringValue(DOMString val)
    {
      SimpleTypeUnionTmpl::stringValue(val);
    }

    virtual inline DOMString sampleValue() 
    {
      return SimpleTypeUnionTmpl::sampleValue();
    }

  protected:

    
  };
  
} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/ListOfFourIntMax500.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_ListOfFourIntMax500_H__ 
#define __STDemo_ListOfFourIntMax500_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"

#include "STDemo/Types/ListOfIntMax500.h"      
      

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class ListOfFourIntMax500 : public STDemo::Types::ListOfIntMax500
  {
  public:
    /// constructor  
    ListOfFourIntMax500(AnyTypeCreateArgs args)
    
        : ListOfIntMax500(args)
      
    {
    
      _maxLengthCFacet.stringValue("4");
      
      this->appliedCFacets( appliedCFacets() | CF_MAXLENGTH );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/CelciusWaterTemp.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_CelciusWaterTemp_H__ 
#define __STDemo_CelciusWaterTemp_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class CelciusWaterTemp : public XMLSchema::Types::bt_decimal
  {
  public:
    /// constructor  
    CelciusWaterTemp(AnyTypeCreateArgs args)
    
        : bt_decimal(args)
      
    {
    
      _fractionDigitsCFacet.stringValue("2");
      
      minExclusiveCFacet().stringValue("0.00");
          
      maxExclusiveCFacet().stringValue("100.00");
          
      this->appliedCFacets( appliedCFacets() | CF_FRACTIONDIGITS| CF_MINEXCLUSIVE| CF_MAXEXCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/ListOfIntMax3k.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_ListOfIntMax3k_H__ 
#define __STDemo_ListOfIntMax3k_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"
 
#include "XSD/SimpleTypeListTmpl.h"      
      

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class ListOfIntMax3k_list_simpleType_restriction_simpleType : public STDemo::Types::IntMax5k
  {
  public:
    /// constructor  
    ListOfIntMax3k_list_simpleType_restriction_simpleType(AnyTypeCreateArgs args)
    
        : IntMax5k(args)
      
    {
    
      maxExclusiveCFacet().stringValue("4000");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXEXCLUSIVE );
    }
    
  protected:
    
  };


  /// class for simpleType with restriction on simpleType
  class ListOfIntMax3k_list_simpleType1 : public ListOfIntMax3k_list_simpleType_restriction_simpleType
  {
  public:
    /// constructor  
    ListOfIntMax3k_list_simpleType1(AnyTypeCreateArgs args):
      ListOfIntMax3k_list_simpleType_restriction_simpleType(args)
    {
      
      maxExclusiveCFacet().stringValue("3000");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXEXCLUSIVE );
    }
    
  };


  typedef XMLSchema::Types::SimpleTypeListTmpl<ListOfIntMax3k_list_simpleType1> ListOfIntMax3k;
        
} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/Fontbynumber.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_Fontbynumber_H__ 
#define __STDemo_Fontbynumber_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
    

  /// class for simpleType with restriction on base
  class Fontbynumber : public XMLSchema::Types::bt_positiveInteger
  {
  public:
    /// constructor  
    Fontbynumber(AnyTypeCreateArgs args)
    
        : bt_positiveInteger(args)
      
    {
    
      maxInclusiveCFacet().stringValue("72");
          
      this->appliedCFacets( appliedCFacets() | CF_MAXINCLUSIVE );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/include/STDemo/Types/ListOfIntMax5k.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __STDemo_ListOfIntMax5k_H__ 
#define __STDemo_ListOfIntMax5k_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"
 
#include "XSD/SimpleTypeListTmpl.h"      
      
#include  "STDemo/Types/IntMax5k.h"
        

using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace STDemo{


namespace Types 
{
  
  typedef XMLSchema::Types::SimpleTypeListTmpl<STDemo::Types::IntMax5k> ListOfIntMax5k;
    
} // end namespace Types

} // end namespace      
    

#endif
  


examples/simpleTypesDemo/main.cpp

#include <iostream>
#include <string>

#include "XSD/UserOps.h"
#include "STDemo/all-include.h"

void populateDocument(STDemo::Document* xsdDoc);
void updateOrConsumeDocument(STDemo::Document* xsdDoc);
  
void chooseDocumentElement(STDemo::Document* xsdDoc);
    

int main (int argc, char**argv)
{
  XSD::UserOps<STDemo::Document>::UserOpsCbStruct cbStruct;
  cbStruct.cbPopulateDocument           =  populateDocument;
  cbStruct.cbUpdateOrConsumeDocument    =  updateOrConsumeDocument;
  
  cbStruct.cbChooseDocumentElement    =  chooseDocumentElement;
  

  XSD::UserOps<STDemo::Document> opHandle(cbStruct);
  opHandle.run(argc, argv);
}

//
// Following functions are use case templates.
// You need to put "code" in the respective contexts.
//

  
// choose the element inside Document that you want as root using
// a call like : xsdDoc->set_root_xyz();
void chooseDocumentElement(STDemo::Document* xsdDoc)
{
  // uncomment one of folowing to choose root
  
  xsdDoc->set_root_myComplexTypeElem();
  
  //xsdDoc->set_root_globalWaterTemp();
    
}
    

// template function to populate the Tree with values
// write code to populate the Document here
void populateDocument(STDemo::Document* xsdDoc)
{
  //
  // Noteworthy Things:
  //
  // - aCommonName : both an element and an attribute share this name, please 
  //                 note the namespace/naming differences in generated classes
  //                 corresponding to these two 
  //
  // - many elements inside MyComplexType are not populated here, they would 
  //   show up in the xml with their default/fixed values
  //

  DOM::Node* markerNode = NULL;

  STDemo::myComplexTypeElem *rootElem = xsdDoc->element_myComplexTypeElem();
  
  // set attributes
  rootElem->set_attr_aCommonName("abcde");
  rootElem->set_attr_globalStringAttr("abc");
  rootElem->set_attr_aNNI("unbounded");
  rootElem->set_attr_anotherNNI("100");

  //  begin : atomic simpleType elements        
  rootElem->set_anIntMax10(0, 10);
  rootElem->set_anIntMax10(1, 10);
  rootElem->set_anIntMax10(2, 10);
  rootElem->set_anIntMax5k(4999);
  rootElem->set_aSKU("123-AB");
  rootElem->set_globalWaterTemp(30.00);
  rootElem->set_aDateTime("2010-01-04T12:00:00Z");
  // let default show up
  //rootElem->set_aDate("2009");
  rootElem->set_aYear(2009);
  rootElem->set_aCommonName("abcde");
  //  end : atomic simpleType elements

  //  begin : list simpleType elements        
  rootElem->set_aListOfIntMax5k("0 1000 2000 3000 4000");
  rootElem->set_aListOfFourIntMax500("100 200 300 400");
  rootElem->set_aListOfTwoIntMax3k("1000 2000");
  //  end : list simpleType elements

  
  //  begin : union simpleType elements        
  //rootElem->set_aNNI("unbounded");
  //rootElem->set_anotherNNI("100");


  rootElem->set_aFont("medium");
  rootElem->set_anotherFont("72");
  //  end : union simpleType elements

  // set some text nodes which also do the job of describing the element sections
  rootElem->setTextAmongChildrenAt("\nHere you will see some examples of simpleType elements", 0);
  rootElem->setTextAmongChildrenAt("\nFollowing are examples of -atomic- simpleType elements", 1);
  markerNode = rootElem->element_aCommonName();
  rootElem->setTextAfterNode("End of -atomic- simpleType elements\n  Following are examples of -list- simpleType elements", markerNode);
  markerNode = rootElem->element_aListOfTwoIntMax3k();
  rootElem->setTextAfterNode("End of -list- simpleType elements\n Following are examples of -union- simpleType elements", markerNode);
  rootElem->setTextEnd("End of -union- simpleType elements\nEnd of all example elements");

}

// write code to operate(update/consume/test etc.) on the Document, which is already
// populated(eg. read from an input xml file)
void updateOrConsumeDocument(STDemo::Document* xsdDoc)
{

}

  


examples/simpleTypesDemo/src/STDemo/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "STDemo/Document.h"


namespace STDemo{


  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(true);
    DOM::Document::elementDefaultQualified(true);
    
  }

  void Document::initFSM()
  {
  
    _fsm_myComplexTypeElem = new XsdFSM<myComplexTypeElem_ptr>( Particle(new DOMString("http://www.example.com/STDemo"),  DOMString("myComplexTypeElem"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<myComplexTypeElem_ptr, Document, FsmCbOptions>(this, &Document::create_myComplexTypeElem));
  
    _fsm_globalWaterTemp = new XsdFSM<globalWaterTemp_ptr>( Particle(new DOMString("http://www.example.com/STDemo"),  DOMString("globalWaterTemp"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<globalWaterTemp_ptr, Document, FsmCbOptions>(this, &Document::create_globalWaterTemp));
  
    XsdFsmBasePtr elemFsms[] = {
    _fsm_myComplexTypeElem,
    _fsm_globalWaterTemp,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  
    void Document::set_root_myComplexTypeElem() 
    {
    
      if(!_myComplexTypeElem) {
        XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("myComplexTypeElem"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    
    void Document::set_root_globalWaterTemp() 
    {
    
      if(!_globalWaterTemp) {
        XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("globalWaterTemp"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    


  /* element functions  */
  

  myComplexTypeElem_ptr Document::create_myComplexTypeElem(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("myComplexTypeElem");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "http://www.example.com/STDemo", "MyComplexType");
    myComplexTypeElem_p node = XSD::createElementTmpl<myComplexTypeElem, STDemo::Types::MyComplexType*>(t);
          
    _myComplexTypeElem = node;
      
    return node;
  }

  
  myComplexTypeElem_p Document::element_myComplexTypeElem()
  {
    FSM::warnNullNode(_myComplexTypeElem, "myComplexTypeElem", "{http://www.example.com/STDemo}myComplexTypeElem", 1);
    return _myComplexTypeElem;
  }
    

  globalWaterTemp_ptr Document::create_globalWaterTemp(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("globalWaterTemp");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "http://www.example.com/STDemo", "CelciusWaterTemp");
    globalWaterTemp_p node = XSD::createElementTmpl<globalWaterTemp, STDemo::Types::CelciusWaterTemp*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _globalWaterTemp = node;
      
    return node;
  }

  
  globalWaterTemp_p Document::element_globalWaterTemp()
  {
    FSM::warnNullNode(_globalWaterTemp, "globalWaterTemp", "{http://www.example.com/STDemo}globalWaterTemp", 1);
    return _globalWaterTemp;
  }
    
} // end namespace      
    


examples/simpleTypesDemo/src/STDemo/Types/MyComplexType.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "STDemo/Types/MyComplexType.h"

namespace STDemo{

namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<MyComplexType> > MyComplexType::s_typeRegistry("MyComplexType", "http://www.example.com/STDemo");

  

  //constructor
  
  MyComplexType::MyComplexType(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_MIXED);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void MyComplexType::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  new XsdFSM<attr_xID_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xID"), 0, 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xID_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xID)),
  new XsdFSM<attr_xIDREF_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xIDREF"), 0, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xIDREF_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xIDREF)),
  new XsdFSM<attr_xIDREFS_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xIDREFS"), 0, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xIDREFS_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xIDREFS)),
  new XsdFSM<attr_xENTITY_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xENTITY"), 0, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xENTITY_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xENTITY)),
  new XsdFSM<attr_xENTITIES_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xENTITIES"), 0, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xENTITIES_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xENTITIES)),
  new XsdFSM<attr_xNMTOKEN_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNMTOKEN"), 0, 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xNMTOKEN_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xNMTOKEN)),
  new XsdFSM<attr_xNMTOKENS_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNMTOKENS"), 0, 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_xNMTOKENS_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_xNMTOKENS)),
  new XsdFSM<attr_globalStringAttr_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("globalStringAttr"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_globalStringAttr_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_globalStringAttr)),
  new XsdFSM<attr_aNOTATION_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aNOTATION"), 0, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_aNOTATION_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_aNOTATION)),
  new XsdFSM<attr_aNNI_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aNNI"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_aNNI_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_aNNI)),
  new XsdFSM<attr_anotherNNI_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("anotherNNI"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_anotherNNI_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_anotherNNI)),
  new XsdFSM<attr_aCommonName_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aCommonName"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_aCommonName_ptr, MyComplexType, FsmCbOptions>(this, &MyComplexType::create_attr_aCommonName)),
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  MyComplexType::xBoolean_ptr MyComplexType::create_xBoolean(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xBoolean");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, true, "http://www.w3.org/2001/XMLSchema", "boolean");
    MyComplexType::xBoolean_p node = XSD::createElementTmpl<xBoolean, XMLSchema::Types::bt_boolean*>(t);
          
    node->defaultValue("false");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xBoolean = node;
      
    return node;
  }

  
  MyComplexType::xBoolean_p MyComplexType::element_xBoolean()
  {
    FSM::warnNullNode(_xBoolean, "xBoolean", "{http://www.w3.org/2001/XMLSchema}xBoolean", 1);
    return _xBoolean;
  }
    
  void MyComplexType::set_xBoolean(DOMString val)
  {
    get_sequence()->set_xBoolean(val);
  }

  DOMString MyComplexType::get_xBoolean_string()
  {
    return get_sequence()->get_xBoolean_string();
  }

          
  void MyComplexType::set_xBoolean(bool val)
  {
    get_sequence()->set_xBoolean(val);
  }
  
  bool MyComplexType::get_xBoolean()
  {
    return get_sequence()->get_xBoolean();
  }

          

  MyComplexType::xDecimal_ptr MyComplexType::create_xDecimal(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDecimal");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "decimal");
    MyComplexType::xDecimal_p node = XSD::createElementTmpl<xDecimal, XMLSchema::Types::bt_decimal*>(t);
          
    node->defaultValue("-1.23e-6");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDecimal = node;
      
    return node;
  }

  
  MyComplexType::xDecimal_p MyComplexType::element_xDecimal()
  {
    FSM::warnNullNode(_xDecimal, "xDecimal", "{http://www.w3.org/2001/XMLSchema}xDecimal", 1);
    return _xDecimal;
  }
    
  void MyComplexType::set_xDecimal(DOMString val)
  {
    get_sequence()->set_xDecimal(val);
  }

  DOMString MyComplexType::get_xDecimal_string()
  {
    return get_sequence()->get_xDecimal_string();
  }

          
  void MyComplexType::set_xDecimal(double val)
  {
    get_sequence()->set_xDecimal(val);
  }
  
  double MyComplexType::get_xDecimal()
  {
    return get_sequence()->get_xDecimal();
  }

          

  MyComplexType::xFloat_ptr MyComplexType::create_xFloat(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xFloat");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "float");
    MyComplexType::xFloat_p node = XSD::createElementTmpl<xFloat, XMLSchema::Types::bt_float*>(t);
          
    node->defaultValue("-1.23e-3");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xFloat = node;
      
    return node;
  }

  
  MyComplexType::xFloat_p MyComplexType::element_xFloat()
  {
    FSM::warnNullNode(_xFloat, "xFloat", "{http://www.w3.org/2001/XMLSchema}xFloat", 1);
    return _xFloat;
  }
    
  void MyComplexType::set_xFloat(DOMString val)
  {
    get_sequence()->set_xFloat(val);
  }

  DOMString MyComplexType::get_xFloat_string()
  {
    return get_sequence()->get_xFloat_string();
  }

          
  void MyComplexType::set_xFloat(float val)
  {
    get_sequence()->set_xFloat(val);
  }
  
  float MyComplexType::get_xFloat()
  {
    return get_sequence()->get_xFloat();
  }

          

  MyComplexType::xDouble_ptr MyComplexType::create_xDouble(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDouble");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "double");
    MyComplexType::xDouble_p node = XSD::createElementTmpl<xDouble, XMLSchema::Types::bt_double*>(t);
          
    node->defaultValue("-1.23e-5");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDouble = node;
      
    return node;
  }

  
  MyComplexType::xDouble_p MyComplexType::element_xDouble()
  {
    FSM::warnNullNode(_xDouble, "xDouble", "{http://www.w3.org/2001/XMLSchema}xDouble", 1);
    return _xDouble;
  }
    
  void MyComplexType::set_xDouble(DOMString val)
  {
    get_sequence()->set_xDouble(val);
  }

  DOMString MyComplexType::get_xDouble_string()
  {
    return get_sequence()->get_xDouble_string();
  }

          
  void MyComplexType::set_xDouble(double val)
  {
    get_sequence()->set_xDouble(val);
  }
  
  double MyComplexType::get_xDouble()
  {
    return get_sequence()->get_xDouble();
  }

          

  MyComplexType::xInteger_ptr MyComplexType::create_xInteger(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xInteger");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "integer");
    MyComplexType::xInteger_p node = XSD::createElementTmpl<xInteger, XMLSchema::Types::bt_integer*>(t);
          
    node->defaultValue("-12678967543233");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xInteger = node;
      
    return node;
  }

  
  MyComplexType::xInteger_p MyComplexType::element_xInteger()
  {
    FSM::warnNullNode(_xInteger, "xInteger", "{http://www.w3.org/2001/XMLSchema}xInteger", 1);
    return _xInteger;
  }
    
  void MyComplexType::set_xInteger(DOMString val)
  {
    get_sequence()->set_xInteger(val);
  }

  DOMString MyComplexType::get_xInteger_string()
  {
    return get_sequence()->get_xInteger_string();
  }

          
  void MyComplexType::set_xInteger(XPlus::Int64 val)
  {
    get_sequence()->set_xInteger(val);
  }
  
  XPlus::Int64 MyComplexType::get_xInteger()
  {
    return get_sequence()->get_xInteger();
  }

          

  MyComplexType::xPositiveInteger_ptr MyComplexType::create_xPositiveInteger(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xPositiveInteger");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "positiveInteger");
    MyComplexType::xPositiveInteger_p node = XSD::createElementTmpl<xPositiveInteger, XMLSchema::Types::bt_positiveInteger*>(t);
          
    node->defaultValue("12678967543233");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xPositiveInteger = node;
      
    return node;
  }

  
  MyComplexType::xPositiveInteger_p MyComplexType::element_xPositiveInteger()
  {
    FSM::warnNullNode(_xPositiveInteger, "xPositiveInteger", "{http://www.w3.org/2001/XMLSchema}xPositiveInteger", 1);
    return _xPositiveInteger;
  }
    
  void MyComplexType::set_xPositiveInteger(DOMString val)
  {
    get_sequence()->set_xPositiveInteger(val);
  }

  DOMString MyComplexType::get_xPositiveInteger_string()
  {
    return get_sequence()->get_xPositiveInteger_string();
  }

          
  void MyComplexType::set_xPositiveInteger(XPlus::UInt64 val)
  {
    get_sequence()->set_xPositiveInteger(val);
  }
  
  XPlus::UInt64 MyComplexType::get_xPositiveInteger()
  {
    return get_sequence()->get_xPositiveInteger();
  }

          

  MyComplexType::xNonPositiveInteger_ptr MyComplexType::create_xNonPositiveInteger(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNonPositiveInteger");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "nonPositiveInteger");
    MyComplexType::xNonPositiveInteger_p node = XSD::createElementTmpl<xNonPositiveInteger, XMLSchema::Types::bt_nonPositiveInteger*>(t);
          
    node->defaultValue("-12678967543233");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xNonPositiveInteger = node;
      
    return node;
  }

  
  MyComplexType::xNonPositiveInteger_p MyComplexType::element_xNonPositiveInteger()
  {
    FSM::warnNullNode(_xNonPositiveInteger, "xNonPositiveInteger", "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger", 1);
    return _xNonPositiveInteger;
  }
    
  void MyComplexType::set_xNonPositiveInteger(DOMString val)
  {
    get_sequence()->set_xNonPositiveInteger(val);
  }

  DOMString MyComplexType::get_xNonPositiveInteger_string()
  {
    return get_sequence()->get_xNonPositiveInteger_string();
  }

          
  void MyComplexType::set_xNonPositiveInteger(XPlus::Int64 val)
  {
    get_sequence()->set_xNonPositiveInteger(val);
  }
  
  XPlus::Int64 MyComplexType::get_xNonPositiveInteger()
  {
    return get_sequence()->get_xNonPositiveInteger();
  }

          

  MyComplexType::xNegativeInteger_ptr MyComplexType::create_xNegativeInteger(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNegativeInteger");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "negativeInteger");
    MyComplexType::xNegativeInteger_p node = XSD::createElementTmpl<xNegativeInteger, XMLSchema::Types::bt_negativeInteger*>(t);
          
    node->defaultValue("-12678967543233");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xNegativeInteger = node;
      
    return node;
  }

  
  MyComplexType::xNegativeInteger_p MyComplexType::element_xNegativeInteger()
  {
    FSM::warnNullNode(_xNegativeInteger, "xNegativeInteger", "{http://www.w3.org/2001/XMLSchema}xNegativeInteger", 1);
    return _xNegativeInteger;
  }
    
  void MyComplexType::set_xNegativeInteger(DOMString val)
  {
    get_sequence()->set_xNegativeInteger(val);
  }

  DOMString MyComplexType::get_xNegativeInteger_string()
  {
    return get_sequence()->get_xNegativeInteger_string();
  }

          
  void MyComplexType::set_xNegativeInteger(XPlus::Int64 val)
  {
    get_sequence()->set_xNegativeInteger(val);
  }
  
  XPlus::Int64 MyComplexType::get_xNegativeInteger()
  {
    return get_sequence()->get_xNegativeInteger();
  }

          

  MyComplexType::xNonNegativeInteger_ptr MyComplexType::create_xNonNegativeInteger(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNonNegativeInteger");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "nonNegativeInteger");
    MyComplexType::xNonNegativeInteger_p node = XSD::createElementTmpl<xNonNegativeInteger, XMLSchema::Types::bt_nonNegativeInteger*>(t);
          
    node->defaultValue("12678967543233");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xNonNegativeInteger = node;
      
    return node;
  }

  
  MyComplexType::xNonNegativeInteger_p MyComplexType::element_xNonNegativeInteger()
  {
    FSM::warnNullNode(_xNonNegativeInteger, "xNonNegativeInteger", "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger", 1);
    return _xNonNegativeInteger;
  }
    
  void MyComplexType::set_xNonNegativeInteger(DOMString val)
  {
    get_sequence()->set_xNonNegativeInteger(val);
  }

  DOMString MyComplexType::get_xNonNegativeInteger_string()
  {
    return get_sequence()->get_xNonNegativeInteger_string();
  }

          
  void MyComplexType::set_xNonNegativeInteger(XPlus::UInt64 val)
  {
    get_sequence()->set_xNonNegativeInteger(val);
  }
  
  XPlus::UInt64 MyComplexType::get_xNonNegativeInteger()
  {
    return get_sequence()->get_xNonNegativeInteger();
  }

          

  MyComplexType::xLong_ptr MyComplexType::create_xLong(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xLong");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "long");
    MyComplexType::xLong_p node = XSD::createElementTmpl<xLong, XMLSchema::Types::bt_long*>(t);
          
    node->defaultValue("-9223372036854775808");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xLong = node;
      
    return node;
  }

  
  MyComplexType::xLong_p MyComplexType::element_xLong()
  {
    FSM::warnNullNode(_xLong, "xLong", "{http://www.w3.org/2001/XMLSchema}xLong", 1);
    return _xLong;
  }
    
  void MyComplexType::set_xLong(DOMString val)
  {
    get_sequence()->set_xLong(val);
  }

  DOMString MyComplexType::get_xLong_string()
  {
    return get_sequence()->get_xLong_string();
  }

          
  void MyComplexType::set_xLong(XPlus::Int64 val)
  {
    get_sequence()->set_xLong(val);
  }
  
  XPlus::Int64 MyComplexType::get_xLong()
  {
    return get_sequence()->get_xLong();
  }

          

  MyComplexType::xInt_ptr MyComplexType::create_xInt(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xInt");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "int");
    MyComplexType::xInt_p node = XSD::createElementTmpl<xInt, XMLSchema::Types::bt_int*>(t);
          
    node->defaultValue("-2147483648");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xInt = node;
      
    return node;
  }

  
  MyComplexType::xInt_p MyComplexType::element_xInt()
  {
    FSM::warnNullNode(_xInt, "xInt", "{http://www.w3.org/2001/XMLSchema}xInt", 1);
    return _xInt;
  }
    
  void MyComplexType::set_xInt(DOMString val)
  {
    get_sequence()->set_xInt(val);
  }

  DOMString MyComplexType::get_xInt_string()
  {
    return get_sequence()->get_xInt_string();
  }

          
  void MyComplexType::set_xInt(int val)
  {
    get_sequence()->set_xInt(val);
  }
  
  int MyComplexType::get_xInt()
  {
    return get_sequence()->get_xInt();
  }

          

  MyComplexType::xShort_ptr MyComplexType::create_xShort(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xShort");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "short");
    MyComplexType::xShort_p node = XSD::createElementTmpl<xShort, XMLSchema::Types::bt_short*>(t);
          
    node->defaultValue("-32768");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xShort = node;
      
    return node;
  }

  
  MyComplexType::xShort_p MyComplexType::element_xShort()
  {
    FSM::warnNullNode(_xShort, "xShort", "{http://www.w3.org/2001/XMLSchema}xShort", 1);
    return _xShort;
  }
    
  void MyComplexType::set_xShort(DOMString val)
  {
    get_sequence()->set_xShort(val);
  }

  DOMString MyComplexType::get_xShort_string()
  {
    return get_sequence()->get_xShort_string();
  }

          
  void MyComplexType::set_xShort(short val)
  {
    get_sequence()->set_xShort(val);
  }
  
  short MyComplexType::get_xShort()
  {
    return get_sequence()->get_xShort();
  }

          

  MyComplexType::xByte_ptr MyComplexType::create_xByte(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xByte");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "byte");
    MyComplexType::xByte_p node = XSD::createElementTmpl<xByte, XMLSchema::Types::bt_byte*>(t);
          
    node->defaultValue("-127");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xByte = node;
      
    return node;
  }

  
  MyComplexType::xByte_p MyComplexType::element_xByte()
  {
    FSM::warnNullNode(_xByte, "xByte", "{http://www.w3.org/2001/XMLSchema}xByte", 1);
    return _xByte;
  }
    
  void MyComplexType::set_xByte(DOMString val)
  {
    get_sequence()->set_xByte(val);
  }

  DOMString MyComplexType::get_xByte_string()
  {
    return get_sequence()->get_xByte_string();
  }

          
  void MyComplexType::set_xByte(char val)
  {
    get_sequence()->set_xByte(val);
  }
  
  char MyComplexType::get_xByte()
  {
    return get_sequence()->get_xByte();
  }

          

  MyComplexType::xUnsignedLong_ptr MyComplexType::create_xUnsignedLong(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xUnsignedLong");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "unsignedLong");
    MyComplexType::xUnsignedLong_p node = XSD::createElementTmpl<xUnsignedLong, XMLSchema::Types::bt_unsignedLong*>(t);
          
    node->defaultValue("18446744073709551615");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xUnsignedLong = node;
      
    return node;
  }

  
  MyComplexType::xUnsignedLong_p MyComplexType::element_xUnsignedLong()
  {
    FSM::warnNullNode(_xUnsignedLong, "xUnsignedLong", "{http://www.w3.org/2001/XMLSchema}xUnsignedLong", 1);
    return _xUnsignedLong;
  }
    
  void MyComplexType::set_xUnsignedLong(DOMString val)
  {
    get_sequence()->set_xUnsignedLong(val);
  }

  DOMString MyComplexType::get_xUnsignedLong_string()
  {
    return get_sequence()->get_xUnsignedLong_string();
  }

          
  void MyComplexType::set_xUnsignedLong(XPlus::UInt64 val)
  {
    get_sequence()->set_xUnsignedLong(val);
  }
  
  XPlus::UInt64 MyComplexType::get_xUnsignedLong()
  {
    return get_sequence()->get_xUnsignedLong();
  }

          

  MyComplexType::xUnsignedInt_ptr MyComplexType::create_xUnsignedInt(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xUnsignedInt");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "unsignedInt");
    MyComplexType::xUnsignedInt_p node = XSD::createElementTmpl<xUnsignedInt, XMLSchema::Types::bt_unsignedInt*>(t);
          
    node->defaultValue("4294967295");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xUnsignedInt = node;
      
    return node;
  }

  
  MyComplexType::xUnsignedInt_p MyComplexType::element_xUnsignedInt()
  {
    FSM::warnNullNode(_xUnsignedInt, "xUnsignedInt", "{http://www.w3.org/2001/XMLSchema}xUnsignedInt", 1);
    return _xUnsignedInt;
  }
    
  void MyComplexType::set_xUnsignedInt(DOMString val)
  {
    get_sequence()->set_xUnsignedInt(val);
  }

  DOMString MyComplexType::get_xUnsignedInt_string()
  {
    return get_sequence()->get_xUnsignedInt_string();
  }

          
  void MyComplexType::set_xUnsignedInt(unsigned int val)
  {
    get_sequence()->set_xUnsignedInt(val);
  }
  
  unsigned int MyComplexType::get_xUnsignedInt()
  {
    return get_sequence()->get_xUnsignedInt();
  }

          

  MyComplexType::xUnsignedShort_ptr MyComplexType::create_xUnsignedShort(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xUnsignedShort");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "unsignedShort");
    MyComplexType::xUnsignedShort_p node = XSD::createElementTmpl<xUnsignedShort, XMLSchema::Types::bt_unsignedShort*>(t);
          
    node->defaultValue("65535");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xUnsignedShort = node;
      
    return node;
  }

  
  MyComplexType::xUnsignedShort_p MyComplexType::element_xUnsignedShort()
  {
    FSM::warnNullNode(_xUnsignedShort, "xUnsignedShort", "{http://www.w3.org/2001/XMLSchema}xUnsignedShort", 1);
    return _xUnsignedShort;
  }
    
  void MyComplexType::set_xUnsignedShort(DOMString val)
  {
    get_sequence()->set_xUnsignedShort(val);
  }

  DOMString MyComplexType::get_xUnsignedShort_string()
  {
    return get_sequence()->get_xUnsignedShort_string();
  }

          
  void MyComplexType::set_xUnsignedShort(unsigned short val)
  {
    get_sequence()->set_xUnsignedShort(val);
  }
  
  unsigned short MyComplexType::get_xUnsignedShort()
  {
    return get_sequence()->get_xUnsignedShort();
  }

          

  MyComplexType::xUnsignedByte_ptr MyComplexType::create_xUnsignedByte(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xUnsignedByte");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "unsignedByte");
    MyComplexType::xUnsignedByte_p node = XSD::createElementTmpl<xUnsignedByte, XMLSchema::Types::bt_unsignedByte*>(t);
          
    node->defaultValue("255");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xUnsignedByte = node;
      
    return node;
  }

  
  MyComplexType::xUnsignedByte_p MyComplexType::element_xUnsignedByte()
  {
    FSM::warnNullNode(_xUnsignedByte, "xUnsignedByte", "{http://www.w3.org/2001/XMLSchema}xUnsignedByte", 1);
    return _xUnsignedByte;
  }
    
  void MyComplexType::set_xUnsignedByte(DOMString val)
  {
    get_sequence()->set_xUnsignedByte(val);
  }

  DOMString MyComplexType::get_xUnsignedByte_string()
  {
    return get_sequence()->get_xUnsignedByte_string();
  }

          
  void MyComplexType::set_xUnsignedByte(unsigned char val)
  {
    get_sequence()->set_xUnsignedByte(val);
  }
  
  unsigned char MyComplexType::get_xUnsignedByte()
  {
    return get_sequence()->get_xUnsignedByte();
  }

          

  MyComplexType::xHexBinary_ptr MyComplexType::create_xHexBinary(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xHexBinary");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "hexBinary");
    MyComplexType::xHexBinary_p node = XSD::createElementTmpl<xHexBinary, XMLSchema::Types::bt_hexBinary*>(t);
          
    node->defaultValue("FEFF");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xHexBinary = node;
      
    return node;
  }

  
  MyComplexType::xHexBinary_p MyComplexType::element_xHexBinary()
  {
    FSM::warnNullNode(_xHexBinary, "xHexBinary", "{http://www.w3.org/2001/XMLSchema}xHexBinary", 1);
    return _xHexBinary;
  }
    
  void MyComplexType::set_xHexBinary(DOMString val)
  {
    get_sequence()->set_xHexBinary(val);
  }

  DOMString MyComplexType::get_xHexBinary_string()
  {
    return get_sequence()->get_xHexBinary_string();
  }

          

  MyComplexType::xBase64Binary_ptr MyComplexType::create_xBase64Binary(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xBase64Binary");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "base64Binary");
    MyComplexType::xBase64Binary_p node = XSD::createElementTmpl<xBase64Binary, XMLSchema::Types::bt_base64Binary*>(t);
          
    node->defaultValue("aGVsbG8gd29ybGQ=");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xBase64Binary = node;
      
    return node;
  }

  
  MyComplexType::xBase64Binary_p MyComplexType::element_xBase64Binary()
  {
    FSM::warnNullNode(_xBase64Binary, "xBase64Binary", "{http://www.w3.org/2001/XMLSchema}xBase64Binary", 1);
    return _xBase64Binary;
  }
    
  void MyComplexType::set_xBase64Binary(DOMString val)
  {
    get_sequence()->set_xBase64Binary(val);
  }

  DOMString MyComplexType::get_xBase64Binary_string()
  {
    return get_sequence()->get_xBase64Binary_string();
  }

          

  MyComplexType::xUri_ptr MyComplexType::create_xUri(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xUri");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "anyURI");
    MyComplexType::xUri_p node = XSD::createElementTmpl<xUri, XMLSchema::Types::bt_anyURI*>(t);
          
    node->defaultValue("http://www.example.com/xmlplus");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xUri = node;
      
    return node;
  }

  
  MyComplexType::xUri_p MyComplexType::element_xUri()
  {
    FSM::warnNullNode(_xUri, "xUri", "{http://www.w3.org/2001/XMLSchema}xUri", 1);
    return _xUri;
  }
    
  void MyComplexType::set_xUri(DOMString val)
  {
    get_sequence()->set_xUri(val);
  }

  DOMString MyComplexType::get_xUri_string()
  {
    return get_sequence()->get_xUri_string();
  }

          

  MyComplexType::xNormalizedString_ptr MyComplexType::create_xNormalizedString(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNormalizedString");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "normalizedString");
    MyComplexType::xNormalizedString_p node = XSD::createElementTmpl<xNormalizedString, XMLSchema::Types::bt_normalizedString*>(t);
          
    node->defaultValue("no CR LF TAB");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xNormalizedString = node;
      
    return node;
  }

  
  MyComplexType::xNormalizedString_p MyComplexType::element_xNormalizedString()
  {
    FSM::warnNullNode(_xNormalizedString, "xNormalizedString", "{http://www.w3.org/2001/XMLSchema}xNormalizedString", 1);
    return _xNormalizedString;
  }
    
  void MyComplexType::set_xNormalizedString(DOMString val)
  {
    get_sequence()->set_xNormalizedString(val);
  }

  DOMString MyComplexType::get_xNormalizedString_string()
  {
    return get_sequence()->get_xNormalizedString_string();
  }

          

  MyComplexType::xToken_ptr MyComplexType::create_xToken(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xToken");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "token");
    MyComplexType::xToken_p node = XSD::createElementTmpl<xToken, XMLSchema::Types::bt_token*>(t);
          
    node->defaultValue(" xs:hexBinary ");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xToken = node;
      
    return node;
  }

  
  MyComplexType::xToken_p MyComplexType::element_xToken()
  {
    FSM::warnNullNode(_xToken, "xToken", "{http://www.w3.org/2001/XMLSchema}xToken", 1);
    return _xToken;
  }
    
  void MyComplexType::set_xToken(DOMString val)
  {
    get_sequence()->set_xToken(val);
  }

  DOMString MyComplexType::get_xToken_string()
  {
    return get_sequence()->get_xToken_string();
  }

          

  MyComplexType::xLanguage_ptr MyComplexType::create_xLanguage(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xLanguage");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "language");
    MyComplexType::xLanguage_p node = XSD::createElementTmpl<xLanguage, XMLSchema::Types::bt_language*>(t);
          
    node->defaultValue("english");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xLanguage = node;
      
    return node;
  }

  
  MyComplexType::xLanguage_p MyComplexType::element_xLanguage()
  {
    FSM::warnNullNode(_xLanguage, "xLanguage", "{http://www.w3.org/2001/XMLSchema}xLanguage", 1);
    return _xLanguage;
  }
    
  void MyComplexType::set_xLanguage(DOMString val)
  {
    get_sequence()->set_xLanguage(val);
  }

  DOMString MyComplexType::get_xLanguage_string()
  {
    return get_sequence()->get_xLanguage_string();
  }

          

  MyComplexType::xName_ptr MyComplexType::create_xName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xName");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "Name");
    MyComplexType::xName_p node = XSD::createElementTmpl<xName, XMLSchema::Types::bt_Name*>(t);
          
    node->defaultValue(":colonToken");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xName = node;
      
    return node;
  }

  
  MyComplexType::xName_p MyComplexType::element_xName()
  {
    FSM::warnNullNode(_xName, "xName", "{http://www.w3.org/2001/XMLSchema}xName", 1);
    return _xName;
  }
    
  void MyComplexType::set_xName(DOMString val)
  {
    get_sequence()->set_xName(val);
  }

  DOMString MyComplexType::get_xName_string()
  {
    return get_sequence()->get_xName_string();
  }

          

  MyComplexType::xNCName_ptr MyComplexType::create_xNCName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNCName");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "NCName");
    MyComplexType::xNCName_p node = XSD::createElementTmpl<xNCName, XMLSchema::Types::bt_NCName*>(t);
          
    node->defaultValue("noColonToken");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xNCName = node;
      
    return node;
  }

  
  MyComplexType::xNCName_p MyComplexType::element_xNCName()
  {
    FSM::warnNullNode(_xNCName, "xNCName", "{http://www.w3.org/2001/XMLSchema}xNCName", 1);
    return _xNCName;
  }
    
  void MyComplexType::set_xNCName(DOMString val)
  {
    get_sequence()->set_xNCName(val);
  }

  DOMString MyComplexType::get_xNCName_string()
  {
    return get_sequence()->get_xNCName_string();
  }

          

  MyComplexType::xQName_ptr MyComplexType::create_xQName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xQName");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "QName");
    MyComplexType::xQName_p node = XSD::createElementTmpl<xQName, XMLSchema::Types::bt_QName*>(t);
          
    node->defaultValue("xsi:schemaLocation");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xQName = node;
      
    return node;
  }

  
  MyComplexType::xQName_p MyComplexType::element_xQName()
  {
    FSM::warnNullNode(_xQName, "xQName", "{http://www.w3.org/2001/XMLSchema}xQName", 1);
    return _xQName;
  }
    
  void MyComplexType::set_xQName(DOMString val)
  {
    get_sequence()->set_xQName(val);
  }

  DOMString MyComplexType::get_xQName_string()
  {
    return get_sequence()->get_xQName_string();
  }

          

  MyComplexType::xDateTime_ptr MyComplexType::create_xDateTime(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDateTime");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "dateTime");
    MyComplexType::xDateTime_p node = XSD::createElementTmpl<xDateTime, XMLSchema::Types::bt_dateTime*>(t);
          
    node->defaultValue("2001-07-04T14:50:59Z");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDateTime = node;
      
    return node;
  }

  
  MyComplexType::xDateTime_p MyComplexType::element_xDateTime()
  {
    FSM::warnNullNode(_xDateTime, "xDateTime", "{http://www.w3.org/2001/XMLSchema}xDateTime", 1);
    return _xDateTime;
  }
    
  void MyComplexType::set_xDateTime(DOMString val)
  {
    get_sequence()->set_xDateTime(val);
  }

  DOMString MyComplexType::get_xDateTime_string()
  {
    return get_sequence()->get_xDateTime_string();
  }

          
  void MyComplexType::set_xDateTime(XPlus::DateTime val)
  {
    get_sequence()->set_xDateTime(val);
  }
  
  XPlus::DateTime MyComplexType::get_xDateTime()
  {
    return get_sequence()->get_xDateTime();
  }

          

  MyComplexType::xDate_ptr MyComplexType::create_xDate(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDate");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "date");
    MyComplexType::xDate_p node = XSD::createElementTmpl<xDate, XMLSchema::Types::bt_date*>(t);
          
    node->defaultValue("2010-01-04");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDate = node;
      
    return node;
  }

  
  MyComplexType::xDate_p MyComplexType::element_xDate()
  {
    FSM::warnNullNode(_xDate, "xDate", "{http://www.w3.org/2001/XMLSchema}xDate", 1);
    return _xDate;
  }
    
  void MyComplexType::set_xDate(DOMString val)
  {
    get_sequence()->set_xDate(val);
  }

  DOMString MyComplexType::get_xDate_string()
  {
    return get_sequence()->get_xDate_string();
  }

          
  void MyComplexType::set_xDate(XPlus::Date val)
  {
    get_sequence()->set_xDate(val);
  }
  
  XPlus::Date MyComplexType::get_xDate()
  {
    return get_sequence()->get_xDate();
  }

          

  MyComplexType::xYearMonth_ptr MyComplexType::create_xYearMonth(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xYearMonth");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "gYearMonth");
    MyComplexType::xYearMonth_p node = XSD::createElementTmpl<xYearMonth, XMLSchema::Types::bt_gYearMonth*>(t);
          
    node->defaultValue("1980-11");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xYearMonth = node;
      
    return node;
  }

  
  MyComplexType::xYearMonth_p MyComplexType::element_xYearMonth()
  {
    FSM::warnNullNode(_xYearMonth, "xYearMonth", "{http://www.w3.org/2001/XMLSchema}xYearMonth", 1);
    return _xYearMonth;
  }
    
  void MyComplexType::set_xYearMonth(DOMString val)
  {
    get_sequence()->set_xYearMonth(val);
  }

  DOMString MyComplexType::get_xYearMonth_string()
  {
    return get_sequence()->get_xYearMonth_string();
  }

          
  void MyComplexType::set_xYearMonth(XPlus::YearMonth val)
  {
    get_sequence()->set_xYearMonth(val);
  }
  
  XPlus::YearMonth MyComplexType::get_xYearMonth()
  {
    return get_sequence()->get_xYearMonth();
  }

          

  MyComplexType::xYear_ptr MyComplexType::create_xYear(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xYear");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "gYear");
    MyComplexType::xYear_p node = XSD::createElementTmpl<xYear, XMLSchema::Types::bt_gYear*>(t);
          
    node->defaultValue("1978");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xYear = node;
      
    return node;
  }

  
  MyComplexType::xYear_p MyComplexType::element_xYear()
  {
    FSM::warnNullNode(_xYear, "xYear", "{http://www.w3.org/2001/XMLSchema}xYear", 1);
    return _xYear;
  }
    
  void MyComplexType::set_xYear(DOMString val)
  {
    get_sequence()->set_xYear(val);
  }

  DOMString MyComplexType::get_xYear_string()
  {
    return get_sequence()->get_xYear_string();
  }

          
  void MyComplexType::set_xYear(XPlus::Year val)
  {
    get_sequence()->set_xYear(val);
  }
  
  XPlus::Year MyComplexType::get_xYear()
  {
    return get_sequence()->get_xYear();
  }

          

  MyComplexType::xMonthDay_ptr MyComplexType::create_xMonthDay(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xMonthDay");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "gMonthDay");
    MyComplexType::xMonthDay_p node = XSD::createElementTmpl<xMonthDay, XMLSchema::Types::bt_gMonthDay*>(t);
          
    node->defaultValue("12-30");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xMonthDay = node;
      
    return node;
  }

  
  MyComplexType::xMonthDay_p MyComplexType::element_xMonthDay()
  {
    FSM::warnNullNode(_xMonthDay, "xMonthDay", "{http://www.w3.org/2001/XMLSchema}xMonthDay", 1);
    return _xMonthDay;
  }
    
  void MyComplexType::set_xMonthDay(DOMString val)
  {
    get_sequence()->set_xMonthDay(val);
  }

  DOMString MyComplexType::get_xMonthDay_string()
  {
    return get_sequence()->get_xMonthDay_string();
  }

          
  void MyComplexType::set_xMonthDay(XPlus::MonthDay val)
  {
    get_sequence()->set_xMonthDay(val);
  }
  
  XPlus::MonthDay MyComplexType::get_xMonthDay()
  {
    return get_sequence()->get_xMonthDay();
  }

          

  MyComplexType::xMonth_ptr MyComplexType::create_xMonth(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xMonth");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "gMonth");
    MyComplexType::xMonth_p node = XSD::createElementTmpl<xMonth, XMLSchema::Types::bt_gMonth*>(t);
          
    node->defaultValue("7");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xMonth = node;
      
    return node;
  }

  
  MyComplexType::xMonth_p MyComplexType::element_xMonth()
  {
    FSM::warnNullNode(_xMonth, "xMonth", "{http://www.w3.org/2001/XMLSchema}xMonth", 1);
    return _xMonth;
  }
    
  void MyComplexType::set_xMonth(DOMString val)
  {
    get_sequence()->set_xMonth(val);
  }

  DOMString MyComplexType::get_xMonth_string()
  {
    return get_sequence()->get_xMonth_string();
  }

          
  void MyComplexType::set_xMonth(XPlus::Month val)
  {
    get_sequence()->set_xMonth(val);
  }
  
  XPlus::Month MyComplexType::get_xMonth()
  {
    return get_sequence()->get_xMonth();
  }

          

  MyComplexType::xDay_ptr MyComplexType::create_xDay(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDay");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "gDay");
    MyComplexType::xDay_p node = XSD::createElementTmpl<xDay, XMLSchema::Types::bt_gDay*>(t);
          
    node->defaultValue("30");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDay = node;
      
    return node;
  }

  
  MyComplexType::xDay_p MyComplexType::element_xDay()
  {
    FSM::warnNullNode(_xDay, "xDay", "{http://www.w3.org/2001/XMLSchema}xDay", 1);
    return _xDay;
  }
    
  void MyComplexType::set_xDay(DOMString val)
  {
    get_sequence()->set_xDay(val);
  }

  DOMString MyComplexType::get_xDay_string()
  {
    return get_sequence()->get_xDay_string();
  }

          
  void MyComplexType::set_xDay(XPlus::Day val)
  {
    get_sequence()->set_xDay(val);
  }
  
  XPlus::Day MyComplexType::get_xDay()
  {
    return get_sequence()->get_xDay();
  }

          

  MyComplexType::xTime_ptr MyComplexType::create_xTime(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xTime");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "time");
    MyComplexType::xTime_p node = XSD::createElementTmpl<xTime, XMLSchema::Types::bt_time*>(t);
          
    node->defaultValue("14:59:57");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xTime = node;
      
    return node;
  }

  
  MyComplexType::xTime_p MyComplexType::element_xTime()
  {
    FSM::warnNullNode(_xTime, "xTime", "{http://www.w3.org/2001/XMLSchema}xTime", 1);
    return _xTime;
  }
    
  void MyComplexType::set_xTime(DOMString val)
  {
    get_sequence()->set_xTime(val);
  }

  DOMString MyComplexType::get_xTime_string()
  {
    return get_sequence()->get_xTime_string();
  }

          
  void MyComplexType::set_xTime(XPlus::Time val)
  {
    get_sequence()->set_xTime(val);
  }
  
  XPlus::Time MyComplexType::get_xTime()
  {
    return get_sequence()->get_xTime();
  }

          

  MyComplexType::xDuration_ptr MyComplexType::create_xDuration(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xDuration");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "duration");
    MyComplexType::xDuration_p node = XSD::createElementTmpl<xDuration, XMLSchema::Types::bt_duration*>(t);
          
    node->defaultValue("P1Y2M3DT10H30M40S");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _xDuration = node;
      
    return node;
  }

  
  MyComplexType::xDuration_p MyComplexType::element_xDuration()
  {
    FSM::warnNullNode(_xDuration, "xDuration", "{http://www.w3.org/2001/XMLSchema}xDuration", 1);
    return _xDuration;
  }
    
  void MyComplexType::set_xDuration(DOMString val)
  {
    get_sequence()->set_xDuration(val);
  }

  DOMString MyComplexType::get_xDuration_string()
  {
    return get_sequence()->get_xDuration_string();
  }

          
  void MyComplexType::set_xDuration(XPlus::Duration val)
  {
    get_sequence()->set_xDuration(val);
  }
  
  XPlus::Duration MyComplexType::get_xDuration()
  {
    return get_sequence()->get_xDuration();
  }

          

  MyComplexType::anIntMax10_ptr MyComplexType::create_anIntMax10(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("anIntMax10");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    MyComplexType::anIntMax10_p node = XSD::createElementTmpl<anIntMax10, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _list_anIntMax10.push_back(node);
      
    return node;
  }

  
  MyComplexType::anIntMax10_p MyComplexType::element_anIntMax10_at(unsigned int idx)
  {
    if(idx > _list_anIntMax10.size()-1) {
      throw IndexOutOfBoundsException("IndexOutOfBoundsException");
    }

    return _list_anIntMax10.at(idx);
  }
    
  List<MyComplexType::anIntMax10_ptr> MyComplexType::elements_anIntMax10()
  {
    return _list_anIntMax10;
  }
    
  MyComplexType::anIntMax10_p MyComplexType::add_node_anIntMax10()
  {
    return get_sequence()->add_node_anIntMax10();
  }

  List<MyComplexType::anIntMax10_ptr> MyComplexType::set_count_anIntMax10(unsigned int size)
  {
    return get_sequence()->set_count_anIntMax10(size);
  }

        
      
    void MyComplexType::add_anIntMax10_string(DOMString val)
    {
      get_sequence()->add_anIntMax10_string(val);
    }

          

    void MyComplexType::add_anIntMax10(int val)
    {
      get_sequence()->add_anIntMax10(val);
    }

          
  void MyComplexType::set_anIntMax10(unsigned int idx, DOMString val)
  {
    get_sequence()->set_anIntMax10(idx, val);
  }

  DOMString MyComplexType::get_anIntMax10_string(unsigned int idx)
  {
    return get_sequence()->get_anIntMax10_string(idx);
  }

          
  void MyComplexType::set_anIntMax10(unsigned int idx,int val)
  {
    get_sequence()->set_anIntMax10(idx, val);
  }

  int MyComplexType::get_anIntMax10(unsigned int idx)
  {
    return get_sequence()->get_anIntMax10(idx);
  }

          

  MyComplexType::anIntMax5k_ptr MyComplexType::create_anIntMax5k(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("anIntMax5k");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "IntMax5k");
    MyComplexType::anIntMax5k_p node = XSD::createElementTmpl<anIntMax5k, STDemo::Types::IntMax5k*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _anIntMax5k = node;
      
    return node;
  }

  
  MyComplexType::anIntMax5k_p MyComplexType::element_anIntMax5k()
  {
    FSM::warnNullNode(_anIntMax5k, "anIntMax5k", "{http://www.example.com/STDemo}anIntMax5k", 1);
    return _anIntMax5k;
  }
    
  void MyComplexType::set_anIntMax5k(DOMString val)
  {
    get_sequence()->set_anIntMax5k(val);
  }

  DOMString MyComplexType::get_anIntMax5k_string()
  {
    return get_sequence()->get_anIntMax5k_string();
  }

          
  void MyComplexType::set_anIntMax5k(int val)
  {
    get_sequence()->set_anIntMax5k(val);
  }
  
  int MyComplexType::get_anIntMax5k()
  {
    return get_sequence()->get_anIntMax5k();
  }

          

  globalWaterTemp_ptr MyComplexType::create_globalWaterTemp(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("globalWaterTemp");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    globalWaterTemp_p node = XSD::createElementTmpl<globalWaterTemp, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _globalWaterTemp = node;
      
    return node;
  }

  
  globalWaterTemp_p MyComplexType::element_globalWaterTemp()
  {
    FSM::warnNullNode(_globalWaterTemp, "globalWaterTemp", "{http://www.example.com/STDemo}globalWaterTemp", 1);
    return _globalWaterTemp;
  }
    
  void MyComplexType::set_globalWaterTemp(DOMString val)
  {
    get_sequence()->set_globalWaterTemp(val);
  }

  DOMString MyComplexType::get_globalWaterTemp_string()
  {
    return get_sequence()->get_globalWaterTemp_string();
  }

          
  void MyComplexType::set_globalWaterTemp(double val)
  {
    get_sequence()->set_globalWaterTemp(val);
  }
  
  double MyComplexType::get_globalWaterTemp()
  {
    return get_sequence()->get_globalWaterTemp();
  }

          

  MyComplexType::aSKU_ptr MyComplexType::create_aSKU(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aSKU");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "SKU");
    MyComplexType::aSKU_p node = XSD::createElementTmpl<aSKU, STDemo::Types::SKU*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aSKU = node;
      
    return node;
  }

  
  MyComplexType::aSKU_p MyComplexType::element_aSKU()
  {
    FSM::warnNullNode(_aSKU, "aSKU", "{http://www.example.com/STDemo}aSKU", 1);
    return _aSKU;
  }
    
  void MyComplexType::set_aSKU(DOMString val)
  {
    get_sequence()->set_aSKU(val);
  }

  DOMString MyComplexType::get_aSKU_string()
  {
    return get_sequence()->get_aSKU_string();
  }

          

  MyComplexType::aDateTime_ptr MyComplexType::create_aDateTime(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aDateTime");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "DateTimeInARange");
    MyComplexType::aDateTime_p node = XSD::createElementTmpl<aDateTime, STDemo::Types::DateTimeInARange*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aDateTime = node;
      
    return node;
  }

  
  MyComplexType::aDateTime_p MyComplexType::element_aDateTime()
  {
    FSM::warnNullNode(_aDateTime, "aDateTime", "{http://www.example.com/STDemo}aDateTime", 1);
    return _aDateTime;
  }
    
  void MyComplexType::set_aDateTime(DOMString val)
  {
    get_sequence()->set_aDateTime(val);
  }

  DOMString MyComplexType::get_aDateTime_string()
  {
    return get_sequence()->get_aDateTime_string();
  }

          
  void MyComplexType::set_aDateTime(XPlus::DateTime val)
  {
    get_sequence()->set_aDateTime(val);
  }
  
  XPlus::DateTime MyComplexType::get_aDateTime()
  {
    return get_sequence()->get_aDateTime();
  }

          

  MyComplexType::aDate_ptr MyComplexType::create_aDate(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aDate");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "DateInARange");
    MyComplexType::aDate_p node = XSD::createElementTmpl<aDate, STDemo::Types::DateInARange*>(t);
          
    node->defaultValue("2010-01-04");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aDate = node;
      
    return node;
  }

  
  MyComplexType::aDate_p MyComplexType::element_aDate()
  {
    FSM::warnNullNode(_aDate, "aDate", "{http://www.example.com/STDemo}aDate", 1);
    return _aDate;
  }
    
  void MyComplexType::set_aDate(DOMString val)
  {
    get_sequence()->set_aDate(val);
  }

  DOMString MyComplexType::get_aDate_string()
  {
    return get_sequence()->get_aDate_string();
  }

          
  void MyComplexType::set_aDate(XPlus::Date val)
  {
    get_sequence()->set_aDate(val);
  }
  
  XPlus::Date MyComplexType::get_aDate()
  {
    return get_sequence()->get_aDate();
  }

          

  MyComplexType::aYear_ptr MyComplexType::create_aYear(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aYear");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "YearInARange");
    MyComplexType::aYear_p node = XSD::createElementTmpl<aYear, STDemo::Types::YearInARange*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aYear = node;
      
    return node;
  }

  
  MyComplexType::aYear_p MyComplexType::element_aYear()
  {
    FSM::warnNullNode(_aYear, "aYear", "{http://www.example.com/STDemo}aYear", 1);
    return _aYear;
  }
    
  void MyComplexType::set_aYear(DOMString val)
  {
    get_sequence()->set_aYear(val);
  }

  DOMString MyComplexType::get_aYear_string()
  {
    return get_sequence()->get_aYear_string();
  }

          
  void MyComplexType::set_aYear(XPlus::Year val)
  {
    get_sequence()->set_aYear(val);
  }
  
  XPlus::Year MyComplexType::get_aYear()
  {
    return get_sequence()->get_aYear();
  }

          
#ifndef __MyComplexType_aCommonName_member_elems_fns
#define __MyComplexType_aCommonName_member_elems_fns
      

  MyComplexType::aCommonName_ptr MyComplexType::create_aCommonName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aCommonName");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    MyComplexType::aCommonName_p node = XSD::createElementTmpl<aCommonName, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aCommonName = node;
      
    return node;
  }

  
  MyComplexType::aCommonName_p MyComplexType::element_aCommonName()
  {
    FSM::warnNullNode(_aCommonName, "aCommonName", "{}aCommonName", 1);
    return _aCommonName;
  }
    
  void MyComplexType::set_aCommonName(DOMString val)
  {
    get_sequence()->set_aCommonName(val);
  }

  DOMString MyComplexType::get_aCommonName_string()
  {
    return get_sequence()->get_aCommonName_string();
  }

          
#endif // __MyComplexType_aCommonName_member_elems_fns
      

  MyComplexType::aListOfIntMax5k_ptr MyComplexType::create_aListOfIntMax5k(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aListOfIntMax5k");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "ListOfIntMax5k");
    MyComplexType::aListOfIntMax5k_p node = XSD::createElementTmpl<aListOfIntMax5k, STDemo::Types::ListOfIntMax5k*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aListOfIntMax5k = node;
      
    return node;
  }

  
  MyComplexType::aListOfIntMax5k_p MyComplexType::element_aListOfIntMax5k()
  {
    FSM::warnNullNode(_aListOfIntMax5k, "aListOfIntMax5k", "{http://www.example.com/STDemo}aListOfIntMax5k", 1);
    return _aListOfIntMax5k;
  }
    
  void MyComplexType::set_aListOfIntMax5k(DOMString val)
  {
    get_sequence()->set_aListOfIntMax5k(val);
  }

  DOMString MyComplexType::get_aListOfIntMax5k_string()
  {
    return get_sequence()->get_aListOfIntMax5k_string();
  }

          

  MyComplexType::aListOfFourIntMax500_ptr MyComplexType::create_aListOfFourIntMax500(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aListOfFourIntMax500");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "ListOfFourIntMax500");
    MyComplexType::aListOfFourIntMax500_p node = XSD::createElementTmpl<aListOfFourIntMax500, STDemo::Types::ListOfFourIntMax500*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aListOfFourIntMax500 = node;
      
    return node;
  }

  
  MyComplexType::aListOfFourIntMax500_p MyComplexType::element_aListOfFourIntMax500()
  {
    FSM::warnNullNode(_aListOfFourIntMax500, "aListOfFourIntMax500", "{http://www.example.com/STDemo}aListOfFourIntMax500", 1);
    return _aListOfFourIntMax500;
  }
    
  void MyComplexType::set_aListOfFourIntMax500(DOMString val)
  {
    get_sequence()->set_aListOfFourIntMax500(val);
  }

  DOMString MyComplexType::get_aListOfFourIntMax500_string()
  {
    return get_sequence()->get_aListOfFourIntMax500_string();
  }

          

  MyComplexType::aListOfTwoIntMax3k_ptr MyComplexType::create_aListOfTwoIntMax3k(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aListOfTwoIntMax3k");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "ListOfTwoIntMax3k");
    MyComplexType::aListOfTwoIntMax3k_p node = XSD::createElementTmpl<aListOfTwoIntMax3k, STDemo::Types::ListOfTwoIntMax3k*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aListOfTwoIntMax3k = node;
      
    return node;
  }

  
  MyComplexType::aListOfTwoIntMax3k_p MyComplexType::element_aListOfTwoIntMax3k()
  {
    FSM::warnNullNode(_aListOfTwoIntMax3k, "aListOfTwoIntMax3k", "{http://www.example.com/STDemo}aListOfTwoIntMax3k", 1);
    return _aListOfTwoIntMax3k;
  }
    
  void MyComplexType::set_aListOfTwoIntMax3k(DOMString val)
  {
    get_sequence()->set_aListOfTwoIntMax3k(val);
  }

  DOMString MyComplexType::get_aListOfTwoIntMax3k_string()
  {
    return get_sequence()->get_aListOfTwoIntMax3k_string();
  }

          

  MyComplexType::aFont_ptr MyComplexType::create_aFont(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aFont");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "Font");
    MyComplexType::aFont_p node = XSD::createElementTmpl<aFont, STDemo::Types::Font*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _aFont = node;
      
    return node;
  }

  
  MyComplexType::aFont_p MyComplexType::element_aFont()
  {
    FSM::warnNullNode(_aFont, "aFont", "{http://www.example.com/STDemo}aFont", 1);
    return _aFont;
  }
    
  void MyComplexType::set_aFont(DOMString val)
  {
    get_sequence()->set_aFont(val);
  }

  DOMString MyComplexType::get_aFont_string()
  {
    return get_sequence()->get_aFont_string();
  }

          

  MyComplexType::anotherFont_ptr MyComplexType::create_anotherFont(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("anotherFont");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.example.com/STDemo", "Font");
    MyComplexType::anotherFont_p node = XSD::createElementTmpl<anotherFont, STDemo::Types::Font*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _anotherFont = node;
      
    return node;
  }

  
  MyComplexType::anotherFont_p MyComplexType::element_anotherFont()
  {
    FSM::warnNullNode(_anotherFont, "anotherFont", "{http://www.example.com/STDemo}anotherFont", 1);
    return _anotherFont;
  }
    
  void MyComplexType::set_anotherFont(DOMString val)
  {
    get_sequence()->set_anotherFont(val);
  }

  DOMString MyComplexType::get_anotherFont_string()
  {
    return get_sequence()->get_anotherFont_string();
  }

          
#ifndef __MyComplexType_attr_aCommonName_member_elems_fns
#define __MyComplexType_attr_aCommonName_member_elems_fns
      
#endif // __MyComplexType_attr_aCommonName_member_elems_fns
        

  /* attribute  functions  */
  

  MyComplexType::attr_xID_ptr MyComplexType::create_attr_xID(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xID");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xID) {
      return _attr_xID;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xID_p node = XSD::createAttributeTmpl<attr_xID>(t);
      
    node->defaultValue("NMTOKENS.minLength");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xID = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xID()
  {
    if(!_attr_xID)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xID"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xID(DOMString val)
    {
        
      mark_present_attr_xID();
        
      attribute_attr_xID()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xID_string()
    {
       
      return attribute_attr_xID()->stringValue();
    }

    
  MyComplexType::attr_xID_p MyComplexType::attribute_attr_xID()
  {
    FSM::warnNullNode(_attr_xID, "attr_xID", "{http://www.w3.org/2001/XMLSchema}xID", 0);
    return _attr_xID;
  }
    

  MyComplexType::attr_xIDREF_ptr MyComplexType::create_attr_xIDREF(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xIDREF");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xIDREF) {
      return _attr_xIDREF;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xIDREF_p node = XSD::createAttributeTmpl<attr_xIDREF>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xIDREF = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xIDREF()
  {
    if(!_attr_xIDREF)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xIDREF"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xIDREF(DOMString val)
    {
        
      mark_present_attr_xIDREF();
        
      attribute_attr_xIDREF()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xIDREF_string()
    {
       
      return attribute_attr_xIDREF()->stringValue();
    }

    
  MyComplexType::attr_xIDREF_p MyComplexType::attribute_attr_xIDREF()
  {
    FSM::warnNullNode(_attr_xIDREF, "attr_xIDREF", "{http://www.w3.org/2001/XMLSchema}xIDREF", 0);
    return _attr_xIDREF;
  }
    

  MyComplexType::attr_xIDREFS_ptr MyComplexType::create_attr_xIDREFS(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xIDREFS");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xIDREFS) {
      return _attr_xIDREFS;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xIDREFS_p node = XSD::createAttributeTmpl<attr_xIDREFS>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xIDREFS = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xIDREFS()
  {
    if(!_attr_xIDREFS)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xIDREFS"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xIDREFS(DOMString val)
    {
        
      mark_present_attr_xIDREFS();
        
      attribute_attr_xIDREFS()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xIDREFS_string()
    {
       
      return attribute_attr_xIDREFS()->stringValue();
    }

    
  MyComplexType::attr_xIDREFS_p MyComplexType::attribute_attr_xIDREFS()
  {
    FSM::warnNullNode(_attr_xIDREFS, "attr_xIDREFS", "{http://www.w3.org/2001/XMLSchema}xIDREFS", 0);
    return _attr_xIDREFS;
  }
    

  MyComplexType::attr_xENTITY_ptr MyComplexType::create_attr_xENTITY(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xENTITY");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xENTITY) {
      return _attr_xENTITY;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xENTITY_p node = XSD::createAttributeTmpl<attr_xENTITY>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xENTITY = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xENTITY()
  {
    if(!_attr_xENTITY)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xENTITY"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xENTITY(DOMString val)
    {
        
      mark_present_attr_xENTITY();
        
      attribute_attr_xENTITY()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xENTITY_string()
    {
       
      return attribute_attr_xENTITY()->stringValue();
    }

    
  MyComplexType::attr_xENTITY_p MyComplexType::attribute_attr_xENTITY()
  {
    FSM::warnNullNode(_attr_xENTITY, "attr_xENTITY", "{http://www.w3.org/2001/XMLSchema}xENTITY", 0);
    return _attr_xENTITY;
  }
    

  MyComplexType::attr_xENTITIES_ptr MyComplexType::create_attr_xENTITIES(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xENTITIES");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xENTITIES) {
      return _attr_xENTITIES;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xENTITIES_p node = XSD::createAttributeTmpl<attr_xENTITIES>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xENTITIES = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xENTITIES()
  {
    if(!_attr_xENTITIES)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xENTITIES"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xENTITIES(DOMString val)
    {
        
      mark_present_attr_xENTITIES();
        
      attribute_attr_xENTITIES()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xENTITIES_string()
    {
       
      return attribute_attr_xENTITIES()->stringValue();
    }

    
  MyComplexType::attr_xENTITIES_p MyComplexType::attribute_attr_xENTITIES()
  {
    FSM::warnNullNode(_attr_xENTITIES, "attr_xENTITIES", "{http://www.w3.org/2001/XMLSchema}xENTITIES", 0);
    return _attr_xENTITIES;
  }
    

  MyComplexType::attr_xNMTOKEN_ptr MyComplexType::create_attr_xNMTOKEN(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNMTOKEN");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xNMTOKEN) {
      return _attr_xNMTOKEN;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xNMTOKEN_p node = XSD::createAttributeTmpl<attr_xNMTOKEN>(t);
      
    node->defaultValue("prohibited");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xNMTOKEN = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xNMTOKEN()
  {
    if(!_attr_xNMTOKEN)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xNMTOKEN"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xNMTOKEN(DOMString val)
    {
        
      mark_present_attr_xNMTOKEN();
        
      attribute_attr_xNMTOKEN()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xNMTOKEN_string()
    {
       
      return attribute_attr_xNMTOKEN()->stringValue();
    }

    
  MyComplexType::attr_xNMTOKEN_p MyComplexType::attribute_attr_xNMTOKEN()
  {
    FSM::warnNullNode(_attr_xNMTOKEN, "attr_xNMTOKEN", "{http://www.w3.org/2001/XMLSchema}xNMTOKEN", 0);
    return _attr_xNMTOKEN;
  }
    

  MyComplexType::attr_xNMTOKENS_ptr MyComplexType::create_attr_xNMTOKENS(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("xNMTOKENS");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_xNMTOKENS) {
      return _attr_xNMTOKENS;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_xNMTOKENS_p node = XSD::createAttributeTmpl<attr_xNMTOKENS>(t);
      
    node->defaultValue("optional prohibited required");    
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_xNMTOKENS = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_xNMTOKENS()
  {
    if(!_attr_xNMTOKENS)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("xNMTOKENS"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_xNMTOKENS(DOMString val)
    {
        
      mark_present_attr_xNMTOKENS();
        
      attribute_attr_xNMTOKENS()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_xNMTOKENS_string()
    {
       
      return attribute_attr_xNMTOKENS()->stringValue();
    }

    
  MyComplexType::attr_xNMTOKENS_p MyComplexType::attribute_attr_xNMTOKENS()
  {
    FSM::warnNullNode(_attr_xNMTOKENS, "attr_xNMTOKENS", "{http://www.w3.org/2001/XMLSchema}xNMTOKENS", 0);
    return _attr_xNMTOKENS;
  }
    

  attr_globalStringAttr_ptr MyComplexType::create_attr_globalStringAttr(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("globalStringAttr");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_globalStringAttr) {
      return _attr_globalStringAttr;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    attr_globalStringAttr_p node = XSD::createAttributeTmpl<attr_globalStringAttr>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_globalStringAttr = node;
      
    return node;
  }

  
    void MyComplexType::set_attr_globalStringAttr(DOMString val)
    {
        
      attribute_attr_globalStringAttr()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_globalStringAttr_string()
    {
       
      return attribute_attr_globalStringAttr()->stringValue();
    }

    
  attr_globalStringAttr_p MyComplexType::attribute_attr_globalStringAttr()
  {
    FSM::warnNullNode(_attr_globalStringAttr, "attr_globalStringAttr", "{http://www.example.com/STDemo}globalStringAttr", 1);
    return _attr_globalStringAttr;
  }
    

  MyComplexType::attr_aNOTATION_ptr MyComplexType::create_attr_aNOTATION(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aNOTATION");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_aNOTATION) {
      return _attr_aNOTATION;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_aNOTATION_p node = XSD::createAttributeTmpl<attr_aNOTATION>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_aNOTATION = node;
      
    return node;
  }

  
  void MyComplexType::mark_present_attr_aNOTATION()
  {
    if(!_attr_aNOTATION)
    {
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("aNOTATION"), XsdEvent::ATTRIBUTE);
      _fsmAttrs->processEventThrow(event); 
      _fsm->fsmCreatedNode(NULL);
    }
  }

  
    void MyComplexType::set_attr_aNOTATION(DOMString val)
    {
        
      mark_present_attr_aNOTATION();
        
      attribute_attr_aNOTATION()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_aNOTATION_string()
    {
       
      return attribute_attr_aNOTATION()->stringValue();
    }

    
  MyComplexType::attr_aNOTATION_p MyComplexType::attribute_attr_aNOTATION()
  {
    FSM::warnNullNode(_attr_aNOTATION, "attr_aNOTATION", "{http://www.example.com/STDemo}aNOTATION", 0);
    return _attr_aNOTATION;
  }
    

  MyComplexType::attr_aNNI_ptr MyComplexType::create_attr_aNNI(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aNNI");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_aNNI) {
      return _attr_aNNI;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_aNNI_p node = XSD::createAttributeTmpl<attr_aNNI>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_aNNI = node;
      
    return node;
  }

  
    void MyComplexType::set_attr_aNNI(DOMString val)
    {
        
      attribute_attr_aNNI()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_aNNI_string()
    {
       
      return attribute_attr_aNNI()->stringValue();
    }

    
  MyComplexType::attr_aNNI_p MyComplexType::attribute_attr_aNNI()
  {
    FSM::warnNullNode(_attr_aNNI, "attr_aNNI", "{http://www.example.com/STDemo}aNNI", 1);
    return _attr_aNNI;
  }
    

  MyComplexType::attr_anotherNNI_ptr MyComplexType::create_attr_anotherNNI(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("anotherNNI");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_anotherNNI) {
      return _attr_anotherNNI;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_anotherNNI_p node = XSD::createAttributeTmpl<attr_anotherNNI>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_anotherNNI = node;
      
    return node;
  }

  
    void MyComplexType::set_attr_anotherNNI(DOMString val)
    {
        
      attribute_attr_anotherNNI()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_anotherNNI_string()
    {
       
      return attribute_attr_anotherNNI()->stringValue();
    }

    
  MyComplexType::attr_anotherNNI_p MyComplexType::attribute_attr_anotherNNI()
  {
    FSM::warnNullNode(_attr_anotherNNI, "attr_anotherNNI", "{http://www.example.com/STDemo}anotherNNI", 1);
    return _attr_anotherNNI;
  }
    
#ifndef __MyComplexType_attr_aCommonName_member_attrs_fns
#define __MyComplexType_attr_aCommonName_member_attrs_fns
        

  MyComplexType::attr_aCommonName_ptr MyComplexType::create_attr_aCommonName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("aCommonName");
    static DOMStringPtr myNsUri = new DOMString("http://www.example.com/STDemo");
    
    if(_attr_aCommonName) {
      return _attr_aCommonName;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    MyComplexType::attr_aCommonName_p node = XSD::createAttributeTmpl<attr_aCommonName>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_aCommonName = node;
      
    return node;
  }

  
    void MyComplexType::set_attr_aCommonName(DOMString val)
    {
        
      attribute_attr_aCommonName()->stringValue(val);
    }

    DOMString MyComplexType::get_attr_aCommonName_string()
    {
       
      return attribute_attr_aCommonName()->stringValue();
    }

    
  MyComplexType::attr_aCommonName_p MyComplexType::attribute_attr_aCommonName()
  {
    FSM::warnNullNode(_attr_aCommonName, "attr_aCommonName", "{}aCommonName", 1);
    return _attr_aCommonName;
  }
    
#endif // __MyComplexType_attr_aCommonName_member_attrs_fns
        
  //constructor
  MyComplexType::sequence::sequence(MyComplexType* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<xBoolean_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xBoolean"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xBoolean_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xBoolean)),
      new XsdFSM<xDecimal_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDecimal"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDecimal_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDecimal)),
      new XsdFSM<xFloat_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xFloat"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xFloat_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xFloat)),
      new XsdFSM<xDouble_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDouble"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDouble_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDouble)),
      new XsdFSM<xInteger_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xInteger"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xInteger_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xInteger)),
      new XsdFSM<xPositiveInteger_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xPositiveInteger"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xPositiveInteger_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xPositiveInteger)),
      new XsdFSM<xNonPositiveInteger_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNonPositiveInteger"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xNonPositiveInteger_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xNonPositiveInteger)),
      new XsdFSM<xNegativeInteger_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNegativeInteger"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xNegativeInteger_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xNegativeInteger)),
      new XsdFSM<xNonNegativeInteger_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNonNegativeInteger"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xNonNegativeInteger_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xNonNegativeInteger)),
      new XsdFSM<xLong_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xLong"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xLong_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xLong)),
      new XsdFSM<xInt_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xInt"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xInt_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xInt)),
      new XsdFSM<xShort_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xShort"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xShort_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xShort)),
      new XsdFSM<xByte_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xByte"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xByte_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xByte)),
      new XsdFSM<xUnsignedLong_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xUnsignedLong"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xUnsignedLong_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xUnsignedLong)),
      new XsdFSM<xUnsignedInt_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xUnsignedInt"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xUnsignedInt_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xUnsignedInt)),
      new XsdFSM<xUnsignedShort_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xUnsignedShort"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xUnsignedShort_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xUnsignedShort)),
      new XsdFSM<xUnsignedByte_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xUnsignedByte"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xUnsignedByte_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xUnsignedByte)),
      new XsdFSM<xHexBinary_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xHexBinary"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xHexBinary_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xHexBinary)),
      new XsdFSM<xBase64Binary_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xBase64Binary"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xBase64Binary_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xBase64Binary)),
      new XsdFSM<xUri_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xUri"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xUri_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xUri)),
      new XsdFSM<xNormalizedString_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNormalizedString"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xNormalizedString_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xNormalizedString)),
      new XsdFSM<xToken_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xToken"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xToken_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xToken)),
      new XsdFSM<xLanguage_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xLanguage"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xLanguage_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xLanguage)),
      new XsdFSM<xName_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xName"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xName_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xName)),
      new XsdFSM<xNCName_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xNCName"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xNCName_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xNCName)),
      new XsdFSM<xQName_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xQName"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xQName_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xQName)),
      new XsdFSM<xDateTime_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDateTime"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDateTime_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDateTime)),
      new XsdFSM<xDate_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDate"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDate_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDate)),
      new XsdFSM<xYearMonth_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xYearMonth"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xYearMonth_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xYearMonth)),
      new XsdFSM<xYear_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xYear"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xYear_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xYear)),
      new XsdFSM<xMonthDay_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xMonthDay"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xMonthDay_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xMonthDay)),
      new XsdFSM<xMonth_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xMonth"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xMonth_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xMonth)),
      new XsdFSM<xDay_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDay"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDay_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDay)),
      new XsdFSM<xTime_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xTime"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xTime_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xTime)),
      new XsdFSM<xDuration_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("xDuration"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<xDuration_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_xDuration)),
      new XsdFSM<anIntMax10_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("anIntMax10"), 3, 5), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<anIntMax10_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_anIntMax10)),
      new XsdFSM<anIntMax5k_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("anIntMax5k"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<anIntMax5k_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_anIntMax5k)),
      new XsdFSM<globalWaterTemp_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("globalWaterTemp"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<globalWaterTemp_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_globalWaterTemp)),
      new XsdFSM<aSKU_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aSKU"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aSKU_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aSKU)),
      new XsdFSM<aDateTime_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aDateTime"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aDateTime_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aDateTime)),
      new XsdFSM<aDate_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aDate"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aDate_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aDate)),
      new XsdFSM<aYear_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aYear"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aYear_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aYear)),
      new XsdFSM<aCommonName_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aCommonName"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aCommonName_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aCommonName)),
      new XsdFSM<aListOfIntMax5k_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aListOfIntMax5k"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aListOfIntMax5k_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aListOfIntMax5k)),
      new XsdFSM<aListOfFourIntMax500_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aListOfFourIntMax500"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aListOfFourIntMax500_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aListOfFourIntMax500)),
      new XsdFSM<aListOfTwoIntMax3k_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aListOfTwoIntMax3k"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aListOfTwoIntMax3k_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aListOfTwoIntMax3k)),
      new XsdFSM<aFont_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("aFont"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<aFont_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_aFont)),
      new XsdFSM<anotherFont_ptr>( Particle(new DOMString("http://www.example.com/STDemo"), DOMString("anotherFont"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<anotherFont_ptr, MyComplexType, FsmCbOptions>(_that, &MyComplexType::create_anotherFont)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  MyComplexType::xBoolean_p MyComplexType::sequence::element_xBoolean()
  {
      MyComplexType::xBoolean_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<xBoolean_ptr> *unitFsm = dynamic_cast<XsdFSM<xBoolean_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xBoolean", "{http://www.w3.org/2001/XMLSchema}xBoolean", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xBoolean(DOMString val)
  {
      
    element_xBoolean()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xBoolean_string()
  {
    return element_xBoolean()->stringValue();
  }

      
  void MyComplexType::sequence::set_xBoolean(bool val)     
  {
        
    element_xBoolean()->value(val);
  }

  bool MyComplexType::sequence::get_xBoolean()     
  {
    return element_xBoolean()->value();
  }

          

  MyComplexType::xDecimal_p MyComplexType::sequence::element_xDecimal()
  {
      MyComplexType::xDecimal_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<xDecimal_ptr> *unitFsm = dynamic_cast<XsdFSM<xDecimal_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDecimal", "{http://www.w3.org/2001/XMLSchema}xDecimal", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDecimal(DOMString val)
  {
      
    element_xDecimal()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDecimal_string()
  {
    return element_xDecimal()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDecimal(double val)     
  {
        
    element_xDecimal()->value(val);
  }

  double MyComplexType::sequence::get_xDecimal()     
  {
    return element_xDecimal()->value();
  }

          

  MyComplexType::xFloat_p MyComplexType::sequence::element_xFloat()
  {
      MyComplexType::xFloat_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[2].get();
    if(fsm_p) 
    {
      XsdFSM<xFloat_ptr> *unitFsm = dynamic_cast<XsdFSM<xFloat_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xFloat", "{http://www.w3.org/2001/XMLSchema}xFloat", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xFloat(DOMString val)
  {
      
    element_xFloat()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xFloat_string()
  {
    return element_xFloat()->stringValue();
  }

      
  void MyComplexType::sequence::set_xFloat(float val)     
  {
        
    element_xFloat()->value(val);
  }

  float MyComplexType::sequence::get_xFloat()     
  {
    return element_xFloat()->value();
  }

          

  MyComplexType::xDouble_p MyComplexType::sequence::element_xDouble()
  {
      MyComplexType::xDouble_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[3].get();
    if(fsm_p) 
    {
      XsdFSM<xDouble_ptr> *unitFsm = dynamic_cast<XsdFSM<xDouble_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDouble", "{http://www.w3.org/2001/XMLSchema}xDouble", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDouble(DOMString val)
  {
      
    element_xDouble()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDouble_string()
  {
    return element_xDouble()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDouble(double val)     
  {
        
    element_xDouble()->value(val);
  }

  double MyComplexType::sequence::get_xDouble()     
  {
    return element_xDouble()->value();
  }

          

  MyComplexType::xInteger_p MyComplexType::sequence::element_xInteger()
  {
      MyComplexType::xInteger_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[4].get();
    if(fsm_p) 
    {
      XsdFSM<xInteger_ptr> *unitFsm = dynamic_cast<XsdFSM<xInteger_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xInteger", "{http://www.w3.org/2001/XMLSchema}xInteger", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xInteger(DOMString val)
  {
      
    element_xInteger()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xInteger_string()
  {
    return element_xInteger()->stringValue();
  }

      
  void MyComplexType::sequence::set_xInteger(XPlus::Int64 val)     
  {
        
    element_xInteger()->value(val);
  }

  XPlus::Int64 MyComplexType::sequence::get_xInteger()     
  {
    return element_xInteger()->value();
  }

          

  MyComplexType::xPositiveInteger_p MyComplexType::sequence::element_xPositiveInteger()
  {
      MyComplexType::xPositiveInteger_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[5].get();
    if(fsm_p) 
    {
      XsdFSM<xPositiveInteger_ptr> *unitFsm = dynamic_cast<XsdFSM<xPositiveInteger_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xPositiveInteger", "{http://www.w3.org/2001/XMLSchema}xPositiveInteger", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xPositiveInteger(DOMString val)
  {
      
    element_xPositiveInteger()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xPositiveInteger_string()
  {
    return element_xPositiveInteger()->stringValue();
  }

      
  void MyComplexType::sequence::set_xPositiveInteger(XPlus::UInt64 val)     
  {
        
    element_xPositiveInteger()->value(val);
  }

  XPlus::UInt64 MyComplexType::sequence::get_xPositiveInteger()     
  {
    return element_xPositiveInteger()->value();
  }

          

  MyComplexType::xNonPositiveInteger_p MyComplexType::sequence::element_xNonPositiveInteger()
  {
      MyComplexType::xNonPositiveInteger_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[6].get();
    if(fsm_p) 
    {
      XsdFSM<xNonPositiveInteger_ptr> *unitFsm = dynamic_cast<XsdFSM<xNonPositiveInteger_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xNonPositiveInteger", "{http://www.w3.org/2001/XMLSchema}xNonPositiveInteger", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xNonPositiveInteger(DOMString val)
  {
      
    element_xNonPositiveInteger()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xNonPositiveInteger_string()
  {
    return element_xNonPositiveInteger()->stringValue();
  }

      
  void MyComplexType::sequence::set_xNonPositiveInteger(XPlus::Int64 val)     
  {
        
    element_xNonPositiveInteger()->value(val);
  }

  XPlus::Int64 MyComplexType::sequence::get_xNonPositiveInteger()     
  {
    return element_xNonPositiveInteger()->value();
  }

          

  MyComplexType::xNegativeInteger_p MyComplexType::sequence::element_xNegativeInteger()
  {
      MyComplexType::xNegativeInteger_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[7].get();
    if(fsm_p) 
    {
      XsdFSM<xNegativeInteger_ptr> *unitFsm = dynamic_cast<XsdFSM<xNegativeInteger_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xNegativeInteger", "{http://www.w3.org/2001/XMLSchema}xNegativeInteger", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xNegativeInteger(DOMString val)
  {
      
    element_xNegativeInteger()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xNegativeInteger_string()
  {
    return element_xNegativeInteger()->stringValue();
  }

      
  void MyComplexType::sequence::set_xNegativeInteger(XPlus::Int64 val)     
  {
        
    element_xNegativeInteger()->value(val);
  }

  XPlus::Int64 MyComplexType::sequence::get_xNegativeInteger()     
  {
    return element_xNegativeInteger()->value();
  }

          

  MyComplexType::xNonNegativeInteger_p MyComplexType::sequence::element_xNonNegativeInteger()
  {
      MyComplexType::xNonNegativeInteger_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[8].get();
    if(fsm_p) 
    {
      XsdFSM<xNonNegativeInteger_ptr> *unitFsm = dynamic_cast<XsdFSM<xNonNegativeInteger_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xNonNegativeInteger", "{http://www.w3.org/2001/XMLSchema}xNonNegativeInteger", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xNonNegativeInteger(DOMString val)
  {
      
    element_xNonNegativeInteger()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xNonNegativeInteger_string()
  {
    return element_xNonNegativeInteger()->stringValue();
  }

      
  void MyComplexType::sequence::set_xNonNegativeInteger(XPlus::UInt64 val)     
  {
        
    element_xNonNegativeInteger()->value(val);
  }

  XPlus::UInt64 MyComplexType::sequence::get_xNonNegativeInteger()     
  {
    return element_xNonNegativeInteger()->value();
  }

          

  MyComplexType::xLong_p MyComplexType::sequence::element_xLong()
  {
      MyComplexType::xLong_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[9].get();
    if(fsm_p) 
    {
      XsdFSM<xLong_ptr> *unitFsm = dynamic_cast<XsdFSM<xLong_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xLong", "{http://www.w3.org/2001/XMLSchema}xLong", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xLong(DOMString val)
  {
      
    element_xLong()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xLong_string()
  {
    return element_xLong()->stringValue();
  }

      
  void MyComplexType::sequence::set_xLong(XPlus::Int64 val)     
  {
        
    element_xLong()->value(val);
  }

  XPlus::Int64 MyComplexType::sequence::get_xLong()     
  {
    return element_xLong()->value();
  }

          

  MyComplexType::xInt_p MyComplexType::sequence::element_xInt()
  {
      MyComplexType::xInt_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[10].get();
    if(fsm_p) 
    {
      XsdFSM<xInt_ptr> *unitFsm = dynamic_cast<XsdFSM<xInt_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xInt", "{http://www.w3.org/2001/XMLSchema}xInt", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xInt(DOMString val)
  {
      
    element_xInt()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xInt_string()
  {
    return element_xInt()->stringValue();
  }

      
  void MyComplexType::sequence::set_xInt(int val)     
  {
        
    element_xInt()->value(val);
  }

  int MyComplexType::sequence::get_xInt()     
  {
    return element_xInt()->value();
  }

          

  MyComplexType::xShort_p MyComplexType::sequence::element_xShort()
  {
      MyComplexType::xShort_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[11].get();
    if(fsm_p) 
    {
      XsdFSM<xShort_ptr> *unitFsm = dynamic_cast<XsdFSM<xShort_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xShort", "{http://www.w3.org/2001/XMLSchema}xShort", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xShort(DOMString val)
  {
      
    element_xShort()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xShort_string()
  {
    return element_xShort()->stringValue();
  }

      
  void MyComplexType::sequence::set_xShort(short val)     
  {
        
    element_xShort()->value(val);
  }

  short MyComplexType::sequence::get_xShort()     
  {
    return element_xShort()->value();
  }

          

  MyComplexType::xByte_p MyComplexType::sequence::element_xByte()
  {
      MyComplexType::xByte_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[12].get();
    if(fsm_p) 
    {
      XsdFSM<xByte_ptr> *unitFsm = dynamic_cast<XsdFSM<xByte_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xByte", "{http://www.w3.org/2001/XMLSchema}xByte", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xByte(DOMString val)
  {
      
    element_xByte()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xByte_string()
  {
    return element_xByte()->stringValue();
  }

      
  void MyComplexType::sequence::set_xByte(char val)     
  {
        
    element_xByte()->value(val);
  }

  char MyComplexType::sequence::get_xByte()     
  {
    return element_xByte()->value();
  }

          

  MyComplexType::xUnsignedLong_p MyComplexType::sequence::element_xUnsignedLong()
  {
      MyComplexType::xUnsignedLong_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[13].get();
    if(fsm_p) 
    {
      XsdFSM<xUnsignedLong_ptr> *unitFsm = dynamic_cast<XsdFSM<xUnsignedLong_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xUnsignedLong", "{http://www.w3.org/2001/XMLSchema}xUnsignedLong", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xUnsignedLong(DOMString val)
  {
      
    element_xUnsignedLong()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xUnsignedLong_string()
  {
    return element_xUnsignedLong()->stringValue();
  }

      
  void MyComplexType::sequence::set_xUnsignedLong(XPlus::UInt64 val)     
  {
        
    element_xUnsignedLong()->value(val);
  }

  XPlus::UInt64 MyComplexType::sequence::get_xUnsignedLong()     
  {
    return element_xUnsignedLong()->value();
  }

          

  MyComplexType::xUnsignedInt_p MyComplexType::sequence::element_xUnsignedInt()
  {
      MyComplexType::xUnsignedInt_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[14].get();
    if(fsm_p) 
    {
      XsdFSM<xUnsignedInt_ptr> *unitFsm = dynamic_cast<XsdFSM<xUnsignedInt_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xUnsignedInt", "{http://www.w3.org/2001/XMLSchema}xUnsignedInt", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xUnsignedInt(DOMString val)
  {
      
    element_xUnsignedInt()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xUnsignedInt_string()
  {
    return element_xUnsignedInt()->stringValue();
  }

      
  void MyComplexType::sequence::set_xUnsignedInt(unsigned int val)     
  {
        
    element_xUnsignedInt()->value(val);
  }

  unsigned int MyComplexType::sequence::get_xUnsignedInt()     
  {
    return element_xUnsignedInt()->value();
  }

          

  MyComplexType::xUnsignedShort_p MyComplexType::sequence::element_xUnsignedShort()
  {
      MyComplexType::xUnsignedShort_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[15].get();
    if(fsm_p) 
    {
      XsdFSM<xUnsignedShort_ptr> *unitFsm = dynamic_cast<XsdFSM<xUnsignedShort_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xUnsignedShort", "{http://www.w3.org/2001/XMLSchema}xUnsignedShort", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xUnsignedShort(DOMString val)
  {
      
    element_xUnsignedShort()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xUnsignedShort_string()
  {
    return element_xUnsignedShort()->stringValue();
  }

      
  void MyComplexType::sequence::set_xUnsignedShort(unsigned short val)     
  {
        
    element_xUnsignedShort()->value(val);
  }

  unsigned short MyComplexType::sequence::get_xUnsignedShort()     
  {
    return element_xUnsignedShort()->value();
  }

          

  MyComplexType::xUnsignedByte_p MyComplexType::sequence::element_xUnsignedByte()
  {
      MyComplexType::xUnsignedByte_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[16].get();
    if(fsm_p) 
    {
      XsdFSM<xUnsignedByte_ptr> *unitFsm = dynamic_cast<XsdFSM<xUnsignedByte_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xUnsignedByte", "{http://www.w3.org/2001/XMLSchema}xUnsignedByte", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xUnsignedByte(DOMString val)
  {
      
    element_xUnsignedByte()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xUnsignedByte_string()
  {
    return element_xUnsignedByte()->stringValue();
  }

      
  void MyComplexType::sequence::set_xUnsignedByte(unsigned char val)     
  {
        
    element_xUnsignedByte()->value(val);
  }

  unsigned char MyComplexType::sequence::get_xUnsignedByte()     
  {
    return element_xUnsignedByte()->value();
  }

          

  MyComplexType::xHexBinary_p MyComplexType::sequence::element_xHexBinary()
  {
      MyComplexType::xHexBinary_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[17].get();
    if(fsm_p) 
    {
      XsdFSM<xHexBinary_ptr> *unitFsm = dynamic_cast<XsdFSM<xHexBinary_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xHexBinary", "{http://www.w3.org/2001/XMLSchema}xHexBinary", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xHexBinary(DOMString val)
  {
      
    element_xHexBinary()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xHexBinary_string()
  {
    return element_xHexBinary()->stringValue();
  }

          

  MyComplexType::xBase64Binary_p MyComplexType::sequence::element_xBase64Binary()
  {
      MyComplexType::xBase64Binary_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[18].get();
    if(fsm_p) 
    {
      XsdFSM<xBase64Binary_ptr> *unitFsm = dynamic_cast<XsdFSM<xBase64Binary_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xBase64Binary", "{http://www.w3.org/2001/XMLSchema}xBase64Binary", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xBase64Binary(DOMString val)
  {
      
    element_xBase64Binary()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xBase64Binary_string()
  {
    return element_xBase64Binary()->stringValue();
  }

          

  MyComplexType::xUri_p MyComplexType::sequence::element_xUri()
  {
      MyComplexType::xUri_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[19].get();
    if(fsm_p) 
    {
      XsdFSM<xUri_ptr> *unitFsm = dynamic_cast<XsdFSM<xUri_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xUri", "{http://www.w3.org/2001/XMLSchema}xUri", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xUri(DOMString val)
  {
      
    element_xUri()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xUri_string()
  {
    return element_xUri()->stringValue();
  }

          

  MyComplexType::xNormalizedString_p MyComplexType::sequence::element_xNormalizedString()
  {
      MyComplexType::xNormalizedString_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[20].get();
    if(fsm_p) 
    {
      XsdFSM<xNormalizedString_ptr> *unitFsm = dynamic_cast<XsdFSM<xNormalizedString_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xNormalizedString", "{http://www.w3.org/2001/XMLSchema}xNormalizedString", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xNormalizedString(DOMString val)
  {
      
    element_xNormalizedString()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xNormalizedString_string()
  {
    return element_xNormalizedString()->stringValue();
  }

          

  MyComplexType::xToken_p MyComplexType::sequence::element_xToken()
  {
      MyComplexType::xToken_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[21].get();
    if(fsm_p) 
    {
      XsdFSM<xToken_ptr> *unitFsm = dynamic_cast<XsdFSM<xToken_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xToken", "{http://www.w3.org/2001/XMLSchema}xToken", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xToken(DOMString val)
  {
      
    element_xToken()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xToken_string()
  {
    return element_xToken()->stringValue();
  }

          

  MyComplexType::xLanguage_p MyComplexType::sequence::element_xLanguage()
  {
      MyComplexType::xLanguage_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[22].get();
    if(fsm_p) 
    {
      XsdFSM<xLanguage_ptr> *unitFsm = dynamic_cast<XsdFSM<xLanguage_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xLanguage", "{http://www.w3.org/2001/XMLSchema}xLanguage", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xLanguage(DOMString val)
  {
      
    element_xLanguage()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xLanguage_string()
  {
    return element_xLanguage()->stringValue();
  }

          

  MyComplexType::xName_p MyComplexType::sequence::element_xName()
  {
      MyComplexType::xName_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[23].get();
    if(fsm_p) 
    {
      XsdFSM<xName_ptr> *unitFsm = dynamic_cast<XsdFSM<xName_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xName", "{http://www.w3.org/2001/XMLSchema}xName", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xName(DOMString val)
  {
      
    element_xName()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xName_string()
  {
    return element_xName()->stringValue();
  }

          

  MyComplexType::xNCName_p MyComplexType::sequence::element_xNCName()
  {
      MyComplexType::xNCName_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[24].get();
    if(fsm_p) 
    {
      XsdFSM<xNCName_ptr> *unitFsm = dynamic_cast<XsdFSM<xNCName_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xNCName", "{http://www.w3.org/2001/XMLSchema}xNCName", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xNCName(DOMString val)
  {
      
    element_xNCName()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xNCName_string()
  {
    return element_xNCName()->stringValue();
  }

          

  MyComplexType::xQName_p MyComplexType::sequence::element_xQName()
  {
      MyComplexType::xQName_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[25].get();
    if(fsm_p) 
    {
      XsdFSM<xQName_ptr> *unitFsm = dynamic_cast<XsdFSM<xQName_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xQName", "{http://www.w3.org/2001/XMLSchema}xQName", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xQName(DOMString val)
  {
      
    element_xQName()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xQName_string()
  {
    return element_xQName()->stringValue();
  }

          

  MyComplexType::xDateTime_p MyComplexType::sequence::element_xDateTime()
  {
      MyComplexType::xDateTime_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[26].get();
    if(fsm_p) 
    {
      XsdFSM<xDateTime_ptr> *unitFsm = dynamic_cast<XsdFSM<xDateTime_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDateTime", "{http://www.w3.org/2001/XMLSchema}xDateTime", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDateTime(DOMString val)
  {
      
    element_xDateTime()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDateTime_string()
  {
    return element_xDateTime()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDateTime(XPlus::DateTime val)     
  {
        
    element_xDateTime()->value(val);
  }

  XPlus::DateTime MyComplexType::sequence::get_xDateTime()     
  {
    return element_xDateTime()->value();
  }

          

  MyComplexType::xDate_p MyComplexType::sequence::element_xDate()
  {
      MyComplexType::xDate_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[27].get();
    if(fsm_p) 
    {
      XsdFSM<xDate_ptr> *unitFsm = dynamic_cast<XsdFSM<xDate_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDate", "{http://www.w3.org/2001/XMLSchema}xDate", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDate(DOMString val)
  {
      
    element_xDate()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDate_string()
  {
    return element_xDate()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDate(XPlus::Date val)     
  {
        
    element_xDate()->value(val);
  }

  XPlus::Date MyComplexType::sequence::get_xDate()     
  {
    return element_xDate()->value();
  }

          

  MyComplexType::xYearMonth_p MyComplexType::sequence::element_xYearMonth()
  {
      MyComplexType::xYearMonth_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[28].get();
    if(fsm_p) 
    {
      XsdFSM<xYearMonth_ptr> *unitFsm = dynamic_cast<XsdFSM<xYearMonth_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xYearMonth", "{http://www.w3.org/2001/XMLSchema}xYearMonth", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xYearMonth(DOMString val)
  {
      
    element_xYearMonth()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xYearMonth_string()
  {
    return element_xYearMonth()->stringValue();
  }

      
  void MyComplexType::sequence::set_xYearMonth(XPlus::YearMonth val)     
  {
        
    element_xYearMonth()->value(val);
  }

  XPlus::YearMonth MyComplexType::sequence::get_xYearMonth()     
  {
    return element_xYearMonth()->value();
  }

          

  MyComplexType::xYear_p MyComplexType::sequence::element_xYear()
  {
      MyComplexType::xYear_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[29].get();
    if(fsm_p) 
    {
      XsdFSM<xYear_ptr> *unitFsm = dynamic_cast<XsdFSM<xYear_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xYear", "{http://www.w3.org/2001/XMLSchema}xYear", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xYear(DOMString val)
  {
      
    element_xYear()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xYear_string()
  {
    return element_xYear()->stringValue();
  }

      
  void MyComplexType::sequence::set_xYear(XPlus::Year val)     
  {
        
    element_xYear()->value(val);
  }

  XPlus::Year MyComplexType::sequence::get_xYear()     
  {
    return element_xYear()->value();
  }

          

  MyComplexType::xMonthDay_p MyComplexType::sequence::element_xMonthDay()
  {
      MyComplexType::xMonthDay_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[30].get();
    if(fsm_p) 
    {
      XsdFSM<xMonthDay_ptr> *unitFsm = dynamic_cast<XsdFSM<xMonthDay_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xMonthDay", "{http://www.w3.org/2001/XMLSchema}xMonthDay", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xMonthDay(DOMString val)
  {
      
    element_xMonthDay()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xMonthDay_string()
  {
    return element_xMonthDay()->stringValue();
  }

      
  void MyComplexType::sequence::set_xMonthDay(XPlus::MonthDay val)     
  {
        
    element_xMonthDay()->value(val);
  }

  XPlus::MonthDay MyComplexType::sequence::get_xMonthDay()     
  {
    return element_xMonthDay()->value();
  }

          

  MyComplexType::xMonth_p MyComplexType::sequence::element_xMonth()
  {
      MyComplexType::xMonth_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[31].get();
    if(fsm_p) 
    {
      XsdFSM<xMonth_ptr> *unitFsm = dynamic_cast<XsdFSM<xMonth_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xMonth", "{http://www.w3.org/2001/XMLSchema}xMonth", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xMonth(DOMString val)
  {
      
    element_xMonth()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xMonth_string()
  {
    return element_xMonth()->stringValue();
  }

      
  void MyComplexType::sequence::set_xMonth(XPlus::Month val)     
  {
        
    element_xMonth()->value(val);
  }

  XPlus::Month MyComplexType::sequence::get_xMonth()     
  {
    return element_xMonth()->value();
  }

          

  MyComplexType::xDay_p MyComplexType::sequence::element_xDay()
  {
      MyComplexType::xDay_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[32].get();
    if(fsm_p) 
    {
      XsdFSM<xDay_ptr> *unitFsm = dynamic_cast<XsdFSM<xDay_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDay", "{http://www.w3.org/2001/XMLSchema}xDay", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDay(DOMString val)
  {
      
    element_xDay()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDay_string()
  {
    return element_xDay()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDay(XPlus::Day val)     
  {
        
    element_xDay()->value(val);
  }

  XPlus::Day MyComplexType::sequence::get_xDay()     
  {
    return element_xDay()->value();
  }

          

  MyComplexType::xTime_p MyComplexType::sequence::element_xTime()
  {
      MyComplexType::xTime_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[33].get();
    if(fsm_p) 
    {
      XsdFSM<xTime_ptr> *unitFsm = dynamic_cast<XsdFSM<xTime_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xTime", "{http://www.w3.org/2001/XMLSchema}xTime", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xTime(DOMString val)
  {
      
    element_xTime()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xTime_string()
  {
    return element_xTime()->stringValue();
  }

      
  void MyComplexType::sequence::set_xTime(XPlus::Time val)     
  {
        
    element_xTime()->value(val);
  }

  XPlus::Time MyComplexType::sequence::get_xTime()     
  {
    return element_xTime()->value();
  }

          

  MyComplexType::xDuration_p MyComplexType::sequence::element_xDuration()
  {
      MyComplexType::xDuration_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[34].get();
    if(fsm_p) 
    {
      XsdFSM<xDuration_ptr> *unitFsm = dynamic_cast<XsdFSM<xDuration_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "xDuration", "{http://www.w3.org/2001/XMLSchema}xDuration", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_xDuration(DOMString val)
  {
      
    element_xDuration()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_xDuration_string()
  {
    return element_xDuration()->stringValue();
  }

      
  void MyComplexType::sequence::set_xDuration(XPlus::Duration val)     
  {
        
    element_xDuration()->value(val);
  }

  XPlus::Duration MyComplexType::sequence::get_xDuration()     
  {
    return element_xDuration()->value();
  }

          

  List<MyComplexType::anIntMax10_ptr> MyComplexType::sequence::elements_anIntMax10()
  {
      
    List<anIntMax10_ptr> nodeList;
    XsdFsmBase* fsm_p = this->allFSMs()[35].get();
    if(fsm_p) 
    {
      XsdFSM<anIntMax10_ptr> *unitFsm = dynamic_cast<XsdFSM<anIntMax10_ptr> *>(fsm_p);
      if(unitFsm) {
        //nodeList = unitFsm->nodeList().stl_list(); 
        nodeList = unitFsm->nodeList(); 
      }
    }
    return nodeList;
        
  }
  
  
  MyComplexType::anIntMax10_p MyComplexType::sequence::element_anIntMax10_at(unsigned int idx)
  {
    return elements_anIntMax10().at(idx);
  }

    
  void MyComplexType::sequence::set_anIntMax10(unsigned int idx, DOMString val)
  {
    element_anIntMax10_at(idx)->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_anIntMax10_string(unsigned int idx)
  {
    return element_anIntMax10_at(idx)->stringValue();
  }
      
  void MyComplexType::sequence::set_anIntMax10(unsigned int idx,int val)
  {
    element_anIntMax10_at(idx)->value(val);
  }

  int MyComplexType::sequence::get_anIntMax10(unsigned int idx)
  {
    return element_anIntMax10_at(idx)->value();
  }

      
  MyComplexType::anIntMax10_p MyComplexType::sequence::add_node_anIntMax10()
  {
    DOMStringPtr nsUriPtr = new DOMString("http://www.example.com/STDemo");
    XsdEvent event(nsUriPtr, NULL, DOMString("anIntMax10"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
    return elements_anIntMax10().back();
  }

  List<MyComplexType::anIntMax10_ptr> MyComplexType::sequence::set_count_anIntMax10(unsigned int size)
  {
    if( (size > 5) || (size < 3)) {
      ostringstream oss;
      oss << "set_count_anIntMax10: size should be in range: [" << 3
        << "," << 5 << "]";
      throw IndexOutOfBoundsException(oss.str());
    }

    unsigned int prevSize = elements_anIntMax10().size();
    if(size < prevSize) {
      //FIXME: allow later:
      throw XPlus::RuntimeException("resize lesser than current size not allowed");
    }

    for(unsigned int j=prevSize; j<size; j++) 
    {
      // pretend docBuilding to avoid computation of adding after first loop
      XsdEvent event(new DOMString("http://www.example.com/STDemo"), NULL, DOMString("anIntMax10"), XsdEvent::ELEMENT_START, false);
      this->processEventThrow(event); 
    }
    
    return elements_anIntMax10();
  }

        
    
  void MyComplexType::sequence::add_anIntMax10_string(DOMString val)
  {
    this->add_node_anIntMax10()->stringValue(val);
  }
          

  void MyComplexType::sequence::add_anIntMax10(int val)  
  {
    this->add_node_anIntMax10()->value(val);
  }
              

  MyComplexType::anIntMax5k_p MyComplexType::sequence::element_anIntMax5k()
  {
      MyComplexType::anIntMax5k_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[36].get();
    if(fsm_p) 
    {
      XsdFSM<anIntMax5k_ptr> *unitFsm = dynamic_cast<XsdFSM<anIntMax5k_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "anIntMax5k", "{http://www.example.com/STDemo}anIntMax5k", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_anIntMax5k(DOMString val)
  {
      
    element_anIntMax5k()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_anIntMax5k_string()
  {
    return element_anIntMax5k()->stringValue();
  }

      
  void MyComplexType::sequence::set_anIntMax5k(int val)     
  {
        
    element_anIntMax5k()->value(val);
  }

  int MyComplexType::sequence::get_anIntMax5k()     
  {
    return element_anIntMax5k()->value();
  }

          

  globalWaterTemp_p MyComplexType::sequence::element_globalWaterTemp()
  {
      globalWaterTemp_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[37].get();
    if(fsm_p) 
    {
      XsdFSM<globalWaterTemp_ptr> *unitFsm = dynamic_cast<XsdFSM<globalWaterTemp_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "globalWaterTemp", "{http://www.example.com/STDemo}globalWaterTemp", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_globalWaterTemp(DOMString val)
  {
      
    element_globalWaterTemp()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_globalWaterTemp_string()
  {
    return element_globalWaterTemp()->stringValue();
  }

      
  void MyComplexType::sequence::set_globalWaterTemp(double val)     
  {
        
    element_globalWaterTemp()->value(val);
  }

  double MyComplexType::sequence::get_globalWaterTemp()     
  {
    return element_globalWaterTemp()->value();
  }

          

  MyComplexType::aSKU_p MyComplexType::sequence::element_aSKU()
  {
      MyComplexType::aSKU_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[38].get();
    if(fsm_p) 
    {
      XsdFSM<aSKU_ptr> *unitFsm = dynamic_cast<XsdFSM<aSKU_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aSKU", "{http://www.example.com/STDemo}aSKU", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aSKU(DOMString val)
  {
      
    element_aSKU()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aSKU_string()
  {
    return element_aSKU()->stringValue();
  }

          

  MyComplexType::aDateTime_p MyComplexType::sequence::element_aDateTime()
  {
      MyComplexType::aDateTime_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[39].get();
    if(fsm_p) 
    {
      XsdFSM<aDateTime_ptr> *unitFsm = dynamic_cast<XsdFSM<aDateTime_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aDateTime", "{http://www.example.com/STDemo}aDateTime", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aDateTime(DOMString val)
  {
      
    element_aDateTime()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aDateTime_string()
  {
    return element_aDateTime()->stringValue();
  }

      
  void MyComplexType::sequence::set_aDateTime(XPlus::DateTime val)     
  {
        
    element_aDateTime()->value(val);
  }

  XPlus::DateTime MyComplexType::sequence::get_aDateTime()     
  {
    return element_aDateTime()->value();
  }

          

  MyComplexType::aDate_p MyComplexType::sequence::element_aDate()
  {
      MyComplexType::aDate_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[40].get();
    if(fsm_p) 
    {
      XsdFSM<aDate_ptr> *unitFsm = dynamic_cast<XsdFSM<aDate_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aDate", "{http://www.example.com/STDemo}aDate", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aDate(DOMString val)
  {
      
    element_aDate()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aDate_string()
  {
    return element_aDate()->stringValue();
  }

      
  void MyComplexType::sequence::set_aDate(XPlus::Date val)     
  {
        
    element_aDate()->value(val);
  }

  XPlus::Date MyComplexType::sequence::get_aDate()     
  {
    return element_aDate()->value();
  }

          

  MyComplexType::aYear_p MyComplexType::sequence::element_aYear()
  {
      MyComplexType::aYear_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[41].get();
    if(fsm_p) 
    {
      XsdFSM<aYear_ptr> *unitFsm = dynamic_cast<XsdFSM<aYear_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aYear", "{http://www.example.com/STDemo}aYear", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aYear(DOMString val)
  {
      
    element_aYear()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aYear_string()
  {
    return element_aYear()->stringValue();
  }

      
  void MyComplexType::sequence::set_aYear(XPlus::Year val)     
  {
        
    element_aYear()->value(val);
  }

  XPlus::Year MyComplexType::sequence::get_aYear()     
  {
    return element_aYear()->value();
  }

          

  MyComplexType::aCommonName_p MyComplexType::sequence::element_aCommonName()
  {
      MyComplexType::aCommonName_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[42].get();
    if(fsm_p) 
    {
      XsdFSM<aCommonName_ptr> *unitFsm = dynamic_cast<XsdFSM<aCommonName_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aCommonName", "{}aCommonName", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aCommonName(DOMString val)
  {
      
    element_aCommonName()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aCommonName_string()
  {
    return element_aCommonName()->stringValue();
  }

          

  MyComplexType::aListOfIntMax5k_p MyComplexType::sequence::element_aListOfIntMax5k()
  {
      MyComplexType::aListOfIntMax5k_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[43].get();
    if(fsm_p) 
    {
      XsdFSM<aListOfIntMax5k_ptr> *unitFsm = dynamic_cast<XsdFSM<aListOfIntMax5k_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aListOfIntMax5k", "{http://www.example.com/STDemo}aListOfIntMax5k", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aListOfIntMax5k(DOMString val)
  {
      
    element_aListOfIntMax5k()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aListOfIntMax5k_string()
  {
    return element_aListOfIntMax5k()->stringValue();
  }

          

  MyComplexType::aListOfFourIntMax500_p MyComplexType::sequence::element_aListOfFourIntMax500()
  {
      MyComplexType::aListOfFourIntMax500_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[44].get();
    if(fsm_p) 
    {
      XsdFSM<aListOfFourIntMax500_ptr> *unitFsm = dynamic_cast<XsdFSM<aListOfFourIntMax500_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aListOfFourIntMax500", "{http://www.example.com/STDemo}aListOfFourIntMax500", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aListOfFourIntMax500(DOMString val)
  {
      
    element_aListOfFourIntMax500()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aListOfFourIntMax500_string()
  {
    return element_aListOfFourIntMax500()->stringValue();
  }

          

  MyComplexType::aListOfTwoIntMax3k_p MyComplexType::sequence::element_aListOfTwoIntMax3k()
  {
      MyComplexType::aListOfTwoIntMax3k_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[45].get();
    if(fsm_p) 
    {
      XsdFSM<aListOfTwoIntMax3k_ptr> *unitFsm = dynamic_cast<XsdFSM<aListOfTwoIntMax3k_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aListOfTwoIntMax3k", "{http://www.example.com/STDemo}aListOfTwoIntMax3k", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aListOfTwoIntMax3k(DOMString val)
  {
      
    element_aListOfTwoIntMax3k()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aListOfTwoIntMax3k_string()
  {
    return element_aListOfTwoIntMax3k()->stringValue();
  }

          

  MyComplexType::aFont_p MyComplexType::sequence::element_aFont()
  {
      MyComplexType::aFont_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[46].get();
    if(fsm_p) 
    {
      XsdFSM<aFont_ptr> *unitFsm = dynamic_cast<XsdFSM<aFont_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "aFont", "{http://www.example.com/STDemo}aFont", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_aFont(DOMString val)
  {
      
    element_aFont()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_aFont_string()
  {
    return element_aFont()->stringValue();
  }

          

  MyComplexType::anotherFont_p MyComplexType::sequence::element_anotherFont()
  {
      MyComplexType::anotherFont_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[47].get();
    if(fsm_p) 
    {
      XsdFSM<anotherFont_ptr> *unitFsm = dynamic_cast<XsdFSM<anotherFont_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "anotherFont", "{http://www.example.com/STDemo}anotherFont", 1);
    return node_p;
        
  }
  
  
  void MyComplexType::sequence::set_anotherFont(DOMString val)
  {
      
    element_anotherFont()->stringValue(val);
  }

  DOMString MyComplexType::sequence::get_anotherFont_string()
  {
    return element_anotherFont()->stringValue();
  }

      
} //  end namespace Types 


} // end namespace      
    



examples/org


examples/org/README

INPUT_XSD=org.xsd


examples/org/engg.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ns1="urn:org:engg"
  xmlns:ns2="urn:org:hr"
  targetNamespace="urn:org:engg"
>
  <xsd:import namespace="urn:org:hr" schemaLocation="hr.xsd"/>

  <xsd:complexType name="EnggDept">
    <xsd:sequence>
      <xsd:element ref="ns2:leaderId"/>
      <xsd:element name="project" type="ns1:EnggProject" maxOccurs="unbounded"/>
    </xsd:sequence>
    <xsd:attribute name="id" type="xsd:token" use="required"/>
  </xsd:complexType>

  <xsd:complexType name="EnggProject">
    <xsd:sequence>
      <xsd:element ref="ns2:leaderId"/>
      <xsd:element name="projectName" type="xsd:string"/>
      <xsd:element name="engineers" type="ns2:UserIdList"/>
    </xsd:sequence>
  </xsd:complexType>



</xsd:schema>


examples/org/hr.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ns1="urn:org:hr"
  targetNamespace="urn:org:hr"
>

  <xsd:element name="userId" type="ns1:UserId" />
  <xsd:element name="leaderId" type="ns1:UserId" />

  <xsd:simpleType name="UserId">
    <xsd:restriction base='xsd:token'>
    </xsd:restriction>
  </xsd:simpleType>

  <xsd:complexType name="UserIdList">
    <xsd:sequence>
      <xsd:element ref="ns1:userId" minOccurs="0" maxOccurs="unbounded"/>
    </xsd:sequence>
  </xsd:complexType>

  <xsd:complexType name="Employee">
    <xsd:sequence>
      <xsd:element ref="ns1:userId"/>
      <xsd:element name="name" type="xsd:string"/>
      <xsd:element name="title" type="xsd:string"/>
      <xsd:element name="joiningDate" type="xsd:date"/>
      <xsd:element name="reportsTo" type="ns1:UserId" minOccurs="0"/>
      <xsd:element name="reportees" type="ns1:UserIdList"/>
    </xsd:sequence>
  </xsd:complexType>

  <xsd:complexType name="AllEmployees">
    <xsd:sequence>
      <xsd:element name="employee" type="ns1:Employee" maxOccurs="unbounded"/>
    </xsd:sequence>
  </xsd:complexType>


</xsd:schema>



examples/org/legal.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ns1="urn:org:legal"
  xmlns:ns2="urn:org:hr"
  targetNamespace="urn:org:legal"
>
  <xsd:import namespace="urn:org:hr" schemaLocation="hr.xsd"/>

  <xsd:complexType name="LegalDept">
    <xsd:sequence>
      <xsd:element ref="ns2:leaderId"/>
      <xsd:element name="legalAdvisors" type="ns2:UserIdList"/>
    </xsd:sequence>
    <xsd:attribute name="id" type="xsd:token" use="required"/>
  </xsd:complexType>

</xsd:schema>


examples/org/org.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
  xmlns:ns1="urn:org"
  xmlns:ns2="urn:org:engg"
  xmlns:ns3="urn:org:legal"
  xmlns:ns4="urn:org:hr"
  targetNamespace="urn:org"
>

  <xsd:import namespace="urn:org:engg" schemaLocation="engg.xsd"/>
  <xsd:import namespace="urn:org:legal" schemaLocation="legal.xsd"/>
  <xsd:import namespace="urn:org:hr" schemaLocation="hr.xsd"/>

  <xsd:element name="organization">
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element ref="ns4:leaderId"/>
        <xsd:element name="name" type="xsd:string"/>
        <xsd:element name="departments" type="ns1:Departments"/>
        <xsd:element name="allEmployees" type="ns4:AllEmployees"/>
      </xsd:sequence>
      <xsd:attribute name="id" type="xsd:token" use="required"/>
    </xsd:complexType>
  </xsd:element>

  <xsd:complexType name="Departments">
    <xsd:sequence>
      <xsd:element name="engineering" type="ns2:EnggDept"/>
      <xsd:element name="legal" type="ns3:LegalDept"/>
    </xsd:sequence>
  </xsd:complexType>

</xsd:schema>


examples/org/valid.xml

<?xml version="1.0"?>
<ns1:organization id="nasa" xmlns:ns1="urn:org" xmlns:ns2="urn:org:hr">
  <ns2:leaderId>jimb</ns2:leaderId>
  <name>NASA</name>
  <departments>
    <engineering id="nasa.deperatments.engineering">
      <ns2:leaderId>paulb</ns2:leaderId>
      <project>
        <ns2:leaderId>allenb</ns2:leaderId>
        <projectName>The unmanned moon mission 2015</projectName>
        <engineers>
          <ns2:userId>charlese</ns2:userId>
          <ns2:userId>waynec</ns2:userId>
        </engineers>
      </project>
      <project>
        <ns2:leaderId>leeb</ns2:leaderId>
        <projectName>The manned moon mission 2020</projectName>
        <engineers>
          <ns2:userId>peterc</ns2:userId>
          <ns2:userId>davidc</ns2:userId>
        </engineers>
      </project>
    </engineering>
    <legal id="nasa.deperatments.legal">
      <ns2:leaderId>donb</ns2:leaderId>
      <legalAdvisors>
        <ns2:userId>danc</ns2:userId>
        <ns2:userId>ugoc</ns2:userId>
      </legalAdvisors>
    </legal>
  </departments>
  <allEmployees>
    <employee>
      <ns2:userId>jimb</ns2:userId>
      <name>Jim Barnette</name>
      <title>org head</title>
      <joiningDate>1978-02-11</joiningDate>
      <reportees>
        <ns2:userId>paulb</ns2:userId>
        <ns2:userId>donb</ns2:userId>
      </reportees>
    </employee>
    <employee>
      <ns2:userId>paulb</ns2:userId>
      <name>Paul V. Biron</name>
      <title>Engg head</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>jimb</reportsTo>
      <reportees>
        <ns2:userId>allenb</ns2:userId>
        <ns2:userId>leeb</ns2:userId>
      </reportees>
    </employee>
    <employee>
      <ns2:userId>donb</ns2:userId>
      <name>Don Box</name>
      <title>Legal head</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>jimb</reportsTo>
      <reportees>
        <ns2:userId>danc</ns2:userId>
        <ns2:userId>ugoc</ns2:userId>
      </reportees>
    </employee>
    <employee>
      <ns2:userId>allenb</ns2:userId>
      <name>Allen Brown</name>
      <title>Proj1 head</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>paulb</reportsTo>
      <reportees>
        <ns2:userId>charlese</ns2:userId>
        <ns2:userId>waynec</ns2:userId>
      </reportees>
    </employee>
    <employee>
      <ns2:userId>leeb</ns2:userId>
      <name>Lee Buck</name>
      <title>Proj2 head</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>paulb</reportsTo>
      <reportees>
        <ns2:userId>peterc</ns2:userId>
        <ns2:userId>davidc</ns2:userId>
      </reportees>
    </employee>
    <employee>
      <ns2:userId>charlese</ns2:userId>
      <name>Charles E Campbell</name>
      <title>SMTS</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>allenb</reportsTo>
      <reportees/>
    </employee>
    <employee>
      <ns2:userId>waynec</ns2:userId>
      <name>Wayne Carr</name>
      <title>SMTS</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>allenb</reportsTo>
      <reportees/>
    </employee>
    <employee>
      <ns2:userId>peterc</ns2:userId>
      <name>Peter Chen</name>
      <title>SMTS</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>leeb</reportsTo>
      <reportees/>
    </employee>
    <employee>
      <ns2:userId>davidc</ns2:userId>
      <name>David Cleary</name>
      <title>SMTS</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>leeb</reportsTo>
      <reportees/>
    </employee>
    <employee>
      <ns2:userId>danc</ns2:userId>
      <name>Dan Connolly</name>
      <title>Legal Advisor</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>donb</reportsTo>
      <reportees/>
    </employee>
    <employee>
      <ns2:userId>ugoc</ns2:userId>
      <name>Ugo Corda</name>
      <title>Legal Advisor</title>
      <joiningDate>1978-02-15</joiningDate>
      <reportsTo>donb</reportsTo>
      <reportees/>
    </employee>
  </allEmployees>
</ns1:organization>


examples/org/include/org_hr/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_DOCUMENT_H__
#define  __org_hr_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "org_hr/userId.h"
    
#include "org_hr/leaderId.h"
    

using namespace XPlus;
using namespace FSM;


namespace org {
      
namespace hr {
    

class Document : public XMLSchema::TDocument
{
  private:
  
  
  userId_ptr _userId;
    
  AutoPtr<XsdFSM<userId_ptr> > _fsm_userId;
  
  leaderId_ptr _leaderId;
    
  AutoPtr<XsdFSM<leaderId_ptr> > _fsm_leaderId;
    
  
  // attributes, elements
  
  userId_ptr create_userId(FsmCbOptions& options);

  leaderId_ptr create_leaderId(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  void set_root_userId();
    
  void set_root_leaderId();
    
  userId_p element_userId();
  
  leaderId_p element_leaderId();
    
    
  void initFSM();
};

} // end namespace hr  
} // end namespace org
#endif
  


examples/org/include/org_hr/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_ALL_INCLUDE_H__
#define  __org_hr_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "org_hr/Document.h"

#include "org_hr/userId.h"    
  
#include "org_hr/leaderId.h"    
  
#include "org_hr/Types/UserId.h"    
  
#include "org_hr/Types/UserIdList.h"    
  
#include "org_hr/Types/Employee.h"    
  
#include "org_hr/Types/AllEmployees.h"    
  

using namespace XPlus;


#endif 
  


examples/org/include/org_hr/userId.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_userId_H__
#define  __org_hr_userId_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/Types/UserId.h"
      

using namespace XPlus;

namespace org {
      
namespace hr {
    
  typedef XMLSchema::XmlElement<org::hr::Types::UserId> userId;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {urn:org:hr}userId
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserId> > userId_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId>* userId_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId> userId; 
  
} // end namespace hr  
} // end namespace org
#endif


examples/org/include/org_hr/leaderId.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_leaderId_H__
#define  __org_hr_leaderId_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/Types/UserId.h"
      

using namespace XPlus;

namespace org {
      
namespace hr {
    
  typedef XMLSchema::XmlElement<org::hr::Types::UserId> leaderId;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {urn:org:hr}leaderId
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserId> > leaderId_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId>* leaderId_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId> leaderId; 
  
} // end namespace hr  
} // end namespace org
#endif


examples/org/include/org_hr/Types/Employee.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_types_Employee_H__
#define  __org_hr_types_Employee_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/userId.h"
      
#include "org_hr/Types/UserId.h"
      
#include "org_hr/Types/UserIdList.h"
      
using namespace XPlus; 



namespace org {
      
namespace hr {
    
namespace Types 
{
  
/// The class for complexType Employee
/// \n Refer to documentation on structures/methods inside ...
class Employee : public XMLSchema::Types::anyType
{
  public:
  //constructor
  Employee(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::userId > userId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::userId* userId_p;
  
  /// typedef for the node
  typedef org::hr::userId userId; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > name_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* name_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> name; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > title_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* title_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> title; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_date> > joiningDate_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_date>* joiningDate_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_date> joiningDate; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserId> > reportsTo_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId>* reportsTo_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserId> reportsTo; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserIdList> > reportees_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList>* reportees_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList> reportees; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(Employee* that);

    

    ///  For the scalar-element with QName "{urn:org:hr}userId" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    userId_p element_userId();

        

    ///  For the scalar-element with QName "{urn:org:hr}userId" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_userId(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}userId" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_userId_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    name_p element_name();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_name(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_name_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    title_p element_title();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_title(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_title_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    joiningDate_p element_joiningDate();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_joiningDate(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_joiningDate_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as XPlus::Date) to set with 
    void set_joiningDate(XPlus::Date val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
    ///  \n Returns the value of the scalar element
    ///  @return the value(as XPlus::Date) of the element 
    XPlus::Date get_joiningDate();

          

    ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    reportsTo_p element_reportsTo();

        

    ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_reportsTo(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_reportsTo_string();

          
    ///  For the optional scalar element with QName "{urn:org:hr}reportsTo" :
    ///  \n Marks the element as present 
    void mark_present_reportsTo();
    

    ///  For the scalar-element with QName "{urn:org:hr}reportees" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    reportees_p element_reportees();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    Employee*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:hr}userId" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  userId_p element_userId();
      

  ///  For the scalar-element with QName "{urn:org:hr}userId" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_userId(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}userId" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_userId_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  name_p element_name();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_name(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_name_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  title_p element_title();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_title(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}title" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_title_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  joiningDate_p element_joiningDate();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_joiningDate(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_joiningDate_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as XPlus::Date) to set with 
  void set_joiningDate(XPlus::Date val);

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}joiningDate" :
  ///  \n Returns the value of the element
  ///  @return the value(as XPlus::Date) of the element 
  XPlus::Date get_joiningDate();

        

  ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  reportsTo_p element_reportsTo();
      

  ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_reportsTo(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}reportsTo" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_reportsTo_string();

        

  ///  For the optional scalar element with QName "{urn:org:hr}reportsTo" :
  ///  Marks the element as present 
  void mark_present_reportsTo();

  

  ///  For the scalar-element with QName "{urn:org:hr}reportees" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  reportees_p element_reportees();
      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  userId_ptr _userId;
            
  name_ptr _name;
            
  title_ptr _title;
            
  joiningDate_ptr _joiningDate;
            
  reportsTo_ptr _reportsTo;
            
  reportees_ptr _reportees;
              

  /// initialize the FSM
  void initFSM();

  
  userId_ptr create_userId(FsmCbOptions& options);

  name_ptr create_name(FsmCbOptions& options);

  title_ptr create_title(FsmCbOptions& options);

  joiningDate_ptr create_joiningDate(FsmCbOptions& options);

  reportsTo_ptr create_reportsTo(FsmCbOptions& options);

  reportees_ptr create_reportees(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<Employee> >   s_typeRegistry;
}; //end class Employee
} // end namespace Types


} // end namespace hr  
} // end namespace org
#endif
  


examples/org/include/org_hr/Types/AllEmployees.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_types_AllEmployees_H__
#define  __org_hr_types_AllEmployees_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/Types/Employee.h"
      
using namespace XPlus; 



namespace org {
      
namespace hr {
    
namespace Types 
{
  
/// The class for complexType AllEmployees
/// \n Refer to documentation on structures/methods inside ...
class AllEmployees : public XMLSchema::Types::anyType
{
  public:
  //constructor
  AllEmployees(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::Employee> > employee_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::Employee>* employee_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::Employee> employee; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(AllEmployees* that);

    

    ///  For vector-element with QName "{urn:org:hr}employee" :
    ///  \n Returns the list of the element nodes
    ///  @return the list of element nodes fetched
    List<employee_ptr> elements_employee();

    ///  For vector-element with QName "{urn:org:hr}employee" :
    ///  \n Returns the element node at supplied index
    ///  @param idx index of the element to fetch 
    ///  @return the element node fetched
    employee_p element_employee_at(unsigned int idx);

        

    ///  For vector-element with QName "{urn:org:hr}employee" :
    ///  \n Adds one element to the end of the "list of the element nodes"
    ///  @return the pointer to the added element
    employee_p add_node_employee();

    ///  For vector-element with QName "{urn:org:hr}employee" :
    ///  \n Sizes-up the "list of the element nodes" with the supplied size
    ///  @param size the request size(unsigned int) of the list
    ///  @return the list of "pointer-to-element-node"
    List<employee_ptr> set_count_employee(unsigned int size);


      

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    AllEmployees*      _that;
  }; // end sequence
  

  ///  For vector-element with QName "{urn:org:hr}employee" :
  ///  \n Returns the list of the element nodes
  ///  @return the list of element nodes fetched
  List<employee_ptr> elements_employee();

  ///  For vector-element with QName "{urn:org:hr}employee" :
  ///  \n Returns the element node at supplied index
  ///  @param idx index of the element to fetch 
  ///  @return the element node fetched
  employee_p element_employee_at(unsigned int idx);

  

  ///  For vector-element with QName "{urn:org:hr}employee" :
  ///  \n Adds one element to the end of the "list of the element nodes"
  ///  @return the pointer to the added element
  employee_p add_node_employee();
  
  ///  For vector-element with QName "{urn:org:hr}employee" :
  ///  \n Sizes-up the "list of the element nodes" with the supplied size
  ///  @param size the request size(unsigned int) of the list
  ///  @return the list of "pointer-to-element-node"
  List<employee_ptr> set_count_employee(unsigned int size);

      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  List<employee_ptr> _list_employee;
              

  /// initialize the FSM
  void initFSM();

  
  employee_ptr create_employee(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<AllEmployees> >   s_typeRegistry;
}; //end class AllEmployees
} // end namespace Types


} // end namespace hr  
} // end namespace org
#endif
  


examples/org/include/org_hr/Types/UserIdList.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_hr_types_UserIdList_H__
#define  __org_hr_types_UserIdList_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/userId.h"
      
using namespace XPlus; 



namespace org {
      
namespace hr {
    
namespace Types 
{
  
/// The class for complexType UserIdList
/// \n Refer to documentation on structures/methods inside ...
class UserIdList : public XMLSchema::Types::anyType
{
  public:
  //constructor
  UserIdList(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::userId > userId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::userId* userId_p;
  
  /// typedef for the node
  typedef org::hr::userId userId; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(UserIdList* that);

    

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Returns the list of the element nodes
    ///  @return the list of element nodes fetched
    List<userId_ptr> elements_userId();

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Returns the element node at supplied index
    ///  @param idx index of the element to fetch 
    ///  @return the element node fetched
    userId_p element_userId_at(unsigned int idx);

        
        

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Sets the value of the element at the supplied index with the supplied value
    ///  @param idx index of the element 
    ///  @param val the value(as DOMString) to set with 
    void set_userId(unsigned int idx, DOMString val);

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Returns the value of the element at the supplied index with the supplied value.
    ///  @param idx index of the element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_userId_string(unsigned int idx);


          

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Adds one element to the end of the "list of the element nodes"
    ///  @return the pointer to the added element
    userId_p add_node_userId();

    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Sizes-up the "list of the element nodes" with the supplied size
    ///  @param size the request size(unsigned int) of the list
    ///  @return the list of "pointer-to-element-node"
    List<userId_ptr> set_count_userId(unsigned int size);


      
      
    ///  For vector-element with QName "{urn:org:hr}userId" :
    ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
    ///  @param val the value(as DOMString) to set with 
    void add_userId_string(DOMString val);
      
        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    UserIdList*      _that;
  }; // end sequence
  

  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Returns the list of the element nodes
  ///  @return the list of element nodes fetched
  List<userId_ptr> elements_userId();

  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Returns the element node at supplied index
  ///  @param idx index of the element to fetch 
  ///  @return the element node fetched
  userId_p element_userId_at(unsigned int idx);

  

  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Sets the value of the element at the supplied index with the supplied value
  ///  @param idx index of the element 
  ///  @param val the value(as DOMString) to set with 
  void set_userId(unsigned int idx, DOMString val);

  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Returns the value of the element at the supplied index with the supplied value.
  ///  @param idx index of the element 
  ///  @return the value(as DOMString) of the element 
  DOMString get_userId_string(unsigned int idx);

        

  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Adds one element to the end of the "list of the element nodes"
  ///  @return the pointer to the added element
  userId_p add_node_userId();
  
  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Sizes-up the "list of the element nodes" with the supplied size
  ///  @param size the request size(unsigned int) of the list
  ///  @return the list of "pointer-to-element-node"
  List<userId_ptr> set_count_userId(unsigned int size);

      
      
  ///  For vector-element with QName "{urn:org:hr}userId" :
  ///  \n Adds one element to the end of the "list of the element nodes", and sets the value with supplied DOMString value
  ///  @param val the value(as DOMString) to set with 
  void add_userId_string(DOMString val);
      
        

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  List<userId_ptr> _list_userId;
              

  /// initialize the FSM
  void initFSM();

  
  userId_ptr create_userId(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<UserIdList> >   s_typeRegistry;
}; //end class UserIdList
} // end namespace Types


} // end namespace hr  
} // end namespace org
#endif
  


examples/org/include/org_hr/Types/UserId.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef __org_hr_UserId_H__ 
#define __org_hr_UserId_H__ 

#include <string>
#include <list>

#include "DOM/DOMCommonInc.h"
#include "XSD/PrimitiveTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/PrimitiveTypes.h"


using namespace std;
using namespace XPlus;
using namespace DOM;
using namespace XMLSchema;


namespace org {
      
namespace hr {
    

namespace Types 
{
    

  /// class for simpleType with restriction on base
  class UserId : public XMLSchema::Types::bt_token
  {
  public:
    /// constructor  
    UserId(AnyTypeCreateArgs args)
    
        : bt_token(args)
      
    {
    
      this->appliedCFacets( appliedCFacets()  );
    }
    
  protected:
    
  };

} // end namespace Types

} // end namespace hr  
} // end namespace org

#endif
  


examples/org/include/org_engg/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_engg_ALL_INCLUDE_H__
#define  __org_engg_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "org_hr/all-include.h"
  
#include "org_engg/Types/EnggDept.h"    
  
#include "org_engg/Types/EnggProject.h"    
  

using namespace XPlus;


#endif 
  


examples/org/include/org_engg/Types/EnggProject.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_engg_types_EnggProject_H__
#define  __org_engg_types_EnggProject_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/leaderId.h"
      
#include "org_hr/Types/UserIdList.h"
      
using namespace XPlus; 



namespace org {
      
namespace engg {
    
namespace Types 
{
  
/// The class for complexType EnggProject
/// \n Refer to documentation on structures/methods inside ...
class EnggProject : public XMLSchema::Types::anyType
{
  public:
  //constructor
  EnggProject(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::leaderId > leaderId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::leaderId* leaderId_p;
  
  /// typedef for the node
  typedef org::hr::leaderId leaderId; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > projectName_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* projectName_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> projectName; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserIdList> > engineers_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList>* engineers_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList> engineers; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(EnggProject* that);

    

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    leaderId_p element_leaderId();

        

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_leaderId(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_leaderId_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    projectName_p element_projectName();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_projectName(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_projectName_string();

          

    ///  For the scalar-element with QName "{urn:org:hr}engineers" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    engineers_p element_engineers();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    EnggProject*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  leaderId_p element_leaderId();
      

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_leaderId(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_leaderId_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  projectName_p element_projectName();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_projectName(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}projectName" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_projectName_string();

        

  ///  For the scalar-element with QName "{urn:org:hr}engineers" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  engineers_p element_engineers();
      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  leaderId_ptr _leaderId;
            
  projectName_ptr _projectName;
            
  engineers_ptr _engineers;
              

  /// initialize the FSM
  void initFSM();

  
  leaderId_ptr create_leaderId(FsmCbOptions& options);

  projectName_ptr create_projectName(FsmCbOptions& options);

  engineers_ptr create_engineers(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<EnggProject> >   s_typeRegistry;
}; //end class EnggProject
} // end namespace Types


} // end namespace engg  
} // end namespace org
#endif
  


examples/org/include/org_engg/Types/EnggDept.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_engg_types_EnggDept_H__
#define  __org_engg_types_EnggDept_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/leaderId.h"
      
#include "org_engg/Types/EnggProject.h"
      
using namespace XPlus; 



namespace org {
      
namespace engg {
    
namespace Types 
{
  
/// The class for complexType EnggDept
/// \n Refer to documentation on structures/methods inside ...
class EnggDept : public XMLSchema::Types::anyType
{
  public:
  //constructor
  EnggDept(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::leaderId > leaderId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::leaderId* leaderId_p;
  
  /// typedef for the node
  typedef org::hr::leaderId leaderId; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::engg::Types::EnggProject> > project_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::engg::Types::EnggProject>* project_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::engg::Types::EnggProject> project; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> > attr_id_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token>* attr_id_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> attr_id; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(EnggDept* that);

    

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    leaderId_p element_leaderId();

        

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_leaderId(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_leaderId_string();

          

    ///  For vector-element with QName "{urn:org:engg}project" :
    ///  \n Returns the list of the element nodes
    ///  @return the list of element nodes fetched
    List<project_ptr> elements_project();

    ///  For vector-element with QName "{urn:org:engg}project" :
    ///  \n Returns the element node at supplied index
    ///  @param idx index of the element to fetch 
    ///  @return the element node fetched
    project_p element_project_at(unsigned int idx);

        

    ///  For vector-element with QName "{urn:org:engg}project" :
    ///  \n Adds one element to the end of the "list of the element nodes"
    ///  @return the pointer to the added element
    project_p add_node_project();

    ///  For vector-element with QName "{urn:org:engg}project" :
    ///  \n Sizes-up the "list of the element nodes" with the supplied size
    ///  @param size the request size(unsigned int) of the list
    ///  @return the list of "pointer-to-element-node"
    List<project_ptr> set_count_project(unsigned int size);


      

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    EnggDept*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  leaderId_p element_leaderId();
      

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_leaderId(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_leaderId_string();

        

  ///  For vector-element with QName "{urn:org:engg}project" :
  ///  \n Returns the list of the element nodes
  ///  @return the list of element nodes fetched
  List<project_ptr> elements_project();

  ///  For vector-element with QName "{urn:org:engg}project" :
  ///  \n Returns the element node at supplied index
  ///  @param idx index of the element to fetch 
  ///  @return the element node fetched
  project_p element_project_at(unsigned int idx);

  

  ///  For vector-element with QName "{urn:org:engg}project" :
  ///  \n Adds one element to the end of the "list of the element nodes"
  ///  @return the pointer to the added element
  project_p add_node_project();
  
  ///  For vector-element with QName "{urn:org:engg}project" :
  ///  \n Sizes-up the "list of the element nodes" with the supplied size
  ///  @param size the request size(unsigned int) of the list
  ///  @return the list of "pointer-to-element-node"
  List<project_ptr> set_count_project(unsigned int size);

      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_id_p attribute_attr_id();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_id(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_id_string();

        

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  leaderId_ptr _leaderId;
            
  List<project_ptr> _list_project;
            
  attr_id_ptr _attr_id;
          

  /// initialize the FSM
  void initFSM();

  
  leaderId_ptr create_leaderId(FsmCbOptions& options);

  project_ptr create_project(FsmCbOptions& options);

  attr_id_ptr create_attr_id(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<EnggDept> >   s_typeRegistry;
}; //end class EnggDept
} // end namespace Types


} // end namespace engg  
} // end namespace org
#endif
  


examples/org/include/org/organization.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_organization_H__
#define  __org_organization_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/leaderId.h"
      
#include "org/Types/Departments.h"
      
#include "org_hr/Types/AllEmployees.h"
      

using namespace XPlus;

namespace org {
    

/// The class for element {}organization with following structure: 
/// \n complexType->ModelGroup-or-ModelGroupDefinition
/// Read more on structures/methods inside ...
class organization : public XMLSchema::XmlElement<XMLSchema::Types::anyType>
{
  public:

    /// constructor for the element node
    organization(ElementCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::leaderId > leaderId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::leaderId* leaderId_p;
  
  /// typedef for the node
  typedef org::hr::leaderId leaderId; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_string> > name_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string>* name_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_string> name; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::Types::Departments> > departments_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::Types::Departments>* departments_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::Types::Departments> departments; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::AllEmployees> > allEmployees_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::AllEmployees>* allEmployees_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::AllEmployees> allEmployees; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> > attr_id_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token>* attr_id_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> attr_id; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(organization* that);

    

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    leaderId_p element_leaderId();

        

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_leaderId(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_leaderId_string();

          

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    name_p element_name();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_name(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_name_string();

          

    ///  For the scalar-element with QName "{urn:org}departments" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    departments_p element_departments();

        

    ///  For the scalar-element with QName "{urn:org:hr}allEmployees" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    allEmployees_p element_allEmployees();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    organization*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  leaderId_p element_leaderId();
      

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_leaderId(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_leaderId_string();

        

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  name_p element_name();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_name(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2001/XMLSchema}name" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_name_string();

        

  ///  For the scalar-element with QName "{urn:org}departments" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  departments_p element_departments();
      

  ///  For the scalar-element with QName "{urn:org:hr}allEmployees" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  allEmployees_p element_allEmployees();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_id_p attribute_attr_id();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_id(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_id_string();

        

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  leaderId_ptr _leaderId;
            
  name_ptr _name;
            
  departments_ptr _departments;
            
  allEmployees_ptr _allEmployees;
            
  attr_id_ptr _attr_id;
          

  /// initialize the FSM
  void initFSM();

  
  leaderId_ptr create_leaderId(FsmCbOptions& options);

  name_ptr create_name(FsmCbOptions& options);

  departments_ptr create_departments(FsmCbOptions& options);

  allEmployees_ptr create_allEmployees(FsmCbOptions& options);

  attr_id_ptr create_attr_id(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END



}; //end class organization

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {}organization
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<organization > organization_ptr;
  /// typedef for the Plain pointer to the node
  typedef organization* organization_p;
  
} // end namespace org
#endif


examples/org/include/org/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_DOCUMENT_H__
#define  __org_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "org/organization.h"
    

using namespace XPlus;
using namespace FSM;


namespace org {
    

class Document : public XMLSchema::TDocument
{
  private:
  
  
  organization_ptr _organization;
    
  AutoPtr<XsdFSM<organization_ptr> > _fsm_organization;
    
  
  // attributes, elements
  
  organization_ptr create_organization(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  organization_p element_organization();
    
    
  void initFSM();
};

} // end namespace org
#endif
  


examples/org/include/org/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_ALL_INCLUDE_H__
#define  __org_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "org_engg/all-include.h"
  
#include "org_legal/all-include.h"
  
#include "org_hr/all-include.h"
  
#include "org/Document.h"

#include "org/organization.h"    
  
#include "org/Types/Departments.h"    
  

using namespace XPlus;


#endif 
  


examples/org/include/org/Types/Departments.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_types_Departments_H__
#define  __org_types_Departments_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_engg/Types/EnggDept.h"
      
#include "org_legal/Types/LegalDept.h"
      
using namespace XPlus; 



namespace org {
    
namespace Types 
{
  
/// The class for complexType Departments
/// \n Refer to documentation on structures/methods inside ...
class Departments : public XMLSchema::Types::anyType
{
  public:
  //constructor
  Departments(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::engg::Types::EnggDept> > engineering_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::engg::Types::EnggDept>* engineering_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::engg::Types::EnggDept> engineering; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::legal::Types::LegalDept> > legal_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::legal::Types::LegalDept>* legal_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::legal::Types::LegalDept> legal; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(Departments* that);

    

    ///  For the scalar-element with QName "{urn:org:engg}engineering" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    engineering_p element_engineering();

        

    ///  For the scalar-element with QName "{urn:org:legal}legal" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    legal_p element_legal();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    Departments*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:engg}engineering" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  engineering_p element_engineering();
      

  ///  For the scalar-element with QName "{urn:org:legal}legal" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  legal_p element_legal();
      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  engineering_ptr _engineering;
            
  legal_ptr _legal;
              

  /// initialize the FSM
  void initFSM();

  
  engineering_ptr create_engineering(FsmCbOptions& options);

  legal_ptr create_legal(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<Departments> >   s_typeRegistry;
}; //end class Departments
} // end namespace Types


} // end namespace org
#endif
  


examples/org/include/org_legal/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_legal_ALL_INCLUDE_H__
#define  __org_legal_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "org_hr/all-include.h"
  
#include "org_legal/Types/LegalDept.h"    
  

using namespace XPlus;


#endif 
  


examples/org/include/org_legal/Types/LegalDept.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __org_legal_types_LegalDept_H__
#define  __org_legal_types_LegalDept_H__
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "org_hr/leaderId.h"
      
#include "org_hr/Types/UserIdList.h"
      
using namespace XPlus; 



namespace org {
      
namespace legal {
    
namespace Types 
{
  
/// The class for complexType LegalDept
/// \n Refer to documentation on structures/methods inside ...
class LegalDept : public XMLSchema::Types::anyType
{
  public:
  //constructor
  LegalDept(AnyTypeCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<org::hr::leaderId > leaderId_ptr;
  /// typedef for the Plain pointer to the node
  typedef org::hr::leaderId* leaderId_p;
  
  /// typedef for the node
  typedef org::hr::leaderId leaderId; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<org::hr::Types::UserIdList> > legalAdvisors_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList>* legalAdvisors_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<org::hr::Types::UserIdList> legalAdvisors; 
  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> > attr_id_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token>* attr_id_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlAttribute<XMLSchema::Types::bt_token> attr_id; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(LegalDept* that);

    

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    leaderId_p element_leaderId();

        

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_leaderId(DOMString val);

    ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_leaderId_string();

          

    ///  For the scalar-element with QName "{urn:org:hr}legalAdvisors" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    legalAdvisors_p element_legalAdvisors();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    LegalDept*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  leaderId_p element_leaderId();
      

  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_leaderId(DOMString val);
  
  ///  For the scalar-element with QName "{urn:org:hr}leaderId" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_leaderId_string();

        

  ///  For the scalar-element with QName "{urn:org:hr}legalAdvisors" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  legalAdvisors_p element_legalAdvisors();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the scalar attribute node
  ///  @return the attribute node fetched
  attr_id_p attribute_attr_id();
      

  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Sets the value of the attribute with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_attr_id(DOMString val);
  
  ///  For the scalar-attribute with QName "{http://www.w3.org/2001/XMLSchema}id" :
  ///  \n Returns the value(as DOMString) of the attribute
  DOMString get_attr_id_string();

        

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  leaderId_ptr _leaderId;
            
  legalAdvisors_ptr _legalAdvisors;
            
  attr_id_ptr _attr_id;
          

  /// initialize the FSM
  void initFSM();

  
  leaderId_ptr create_leaderId(FsmCbOptions& options);

  legalAdvisors_ptr create_legalAdvisors(FsmCbOptions& options);

  attr_id_ptr create_attr_id(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END

  

  private:
  static XSD::TypeDefinitionFactoryTmpl<XmlElement<LegalDept> >   s_typeRegistry;
}; //end class LegalDept
} // end namespace Types


} // end namespace legal  
} // end namespace org
#endif
  


examples/org/main.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  On subsequent "xsd2cpp" invocations, this file would not be overwritten.
 //  You can edit this file.
 //
  
#include <iostream>
#include <string>

#include "XSD/UserOps.h"
#include "org/all-include.h"

void populateDocument(org::Document* xsdDoc);
void updateOrConsumeDocument(org::Document* xsdDoc);
    

int main (int argc, char**argv)
{
  XSD::UserOps<org::Document>::UserOpsCbStruct cbStruct;
  cbStruct.cbPopulateDocument           =  populateDocument;
  cbStruct.cbUpdateOrConsumeDocument    =  updateOrConsumeDocument;
  

  XSD::UserOps<org::Document> opHandle(cbStruct);
  opHandle.run(argc, argv);
}

//
// Following functions are use case templates.
// You need to put "code" in the respective contexts.
//

    

// template function to populate the Tree with values
// write code to populate the Document here ...
void populateDocument(org::Document* xsdDoc)
{
  /*
  Jim Barnette    : org head

  Engg:  
      Paul V. Biron : engg head
   
    Project1: 
        Allen Brown : proj1 head
        Charles E. Campbell
        Wayne Carr

    Project2:
        Lee Buck : proj2 head
        Peter Chen
        David Cleary

  
  Legal:
      Don Box :legal head
      Dan Connolly
      Ugo Corda

  */

  org::organization* pOrgn = xsdDoc->element_organization();
  pOrgn->set_leaderId("jimb");
  pOrgn->set_attr_id("nasa");
  pOrgn->set_name("NASA");

  // all employees
  pOrgn->element_allEmployees()->set_count_employee(11);
  org::hr::Types::Employee* pEmpl = NULL;
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(0);
  pEmpl->set_name("Jim Barnette");
  pEmpl->set_userId("jimb");
  pEmpl->set_joiningDate("1978-02-11");
  pEmpl->set_title("org head");
  pEmpl->element_reportees()->add_userId_string("paulb");
  pEmpl->element_reportees()->add_userId_string("donb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(1);
  pEmpl->set_name("Paul V. Biron");
  pEmpl->set_userId("paulb");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Engg head");
  pEmpl->element_reportees()->add_userId_string("allenb");
  pEmpl->element_reportees()->add_userId_string("leeb");
  pEmpl->set_reportsTo("jimb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(2);
  pEmpl->set_name("Don Box");
  pEmpl->set_userId("donb");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Legal head");
  pEmpl->element_reportees()->add_userId_string("danc");
  pEmpl->element_reportees()->add_userId_string("ugoc");
  pEmpl->set_reportsTo("jimb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(3);
  pEmpl->set_name("Allen Brown");
  pEmpl->set_userId("allenb");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Proj1 head");
  pEmpl->element_reportees()->add_userId_string("charlese");
  pEmpl->element_reportees()->add_userId_string("waynec");
  pEmpl->set_reportsTo("paulb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(4);
  pEmpl->set_name("Lee Buck");
  pEmpl->set_userId("leeb");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Proj2 head");
  pEmpl->element_reportees()->add_userId_string("peterc");
  pEmpl->element_reportees()->add_userId_string("davidc");
  pEmpl->set_reportsTo("paulb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(5);
  pEmpl->set_name("Charles E Campbell");
  pEmpl->set_userId("charlese");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("SMTS");
  pEmpl->set_reportsTo("allenb");

  pEmpl = pOrgn->element_allEmployees()->element_employee_at(6);
  pEmpl->set_name("Wayne Carr");
  pEmpl->set_userId("waynec");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("SMTS");
  pEmpl->set_reportsTo("allenb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(7);
  pEmpl->set_name("Peter Chen");
  pEmpl->set_userId("peterc");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("SMTS");
  pEmpl->set_reportsTo("leeb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(8);
  pEmpl->set_name("David Cleary");
  pEmpl->set_userId("davidc");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("SMTS");
  pEmpl->set_reportsTo("leeb");

  pEmpl = pOrgn->element_allEmployees()->element_employee_at(9);
  pEmpl->set_name("Dan Connolly");
  pEmpl->set_userId("danc");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Legal Advisor");
  pEmpl->set_reportsTo("donb");
  
  pEmpl = pOrgn->element_allEmployees()->element_employee_at(10);
  pEmpl->set_name("Ugo Corda");
  pEmpl->set_userId("ugoc");
  pEmpl->set_joiningDate("1978-02-15");
  pEmpl->set_title("Legal Advisor");
  pEmpl->set_reportsTo("donb");
  

  org::Types::Departments::engineering* pEnggDept = pOrgn->element_departments()->element_engineering();
  pEnggDept->set_attr_id("nasa.deperatments.engineering");
  pEnggDept->set_leaderId("paulb");
  pEnggDept->set_count_project(2);

  org::engg::Types::EnggDept::project* pProj = NULL;
  
  pProj = pEnggDept->element_project_at(0);
  pProj->set_leaderId("allenb");
  pProj->element_engineers()->add_userId_string("charlese");
  pProj->element_engineers()->add_userId_string("waynec");
  pProj->set_projectName("The unmanned moon mission 2015");

  pProj = pEnggDept->element_project_at(1);
  pProj->set_leaderId("leeb");
  pProj->element_engineers()->add_userId_string("peterc");
  pProj->element_engineers()->add_userId_string("davidc");
  pProj->set_projectName("The manned moon mission 2020");

  org::Types::Departments::legal* pLegalDept = pOrgn->element_departments()->element_legal();
  pLegalDept->set_attr_id("nasa.deperatments.legal");
  pLegalDept->set_leaderId("donb");
  pLegalDept->element_legalAdvisors()->add_userId_string("danc");
  pLegalDept->element_legalAdvisors()->add_userId_string("ugoc");
}

// write code to operate(update/consume/test etc.) on the Document here...
// This Document is typically already populated(eg. read from an input
// xml file)
void updateOrConsumeDocument(org::Document* xsdDoc)
{

}

  


examples/org/src/org_hr/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_hr/Document.h"


namespace org {
      
namespace hr {
    

  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(false);
    DOM::Document::elementDefaultQualified(false);
    
  }

  void Document::initFSM()
  {
  
    _fsm_userId = new XsdFSM<userId_ptr>( Particle(new DOMString("urn:org:hr"),  DOMString("userId"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<userId_ptr, Document, FsmCbOptions>(this, &Document::create_userId));
  
    _fsm_leaderId = new XsdFSM<leaderId_ptr>( Particle(new DOMString("urn:org:hr"),  DOMString("leaderId"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<leaderId_ptr, Document, FsmCbOptions>(this, &Document::create_leaderId));
  
    XsdFsmBasePtr elemFsms[] = {
    _fsm_userId,
    _fsm_leaderId,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  
    void Document::set_root_userId() 
    {
    
      if(!_userId) {
        XsdEvent event(new DOMString("urn:org:hr"), NULL, DOMString("userId"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    
    void Document::set_root_leaderId() 
    {
    
      if(!_leaderId) {
        XsdEvent event(new DOMString("urn:org:hr"), NULL, DOMString("leaderId"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    


  /* element functions  */
  

  userId_ptr Document::create_userId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("userId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "urn:org:hr", "UserId");
    userId_p node = XSD::createElementTmpl<userId, org::hr::Types::UserId*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _userId = node;
      
    return node;
  }

  
  userId_p Document::element_userId()
  {
    FSM::warnNullNode(_userId, "userId", "{urn:org:hr}userId", 1);
    return _userId;
  }
    

  leaderId_ptr Document::create_leaderId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("leaderId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "urn:org:hr", "UserId");
    leaderId_p node = XSD::createElementTmpl<leaderId, org::hr::Types::UserId*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _leaderId = node;
      
    return node;
  }

  
  leaderId_p Document::element_leaderId()
  {
    FSM::warnNullNode(_leaderId, "leaderId", "{urn:org:hr}leaderId", 1);
    return _leaderId;
  }
    
} // end namespace hr  
} // end namespace org


examples/org/src/org_hr/Types/AllEmployees.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_hr/Types/AllEmployees.h"

namespace org {
      
namespace hr {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<AllEmployees> > AllEmployees::s_typeRegistry("AllEmployees", "urn:org:hr");

  

  //constructor
  
  AllEmployees::AllEmployees(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void AllEmployees::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  AllEmployees::employee_ptr AllEmployees::create_employee(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("employee");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "Employee");
    AllEmployees::employee_p node = XSD::createElementTmpl<employee, org::hr::Types::Employee*>(t);
          
    _list_employee.push_back(node);
      
    return node;
  }

  
  AllEmployees::employee_p AllEmployees::element_employee_at(unsigned int idx)
  {
    if(idx > _list_employee.size()-1) {
      throw IndexOutOfBoundsException("IndexOutOfBoundsException");
    }

    return _list_employee.at(idx);
  }
    
  List<AllEmployees::employee_ptr> AllEmployees::elements_employee()
  {
    return _list_employee;
  }
    
  AllEmployees::employee_p AllEmployees::add_node_employee()
  {
    return get_sequence()->add_node_employee();
  }

  List<AllEmployees::employee_ptr> AllEmployees::set_count_employee(unsigned int size)
  {
    return get_sequence()->set_count_employee(size);
  }

          

  /* attribute  functions  */
  
  //constructor
  AllEmployees::sequence::sequence(AllEmployees* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<employee_ptr>( Particle(NULL, DOMString("employee"), 1, -1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<employee_ptr, AllEmployees, FsmCbOptions>(_that, &AllEmployees::create_employee)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  List<AllEmployees::employee_ptr> AllEmployees::sequence::elements_employee()
  {
      
    List<employee_ptr> nodeList;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<employee_ptr> *unitFsm = dynamic_cast<XsdFSM<employee_ptr> *>(fsm_p);
      if(unitFsm) {
        //nodeList = unitFsm->nodeList().stl_list(); 
        nodeList = unitFsm->nodeList(); 
      }
    }
    return nodeList;
        
  }
  
  
  AllEmployees::employee_p AllEmployees::sequence::element_employee_at(unsigned int idx)
  {
    return elements_employee().at(idx);
  }

    
  AllEmployees::employee_p AllEmployees::sequence::add_node_employee()
  {
    DOMStringPtr nsUriPtr = NULL;
    XsdEvent event(nsUriPtr, NULL, DOMString("employee"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
    return elements_employee().back();
  }

  List<AllEmployees::employee_ptr> AllEmployees::sequence::set_count_employee(unsigned int size)
  {
    if( (size > -1) || (size < 1)) {
      ostringstream oss;
      oss << "set_count_employee: size should be in range: [" << 1
        << "," << "unbounded" << "]";
      throw IndexOutOfBoundsException(oss.str());
    }

    unsigned int prevSize = elements_employee().size();
    if(size < prevSize) {
      //FIXME: allow later:
      throw XPlus::RuntimeException("resize lesser than current size not allowed");
    }

    for(unsigned int j=prevSize; j<size; j++) 
    {
      // pretend docBuilding to avoid computation of adding after first loop
      XsdEvent event(NULL, NULL, DOMString("employee"), XsdEvent::ELEMENT_START, false);
      this->processEventThrow(event); 
    }
    
    return elements_employee();
  }

        
} //  end namespace Types 


} // end namespace hr  
} // end namespace org


examples/org/src/org_hr/Types/UserIdList.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_hr/Types/UserIdList.h"

namespace org {
      
namespace hr {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<UserIdList> > UserIdList::s_typeRegistry("UserIdList", "urn:org:hr");

  

  //constructor
  
  UserIdList::UserIdList(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void UserIdList::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  userId_ptr UserIdList::create_userId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("userId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    userId_p node = XSD::createElementTmpl<userId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _list_userId.push_back(node);
      
    return node;
  }

  
  userId_p UserIdList::element_userId_at(unsigned int idx)
  {
    if(idx > _list_userId.size()-1) {
      throw IndexOutOfBoundsException("IndexOutOfBoundsException");
    }

    return _list_userId.at(idx);
  }
    
  List<userId_ptr> UserIdList::elements_userId()
  {
    return _list_userId;
  }
    
  userId_p UserIdList::add_node_userId()
  {
    return get_sequence()->add_node_userId();
  }

  List<userId_ptr> UserIdList::set_count_userId(unsigned int size)
  {
    return get_sequence()->set_count_userId(size);
  }

        
      
    void UserIdList::add_userId_string(DOMString val)
    {
      get_sequence()->add_userId_string(val);
    }

          
  void UserIdList::set_userId(unsigned int idx, DOMString val)
  {
    get_sequence()->set_userId(idx, val);
  }

  DOMString UserIdList::get_userId_string(unsigned int idx)
  {
    return get_sequence()->get_userId_string(idx);
  }

            

  /* attribute  functions  */
  
  //constructor
  UserIdList::sequence::sequence(UserIdList* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<userId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("userId"), 0, -1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<userId_ptr, UserIdList, FsmCbOptions>(_that, &UserIdList::create_userId)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  List<userId_ptr> UserIdList::sequence::elements_userId()
  {
      
    List<userId_ptr> nodeList;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<userId_ptr> *unitFsm = dynamic_cast<XsdFSM<userId_ptr> *>(fsm_p);
      if(unitFsm) {
        //nodeList = unitFsm->nodeList().stl_list(); 
        nodeList = unitFsm->nodeList(); 
      }
    }
    return nodeList;
        
  }
  
  
  userId_p UserIdList::sequence::element_userId_at(unsigned int idx)
  {
    return elements_userId().at(idx);
  }

    
  void UserIdList::sequence::set_userId(unsigned int idx, DOMString val)
  {
    element_userId_at(idx)->stringValue(val);
  }

  DOMString UserIdList::sequence::get_userId_string(unsigned int idx)
  {
    return element_userId_at(idx)->stringValue();
  }
      
  userId_p UserIdList::sequence::add_node_userId()
  {
    DOMStringPtr nsUriPtr = new DOMString("urn:org:hr");
    XsdEvent event(nsUriPtr, NULL, DOMString("userId"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
    return elements_userId().back();
  }

  List<userId_ptr> UserIdList::sequence::set_count_userId(unsigned int size)
  {
    if( (size > -1) || (size < 0)) {
      ostringstream oss;
      oss << "set_count_userId: size should be in range: [" << 0
        << "," << "unbounded" << "]";
      throw IndexOutOfBoundsException(oss.str());
    }

    unsigned int prevSize = elements_userId().size();
    if(size < prevSize) {
      //FIXME: allow later:
      throw XPlus::RuntimeException("resize lesser than current size not allowed");
    }

    for(unsigned int j=prevSize; j<size; j++) 
    {
      // pretend docBuilding to avoid computation of adding after first loop
      XsdEvent event(new DOMString("urn:org:hr"), NULL, DOMString("userId"), XsdEvent::ELEMENT_START, false);
      this->processEventThrow(event); 
    }
    
    return elements_userId();
  }

        
    
  void UserIdList::sequence::add_userId_string(DOMString val)
  {
    this->add_node_userId()->stringValue(val);
  }
          
} //  end namespace Types 


} // end namespace hr  
} // end namespace org


examples/org/src/org_hr/Types/Employee.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_hr/Types/Employee.h"

namespace org {
      
namespace hr {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<Employee> > Employee::s_typeRegistry("Employee", "urn:org:hr");

  

  //constructor
  
  Employee::Employee(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void Employee::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  userId_ptr Employee::create_userId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("userId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    userId_p node = XSD::createElementTmpl<userId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _userId = node;
      
    return node;
  }

  
  userId_p Employee::element_userId()
  {
    FSM::warnNullNode(_userId, "userId", "{urn:org:hr}userId", 1);
    return _userId;
  }
    
  void Employee::set_userId(DOMString val)
  {
    get_sequence()->set_userId(val);
  }

  DOMString Employee::get_userId_string()
  {
    return get_sequence()->get_userId_string();
  }

          

  Employee::name_ptr Employee::create_name(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("name");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    Employee::name_p node = XSD::createElementTmpl<name, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _name = node;
      
    return node;
  }

  
  Employee::name_p Employee::element_name()
  {
    FSM::warnNullNode(_name, "name", "{http://www.w3.org/2001/XMLSchema}name", 1);
    return _name;
  }
    
  void Employee::set_name(DOMString val)
  {
    get_sequence()->set_name(val);
  }

  DOMString Employee::get_name_string()
  {
    return get_sequence()->get_name_string();
  }

          

  Employee::title_ptr Employee::create_title(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("title");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    Employee::title_p node = XSD::createElementTmpl<title, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _title = node;
      
    return node;
  }

  
  Employee::title_p Employee::element_title()
  {
    FSM::warnNullNode(_title, "title", "{http://www.w3.org/2001/XMLSchema}title", 1);
    return _title;
  }
    
  void Employee::set_title(DOMString val)
  {
    get_sequence()->set_title(val);
  }

  DOMString Employee::get_title_string()
  {
    return get_sequence()->get_title_string();
  }

          

  Employee::joiningDate_ptr Employee::create_joiningDate(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("joiningDate");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "date");
    Employee::joiningDate_p node = XSD::createElementTmpl<joiningDate, XMLSchema::Types::bt_date*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _joiningDate = node;
      
    return node;
  }

  
  Employee::joiningDate_p Employee::element_joiningDate()
  {
    FSM::warnNullNode(_joiningDate, "joiningDate", "{http://www.w3.org/2001/XMLSchema}joiningDate", 1);
    return _joiningDate;
  }
    
  void Employee::set_joiningDate(DOMString val)
  {
    get_sequence()->set_joiningDate(val);
  }

  DOMString Employee::get_joiningDate_string()
  {
    return get_sequence()->get_joiningDate_string();
  }

          
  void Employee::set_joiningDate(XPlus::Date val)
  {
    get_sequence()->set_joiningDate(val);
  }
  
  XPlus::Date Employee::get_joiningDate()
  {
    return get_sequence()->get_joiningDate();
  }

          

  Employee::reportsTo_ptr Employee::create_reportsTo(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("reportsTo");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "UserId");
    Employee::reportsTo_p node = XSD::createElementTmpl<reportsTo, org::hr::Types::UserId*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _reportsTo = node;
      
    return node;
  }

  
  Employee::reportsTo_p Employee::element_reportsTo()
  {
    FSM::warnNullNode(_reportsTo, "reportsTo", "{urn:org:hr}reportsTo", 0);
    return _reportsTo;
  }
    
  void Employee::set_reportsTo(DOMString val)
  {
    get_sequence()->set_reportsTo(val);
  }

  DOMString Employee::get_reportsTo_string()
  {
    return get_sequence()->get_reportsTo_string();
  }

          
  void Employee::mark_present_reportsTo()
  {
    return get_sequence()->mark_present_reportsTo();
  }
      

  Employee::reportees_ptr Employee::create_reportees(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("reportees");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "UserIdList");
    Employee::reportees_p node = XSD::createElementTmpl<reportees, org::hr::Types::UserIdList*>(t);
          
    _reportees = node;
      
    return node;
  }

  
  Employee::reportees_p Employee::element_reportees()
  {
    FSM::warnNullNode(_reportees, "reportees", "{urn:org:hr}reportees", 1);
    return _reportees;
  }
      

  /* attribute  functions  */
  
  //constructor
  Employee::sequence::sequence(Employee* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<userId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("userId"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<userId_ptr, Employee, FsmCbOptions>(_that, &Employee::create_userId)),
      new XsdFSM<name_ptr>( Particle(NULL, DOMString("name"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<name_ptr, Employee, FsmCbOptions>(_that, &Employee::create_name)),
      new XsdFSM<title_ptr>( Particle(NULL, DOMString("title"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<title_ptr, Employee, FsmCbOptions>(_that, &Employee::create_title)),
      new XsdFSM<joiningDate_ptr>( Particle(NULL, DOMString("joiningDate"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<joiningDate_ptr, Employee, FsmCbOptions>(_that, &Employee::create_joiningDate)),
      new XsdFSM<reportsTo_ptr>( Particle(NULL, DOMString("reportsTo"), 0, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<reportsTo_ptr, Employee, FsmCbOptions>(_that, &Employee::create_reportsTo)),
      new XsdFSM<reportees_ptr>( Particle(NULL, DOMString("reportees"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<reportees_ptr, Employee, FsmCbOptions>(_that, &Employee::create_reportees)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  userId_p Employee::sequence::element_userId()
  {
      userId_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<userId_ptr> *unitFsm = dynamic_cast<XsdFSM<userId_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "userId", "{urn:org:hr}userId", 1);
    return node_p;
        
  }
  
  
  void Employee::sequence::set_userId(DOMString val)
  {
      
    element_userId()->stringValue(val);
  }

  DOMString Employee::sequence::get_userId_string()
  {
    return element_userId()->stringValue();
  }

          

  Employee::name_p Employee::sequence::element_name()
  {
      Employee::name_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<name_ptr> *unitFsm = dynamic_cast<XsdFSM<name_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "name", "{http://www.w3.org/2001/XMLSchema}name", 1);
    return node_p;
        
  }
  
  
  void Employee::sequence::set_name(DOMString val)
  {
      
    element_name()->stringValue(val);
  }

  DOMString Employee::sequence::get_name_string()
  {
    return element_name()->stringValue();
  }

          

  Employee::title_p Employee::sequence::element_title()
  {
      Employee::title_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[2].get();
    if(fsm_p) 
    {
      XsdFSM<title_ptr> *unitFsm = dynamic_cast<XsdFSM<title_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "title", "{http://www.w3.org/2001/XMLSchema}title", 1);
    return node_p;
        
  }
  
  
  void Employee::sequence::set_title(DOMString val)
  {
      
    element_title()->stringValue(val);
  }

  DOMString Employee::sequence::get_title_string()
  {
    return element_title()->stringValue();
  }

          

  Employee::joiningDate_p Employee::sequence::element_joiningDate()
  {
      Employee::joiningDate_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[3].get();
    if(fsm_p) 
    {
      XsdFSM<joiningDate_ptr> *unitFsm = dynamic_cast<XsdFSM<joiningDate_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "joiningDate", "{http://www.w3.org/2001/XMLSchema}joiningDate", 1);
    return node_p;
        
  }
  
  
  void Employee::sequence::set_joiningDate(DOMString val)
  {
      
    element_joiningDate()->stringValue(val);
  }

  DOMString Employee::sequence::get_joiningDate_string()
  {
    return element_joiningDate()->stringValue();
  }

      
  void Employee::sequence::set_joiningDate(XPlus::Date val)     
  {
        
    element_joiningDate()->value(val);
  }

  XPlus::Date Employee::sequence::get_joiningDate()     
  {
    return element_joiningDate()->value();
  }

          

  Employee::reportsTo_p Employee::sequence::element_reportsTo()
  {
      Employee::reportsTo_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[4].get();
    if(fsm_p) 
    {
      XsdFSM<reportsTo_ptr> *unitFsm = dynamic_cast<XsdFSM<reportsTo_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "reportsTo", "{urn:org:hr}reportsTo", 0);
    return node_p;
        
  }
  
  
  void Employee::sequence::set_reportsTo(DOMString val)
  {
      
    mark_present_reportsTo();
      
    element_reportsTo()->stringValue(val);
  }

  DOMString Employee::sequence::get_reportsTo_string()
  {
    return element_reportsTo()->stringValue();
  }

      

  void Employee::sequence::mark_present_reportsTo()
  {
    DOMStringPtr nsUriPtr = NULL;
    XsdEvent event(nsUriPtr, NULL, DOMString("reportsTo"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
  }

            

  Employee::reportees_p Employee::sequence::element_reportees()
  {
      Employee::reportees_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[5].get();
    if(fsm_p) 
    {
      XsdFSM<reportees_ptr> *unitFsm = dynamic_cast<XsdFSM<reportees_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "reportees", "{urn:org:hr}reportees", 1);
    return node_p;
        
  }
  
  
} //  end namespace Types 


} // end namespace hr  
} // end namespace org


examples/org/src/org_engg/Types/EnggDept.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_engg/Types/EnggDept.h"

namespace org {
      
namespace engg {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<EnggDept> > EnggDept::s_typeRegistry("EnggDept", "urn:org:engg");

  

  //constructor
  
  EnggDept::EnggDept(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void EnggDept::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  new XsdFSM<attr_id_ptr>( Particle(NULL, DOMString("id"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_id_ptr, EnggDept, FsmCbOptions>(this, &EnggDept::create_attr_id)),
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  org::hr::leaderId_ptr EnggDept::create_leaderId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("leaderId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    org::hr::leaderId_p node = XSD::createElementTmpl<leaderId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _leaderId = node;
      
    return node;
  }

  
  org::hr::leaderId_p EnggDept::element_leaderId()
  {
    FSM::warnNullNode(_leaderId, "leaderId", "{urn:org:hr}leaderId", 1);
    return _leaderId;
  }
    
  void EnggDept::set_leaderId(DOMString val)
  {
    get_sequence()->set_leaderId(val);
  }

  DOMString EnggDept::get_leaderId_string()
  {
    return get_sequence()->get_leaderId_string();
  }

          

  EnggDept::project_ptr EnggDept::create_project(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("project");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:engg", "EnggProject");
    EnggDept::project_p node = XSD::createElementTmpl<project, org::engg::Types::EnggProject*>(t);
          
    _list_project.push_back(node);
      
    return node;
  }

  
  EnggDept::project_p EnggDept::element_project_at(unsigned int idx)
  {
    if(idx > _list_project.size()-1) {
      throw IndexOutOfBoundsException("IndexOutOfBoundsException");
    }

    return _list_project.at(idx);
  }
    
  List<EnggDept::project_ptr> EnggDept::elements_project()
  {
    return _list_project;
  }
    
  EnggDept::project_p EnggDept::add_node_project()
  {
    return get_sequence()->add_node_project();
  }

  List<EnggDept::project_ptr> EnggDept::set_count_project(unsigned int size)
  {
    return get_sequence()->set_count_project(size);
  }

          

  /* attribute  functions  */
  

  EnggDept::attr_id_ptr EnggDept::create_attr_id(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("id");
    static DOMStringPtr myNsUri = NULL;
    
    if(_attr_id) {
      return _attr_id;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    EnggDept::attr_id_p node = XSD::createAttributeTmpl<attr_id>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_id = node;
      
    return node;
  }

  
    void EnggDept::set_attr_id(DOMString val)
    {
        
      attribute_attr_id()->stringValue(val);
    }

    DOMString EnggDept::get_attr_id_string()
    {
       
      return attribute_attr_id()->stringValue();
    }

    
  EnggDept::attr_id_p EnggDept::attribute_attr_id()
  {
    FSM::warnNullNode(_attr_id, "attr_id", "{http://www.w3.org/2001/XMLSchema}id", 1);
    return _attr_id;
  }
    
  //constructor
  EnggDept::sequence::sequence(EnggDept* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<leaderId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("leaderId"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<leaderId_ptr, EnggDept, FsmCbOptions>(_that, &EnggDept::create_leaderId)),
      new XsdFSM<project_ptr>( Particle(NULL, DOMString("project"), 1, -1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<project_ptr, EnggDept, FsmCbOptions>(_that, &EnggDept::create_project)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  org::hr::leaderId_p EnggDept::sequence::element_leaderId()
  {
      org::hr::leaderId_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<leaderId_ptr> *unitFsm = dynamic_cast<XsdFSM<leaderId_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "leaderId", "{urn:org:hr}leaderId", 1);
    return node_p;
        
  }
  
  
  void EnggDept::sequence::set_leaderId(DOMString val)
  {
      
    element_leaderId()->stringValue(val);
  }

  DOMString EnggDept::sequence::get_leaderId_string()
  {
    return element_leaderId()->stringValue();
  }

          

  List<EnggDept::project_ptr> EnggDept::sequence::elements_project()
  {
      
    List<project_ptr> nodeList;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<project_ptr> *unitFsm = dynamic_cast<XsdFSM<project_ptr> *>(fsm_p);
      if(unitFsm) {
        //nodeList = unitFsm->nodeList().stl_list(); 
        nodeList = unitFsm->nodeList(); 
      }
    }
    return nodeList;
        
  }
  
  
  EnggDept::project_p EnggDept::sequence::element_project_at(unsigned int idx)
  {
    return elements_project().at(idx);
  }

    
  EnggDept::project_p EnggDept::sequence::add_node_project()
  {
    DOMStringPtr nsUriPtr = NULL;
    XsdEvent event(nsUriPtr, NULL, DOMString("project"), XsdEvent::ELEMENT_START, false);
    this->processEventThrow(event); 
    return elements_project().back();
  }

  List<EnggDept::project_ptr> EnggDept::sequence::set_count_project(unsigned int size)
  {
    if( (size > -1) || (size < 1)) {
      ostringstream oss;
      oss << "set_count_project: size should be in range: [" << 1
        << "," << "unbounded" << "]";
      throw IndexOutOfBoundsException(oss.str());
    }

    unsigned int prevSize = elements_project().size();
    if(size < prevSize) {
      //FIXME: allow later:
      throw XPlus::RuntimeException("resize lesser than current size not allowed");
    }

    for(unsigned int j=prevSize; j<size; j++) 
    {
      // pretend docBuilding to avoid computation of adding after first loop
      XsdEvent event(NULL, NULL, DOMString("project"), XsdEvent::ELEMENT_START, false);
      this->processEventThrow(event); 
    }
    
    return elements_project();
  }

        
} //  end namespace Types 


} // end namespace engg  
} // end namespace org


examples/org/src/org_engg/Types/EnggProject.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_engg/Types/EnggProject.h"

namespace org {
      
namespace engg {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<EnggProject> > EnggProject::s_typeRegistry("EnggProject", "urn:org:engg");

  

  //constructor
  
  EnggProject::EnggProject(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void EnggProject::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  org::hr::leaderId_ptr EnggProject::create_leaderId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("leaderId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    org::hr::leaderId_p node = XSD::createElementTmpl<leaderId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _leaderId = node;
      
    return node;
  }

  
  org::hr::leaderId_p EnggProject::element_leaderId()
  {
    FSM::warnNullNode(_leaderId, "leaderId", "{urn:org:hr}leaderId", 1);
    return _leaderId;
  }
    
  void EnggProject::set_leaderId(DOMString val)
  {
    get_sequence()->set_leaderId(val);
  }

  DOMString EnggProject::get_leaderId_string()
  {
    return get_sequence()->get_leaderId_string();
  }

          

  EnggProject::projectName_ptr EnggProject::create_projectName(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("projectName");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    EnggProject::projectName_p node = XSD::createElementTmpl<projectName, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _projectName = node;
      
    return node;
  }

  
  EnggProject::projectName_p EnggProject::element_projectName()
  {
    FSM::warnNullNode(_projectName, "projectName", "{http://www.w3.org/2001/XMLSchema}projectName", 1);
    return _projectName;
  }
    
  void EnggProject::set_projectName(DOMString val)
  {
    get_sequence()->set_projectName(val);
  }

  DOMString EnggProject::get_projectName_string()
  {
    return get_sequence()->get_projectName_string();
  }

          

  EnggProject::engineers_ptr EnggProject::create_engineers(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("engineers");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "UserIdList");
    EnggProject::engineers_p node = XSD::createElementTmpl<engineers, org::hr::Types::UserIdList*>(t);
          
    _engineers = node;
      
    return node;
  }

  
  EnggProject::engineers_p EnggProject::element_engineers()
  {
    FSM::warnNullNode(_engineers, "engineers", "{urn:org:hr}engineers", 1);
    return _engineers;
  }
      

  /* attribute  functions  */
  
  //constructor
  EnggProject::sequence::sequence(EnggProject* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<leaderId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("leaderId"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<leaderId_ptr, EnggProject, FsmCbOptions>(_that, &EnggProject::create_leaderId)),
      new XsdFSM<projectName_ptr>( Particle(NULL, DOMString("projectName"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<projectName_ptr, EnggProject, FsmCbOptions>(_that, &EnggProject::create_projectName)),
      new XsdFSM<engineers_ptr>( Particle(NULL, DOMString("engineers"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<engineers_ptr, EnggProject, FsmCbOptions>(_that, &EnggProject::create_engineers)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  org::hr::leaderId_p EnggProject::sequence::element_leaderId()
  {
      org::hr::leaderId_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<leaderId_ptr> *unitFsm = dynamic_cast<XsdFSM<leaderId_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "leaderId", "{urn:org:hr}leaderId", 1);
    return node_p;
        
  }
  
  
  void EnggProject::sequence::set_leaderId(DOMString val)
  {
      
    element_leaderId()->stringValue(val);
  }

  DOMString EnggProject::sequence::get_leaderId_string()
  {
    return element_leaderId()->stringValue();
  }

          

  EnggProject::projectName_p EnggProject::sequence::element_projectName()
  {
      EnggProject::projectName_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<projectName_ptr> *unitFsm = dynamic_cast<XsdFSM<projectName_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "projectName", "{http://www.w3.org/2001/XMLSchema}projectName", 1);
    return node_p;
        
  }
  
  
  void EnggProject::sequence::set_projectName(DOMString val)
  {
      
    element_projectName()->stringValue(val);
  }

  DOMString EnggProject::sequence::get_projectName_string()
  {
    return element_projectName()->stringValue();
  }

          

  EnggProject::engineers_p EnggProject::sequence::element_engineers()
  {
      EnggProject::engineers_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[2].get();
    if(fsm_p) 
    {
      XsdFSM<engineers_ptr> *unitFsm = dynamic_cast<XsdFSM<engineers_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "engineers", "{urn:org:hr}engineers", 1);
    return node_p;
        
  }
  
  
} //  end namespace Types 


} // end namespace engg  
} // end namespace org


examples/org/src/org/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org/Document.h"


namespace org {
    

  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(false);
    DOM::Document::elementDefaultQualified(false);
    
    if(buildTree()) 
    {
      
      DOMStringPtr nsUriPtr = new DOMString("urn:org");   
      XsdEvent event(nsUriPtr, NULL, DOMString("organization"), XsdEvent::ELEMENT_START);
      if(this->createSample()) {
        event.cbOptions.isSampleCreate = true;
      }
      _fsm->processEventThrow(event); 
      
    }
    
  }

  void Document::initFSM()
  {
  
    _fsm_organization = new XsdFSM<organization_ptr>( Particle(new DOMString("urn:org"),  DOMString("organization"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<organization_ptr, Document, FsmCbOptions>(this, &Document::create_organization));
  
    XsdFsmBasePtr elemFsms[] = {
    _fsm_organization,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  


  /* element functions  */
  

  organization_ptr Document::create_organization(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("organization");
    static DOMStringPtr myNsUri = new DOMString("urn:org");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false);
    organization_p node = XSD::createElementTmpl<organization, void*>(t);
          
    _organization = node;
      
    return node;
  }

  
  organization_p Document::element_organization()
  {
    FSM::warnNullNode(_organization, "organization", "{}organization", 1);
    return _organization;
  }
    
} // end namespace org


examples/org/src/org/organization.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org/organization.h"

namespace org {
    

  //constructor
  
  organization::organization(ElementCreateArgs args):
      XMLSchema::XmlElement<anyType>(args),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree())
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void organization::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  new XsdFSM<attr_id_ptr>( Particle(NULL, DOMString("id"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_id_ptr, organization, FsmCbOptions>(this, &organization::create_attr_id)),
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  org::hr::leaderId_ptr organization::create_leaderId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("leaderId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    org::hr::leaderId_p node = XSD::createElementTmpl<leaderId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _leaderId = node;
      
    return node;
  }

  
  org::hr::leaderId_p organization::element_leaderId()
  {
    FSM::warnNullNode(_leaderId, "leaderId", "{urn:org:hr}leaderId", 1);
    return _leaderId;
  }
    
  void organization::set_leaderId(DOMString val)
  {
    get_sequence()->set_leaderId(val);
  }

  DOMString organization::get_leaderId_string()
  {
    return get_sequence()->get_leaderId_string();
  }

          

  organization::name_ptr organization::create_name(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("name");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "string");
    organization::name_p node = XSD::createElementTmpl<name, XMLSchema::Types::bt_string*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _name = node;
      
    return node;
  }

  
  organization::name_p organization::element_name()
  {
    FSM::warnNullNode(_name, "name", "{http://www.w3.org/2001/XMLSchema}name", 1);
    return _name;
  }
    
  void organization::set_name(DOMString val)
  {
    get_sequence()->set_name(val);
  }

  DOMString organization::get_name_string()
  {
    return get_sequence()->get_name_string();
  }

          

  organization::departments_ptr organization::create_departments(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("departments");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org", "Departments");
    organization::departments_p node = XSD::createElementTmpl<departments, org::Types::Departments*>(t);
          
    _departments = node;
      
    return node;
  }

  
  organization::departments_p organization::element_departments()
  {
    FSM::warnNullNode(_departments, "departments", "{urn:org}departments", 1);
    return _departments;
  }
    

  organization::allEmployees_ptr organization::create_allEmployees(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("allEmployees");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "AllEmployees");
    organization::allEmployees_p node = XSD::createElementTmpl<allEmployees, org::hr::Types::AllEmployees*>(t);
          
    _allEmployees = node;
      
    return node;
  }

  
  organization::allEmployees_p organization::element_allEmployees()
  {
    FSM::warnNullNode(_allEmployees, "allEmployees", "{urn:org:hr}allEmployees", 1);
    return _allEmployees;
  }
      

  /* attribute  functions  */
  

  organization::attr_id_ptr organization::create_attr_id(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("id");
    static DOMStringPtr myNsUri = NULL;
    
    if(_attr_id) {
      return _attr_id;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    organization::attr_id_p node = XSD::createAttributeTmpl<attr_id>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_id = node;
      
    return node;
  }

  
    void organization::set_attr_id(DOMString val)
    {
        
      attribute_attr_id()->stringValue(val);
    }

    DOMString organization::get_attr_id_string()
    {
       
      return attribute_attr_id()->stringValue();
    }

    
  organization::attr_id_p organization::attribute_attr_id()
  {
    FSM::warnNullNode(_attr_id, "attr_id", "{http://www.w3.org/2001/XMLSchema}id", 1);
    return _attr_id;
  }
    
  //constructor
  organization::sequence::sequence(organization* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<leaderId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("leaderId"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<leaderId_ptr, organization, FsmCbOptions>(_that, &organization::create_leaderId)),
      new XsdFSM<name_ptr>( Particle(NULL, DOMString("name"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<name_ptr, organization, FsmCbOptions>(_that, &organization::create_name)),
      new XsdFSM<departments_ptr>( Particle(NULL, DOMString("departments"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<departments_ptr, organization, FsmCbOptions>(_that, &organization::create_departments)),
      new XsdFSM<allEmployees_ptr>( Particle(NULL, DOMString("allEmployees"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<allEmployees_ptr, organization, FsmCbOptions>(_that, &organization::create_allEmployees)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  org::hr::leaderId_p organization::sequence::element_leaderId()
  {
      org::hr::leaderId_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<leaderId_ptr> *unitFsm = dynamic_cast<XsdFSM<leaderId_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "leaderId", "{urn:org:hr}leaderId", 1);
    return node_p;
        
  }
  
  
  void organization::sequence::set_leaderId(DOMString val)
  {
      
    element_leaderId()->stringValue(val);
  }

  DOMString organization::sequence::get_leaderId_string()
  {
    return element_leaderId()->stringValue();
  }

          

  organization::name_p organization::sequence::element_name()
  {
      organization::name_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<name_ptr> *unitFsm = dynamic_cast<XsdFSM<name_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "name", "{http://www.w3.org/2001/XMLSchema}name", 1);
    return node_p;
        
  }
  
  
  void organization::sequence::set_name(DOMString val)
  {
      
    element_name()->stringValue(val);
  }

  DOMString organization::sequence::get_name_string()
  {
    return element_name()->stringValue();
  }

          

  organization::departments_p organization::sequence::element_departments()
  {
      organization::departments_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[2].get();
    if(fsm_p) 
    {
      XsdFSM<departments_ptr> *unitFsm = dynamic_cast<XsdFSM<departments_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "departments", "{urn:org}departments", 1);
    return node_p;
        
  }
  
      

  organization::allEmployees_p organization::sequence::element_allEmployees()
  {
      organization::allEmployees_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[3].get();
    if(fsm_p) 
    {
      XsdFSM<allEmployees_ptr> *unitFsm = dynamic_cast<XsdFSM<allEmployees_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "allEmployees", "{urn:org:hr}allEmployees", 1);
    return node_p;
        
  }
  
  
} // end namespace org


examples/org/src/org/Types/Departments.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org/Types/Departments.h"

namespace org {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<Departments> > Departments::s_typeRegistry("Departments", "urn:org");

  

  //constructor
  
  Departments::Departments(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void Departments::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  Departments::engineering_ptr Departments::create_engineering(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("engineering");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:engg", "EnggDept");
    Departments::engineering_p node = XSD::createElementTmpl<engineering, org::engg::Types::EnggDept*>(t);
          
    _engineering = node;
      
    return node;
  }

  
  Departments::engineering_p Departments::element_engineering()
  {
    FSM::warnNullNode(_engineering, "engineering", "{urn:org:engg}engineering", 1);
    return _engineering;
  }
    

  Departments::legal_ptr Departments::create_legal(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("legal");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:legal", "LegalDept");
    Departments::legal_p node = XSD::createElementTmpl<legal, org::legal::Types::LegalDept*>(t);
          
    _legal = node;
      
    return node;
  }

  
  Departments::legal_p Departments::element_legal()
  {
    FSM::warnNullNode(_legal, "legal", "{urn:org:legal}legal", 1);
    return _legal;
  }
      

  /* attribute  functions  */
  
  //constructor
  Departments::sequence::sequence(Departments* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<engineering_ptr>( Particle(NULL, DOMString("engineering"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<engineering_ptr, Departments, FsmCbOptions>(_that, &Departments::create_engineering)),
      new XsdFSM<legal_ptr>( Particle(NULL, DOMString("legal"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<legal_ptr, Departments, FsmCbOptions>(_that, &Departments::create_legal)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  Departments::engineering_p Departments::sequence::element_engineering()
  {
      Departments::engineering_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<engineering_ptr> *unitFsm = dynamic_cast<XsdFSM<engineering_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "engineering", "{urn:org:engg}engineering", 1);
    return node_p;
        
  }
  
      

  Departments::legal_p Departments::sequence::element_legal()
  {
      Departments::legal_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<legal_ptr> *unitFsm = dynamic_cast<XsdFSM<legal_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "legal", "{urn:org:legal}legal", 1);
    return node_p;
        
  }
  
  
} //  end namespace Types 


} // end namespace org


examples/org/src/org_legal/Types/LegalDept.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "org_legal/Types/LegalDept.h"

namespace org {
      
namespace legal {
    
namespace Types
{
  XSD::TypeDefinitionFactoryTmpl<XmlElement<LegalDept> > LegalDept::s_typeRegistry("LegalDept", "urn:org:legal");

  

  //constructor
  
  LegalDept::LegalDept(AnyTypeCreateArgs args):
  XMLSchema::Types::anyType(AnyTypeCreateArgs(false, 
                                              args.ownerNode, 
                                              args.ownerElem, 
                                              args.ownerDoc, 
                                              args.childBuildsTree, 
                                              (args.createFromElementAttr? false : args.abstract),
                                              args.blockMask,
                                              args.finalMask,
                                              args.contentTypeVariety,
                                              args.anyTypeUseCase,
                                              args.suppressTypeAbstract
                                             )),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree() && !args.childBuildsTree)
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void LegalDept::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  new XsdFSM<attr_id_ptr>( Particle(NULL, DOMString("id"), 1, 1), XsdEvent::ATTRIBUTE, new object_unary_mem_fun_t<attr_id_ptr, LegalDept, FsmCbOptions>(this, &LegalDept::create_attr_id)),
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  org::hr::leaderId_ptr LegalDept::create_leaderId(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("leaderId");
    static DOMStringPtr myNsUri = new DOMString("urn:org:hr");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    org::hr::leaderId_p node = XSD::createElementTmpl<leaderId, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _leaderId = node;
      
    return node;
  }

  
  org::hr::leaderId_p LegalDept::element_leaderId()
  {
    FSM::warnNullNode(_leaderId, "leaderId", "{urn:org:hr}leaderId", 1);
    return _leaderId;
  }
    
  void LegalDept::set_leaderId(DOMString val)
  {
    get_sequence()->set_leaderId(val);
  }

  DOMString LegalDept::get_leaderId_string()
  {
    return get_sequence()->get_leaderId_string();
  }

          

  LegalDept::legalAdvisors_ptr LegalDept::create_legalAdvisors(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("legalAdvisors");
    static DOMStringPtr myNsUri = NULL;
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false, "urn:org:hr", "UserIdList");
    LegalDept::legalAdvisors_p node = XSD::createElementTmpl<legalAdvisors, org::hr::Types::UserIdList*>(t);
          
    _legalAdvisors = node;
      
    return node;
  }

  
  LegalDept::legalAdvisors_p LegalDept::element_legalAdvisors()
  {
    FSM::warnNullNode(_legalAdvisors, "legalAdvisors", "{urn:org:hr}legalAdvisors", 1);
    return _legalAdvisors;
  }
      

  /* attribute  functions  */
  

  LegalDept::attr_id_ptr LegalDept::create_attr_id(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("id");
    static DOMStringPtr myNsUri = NULL;
    
    if(_attr_id) {
      return _attr_id;
    }  
    XSD::StructCreateAttrThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options);
    LegalDept::attr_id_p node = XSD::createAttributeTmpl<attr_id>(t);
      
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _attr_id = node;
      
    return node;
  }

  
    void LegalDept::set_attr_id(DOMString val)
    {
        
      attribute_attr_id()->stringValue(val);
    }

    DOMString LegalDept::get_attr_id_string()
    {
       
      return attribute_attr_id()->stringValue();
    }

    
  LegalDept::attr_id_p LegalDept::attribute_attr_id()
  {
    FSM::warnNullNode(_attr_id, "attr_id", "{http://www.w3.org/2001/XMLSchema}id", 1);
    return _attr_id;
  }
    
  //constructor
  LegalDept::sequence::sequence(LegalDept* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<leaderId_ptr>( Particle(new DOMString("urn:org:hr"), DOMString("leaderId"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<leaderId_ptr, LegalDept, FsmCbOptions>(_that, &LegalDept::create_leaderId)),
      new XsdFSM<legalAdvisors_ptr>( Particle(NULL, DOMString("legalAdvisors"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<legalAdvisors_ptr, LegalDept, FsmCbOptions>(_that, &LegalDept::create_legalAdvisors)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  org::hr::leaderId_p LegalDept::sequence::element_leaderId()
  {
      org::hr::leaderId_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<leaderId_ptr> *unitFsm = dynamic_cast<XsdFSM<leaderId_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "leaderId", "{urn:org:hr}leaderId", 1);
    return node_p;
        
  }
  
  
  void LegalDept::sequence::set_leaderId(DOMString val)
  {
      
    element_leaderId()->stringValue(val);
  }

  DOMString LegalDept::sequence::get_leaderId_string()
  {
    return element_leaderId()->stringValue();
  }

          

  LegalDept::legalAdvisors_p LegalDept::sequence::element_legalAdvisors()
  {
      LegalDept::legalAdvisors_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[1].get();
    if(fsm_p) 
    {
      XsdFSM<legalAdvisors_ptr> *unitFsm = dynamic_cast<XsdFSM<legalAdvisors_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "legalAdvisors", "{urn:org:hr}legalAdvisors", 1);
    return node_p;
        
  }
  
  
} //  end namespace Types 


} // end namespace legal  
} // end namespace org



examples/netEnabled


examples/netEnabled/README.txt


 This example(netEnabled) demonstrates the "network-enabled processor" capability of xsd2cpp.

 The netEnabled.xsd document includes a XML Schema located on world-wide-web:
   schemaLocation="http://www.w3.org/2002/ws/databinding/examples/6/05/HexBinaryElement/echoHexBinaryElement.xsd"

 For xsd2cpp to work sucessfully:
  - the world-wide-web must be accessible on machine(internet)
  - the schemaLocation URL must be valid, and available on WWW.


 Since xsd2cpp is also a "minimally-conforming processor", with "network-enabled processor" capability, it qualifies to become "Fully conforming processor".


 Related definitions from W3C specification:
 ===========================================

  link:
    http://www.w3.org/TR/xmlschema-1/XML%20Schema%20Part%201_%20Structures%20Second%20Edition.html#key-fullyConforming

  [Definition:]  Minimally conforming processors must completely and correctly implement the ·Schema Component Constraints·, ·Validation Rules·, and ·Schema Information Set Contributions· contained in this specification.

  [Definition:]  ·Minimally conforming· processors which accept schemas represented in the form of XML documents as described in Layer 2: Schema Documents, Namespaces and Composition (§4.2) are additionally said to provide conformance to the XML Representation of Schemas. Such processors must, when processing schema documents, completely and correctly implement all ·Schema Representation Constraints· in this specification, and must adhere exactly to the specifications in Schema Component Details (§3) for mapping the contents of such documents to ·schema components· for use in ·validation· and ·assessment·.

  [Definition:]   Fully conforming processors are network-enabled processors which are not only both ·minimally conforming· and ·in conformance to the XML Representation of Schemas·, but which additionally must be capable of accessing schema documents from the World Wide Web according to Representation of Schemas on the World Wide Web (§2.7) and How schema definitions are located on the Web (§4.3.2). .



examples/netEnabled/netEnabled.xsd

<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  targetNamespace="http://www.w3.org/2002/ws/databinding/examples/6/05/"
  xmlns="http://www.w3.org/2002/ws/databinding/examples/6/05/"
  xmlns:ns1="http://www.w3.org/2002/ws/databinding/examples/6/05/"
  >

  <xsd:include schemaLocation="http://www.w3.org/2002/ws/databinding/examples/6/05/HexBinaryElement/echoHexBinaryElement.xsd"/>

  
  <xsd:element name="echo"> 
    <xsd:complexType>
      <xsd:sequence>
        <xsd:element ref="ns1:echoHexBinaryElement"/> 
      </xsd:sequence>
    </xsd:complexType>
  </xsd:element>

</xsd:schema>


examples/netEnabled/nsaliases.xml

<nsaliases>
  <alias uri="http://www.w3.org/2002/ws/databinding/examples/6/05/" toUrn="urn:examples_6_05"/>
</nsaliases>


examples/netEnabled/valid.xml

<?xml version="1.0"?>
<ns1:echo xmlns:ns1="http://www.w3.org/2002/ws/databinding/examples/6/05/">
  <ns1:echoHexBinaryElement>
    <ns1:hexBinaryElement>77696f646d6f6e7974637174716a7169696e6b65616f76786f746e66716b707875757261736e686469796b65706c656d7465626661637661646e6b65636662647669726d6f6e757361</ns1:hexBinaryElement>
  </ns1:echoHexBinaryElement>
</ns1:echo>


examples/netEnabled/include/examples_6_05/echoHexBinaryElement.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __examples_6_05_echoHexBinaryElement_H__
#define  __examples_6_05_echoHexBinaryElement_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "examples_6_05/hexBinaryElement.h"
      

using namespace XPlus;

namespace examples_6_05{


/// The class for element {}echoHexBinaryElement with following structure: 
/// \n complexType->ModelGroup-or-ModelGroupDefinition
/// Read more on structures/methods inside ...
class echoHexBinaryElement : public XMLSchema::XmlElement<XMLSchema::Types::anyType>
{
  public:

    /// constructor for the element node
    echoHexBinaryElement(ElementCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<examples_6_05::hexBinaryElement > hexBinaryElement_ptr;
  /// typedef for the Plain pointer to the node
  typedef examples_6_05::hexBinaryElement* hexBinaryElement_p;
  
  /// typedef for the node
  typedef examples_6_05::hexBinaryElement hexBinaryElement; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(echoHexBinaryElement* that);

    

    ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    hexBinaryElement_p element_hexBinaryElement();

        

    ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
    ///  \n Sets the value of the scalar element with the supplied value.
    ///  @param val the value(as DOMString) to set with 
    void set_hexBinaryElement(DOMString val);

    ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
    ///  \n Returns the value of the scalar element 
    ///  @return the value(as DOMString) of the element 
    DOMString get_hexBinaryElement_string();

          

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    echoHexBinaryElement*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  hexBinaryElement_p element_hexBinaryElement();
      

  ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
  ///  \n Sets the value of the element with the supplied value.
  ///  @param val the value(as DOMString) to set with 
  void set_hexBinaryElement(DOMString val);
  
  ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement" :
  ///  \n Returns the value(as DOMString) of the element
  DOMString get_hexBinaryElement_string();

        

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  hexBinaryElement_ptr _hexBinaryElement;
              

  /// initialize the FSM
  void initFSM();

  
  hexBinaryElement_ptr create_hexBinaryElement(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END



}; //end class echoHexBinaryElement

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {}echoHexBinaryElement
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<echoHexBinaryElement > echoHexBinaryElement_ptr;
  /// typedef for the Plain pointer to the node
  typedef echoHexBinaryElement* echoHexBinaryElement_p;
  
} // end namespace      
    
#endif


examples/netEnabled/include/examples_6_05/Document.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __examples_6_05_DOCUMENT_H__
#define  __examples_6_05_DOCUMENT_H__
        
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"

#include "examples_6_05/echo.h"
    
#include "examples_6_05/hexBinaryElement.h"
    
#include "examples_6_05/echoHexBinaryElement.h"
    

using namespace XPlus;
using namespace FSM;


namespace examples_6_05{


class Document : public XMLSchema::TDocument
{
  private:
  
  
  echo_ptr _echo;
    
  AutoPtr<XsdFSM<echo_ptr> > _fsm_echo;
  
  hexBinaryElement_ptr _hexBinaryElement;
    
  XsdFSM<hexBinaryElement_ptr>* _fsm_hexBinaryElement;
    
  echoHexBinaryElement_ptr _echoHexBinaryElement;
    
  XsdFSM<echoHexBinaryElement_ptr>* _fsm_echoHexBinaryElement;
      
  
  // attributes, elements
  
  echo_ptr create_echo(FsmCbOptions& options);

  hexBinaryElement_ptr create_hexBinaryElement(FsmCbOptions& options);

  echoHexBinaryElement_ptr create_echoHexBinaryElement(FsmCbOptions& options);
  

  public:

  Document(bool buildTree=true, bool createSample=false);
  virtual ~Document() {}
    
  
  void set_root_echo();
    
  void set_root_hexBinaryElement();
    
  void set_root_echoHexBinaryElement();
    
  echo_p element_echo();
  
  hexBinaryElement_p element_hexBinaryElement();
    
  echoHexBinaryElement_p element_echoHexBinaryElement();
      
    
  void initFSM();
};

} // end namespace      
    
#endif
  


examples/netEnabled/include/examples_6_05/echo.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __examples_6_05_echo_H__
#define  __examples_6_05_echo_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"


#include "examples_6_05/echoHexBinaryElement.h"
      

using namespace XPlus;

namespace examples_6_05{


/// The class for element {http://www.w3.org/2002/ws/databinding/examples/6/05/}echo with following structure: 
/// \n complexType->ModelGroup-or-ModelGroupDefinition
/// Read more on structures/methods inside ...
class echo : public XMLSchema::XmlElement<XMLSchema::Types::anyType>
{
  public:

    /// constructor for the element node
    echo(ElementCreateArgs args);

  

  /// typedef for the Shared pointer to the node
  typedef AutoPtr<examples_6_05::echoHexBinaryElement > echoHexBinaryElement_ptr;
  /// typedef for the Plain pointer to the node
  typedef examples_6_05::echoHexBinaryElement* echoHexBinaryElement_p;
  
  /// typedef for the node
  typedef examples_6_05::echoHexBinaryElement echoHexBinaryElement; 
  
  /// The MG class inside a complexType
  /// \n Refer to documentation on structures/methods inside ...
  struct sequence : public XsdSequenceFsmOfFSMs 
  {
      

    /// constructor for the MG node
    sequence(echo* that);

    

    ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}echoHexBinaryElement" :
    ///  \n Returns the scalar element node
    ///  @return the element node fetched
    echoHexBinaryElement_p element_echoHexBinaryElement();

        

    //  accessors for MGs/MGDs which are nested children of this MG/MGD
    

  private:  

    inline XsdFsmBase* clone() const {
      return new sequence(*this);
    }

    echo*      _that;
  }; // end sequence
  

  ///  For the scalar-element with QName "{http://www.w3.org/2002/ws/databinding/examples/6/05/}echoHexBinaryElement" :
  ///  \n Returns the scalar element node
  ///  @return the element node fetched
  echoHexBinaryElement_p element_echoHexBinaryElement();
      

  /// Returns the MG node(or node-list) inside  the complexType 
  sequence*  get_sequence() {
    return _sequence;
  }

    

  protected:
  
  XsdAllFsmOfFSMsPtr   _fsmAttrs;   
  XsdFsmBasePtr        _fsmElems;   
  
  
  AutoPtr<sequence> _sequence;
    
    
  echoHexBinaryElement_ptr _echoHexBinaryElement;
              

  /// initialize the FSM
  void initFSM();

  
  echoHexBinaryElement_ptr create_echoHexBinaryElement(FsmCbOptions& options);
  

public:

  //types which this class needs, as INNER CLASSES
  
  //types which this class needs, as INNER CLASSES : END



}; //end class echo

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {http://www.w3.org/2002/ws/databinding/examples/6/05/}echo
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<echo > echo_ptr;
  /// typedef for the Plain pointer to the node
  typedef echo* echo_p;
  
} // end namespace      
    
#endif


examples/netEnabled/include/examples_6_05/all-include.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __examples_6_05_ALL_INCLUDE_H__
#define  __examples_6_05_ALL_INCLUDE_H__

#include "XPlus/AutoPtr.h"

  
#include "examples_6_05/Document.h"

#include "examples_6_05/echo.h"    
  

using namespace XPlus;


#endif 
  


examples/netEnabled/include/examples_6_05/hexBinaryElement.h


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#ifndef  __examples_6_05_hexBinaryElement_H__
#define  __examples_6_05_hexBinaryElement_H__
#include "XSD/UrTypes.h"
#include "XSD/xsdUtils.h"
#include "XSD/TypeDefinitionFactory.h"



using namespace XPlus;

namespace examples_6_05{

  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary> hexBinaryElement;
    

  //
  // Following types(mostly typedefs) are the ones, based on above C++ class definition
  // for the top-level element {http://www.w3.org/2001/XMLSchema}hexBinaryElement
  //


  /// typedef for the Shared pointer to the node
  typedef AutoPtr<XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary> > hexBinaryElement_ptr;
  /// typedef for the Plain pointer to the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary>* hexBinaryElement_p;
  
  /// typedef for the node
  typedef XMLSchema::XmlElement<XMLSchema::Types::bt_hexBinary> hexBinaryElement; 
  
} // end namespace      
    
#endif


examples/netEnabled/main.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  On subsequent "xsd2cpp" invocations, this file would not be overwritten.
 //  You can edit this file.
 //
  
#include <iostream>
#include <string>

#include "XSD/UserOps.h"
#include "examples_6_05/all-include.h"

void populateDocument(examples_6_05::Document* xsdDoc);
void updateOrConsumeDocument(examples_6_05::Document* xsdDoc);
  
void chooseDocumentElement(examples_6_05::Document* xsdDoc);
    

int main (int argc, char** argv)
{
  XSD::UserOps<examples_6_05::Document>::UserOpsCbStruct cbStruct;
  cbStruct.cbPopulateDocument           =  populateDocument;
  cbStruct.cbUpdateOrConsumeDocument    =  updateOrConsumeDocument;
  cbStruct.cbChooseDocumentElement      =  chooseDocumentElement;

  XSD::UserOps<examples_6_05::Document> opHandle(cbStruct);
  opHandle.run(argc, argv);
}

//
// Following functions are use case templates.
// You need to put "code" in the respective contexts.
//

  
// choose the element inside Document that you want as root using
// a call like : xsdDoc->set_root_xyz();
void chooseDocumentElement(examples_6_05::Document* xsdDoc)
{
  // uncomment one of folowing to choose root
  
  xsdDoc->set_root_echo();
  
  //xsdDoc->set_root_hexBinaryElement();
    
  //xsdDoc->set_root_echoHexBinaryElement();
      
}
    

// template function to populate the Tree with values
// write code to populate the Document here ...
void populateDocument(examples_6_05::Document* xsdDoc)
{
  xsdDoc->element_echo()->element_echoHexBinaryElement()->set_hexBinaryElement("77696f646d6f6e7974637174716a7169696e6b65616f76786f746e66716b707875757261736e686469796b65706c656d7465626661637661646e6b65636662647669726d6f6e757361");
}

// write code to operate(update/consume/test etc.) on the Document here...
// This Document is typically already populated(eg. read from an input
// xml file)
void updateOrConsumeDocument(examples_6_05::Document* xsdDoc)
{

}

  


examples/netEnabled/src/examples_6_05/Document.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "examples_6_05/Document.h"


namespace examples_6_05{


  ///constructor for the Document node
  Document::Document(bool buildTree_, bool createSample_):
    XMLSchema::TDocument(buildTree_, createSample_)
  {
    initFSM();
    DOM::Document::attributeDefaultQualified(false);
    DOM::Document::elementDefaultQualified(false);
    
  }

  void Document::initFSM()
  {
  
    _fsm_echo = new XsdFSM<echo_ptr>( Particle(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"),  DOMString("echo"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<echo_ptr, Document, FsmCbOptions>(this, &Document::create_echo));
  _fsm_hexBinaryElement = new XsdFSM<hexBinaryElement_ptr>( Particle(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"),  DOMString("hexBinaryElement"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<hexBinaryElement_ptr, Document, FsmCbOptions>(this, &Document::create_hexBinaryElement));
    _fsm_echoHexBinaryElement = new XsdFSM<echoHexBinaryElement_ptr>( Particle(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"),  DOMString("echoHexBinaryElement"), 1, 1),  XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<echoHexBinaryElement_ptr, Document, FsmCbOptions>(this, &Document::create_echoHexBinaryElement));
    
    XsdFsmBasePtr elemFsms[] = {
    _fsm_echo,
    _fsm_hexBinaryElement,
    _fsm_echoHexBinaryElement,
      
      NULL
    };
    XsdFsmBasePtr fofElem = new XsdFsmOfFSMs(elemFsms, XsdFsmOfFSMs::CHOICE);
    
    XsdFsmBasePtr docEndFsm = new XsdFSM<void *>(Particle(NULL, "", 1, 1), XsdEvent::DOCUMENT_END);
    XsdFsmBasePtr ptrFsms[] = { fofElem,  docEndFsm, NULL };
    _fsm = new XsdFsmOfFSMs(ptrFsms, XsdFsmOfFSMs::SEQUENCE);
  }

  
    void Document::set_root_echo() 
    {
    
      if(!_echo) {
        XsdEvent event(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"), NULL, DOMString("echo"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    
    void Document::set_root_hexBinaryElement() 
    {
    
      if(!_hexBinaryElement) 
      {
        XsdEvent event(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"), NULL, DOMString("hexBinaryElement"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    
    void Document::set_root_echoHexBinaryElement() 
    {
    
      if(!_echoHexBinaryElement) 
      {
        XsdEvent event(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"), NULL, DOMString("echoHexBinaryElement"), XsdEvent::ELEMENT_START);
        _fsm->processEventThrow(event); 
      }
    }
    


  /* element functions  */
  

  echo_ptr Document::create_echo(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("echo");
    static DOMStringPtr myNsUri = new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false);
    echo_p node = XSD::createElementTmpl<echo, void*>(t);
          
    _echo = node;
      
    return node;
  }

  
  echo_p Document::element_echo()
  {
    FSM::warnNullNode(_echo, "echo", "{http://www.w3.org/2002/ws/databinding/examples/6/05/}echo", 1);
    return _echo;
  }
    

  hexBinaryElement_ptr Document::create_hexBinaryElement(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("hexBinaryElement");
    static DOMStringPtr myNsUri = new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false, "http://www.w3.org/2001/XMLSchema", "hexBinary");
    hexBinaryElement_p node = XSD::createElementTmpl<hexBinaryElement, XMLSchema::Types::bt_hexBinary*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _hexBinaryElement = node;
      
    return node;
  }

  
  hexBinaryElement_p Document::element_hexBinaryElement()
  {
    FSM::warnNullNode(_hexBinaryElement, "hexBinaryElement", "{http://www.w3.org/2001/XMLSchema}hexBinaryElement", 1);
    return _hexBinaryElement;
  }
    

  echoHexBinaryElement_ptr Document::create_echoHexBinaryElement(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("echoHexBinaryElement");
    static DOMStringPtr myNsUri = new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this, this, _fsm, options, false, false, false);
    echoHexBinaryElement_p node = XSD::createElementTmpl<echoHexBinaryElement, void*>(t);
          
    _echoHexBinaryElement = node;
      
    return node;
  }

  
  echoHexBinaryElement_p Document::element_echoHexBinaryElement()
  {
    FSM::warnNullNode(_echoHexBinaryElement, "echoHexBinaryElement", "{}echoHexBinaryElement", 1);
    return _echoHexBinaryElement;
  }
    
} // end namespace      
    


examples/netEnabled/src/examples_6_05/echoHexBinaryElement.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "examples_6_05/echoHexBinaryElement.h"

namespace examples_6_05{


  //constructor
  
  echoHexBinaryElement::echoHexBinaryElement(ElementCreateArgs args):
      XMLSchema::XmlElement<anyType>(args),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree())
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void echoHexBinaryElement::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  hexBinaryElement_ptr echoHexBinaryElement::create_hexBinaryElement(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("hexBinaryElement");
    static DOMStringPtr myNsUri = new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    hexBinaryElement_p node = XSD::createElementTmpl<hexBinaryElement, void*>(t);
          
    if(options.isSampleCreate && (node->stringValue() == "") ) {
      node->stringValue(node->sampleValue());
    }
    
    _hexBinaryElement = node;
      
    return node;
  }

  
  hexBinaryElement_p echoHexBinaryElement::element_hexBinaryElement()
  {
    FSM::warnNullNode(_hexBinaryElement, "hexBinaryElement", "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement", 1);
    return _hexBinaryElement;
  }
    
  void echoHexBinaryElement::set_hexBinaryElement(DOMString val)
  {
    get_sequence()->set_hexBinaryElement(val);
  }

  DOMString echoHexBinaryElement::get_hexBinaryElement_string()
  {
    return get_sequence()->get_hexBinaryElement_string();
  }

            

  /* attribute  functions  */
  
  //constructor
  echoHexBinaryElement::sequence::sequence(echoHexBinaryElement* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<hexBinaryElement_ptr>( Particle(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"), DOMString("hexBinaryElement"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<hexBinaryElement_ptr, echoHexBinaryElement, FsmCbOptions>(_that, &echoHexBinaryElement::create_hexBinaryElement)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  hexBinaryElement_p echoHexBinaryElement::sequence::element_hexBinaryElement()
  {
      hexBinaryElement_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<hexBinaryElement_ptr> *unitFsm = dynamic_cast<XsdFSM<hexBinaryElement_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "hexBinaryElement", "{http://www.w3.org/2002/ws/databinding/examples/6/05/}hexBinaryElement", 1);
    return node_p;
        
  }
  
  
  void echoHexBinaryElement::sequence::set_hexBinaryElement(DOMString val)
  {
      
    element_hexBinaryElement()->stringValue(val);
  }

  DOMString echoHexBinaryElement::sequence::get_hexBinaryElement_string()
  {
    return element_hexBinaryElement()->stringValue();
  }

      
} // end namespace      
    


examples/netEnabled/src/examples_6_05/echo.cpp


 //
 //  This file was automatically generated using XmlPlus xsd2cpp tool.
 //  Please do not edit.
 //
  
#include "examples_6_05/echo.h"

namespace examples_6_05{


  //constructor
  
  echo::echo(ElementCreateArgs args):
      XMLSchema::XmlElement<anyType>(args),
    
    _fsmElems(NULL),
    _fsmAttrs(NULL)
  
    , _sequence(new sequence(this) )
  
  {
    this->contentTypeVariety(CONTENT_TYPE_VARIETY_ELEMENT_ONLY);
    initFSM();
    if(args.ownerDoc && args.ownerDoc->buildTree())
    {
      if(args.ownerDoc->createSample()) {
        _fsm->fireSampleEvents();
      }
      else {
        _fsm->fireRequiredEvents();
      }
    }
  }
    
  void echo::initFSM()
  {
    XsdFsmBasePtr fsmsAttrs[] = {
  
      NULL
    };

    _fsm->replaceOrAppendUniqueAttributeFsms(fsmsAttrs);
  
    _fsm->replaceContentFsm(_sequence);
      
    _fsmAttrs = _fsm->attributeFsm();
    _fsmElems = _fsm->contentFsm();

  }

  /* element functions  */
  

  echoHexBinaryElement_ptr echo::create_echoHexBinaryElement(FsmCbOptions& options)
  {
    static DOMStringPtr myName = new DOMString("echoHexBinaryElement");
    static DOMStringPtr myNsUri = new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/");
    
    XSD::StructCreateElementThroughFsm t( myName, myNsUri, NULL, this->ownerElement(), this->ownerDocument(), _fsm, options, false, false, false);
    echoHexBinaryElement_p node = XSD::createElementTmpl<echoHexBinaryElement, void*>(t);
          
    _echoHexBinaryElement = node;
      
    return node;
  }

  
  echoHexBinaryElement_p echo::element_echoHexBinaryElement()
  {
    FSM::warnNullNode(_echoHexBinaryElement, "echoHexBinaryElement", "{http://www.w3.org/2002/ws/databinding/examples/6/05/}echoHexBinaryElement", 1);
    return _echoHexBinaryElement;
  }
      

  /* attribute  functions  */
  
  //constructor
  echo::sequence::sequence(echo* that):
    _that(that)
  {
    XsdFsmBasePtr fsmArray[] = {
    new XsdFSM<echoHexBinaryElement_ptr>( Particle(new DOMString("http://www.w3.org/2002/ws/databinding/examples/6/05/"), DOMString("echoHexBinaryElement"), 1, 1), XsdEvent::ELEMENT_START, new object_unary_mem_fun_t<echoHexBinaryElement_ptr, echo, FsmCbOptions>(_that, &echo::create_echoHexBinaryElement)),
             
      NULL 
    } ;
    
    XsdSequenceFsmOfFSMs::init(fsmArray);
  }

      

  echoHexBinaryElement_p echo::sequence::element_echoHexBinaryElement()
  {
      echoHexBinaryElement_p node_p = NULL;
    XsdFsmBase* fsm_p = this->allFSMs()[0].get();
    if(fsm_p) 
    {
      XsdFSM<echoHexBinaryElement_ptr> *unitFsm = dynamic_cast<XsdFSM<echoHexBinaryElement_ptr> *>(fsm_p);
      if(unitFsm && unitFsm->nodeList().size()>0) {
        assert(unitFsm->nodeList().size()==1);  
        node_p = unitFsm->nodeList().at(0); 
      }
    }
    
    FSM::warnNullNode(node_p, "echoHexBinaryElement", "{http://www.w3.org/2002/ws/databinding/examples/6/05/}echoHexBinaryElement", 1);
    return node_p;
        
  }
  
  
} // end namespace