Package gofer :: Package rmi :: Module dispatcher :: Class RMI
[hide private]
[frames] | no frames]

Class RMI

source code

object --+
         |
        RMI

The RMI object performs the invocation.

Instance Methods [hide private]
 
__init__(self, request, auth, catalog)
x.__init__(...) initializes x; see help(type(x)) for signature
source code
 
__shared(self, fninfo)
Validate the method is either marked as shared or that the request was received on the method's contributing plugin UUID.
source code
 
permitted(self)
Check whether remote invocation of the specified method is permitted.
source code
Return
__call__(self)
Invoke the method.
source code
 
__str__(self)
str(x)
source code
 
__repr__(self)
repr(x)
source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __setattr__, __sizeof__, __subclasshook__

Static Methods [hide private]
(class|module)
getclass(request, catalog)
Get an instance of the class or module specified in the request using the catalog.
source code
(method|function)
getmethod(request, inst)
Get method of the class specified in the request.
source code
function
__fn(method)
Return the method's function (if a method) or the method assuming it's a function.
source code
Options
__fninfo(method)
Get the gofer metadata embedded in the function by the @remote decorator.
source code
 
constructor(request)
Get (optional) constructor arguments.
source code
Instance Variables [hide private]
dict catalog
A dict of class mappings.
Request request
The request envelope.
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, request, auth, catalog)
(Constructor)

source code 

x.__init__(...) initializes x; see help(type(x)) for signature

Parameters:
  • request (Request) - The request envelope.
  • auth (Options) - Authentication properties.
  • catalog (dict) - A dict of class mappings.
Overrides: object.__init__

getclass(request, catalog)
Static Method

source code 

Get an instance of the class or module specified in the request using the catalog.

Parameters:
  • request (Request) - The request envelope.
  • catalog (dict) - A dict of class mappings.
Returns: (class|module)
An instance.

getmethod(request, inst)
Static Method

source code 

Get method of the class specified in the request. Ensures that remote invocation is permitted.

Parameters:
  • request (Request) - The request envelope.
  • inst ((class|module)) - A class or module object.
Returns: (method|function)
The requested method.

__fn(method)
Static Method

source code 

Return the method's function (if a method) or the method assuming it's a function.

Parameters:
  • method (instancemethod) - An instance method.
Returns: function
The function

__fninfo(method)
Static Method

source code 

Get the gofer metadata embedded in the function by the @remote decorator.

Parameters:
  • method (instancemethod) - An instance method.
Returns: Options
The gofer attribute.

constructor(request)
Static Method

source code 

Get (optional) constructor arguments.

Returns:
cntr: ([],{})

__shared(self, fninfo)

source code 

Validate the method is either marked as shared or that the request was received on the method's contributing plugin UUID.

Parameters:
  • fninfo (Options) - The decorated function info.
Raises:

permitted(self)

source code 

Check whether remote invocation of the specified method is permitted. Applies security model using Security.

__call__(self)
(Call operator)

source code 

Invoke the method.

Returns: Return
The invocation result.

__str__(self)
(Informal representation operator)

source code 

str(x)

Overrides: object.__str__
(inherited documentation)

__repr__(self)
(Representation operator)

source code 

repr(x)

Overrides: object.__repr__
(inherited documentation)