Package rpcServices :: Package services :: Module stack :: Class Stack
[show private | hide private]
[frames | no frames]

Type Stack

object --+    
         |    
      Stub --+
             |
            Stack


stack access object
Method Summary
  __init__(self, rpcClient, name)
contstr.
string getName(self)
get stack name
int getSize(self)
returns thge stack size
boolean isEmpty(self)
is stack empty
object/type pop(self)
pop item from stack
int push(self, item)
push item to stack
int truncate(self)
truncates the stack
    Inherited from Stub
  execute(self)
  setBatchMode(self, batchmode)
  _getLocalExceptionClass(self, xmlRpcFault)
map xmprpclib.Fault to local client exception
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name
  __getattribute__(...)
x.__getattribute__('name') <==> x.name
  __hash__(x)
x.__hash__() <==> hash(x)
  __new__(T, S, ...)
T.__new__(S, ...) -> a new object with type S, a subtype of T
  __reduce__(...)
helper for pickle
  __reduce_ex__(...)
helper for pickle
  __repr__(x)
x.__repr__() <==> repr(x)
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value
  __str__(x)
x.__str__() <==> str(x)

Method Details

__init__(self, rpcClient, name)
(Constructor)

contstr.
Parameters:
rpcClient - rpcClientStub
           (type=client.XmlRpcClient)
name - stackname
Overrides:
rpcServices.core.Stub.__init__

getName(self)

get stack name
Returns:
stack name
           (type=string)

getSize(self)

returns thge stack size
Returns:
stack size
           (type=int)
Raises:
StackNotFoundError - stack not found

isEmpty(self)

is stack empty
Returns:
True if stack is empty
           (type=boolean)
Raises:
StackNotFoundError - stack not found

pop(self)

pop item from stack
Returns:
stack item object
           (type=object/type)
Raises:
StackNotFoundError - stack not found
StackIndexError - stack empty

push(self, item)

push item to stack
Parameters:
item - stack item object
           (type=object/type)
Returns:
stack size
           (type=int)
Raises:
StackNotFoundError - stack not found

truncate(self)

truncates the stack
Returns:
number of droped itemns
           (type=int)
Raises:
StackNotFoundError - stack not found

Generated by Epydoc 2.1 on Sun Jan 8 23:45:28 2006 http://epydoc.sf.net