65 delete baseContainer_;
70 for (std::map < std::string, Containers *>::iterator i = particleContainers_.begin();
71 particleContainers_.end() != i; ++i){
76 if(tcTable.size()>0) {
81 for (
size_t i = 0; i < tcTable.size(); i++)
98 if ((container = attributeContainers_[elemName]) != 0)
107 if (pType != 0 && !pType->
isSimple())
116 tcTable.push_back(container);
121 attributeContainers_[elemName] = container;
140 if((cs = particleContainers_[elemName]) != 0)
153 std::vector<TypeContainer*>::iterator iTc=tcTable.begin();
154 while(iTc != tcTable.end()) {
171 cs = particleContainers_[elemName];
176 particleContainers_[elemName] = cs;
184 for (ci=cit_b;ci!=cit_e;ci++){
186 if(ci->first.e->getName()==elemName){
190 tcTable.push_back(tC);
195 cs->
tc.push_back(tC);
204 if (! baseContainer_ && create){
211 return baseContainer_;
222 tC = cmContainers_[cm];
227 std::vector<TypeContainer*>::iterator iTc=tcTable.begin();
228 while(iTc!=tcTable.end()) {
242 tC= cmContainers_[cm];
246 cmContainers_[cm]=tC;
247 tcTable.push_back(tC);
269 return (
void *) Value.iValue;
271 return (
void *) Value.lValue;
274 return (
void *) Value.ulValue;
276 return (
void *) Value.fValue;
279 return (
void *) Value.dbValue;
281 return (
void *) Value.bValue;
283 return (
void *) Value.qnValue;
285 return (
void *) Value.sValue;
297 TypeContainer::deleteValue()
318 delete Value.ulValue;
325 delete Value.dbValue;
331 delete Value.qnValue;
347 baseContainer_->
print(os);
350 printContentModel(os);
356 printComplexType(os);
374 TypeContainer::printSimpleType(std::ostream & os)
391 os << *((
unsigned long *) (
getValue ()));
414 os << *((std::string *) (
getValue ()));
420 os<<
" -->Invalid value for data type";
425 TypeContainer::printComplexType (std::ostream & os)
454 TypeContainer::printContentModel(std::ostream & os)
460 for (ci=cit_b;ci!=cit_e;ci++){
470 if( ci->first.e->getName() !=
"*" &&
472 os << ci->first.e->getName() <<
":";
475 TypeContainer::printTypeNames_)
492 TypeContainer::rewindParticleContainers(std::map < std::string, Containers *> &particleContainers)
495 std::map < std::string, Containers *>::iterator it = particleContainers_.begin();
496 std::map < std::string, Containers *>::iterator end = particleContainers_.end();
497 for ( ; it != end; ++it) {
510 rewindParticleContainers(particleContainers_);
517 for ( ; ci != cit_e; ci++) {
541 rewindParticleContainers(particleContainers_);
575 return (
void*)Value.sValue;
583 for (ci=cit_b;ci!=cit_e;ci++){
593 if(ci->first.e->getName() == name){
std::string getPrefix(void) const
int getNumAttributes() const
void print(std::ostream &os)
TypeContainer * getChildContainer(std::string elemName, bool create=false)
std::string getAttributeName(int index) const
const SchemaParser * schemaParser() const
virtual bool isSimple() const =0
const XSDType * getType(const Qname &type, bool checkImports=true)
int getBasicContentType(int typeId) const
std::vector< TypeContainer * > tc
std::string getNamespace(void) const
static bool printTypeNames_
std::string getLocalName(void) const
TypeContainer * getAttributeContainer(std::string attName, bool create=false)
std::list< ContentHolder >::iterator ContentsIterator
ContentModel * getContents() const
Schema::ContentModelType getContentModel() const
TypeContainer * getBaseTypeContainer(bool create=false)
friend std::ostream & operator<<(std::ostream &os, TypeContainer &tc)
int getAttributeType(int index)
TypeContainer(int typeId, const SchemaParser *sp)
int getBaseTypeId() const
bool isBasicType(int sType) const
void rewind()
resets the access counters so that all access starts from first child