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

Public Member Functions

def __str__ (self)
 
def __repr__ (self)
 
def mode (self)
 
def binsha (self)
 
def hexsha (self)
 
def stage (self)
 
def path (self)
 
def flags (self)
 
def from_blob (cls, blob, stage=0)
 
def to_blob (self, repo)
 

Detailed Description

Small Brother of an index entry which can be created to describe changes
done to the index in which case plenty of additional information is not required.

As the first 4 data members match exactly to the IndexEntry type, methods
expecting a BaseIndexEntry can also handle full IndexEntries even if they
use numeric indices for performance reasons. 

Member Function Documentation

◆ __repr__()

def __repr__ (   self)

◆ __str__()

def __str__ (   self)

◆ binsha()

def binsha (   self)
binary sha of the blob 

◆ flags()

def flags (   self)
:return: flags stored with this entry

◆ from_blob()

def from_blob (   cls,
  blob,
  stage = 0 
)
:return: Fully equipped BaseIndexEntry at the given stage

Reimplemented in IndexEntry.

◆ hexsha()

def hexsha (   self)
hex version of our sha

◆ mode()

def mode (   self)
File Mode, compatible to stat module constants 

◆ path()

def path (   self)
:return: our path relative to the repository working tree root

◆ stage()

def stage (   self)
Stage of the entry, either:

    * 0 = default stage
    * 1 = stage before a merge or common ancestor entry in case of a 3 way merge
    * 2 = stage of entries from the 'left' side of the merge
    * 3 = stage of entries from the right side of the merge

:note: For more information, see http://www.kernel.org/pub/software/scm/git/docs/git-read-tree.html

◆ to_blob()

def to_blob (   self,
  repo 
)
:return: Blob using the information of this index entry

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