|
OpenQuizz
Une application de gestion des contenus pédagogiques
|


Public Member Functions | |
| def | __init__ (self, root_path) |
| def | store (self, istream) |
| def | ostream (self) |
| def | set_ostream (self, ostream) |
Public Member Functions inherited from FileDBBase | |
| def | root_path (self) |
| def | db_path (self, rela_path) |
Public Member Functions inherited from ObjectDBW | |
| def | __init__ (self, *args, **kwargs) |
Public Member Functions inherited from CompoundDB | |
| def | has_object (self, sha) |
| def | info (self, sha) |
| def | stream (self, sha) |
| def | size (self) |
| def | sha_iter (self) |
| def | databases (self) |
| def | update_cache (self, force=False) |
| def | partial_to_complete_sha_hex (self, partial_hexsha) |
Public Member Functions inherited from ObjectDBR | |
| def | __contains__ (self, sha) |
Public Member Functions inherited from LazyMixin | |
| def | __getattr__ (self, attr) |
Static Public Attributes | |
| PackDBCls | |
| LooseDBCls | |
| ReferenceDBCls | |
| packs_dir | |
| loose_dir | |
| alternates_dir | |
A git-style object database, which contains all objects in the 'objects' subdirectory ``IMPORTANT``: The usage of this implementation is highly discouraged as it fails to release file-handles. This can be a problem with long-running processes and/or big repositories.
| def __init__ | ( | self, | |
| root_path | |||
| ) |
Initialize ourselves on a git objects directory
Reimplemented from FileDBBase.
| def ostream | ( | self | ) |
:return: overridden output stream this instance will write to, or None
if it will write to the default stream
Reimplemented from ObjectDBW.
| def set_ostream | ( | self, | |
| stream | |||
| ) |
Adjusts the stream to which all data should be sent when storing new objects
:param stream: if not None, the stream to use, if None the default stream
will be used.
:return: previously installed stream, or None if there was no override
:raise TypeError: if the stream doesn't have the supported functionality
Reimplemented from ObjectDBW.
| def store | ( | self, | |
| istream | |||
| ) |
Create a new object in the database
:return: the input istream object with its sha set to its corresponding value
:param istream: IStream compatible instance. If its sha is already set
to a value, the object will just be stored in the our database format,
in which case the input stream is expected to be in object format ( header + contents ).
:raise IOError: if data could not be written
Reimplemented from ObjectDBW.
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |