fileobj
index
/tmp/makerelease-pwman-python.ZTvWhNke/pwman-python-2.14/libpwman/fileobj.py

# Simple object file format.
# Copyright (c) 2011-2026 Michael Büsch <m@bues.ch>
# Licensed under the GNU/GPL version 2 or later.

 
Modules
       
errno

 
Classes
       
builtins.Exception(builtins.BaseException)
FileObjError
builtins.object
FileObj
FileObjCollection

 
class FileObj(builtins.object)
    FileObj(name, data)
 

 
  Methods defined here:
__init__(self, name, data)
Construct FileObj().
name: The object name. Must be bytes-like.
data: The object payload. Must be bytes-like.
__len__(self)
getData(self)
getHeaderLen(self)
getIndex(self)
getName(self)
getRaw(self, buffer)
getRawOffset(self)
getRawPayloadOffset(self)
setIndex(self, index)
setRawOffset(self, rawOffset)

Class methods defined here:
parseRaw(raw)

Data and other attributes defined here:
DATALEN_LEN = 4
NAMELEN_LEN = 1

 
class FileObjCollection(builtins.object)
    FileObjCollection(objects)
 

 
  Methods defined here:
__init__(self, objects)
Initialize self.  See help(type(self)) for accurate signature.
__len__(self)
get(self, name, error=None, default=None)
getObj(self, name)
getRaw(self)
setObj(self, obj, override=False)

Class methods defined here:
parseFile(filepath)
parseRaw(raw)

Readonly properties defined here:
objects

 
class FileObjError(builtins.Exception)
    
Method resolution order:
FileObjError
builtins.Exception
builtins.BaseException
builtins.object

Data descriptors defined here:
__weakref__
list of weak references to the object

Static methods inherited from builtins.Exception:
__new__(*args, **kwargs) class method of builtins.Exception
Create and return a new object.  See help(type) for accurate signature.

Methods inherited from builtins.BaseException:
__init__(self, /, *args, **kwargs)
Initialize self.  See help(type(self)) for accurate signature.
__reduce__(self, /)
Helper for pickle.
__repr__(self, /)
Return repr(self).
__setstate__(self, state, /)
__str__(self, /)
Return str(self).
add_note(self, note, /)
Add a note to the exception
with_traceback(self, tb, /)
Set self.__traceback__ to tb and return self.

Data descriptors inherited from builtins.BaseException:
__cause__
__context__
__dict__
__suppress_context__
__traceback__
args

 
Data
        __all__ = ['FileObjError', 'FileObj', 'FileObjCollection']