Modifier and Type | Class and Description |
---|---|
static class |
GrpcProtocol.GrpcDigest
Wrapped Grpc Digest.
|
static class |
GrpcProtocol.GrpcOutputDirectory
Wrapped Grpc OutputDirectory.
|
static class |
GrpcProtocol.GrpcOutputFile
Wrapped Grpc OutputFile.
|
Protocol.Action, Protocol.Command, Protocol.Digest, Protocol.Directory, Protocol.DirectoryNode, Protocol.FileNode, Protocol.OutputDirectory, Protocol.OutputFile, Protocol.SymlinkNode, Protocol.Tree, Protocol.TreeNode
Constructor and Description |
---|
GrpcProtocol() |
public Protocol.Command parseCommand(ByteBuffer data) throws IOException
parseCommand
in interface Protocol
IOException
public Protocol.Action parseAction(ByteBuffer data) throws IOException
parseAction
in interface Protocol
IOException
public Protocol.Directory parseDirectory(ByteBuffer data) throws IOException
parseDirectory
in interface Protocol
IOException
public Protocol.Tree parseTree(ByteBuffer data) throws IOException
parseTree
in interface Protocol
IOException
public Protocol.Digest computeDigest(Protocol.Directory directory)
computeDigest
in interface Protocol
public Protocol.Command newCommand(com.google.common.collect.ImmutableList<String> command, com.google.common.collect.ImmutableSortedMap<String,String> commandEnvironment, Set<Path> outputs, com.facebook.buck.remoteexecution.proto.WorkerRequirements workerRequirements)
newCommand
in interface Protocol
public Protocol.Action newAction(Protocol.Digest commandDigest, Protocol.Digest inputRootDigest)
public Protocol.SymlinkNode newSymlinkNode(String name, Path target)
newSymlinkNode
in interface Protocol
public Protocol.OutputDirectory newOutputDirectory(Path output, Protocol.Digest treeDigest)
newOutputDirectory
in interface Protocol
public Protocol.Tree newTree(Protocol.Directory directory, List<Protocol.Directory> directories)
public Protocol.DirectoryNode newDirectoryNode(String name, Protocol.Digest digest)
newDirectoryNode
in interface Protocol
public Protocol.Directory newDirectory(List<Protocol.DirectoryNode> directories, Collection<Protocol.FileNode> files, Collection<Protocol.SymlinkNode> symlinks)
newDirectory
in interface Protocol
public Protocol.Digest newDigest(String hash, int size)
public Protocol.OutputFile newOutputFile(Path output, Protocol.Digest digest, boolean isExecutable)
newOutputFile
in interface Protocol
public Protocol.FileNode newFileNode(Protocol.Digest digest, String name, boolean isExecutable)
newFileNode
in interface Protocol
public byte[] toByteArray(Protocol.Directory directory)
toByteArray
in interface Protocol
public byte[] toByteArray(Protocol.Tree tree)
toByteArray
in interface Protocol
public byte[] toByteArray(Protocol.Command actionCommand)
toByteArray
in interface Protocol
public byte[] toByteArray(Protocol.Action action)
toByteArray
in interface Protocol
public Protocol.Digest computeDigest(byte[] data)
computeDigest
in interface Protocol
public com.google.common.hash.HashFunction getHashFunction()
getHashFunction
in interface Protocol
public MessageDigest getMessageDigest()
getMessageDigest
in interface Protocol
public static build.bazel.remote.execution.v2.Digest get(Protocol.Digest blob)
public static build.bazel.remote.execution.v2.OutputFile get(Protocol.OutputFile outputFile)
public static build.bazel.remote.execution.v2.OutputDirectory get(Protocol.OutputDirectory outputDirectory)
public static build.bazel.remote.execution.v2.Directory get(Protocol.Directory directory)