##################################################
# file: SecurityTokenService_types.py
#
# schema types generated by "ZSI.generate.wsdl2python.WriteServiceModule"
#    D:\workspace\digsby\Digsby.py --no-traceback-dialog --multi --server=api5.digsby.org
#
##################################################

import ZSI
import ZSI.TCcompound
from ZSI.schema import LocalElementDeclaration, ElementDeclaration, TypeDefinition, GTD, GED
from ZSI.generate.pyclass import pyclass_type

import ZSI.wstools.Namespaces as NS
from msn.SOAP import Namespaces as MSNS

##############################
# targetNamespace
# http://schemas.microsoft.com/Passport/SoapServices/PPCRL
##############################

class ps:
    targetNamespace = MSNS.PPCRL.BASE

    class RequestMultipleSecurityTokensType_Def(ZSI.TCcompound.ComplexType, TypeDefinition):
        schema = MSNS.PPCRL.BASE
        type = (schema, "RequestMultipleSecurityTokensType")
        def __init__(self, pname, ofwhat=(), attributes=None, extend=False, restrict=False, **kw):
            ns = ps.RequestMultipleSecurityTokensType_Def.schema
            TClist = [GED(NS.WSTRUST.BASE,"RequestSecurityToken",lazy=False, isref=True)(minOccurs=1, maxOccurs="unbounded", nillable=False, encoded=kw.get("encoded"))]
            self.attribute_typecode_dict = attributes or {}
            if extend: TClist += ofwhat
            if restrict: TClist = ofwhat
            else:
                # attribute handling code
                self.attribute_typecode_dict["Id"] = ZSI.TC.String()
            ZSI.TCcompound.ComplexType.__init__(self, None, TClist, pname=pname, inorder=0, **kw)
            class Holder:
                __metaclass__ = pyclass_type
                typecode = self
                def __init__(self):
                    # pyclass
                    self._RequestSecurityToken = None
                    return
            Holder.__name__ = "RequestMultipleSecurityTokensType_Holder"
            self.pyclass = Holder

    class AuthInfoType_Def(ZSI.TCcompound.ComplexType, TypeDefinition):
        schema = MSNS.PPCRL.BASE
        type = (schema, "AuthInfoType")
        def __init__(self, pname, ofwhat=(), attributes=None, extend=False, restrict=False, **kw):
            ns = ps.AuthInfoType_Def.schema
            TClist = [ZSI.TC.String(pname=(ns,"HostingApp"), aname="_HostingApp", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname=(ns,"BinaryVersion"), aname="_BinaryVersion", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname=(ns,"UIVersion"), aname="_UIVersion", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname=(ns,"Cookies"), aname="_Cookies", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded")), ZSI.TC.String(pname=(ns,"RequestParams"), aname="_RequestParams", minOccurs=1, maxOccurs=1, nillable=False, typed=False, encoded=kw.get("encoded"))]
            self.attribute_typecode_dict = attributes or {}
            if extend: TClist += ofwhat
            if restrict: TClist = ofwhat
            else:
                # attribute handling code
                self.attribute_typecode_dict["Id"] = ZSI.TC.String()
            ZSI.TCcompound.ComplexType.__init__(self, None, TClist, pname=pname, inorder=0, **kw)
            class Holder:
                __metaclass__ = pyclass_type
                typecode = self
                def __init__(self):
                    # pyclass
                    self._HostingApp = None
                    self._BinaryVersion = None
                    self._UIVersion = None
                    self._Cookies = None
                    self._RequestParams = None
                    return
            Holder.__name__ = "AuthInfoType_Holder"
            self.pyclass = Holder

    class RequestMultipleSecurityTokens_Dec(ElementDeclaration):
        literal = "RequestMultipleSecurityTokens"
        schema = MSNS.PPCRL.BASE
        substitutionGroup = None
        def __init__(self, **kw):
            kw["pname"] = (MSNS.PPCRL.BASE,"RequestMultipleSecurityTokens")
            kw["aname"] = "_RequestMultipleSecurityTokens"
            if ps.RequestMultipleSecurityTokensType_Def not in ps.RequestMultipleSecurityTokens_Dec.__bases__:
                bases = list(ps.RequestMultipleSecurityTokens_Dec.__bases__)
                bases.insert(0, ps.RequestMultipleSecurityTokensType_Def)
                ps.RequestMultipleSecurityTokens_Dec.__bases__ = tuple(bases)

            ps.RequestMultipleSecurityTokensType_Def.__init__(self, **kw)
            if self.pyclass is not None: self.pyclass.__name__ = "RequestMultipleSecurityTokens_Dec_Holder"

    class AuthInfo_Dec(ElementDeclaration):
        literal = "AuthInfo"
        schema = MSNS.PPCRL.BASE
        substitutionGroup = None
        def __init__(self, **kw):
            kw["pname"] = (MSNS.PPCRL.BASE,"AuthInfo")
            kw["aname"] = "_AuthInfo"
            if ps.AuthInfoType_Def not in ps.AuthInfo_Dec.__bases__:
                bases = list(ps.AuthInfo_Dec.__bases__)
                bases.insert(0, ps.AuthInfoType_Def)
                ps.AuthInfo_Dec.__bases__ = tuple(bases)

            ps.AuthInfoType_Def.__init__(self, **kw)
            if self.pyclass is not None: self.pyclass.__name__ = "AuthInfo_Dec_Holder"

# end class ps (tns: http://schemas.microsoft.com/Passport/SoapServices/PPCRL)
