Package pulp :: Package server :: Module auditing :: Class MethodInspector
[hide private]
[frames] | no frames]

Class MethodInspector

source code

object --+
         |
        MethodInspector

Class for method inspection.

Instance Methods [hide private]
 
__init__(self, method, params)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
api_name(self, args)
Return the api class name for the given instance method positional arguments.
source code
 
audit_repr(self, value)
Return an audit-friendly representation of a value.
source code
 
param_values(self, args, kwargs)
Grep through passed in arguments and keyword arguments and return a list of values corresponding to the parameters of interest.
source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, method, params)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Parameters:
  • method (unbound class instance method) - method to build spec of
  • params (list of str's or None) - ordered list of method parameters of interest, None means all parameters are of interest
Overrides: object.__init__

api_name(self, args)

source code 

Return the api class name for the given instance method positional arguments.

Parameters:
  • args (list) - positional arguments of an api instance method
Returns:
name of api class

audit_repr(self, value)

source code 

Return an audit-friendly representation of a value.

Parameters:
  • value (any) - parameter value
Returns:
string representing the value

param_values(self, args, kwargs)

source code 

Grep through passed in arguments and keyword arguments and return a list of values corresponding to the parameters of interest.

Parameters:
  • args (list or tuple) - positional arguments
  • kwargs (dict) - keyword arguments
Returns:
list of (paramter, value) for parameters of interest