Package dlinklist :: Module linklist :: Class SrchOrigin
[hide private]
[frames] | no frames]

Class SrchOrigin

source code


Provides an enumeration of the search origin values.

Instance Methods [hide private]

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

Class Methods [hide private]
(str or int, str)
getMessage(self, num)
Return a tuple consisting of the text name of the search origin value and the description of the status.
source code
Class Variables [hide private]
  ORIGIN_DEFAULT = 0
  HEAD = 1
  CURRENT = 2
  TAIL = 3
  __MESSAGES = {0: 'Use current origin setting', 1: 'Set origin ...
  _ORIGINS = {0: 'ORIGIN_DEFAULT', 1: 'HEAD', 2: 'CURRENT', 3: '...
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

getMessage(self, num)
Class Method

source code 

Return a tuple consisting of the text name of the search origin value and the description of the status. If the search origin value is invalid the number of the value is returned and the phrase 'Unknown error'.

Parameters:
  • num (int) - The numeric value from the SrchOrigin class.
Returns: (str or int, str)
A tuple consisting of the text SrchOrigin value and the description.

Class Variable Details [hide private]

__MESSAGES

Value:
{0: 'Use current origin setting',
 1: 'Set origin to head pointer',
 2: 'Set origin to current pointer',
 3: 'Set origin to tail pointer'}

_ORIGINS

Value:
{0: 'ORIGIN_DEFAULT',
 1: 'HEAD',
 2: 'CURRENT',
 3: 'TAIL',
 <classmethod object at 0x8cb498c>: 'getMessage'}