[%
IF (complexType.get_variety == 'all');
    INCLUDE complexType/all.tt(complexType = complexType);
ELSIF (complexType.get_variety == 'sequence');
    INCLUDE complexType/all.tt(complexType = complexType);
ELSIF (complexType.get_variety == 'group');
    THROW NOT_IMPLEMENTED, "${ element.get_name } - complexType group not implemented yet";
ELSIF (complexType.get_variety == 'choice');
    INCLUDE complexType/all.tt(complexType = complexType);
#ELSIF (complexType.get_variety);
#    THROW NOT_IMPLEMENTED, "unknown variety ${ complexType.get_variety } in ${ complexType.get_name } (${ element.get_name })";
ELSE %]

# There's no variety - empty complexType
use Class::Std::Fast::Storable constructor => 'none';
use base qw(SOAP::WSDL::XSD::Typelib::ComplexType);

__PACKAGE__->_factory();

[% END %]