def setUp(self, tp, empty=False):
self._item = tp<EOL>self.name = tp.getAttribute('<STR_LIT:name>')<EOL>self.ns = tp.getTargetNamespace()<EOL>self.mixed = tp.isMixed()<EOL>self.mgContent = ()<EOL>self.attrComponents = self._setAttributes(tp.getAttributeContent())<EOL>self._item = tp<EOL>if empty:<EOL><INDENT>return<EOL><DEDENT>model = tp.content<EOL>if model.isReference(): <EOL><INDENT>model = model.getModelGroupReference()<EOL><DEDENT>if model is None:<EOL><INDENT>return<EOL><DEDENT>if model.content is None:<EOL><INDENT>return<EOL><DEDENT>self.mgContent = model<EOL>
Problematic, loose all model group information.
        <all>, <choice>, <sequence> ..

           tp -- type definition
           empty -- no model group, just use as a dummy holder.