|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectbr.com.objectos.git.MutableTree
public final class MutableTree
A class for creating a Git tree hierarchy suitable for recursively writing to a repository.
| Constructor Summary | |
|---|---|
MutableTree()
Creates an unnamed MutableTree instance. |
|
MutableTree(String name)
Creates a MutableTree instance having the specified name. |
|
| Method Summary | |
|---|---|
void |
addEntry(Entry entry)
Adds the specified entry to this mutable tree. |
void |
addEntry(MutableBlob blob)
Adds the specified blob to this mutable tree. |
void |
addEntry(MutableTree tree)
Adds the specified tree to this mutable tree. |
void |
clear()
Removes all of the entries from this tree. |
void |
formatToString(StringBuilder sb,
int depth)
|
EntryMode |
getMode()
Returns the file mode of this tree entry. |
String |
getName()
Returns the name of this tree entry. |
boolean |
hasName(String name)
Returns true if this tree entry has the specified name,
false otherwise. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public MutableTree()
MutableTree instance.
public MutableTree(String name)
MutableTree instance having the specified name.
name - the name of this tree when serving as a tree entry
IllegalArgumentException - if name is an empty string| Method Detail |
|---|
public final void addEntry(Entry entry)
entry - the entry to be addedpublic final void addEntry(MutableBlob blob)
blob - the blob to be addedpublic final void addEntry(MutableTree tree)
tree - the tree to be addedpublic final void clear()
public final void formatToString(StringBuilder sb,
int depth)
public final EntryMode getMode()
public final String getName()
public final boolean hasName(String name)
true if this tree entry has the specified name,
false otherwise.
name - the value to test this entry's name against
true if this tree entry has the specified name,
false otherwisepublic final String toString()
toString in class Object
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||