OpenQuizz
Une application de gestion des contenus pédagogiques
OInfo Class Reference
Inheritance diagram for OInfo:
Collaboration diagram for OInfo:

Public Member Functions

def __new__ (cls, sha, type, size)
 
def __init__ (self, *args)
 
def binsha (self)
 
def hexsha (self)
 
def type (self)
 
def type_id (self)
 
def size (self)
 

Detailed Description

Carries information about an object in an ODB, providing information
about the binary sha of the object, the type_string as well as the uncompressed size
in bytes.

It can be accessed using tuple notation and using attribute access notation::

    assert dbi[0] == dbi.binsha
    assert dbi[1] == dbi.type
    assert dbi[2] == dbi.size

The type is designed to be as lightweight as possible.

Constructor & Destructor Documentation

◆ __init__()

def __init__ (   self,
args 
)

Member Function Documentation

◆ __new__()

def __new__ (   cls,
  sha,
  type,
  size 
)

◆ binsha()

def binsha (   self)
:return: our sha as binary, 20 bytes

◆ hexsha()

def hexsha (   self)
:return: our sha, hex encoded, 40 bytes

◆ size()

def size (   self)

Reimplemented in ODeltaStream.

◆ type()

def type (   self)

◆ type_id()

def type_id (   self)

The documentation for this class was generated from the following file: