dulwich.objects.Tree(ShaFile)
class documentationdulwich.objects
(View In Hierarchy)
Method | __init__ | Don't call this directly |
Class Method | from_path | Open a SHA file from disk. |
Method | __contains__ | Undocumented |
Method | __getitem__ | Undocumented |
Method | __setitem__ | Set a tree entry by name. |
Method | __delitem__ | Undocumented |
Method | __len__ | Undocumented |
Method | __iter__ | Undocumented |
Method | add | Add an entry to the tree. |
Method | iteritems | Iterate over entries. |
Method | items | Return the sorted entries in this tree. |
Method | check | Check this object for internal consistency. |
Method | as_pretty_string | Return a string representing this object, fit for display. |
Method | lookup_path | Look up an object in a Git tree. |
Method | _deserialize | Grab the entries in the tree |
Method | _serialize | Undocumented |
Inherited from ShaFile:
Method | as_legacy_object_chunks | Return chunks representing the object in the experimental format. |
Method | as_legacy_object | Return string representing the object in the experimental format. |
Method | as_raw_chunks | Return chunks with serialization of the object. |
Method | as_raw_string | Return raw string with serialization of the object. |
Method | __bytes__ | Return raw string serialization of this object. |
Method | __str__ | Return raw string serialization of this object. |
Method | __hash__ | Return unique hash for this object. |
Method | set_raw_string | Set the contents of this object from a serialized string. |
Method | set_raw_chunks | Set the contents of this object from a list of chunks. |
Class Method | from_file | Get the contents of a SHA file on disk. |
Static Method | from_raw_string | Creates an object of the indicated type from the raw string given. |
Static Method | from_raw_chunks | Creates an object of the indicated type from the raw chunks given. |
Class Method | from_string | Create a ShaFile from a string. |
Method | raw_length | Returns the length of the raw string of this object. |
Method | sha | The SHA1 object that is the name of this object. |
Method | copy | Create a new copy of this SHA1 object from its raw string |
Method | id | The hex SHA of this object. |
Method | get_type | Return the type number for this object class. |
Method | set_type | Set the type number for this object class. |
Method | __repr__ | Undocumented |
Method | __ne__ | Undocumented |
Method | __eq__ | Return True if the SHAs of the two objects match. |
Method | __lt__ | Undocumented |
Method | __le__ | Undocumented |
Method | __cmp__ | Undocumented |
Static Method | _parse_legacy_object_header | Parse a legacy object, creating it but not reading the file. |
Method | _parse_legacy_object | Parse a legacy object, setting the raw string. |
Static Method | _parse_object_header | Parse a new style object, creating it but not reading the file. |
Method | _parse_object | Parse a new style object, setting self._text. |
Class Method | _is_legacy_object | Undocumented |
Class Method | _parse_file | Undocumented |
Method | _check_has_member | Check that the object has a given member variable. |
Method | _header | Undocumented |
Parameters | name | The name of the entry, as a string. |
value | A tuple of (mode, hexsha), where mode is the mode of the entry as an integral type and hexsha is the hex SHA of the entry as a string. |
Parameters | mode | The mode of the entry as an integral type. Not all possible modes are supported by git; see check() for details. |
name | The name of the entry, as a string. | |
hexsha | The hex SHA of the entry as a string. |
Parameters | name_order | If True, iterate in name order instead of tree order. |
Returns | Iterator over (name, mode, sha) tuples |
Raises | ObjectFormatException | if the object is malformed in some way |