예제 #1
0
    def __init__(self, user_name):
        # TODO: self.transport.http.resp_code = HTTP_401

        Fault.__init__(self,
                faultcode='Client.AuthenticationError',
                faultstring='Invalid authentication request for %r' % user_name
            )
예제 #2
0
    def __init__(self):
        # TODO: self.transport.http.resp_code = HTTP_401

        Fault.__init__(self,
                faultcode='Client.AuthorizationError',
                faultstring='You are not authorized to access this resource.'
            )
예제 #3
0
    def __init__(self, user_name):
        # TODO: self.transport.http.resp_code = HTTP_401

        Fault.__init__(self,
                faultcode='Client.AuthenticationError',
                faultstring='Invalid authentication request for %r' % user_name
            )
예제 #4
0
    def __init__(self):
        # TODO: self.transport.http.resp_code = HTTP_401

        Fault.__init__(self,
                faultcode='Client.AuthorizationError',
                faultstring='You are not authorized to access this resource.'
            )
예제 #5
0
파일: _service.py 프로젝트: azurit/rpclib
 def __init__(self):
     Fault.__init__(self,
             faultcode="Documented",
             faultstring="A documented fault",
             faultactor='http://faultactor.example.com',
             detail=etree.Element('something')
         )
예제 #6
0
 def __init__(self, err):
     # TODO: handle that err could be a list of strings, first element
     # should be faultstring, rest should go in self.extra.
     faultstring = err
     if isinstance(err, Exception) and err.args:
         faultstring = err.args[0]
         self.extra = err.args[1:]
     faultstring = str(faultstring)
     Fault.__init__(self, faultcode=self.faultcode, faultstring=faultstring)
예제 #7
0
 def __init__(self, err):
     # TODO: handle that err could be a list of strings, first element
     # should be faultstring, rest should go in self.extra.
     faultstring = err
     if isinstance(err, Exception) and err.args:
         faultstring = err.args[0]
         self.extra = err.args[1:]
     faultstring = str(faultstring)
     Fault.__init__(self, faultcode=self.faultcode,
                          faultstring=faultstring)
예제 #8
0
 def __init__(self):
     Fault.__init__(self,
             faultcode='Client.UnauthenticatedError',
             faultstring='This resource can only be accessed after authentication.'
         )
예제 #9
0
 def __init__(self, value):
     Fault.__init__(self,
             faultcode='Client.KeyError',
             faultstring='Value %r not found' % value
         )
예제 #10
0
 def __init__(self):
     Fault.__init__(self,
             faultcode='Client.UnauthenticatedError',
             faultstring='This resource can only be accessed after authentication.'
         )
예제 #11
0
파일: error.py 프로젝트: rch/rpclib
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.ValidationError',
                    'The string %r could not be validated.' % faultstring)
예제 #12
0
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.ValidationError',
                     'The string %r could not be validated.' % faultstring)
예제 #13
0
 def __init__(self, value):
     Fault.__init__(self,
             faultcode='Client.KeyError',
             faultstring='Value %r not found' % value
         )
예제 #14
0
파일: error.py 프로젝트: azurit/rpclib
 def __init__(self, faultstring="Requested resource not found"):
     Fault.__init__(self, 'Client.ResourceNotFound', faultstring)
예제 #15
0
파일: error.py 프로젝트: azurit/rpclib
 def __init__(self, faultstring=""):
     Fault.__init__(self, 'Client.RequestNotAllowed', faultstring)
예제 #16
0
파일: error.py 프로젝트: rch/rpclib
 def __init__(self, faultstring="Requested resource not found"):
     Fault.__init__(self, 'Client.ResourceNotFound', faultstring)
예제 #17
0
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.RequestTooLong', faultstring)
예제 #18
0
 def __init__(self):
     Fault.__init__(self,
                    faultcode="Documented",
                    faultstring="A documented fault",
                    faultactor='http://faultactor.example.com',
                    detail=etree.Element('something'))
예제 #19
0
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.ArgumentError', faultstring)
예제 #20
0
파일: error.py 프로젝트: rch/rpclib
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.RequestTooLong', faultstring)
예제 #21
0
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.ResourceNotFound', faultstring)
예제 #22
0
파일: error.py 프로젝트: rch/rpclib
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.ArgumentError', faultstring)
예제 #23
0
파일: _base.py 프로젝트: rch/rpclib
 def __init__(self, faultstring):
     Fault.__init__(self, "Client.SchemaValidationError", faultstring)
예제 #24
0
파일: _base.py 프로젝트: rch/rpclib
 def __init__(self, faultstring):
     Fault.__init__(self, 'Client.SchemaValidationError', faultstring)