br.com.objectos.git
Class MaterializeCommand
java.lang.Object
br.com.objectos.concurrent.StageComputationTask<V>
br.com.objectos.git.StageGitCommand<Directory>
br.com.objectos.git.MaterializeCommand
- All Implemented Interfaces:
- Computation<Directory>, CpuTask, br.com.objectos.core.object.ToStringObject, GitCommand<Directory>
public final class MaterializeCommand
- extends StageGitCommand<Directory>
A command for materializing a Git repository.
To materialize a specific commit or a specific ref
from a source repository into a target directory means to
recursively create, at the target directory, the tree associated with
the commit.
In other words, this command behaves like a git clone except it does
not copy the whole history of the repository; in fact it will not create the
.git directory at the target directory at all.
- Since:
- 3
| Methods inherited from class br.com.objectos.git.StageGitCommand |
copyObjects, copyTree, executeFinally, materializeEntry, openRepository, readBlob, readCommit, readTree, resolve, submit, submitAsync, toString, updateRef, writeCommit, writeTree |
| Methods inherited from class br.com.objectos.concurrent.StageComputationTask |
addComputation, executeOne, get, getAll, getResult, goTo, hasComputations, isActive, isComputing, reset, setResult |
MaterializeCommand
public MaterializeCommand(Directory source,
ObjectId commit,
Directory target)
- Materializes from the
source repository the specified
commit to the target directory.
- Parameters:
source - the source directory containing the Git repositorycommit - the hash value of the containing pointing to the tree to be
materializedtarget - the target directory
MaterializeCommand
public MaterializeCommand(Directory source,
RefName ref,
Directory target)
- Materializes from the
source repository the specified
ref to the target directory.
- Parameters:
source - the source directory containing the Git repositoryref - the Git reference to be materializedtarget - the target directory
formatToString
public final void formatToString(StringBuilder toString,
int level)
-
- Specified by:
formatToString in interface br.com.objectos.core.object.ToStringObject- Overrides:
formatToString in class StageGitCommand<Directory>
executeStage
protected final void executeStage(int stage)
throws Exception
-
- Specified by:
executeStage in class StageComputationTask<Directory>
- Throws:
Exception
Copyright © 2020–2022 Objectos Software LTDA. All rights reserved.