ganeti :: hypervisor :: hv_lxc :: LXCVersion :: Class LXCVersion
[hide private]
[frames] | no frames]

Class LXCVersion

source code


LXC version class.

Instance Methods [hide private]
a new object with type S, a subtype of T
__new__(cls, version_string) source code
 
__str__(self)
str(x)
source code

Inherited from tuple: __add__, __contains__, __eq__, __ge__, __getattribute__, __getitem__, __getnewargs__, __getslice__, __gt__, __hash__, __iter__, __le__, __len__, __lt__, __mul__, __ne__, __repr__, __rmul__, __sizeof__, count, index

Inherited from object: __delattr__, __format__, __init__, __reduce__, __reduce_ex__, __setattr__, __subclasshook__

Class Methods [hide private]
 
_Parse(cls, version_string)
Parse a passed string as an LXC version string.
source code
Class Variables [hide private]
  _VERSION_RE = re.compile(r"^(\d+)\.(\d+)\.(\d+)")
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

_Parse(cls, version_string)
Class Method

source code 

Parse a passed string as an LXC version string.

Parameters:
  • version_string (string) - a valid LXC version string
Raises:
  • ValueError - if version_string is an invalid LXC version string @rtype tuple(int, int, int) @return (major_num, minor_num, micro_num)

__new__(cls, version_string)

source code 
Returns: a new object with type S, a subtype of T
Overrides: object.__new__
(inherited documentation)

__str__(self)
(Informal representation operator)

source code 

str(x)

Overrides: object.__str__
(inherited documentation)