Update bdledger-apis
This commit is contained in:
parent
c7889c1874
commit
05f61ab984
7
.gitmodules
vendored
7
.gitmodules
vendored
@ -1,4 +1,3 @@
|
|||||||
[submodule "src/main/proto"]
|
[submodule "api"]
|
||||||
path = src/main/proto
|
path = api
|
||||||
url = ssh://vcs@phabricator.internetapi.cn/source/bdledger-grpc-api.git
|
url = ssh://vcs@phabricator.internetapi.cn/source/bdledger-apis.git
|
||||||
branch = master
|
|
||||||
|
1
api
Submodule
1
api
Submodule
@ -0,0 +1 @@
|
|||||||
|
Subproject commit 60aed81a2ae79870702595979c3158d19fdbb1c7
|
@ -24,6 +24,15 @@ tasks.withType(JavaCompile) {
|
|||||||
options.encoding = "UTF-8"
|
options.encoding = "UTF-8"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
sourceSets {
|
||||||
|
main {
|
||||||
|
proto {
|
||||||
|
// In addition to the default 'src/main/proto'
|
||||||
|
srcDir 'api/grpc/pb'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
test {
|
test {
|
||||||
useJUnitPlatform()
|
useJUnitPlatform()
|
||||||
// testLogging {
|
// testLogging {
|
||||||
|
File diff suppressed because it is too large
Load Diff
@ -1,190 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/common.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
public interface BlockOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.Block)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 区块的哈希,当区块处于待确认状态时为`null`
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 父区块的哈希
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes parent_hashes = 2;</code>
|
|
||||||
* @return A list containing the parentHashes.
|
|
||||||
*/
|
|
||||||
java.util.List<com.google.protobuf.ByteString> getParentHashesList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 父区块的哈希
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes parent_hashes = 2;</code>
|
|
||||||
* @return The count of parentHashes.
|
|
||||||
*/
|
|
||||||
int getParentHashesCount();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 父区块的哈希
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes parent_hashes = 2;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The parentHashes at the given index.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getParentHashes(int index);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 见证者账户地址
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes witnesses = 3;</code>
|
|
||||||
* @return A list containing the witnesses.
|
|
||||||
*/
|
|
||||||
java.util.List<com.google.protobuf.ByteString> getWitnessesList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 见证者账户地址
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes witnesses = 3;</code>
|
|
||||||
* @return The count of witnesses.
|
|
||||||
*/
|
|
||||||
int getWitnessesCount();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 见证者账户地址
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes witnesses = 3;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The witnesses at the given index.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getWitnesses(int index);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 区块产生时的 UNIX 时间戳,单位为秒
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>int64 timestamp = 4;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
long getTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 区块大小的字节数
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>uint64 size = 5;</code>
|
|
||||||
* @return The size.
|
|
||||||
*/
|
|
||||||
long getSize();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 区块包含的事务数量
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>uint32 transaction_count = 6;</code>
|
|
||||||
* @return The transactionCount.
|
|
||||||
*/
|
|
||||||
int getTransactionCount();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 区块的事务默克尔树根
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes transactions_root = 7;</code>
|
|
||||||
* @return The transactionsRoot.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getTransactionsRoot();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务对象的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 8;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.common.Transaction>
|
|
||||||
getTransactionsList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务对象的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 8;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Transaction getTransactions(int index);
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务对象的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 8;</code>
|
|
||||||
*/
|
|
||||||
int getTransactionsCount();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务对象的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 8;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionsOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务对象的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 8;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.TransactionOrBuilder getTransactionsOrBuilder(
|
|
||||||
int index);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 20字节的交易哈希的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes transaction_hashes = 9;</code>
|
|
||||||
* @return A list containing the transactionHashes.
|
|
||||||
*/
|
|
||||||
java.util.List<com.google.protobuf.ByteString> getTransactionHashesList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 20字节的交易哈希的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes transaction_hashes = 9;</code>
|
|
||||||
* @return The count of transactionHashes.
|
|
||||||
*/
|
|
||||||
int getTransactionHashesCount();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 20字节的交易哈希的数组,或为空
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated bytes transaction_hashes = 9;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The transactionHashes at the given index.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getTransactionHashes(int index);
|
|
||||||
}
|
|
@ -1,73 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/common.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
public final class CommonProto {
|
|
||||||
private CommonProto() {}
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistry registry) {
|
|
||||||
registerAllExtensions(
|
|
||||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
|
||||||
}
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_Transaction_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_Transaction_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_Block_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_Block_fieldAccessorTable;
|
|
||||||
|
|
||||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return descriptor;
|
|
||||||
}
|
|
||||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
descriptor;
|
|
||||||
static {
|
|
||||||
java.lang.String[] descriptorData = {
|
|
||||||
"\n\031bdledger/api/common.proto\022\014bdledger.ap" +
|
|
||||||
"i\"\303\001\n\013Transaction\022\022\n\nblock_hash\030\001 \001(\014\022\r\n" +
|
|
||||||
"\005index\030\002 \001(\r\022\014\n\004hash\030\003 \001(\014\022+\n\004type\030\004 \001(\016" +
|
|
||||||
"2\035.bdledger.api.TransactionType\022\014\n\004from\030" +
|
|
||||||
"\005 \001(\014\022\r\n\005nonce\030\006 \001(\004\022\n\n\002to\030\007 \001(\014\022\014\n\004data" +
|
|
||||||
"\030\010 \001(\014\022\t\n\001v\030\t \001(\014\022\t\n\001r\030\n \001(\014\022\t\n\001s\030\013 \001(\014\"" +
|
|
||||||
"\343\001\n\005Block\022\014\n\004hash\030\001 \001(\014\022\025\n\rparent_hashes" +
|
|
||||||
"\030\002 \003(\014\022\021\n\twitnesses\030\003 \003(\014\022\021\n\ttimestamp\030\004" +
|
|
||||||
" \001(\003\022\014\n\004size\030\005 \001(\004\022\031\n\021transaction_count\030" +
|
|
||||||
"\006 \001(\r\022\031\n\021transactions_root\030\007 \001(\014\022/\n\014tran" +
|
|
||||||
"sactions\030\010 \003(\0132\031.bdledger.api.Transactio" +
|
|
||||||
"n\022\032\n\022transaction_hashes\030\t \003(\014*o\n\017Transac" +
|
|
||||||
"tionType\022\n\n\006RECORD\020\000\022\013\n\007MESSAGE\020\001\022\025\n\021CON" +
|
|
||||||
"TRACT_CREATION\020\002\022\027\n\023CONTRACT_INVOCATION\020" +
|
|
||||||
"\003\022\023\n\017CONTRACT_STATUS\020\004BQ\n\030bdledger.api.g" +
|
|
||||||
"rpc.commonB\013CommonProtoP\001Z&bdware.org/bd" +
|
|
||||||
"ledger/pkg/api/grpc/protob\006proto3"
|
|
||||||
};
|
|
||||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
.internalBuildGeneratedFileFrom(descriptorData,
|
|
||||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
||||||
});
|
|
||||||
internal_static_bdledger_api_Transaction_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(0);
|
|
||||||
internal_static_bdledger_api_Transaction_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_Transaction_descriptor,
|
|
||||||
new java.lang.String[] { "BlockHash", "Index", "Hash", "Type", "From", "Nonce", "To", "Data", "V", "R", "S", });
|
|
||||||
internal_static_bdledger_api_Block_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(1);
|
|
||||||
internal_static_bdledger_api_Block_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_Block_descriptor,
|
|
||||||
new java.lang.String[] { "Hash", "ParentHashes", "Witnesses", "Timestamp", "Size", "TransactionCount", "TransactionsRoot", "Transactions", "TransactionHashes", });
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(outer_class_scope)
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/error_details.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
public final class ErrorDetailsProto {
|
|
||||||
private ErrorDetailsProto() {}
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistry registry) {
|
|
||||||
registerAllExtensions(
|
|
||||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
|
||||||
}
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_InvalidArgument_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_InvalidArgument_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_InvalidArgument_FieldViolation_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_InvalidArgument_FieldViolation_fieldAccessorTable;
|
|
||||||
|
|
||||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return descriptor;
|
|
||||||
}
|
|
||||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
descriptor;
|
|
||||||
static {
|
|
||||||
java.lang.String[] descriptorData = {
|
|
||||||
"\n bdledger/api/error_details.proto\022\014bdle" +
|
|
||||||
"dger.api\"\217\001\n\017InvalidArgument\022F\n\020field_vi" +
|
|
||||||
"olations\030\001 \003(\0132,.bdledger.api.InvalidArg" +
|
|
||||||
"ument.FieldViolation\0324\n\016FieldViolation\022\r" +
|
|
||||||
"\n\005field\030\001 \001(\t\022\023\n\013description\030\002 \001(\tBW\n\030bd" +
|
|
||||||
"ledger.api.grpc.commonB\021ErrorDetailsProt" +
|
|
||||||
"oP\001Z&bdware.org/bdledger/pkg/api/grpc/pr" +
|
|
||||||
"otob\006proto3"
|
|
||||||
};
|
|
||||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
.internalBuildGeneratedFileFrom(descriptorData,
|
|
||||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
||||||
});
|
|
||||||
internal_static_bdledger_api_InvalidArgument_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(0);
|
|
||||||
internal_static_bdledger_api_InvalidArgument_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_InvalidArgument_descriptor,
|
|
||||||
new java.lang.String[] { "FieldViolations", });
|
|
||||||
internal_static_bdledger_api_InvalidArgument_FieldViolation_descriptor =
|
|
||||||
internal_static_bdledger_api_InvalidArgument_descriptor.getNestedTypes().get(0);
|
|
||||||
internal_static_bdledger_api_InvalidArgument_FieldViolation_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_InvalidArgument_FieldViolation_descriptor,
|
|
||||||
new java.lang.String[] { "Field", "Description", });
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(outer_class_scope)
|
|
||||||
}
|
|
File diff suppressed because it is too large
Load Diff
@ -1,53 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/error_details.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
public interface InvalidArgumentOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.InvalidArgument)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* Describes all violations in a client request.
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.InvalidArgument.FieldViolation field_violations = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.common.InvalidArgument.FieldViolation>
|
|
||||||
getFieldViolationsList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* Describes all violations in a client request.
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.InvalidArgument.FieldViolation field_violations = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.InvalidArgument.FieldViolation getFieldViolations(int index);
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* Describes all violations in a client request.
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.InvalidArgument.FieldViolation field_violations = 1;</code>
|
|
||||||
*/
|
|
||||||
int getFieldViolationsCount();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* Describes all violations in a client request.
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.InvalidArgument.FieldViolation field_violations = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.common.InvalidArgument.FieldViolationOrBuilder>
|
|
||||||
getFieldViolationsOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* Describes all violations in a client request.
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>repeated .bdledger.api.InvalidArgument.FieldViolation field_violations = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.InvalidArgument.FieldViolationOrBuilder getFieldViolationsOrBuilder(
|
|
||||||
int index);
|
|
||||||
}
|
|
File diff suppressed because it is too large
Load Diff
@ -1,128 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/common.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
public interface TransactionOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.Transaction)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务所在的区块的哈希,当事务处于待确认状态时为`null`
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes block_hash = 1;</code>
|
|
||||||
* @return The blockHash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getBlockHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务在区块中的位置 index,当事务处于待确认状态时为`null`
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>uint32 index = 2;</code>
|
|
||||||
* @return The index.
|
|
||||||
*/
|
|
||||||
int getIndex();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务的哈希
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes hash = 3;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务类型
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>.bdledger.api.TransactionType type = 4;</code>
|
|
||||||
* @return The enum numeric value on the wire for type.
|
|
||||||
*/
|
|
||||||
int getTypeValue();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务类型
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>.bdledger.api.TransactionType type = 4;</code>
|
|
||||||
* @return The type.
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.TransactionType getType();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 发送账户地址
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes from = 5;</code>
|
|
||||||
* @return The from.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getFrom();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 这条事务之前发送者所发送的事务数量
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>uint64 nonce = 6;</code>
|
|
||||||
* @return The nonce.
|
|
||||||
*/
|
|
||||||
long getNonce();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 接收账户地址,或者调用的合约地址,或者`null`如为合约创建
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes to = 7;</code>
|
|
||||||
* @return The to.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getTo();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 数据或合约代码
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes data = 8;</code>
|
|
||||||
* @return The data.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getData();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* ECDSA recovery id
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes v = 9;</code>
|
|
||||||
* @return The v.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getV();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* ECDSA signature r
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes r = 10;</code>
|
|
||||||
* @return The r.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getR();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* ECDSA signature s
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>bytes s = 11;</code>
|
|
||||||
* @return The s.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getS();
|
|
||||||
}
|
|
@ -1,180 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/common.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.common;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 事务类型
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* Protobuf enum {@code bdledger.api.TransactionType}
|
|
||||||
*/
|
|
||||||
public enum TransactionType
|
|
||||||
implements com.google.protobuf.ProtocolMessageEnum {
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 通用数据记录
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>RECORD = 0;</code>
|
|
||||||
*/
|
|
||||||
RECORD(0),
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 消息
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>MESSAGE = 1;</code>
|
|
||||||
*/
|
|
||||||
MESSAGE(1),
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约创建
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_CREATION = 2;</code>
|
|
||||||
*/
|
|
||||||
CONTRACT_CREATION(2),
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约调用
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_INVOCATION = 3;</code>
|
|
||||||
*/
|
|
||||||
CONTRACT_INVOCATION(3),
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约状态
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_STATUS = 4;</code>
|
|
||||||
*/
|
|
||||||
CONTRACT_STATUS(4),
|
|
||||||
UNRECOGNIZED(-1),
|
|
||||||
;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 通用数据记录
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>RECORD = 0;</code>
|
|
||||||
*/
|
|
||||||
public static final int RECORD_VALUE = 0;
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 消息
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>MESSAGE = 1;</code>
|
|
||||||
*/
|
|
||||||
public static final int MESSAGE_VALUE = 1;
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约创建
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_CREATION = 2;</code>
|
|
||||||
*/
|
|
||||||
public static final int CONTRACT_CREATION_VALUE = 2;
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约调用
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_INVOCATION = 3;</code>
|
|
||||||
*/
|
|
||||||
public static final int CONTRACT_INVOCATION_VALUE = 3;
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 合约状态
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>CONTRACT_STATUS = 4;</code>
|
|
||||||
*/
|
|
||||||
public static final int CONTRACT_STATUS_VALUE = 4;
|
|
||||||
|
|
||||||
|
|
||||||
public final int getNumber() {
|
|
||||||
if (this == UNRECOGNIZED) {
|
|
||||||
throw new java.lang.IllegalArgumentException(
|
|
||||||
"Can't get the number of an unknown enum value.");
|
|
||||||
}
|
|
||||||
return value;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param value The numeric wire value of the corresponding enum entry.
|
|
||||||
* @return The enum associated with the given numeric wire value.
|
|
||||||
* @deprecated Use {@link #forNumber(int)} instead.
|
|
||||||
*/
|
|
||||||
@java.lang.Deprecated
|
|
||||||
public static TransactionType valueOf(int value) {
|
|
||||||
return forNumber(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param value The numeric wire value of the corresponding enum entry.
|
|
||||||
* @return The enum associated with the given numeric wire value.
|
|
||||||
*/
|
|
||||||
public static TransactionType forNumber(int value) {
|
|
||||||
switch (value) {
|
|
||||||
case 0: return RECORD;
|
|
||||||
case 1: return MESSAGE;
|
|
||||||
case 2: return CONTRACT_CREATION;
|
|
||||||
case 3: return CONTRACT_INVOCATION;
|
|
||||||
case 4: return CONTRACT_STATUS;
|
|
||||||
default: return null;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static com.google.protobuf.Internal.EnumLiteMap<TransactionType>
|
|
||||||
internalGetValueMap() {
|
|
||||||
return internalValueMap;
|
|
||||||
}
|
|
||||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
|
||||||
TransactionType> internalValueMap =
|
|
||||||
new com.google.protobuf.Internal.EnumLiteMap<TransactionType>() {
|
|
||||||
public TransactionType findValueByNumber(int number) {
|
|
||||||
return TransactionType.forNumber(number);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
|
||||||
getValueDescriptor() {
|
|
||||||
return getDescriptor().getValues().get(ordinal());
|
|
||||||
}
|
|
||||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return getDescriptor();
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.common.CommonProto.getDescriptor().getEnumTypes().get(0);
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final TransactionType[] VALUES = values();
|
|
||||||
|
|
||||||
public static TransactionType valueOf(
|
|
||||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
|
||||||
if (desc.getType() != getDescriptor()) {
|
|
||||||
throw new java.lang.IllegalArgumentException(
|
|
||||||
"EnumValueDescriptor is not for this type.");
|
|
||||||
}
|
|
||||||
if (desc.getIndex() == -1) {
|
|
||||||
return UNRECOGNIZED;
|
|
||||||
}
|
|
||||||
return VALUES[desc.getIndex()];
|
|
||||||
}
|
|
||||||
|
|
||||||
private final int value;
|
|
||||||
|
|
||||||
private TransactionType(int value) {
|
|
||||||
this.value = value;
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(enum_scope:bdledger.api.TransactionType)
|
|
||||||
}
|
|
||||||
|
|
@ -1,555 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CreateLedgerRequest}
|
|
||||||
*/
|
|
||||||
public final class CreateLedgerRequest extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.CreateLedgerRequest)
|
|
||||||
CreateLedgerRequestOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use CreateLedgerRequest.newBuilder() to construct.
|
|
||||||
private CreateLedgerRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private CreateLedgerRequest() {
|
|
||||||
name_ = "";
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new CreateLedgerRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private CreateLedgerRequest(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
|
|
||||||
name_ = s;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest.class, bdledger.api.grpc.ledger.CreateLedgerRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int NAME_FIELD_NUMBER = 1;
|
|
||||||
private volatile java.lang.Object name_;
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The name.
|
|
||||||
*/
|
|
||||||
public java.lang.String getName() {
|
|
||||||
java.lang.Object ref = name_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
} else {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
name_ = s;
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The bytes for name.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getNameBytes() {
|
|
||||||
java.lang.Object ref = name_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
name_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!getNameBytes().isEmpty()) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!getNameBytes().isEmpty()) {
|
|
||||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.ledger.CreateLedgerRequest)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest other = (bdledger.api.grpc.ledger.CreateLedgerRequest) obj;
|
|
||||||
|
|
||||||
if (!getName()
|
|
||||||
.equals(other.getName())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + NAME_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getName().hashCode();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.ledger.CreateLedgerRequest prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CreateLedgerRequest}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.CreateLedgerRequest)
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequestOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest.class, bdledger.api.grpc.ledger.CreateLedgerRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.ledger.CreateLedgerRequest.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
name_ = "";
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerRequest getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.ledger.CreateLedgerRequest.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerRequest build() {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerRequest buildPartial() {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest result = new bdledger.api.grpc.ledger.CreateLedgerRequest(this);
|
|
||||||
result.name_ = name_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.ledger.CreateLedgerRequest) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.ledger.CreateLedgerRequest)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.ledger.CreateLedgerRequest other) {
|
|
||||||
if (other == bdledger.api.grpc.ledger.CreateLedgerRequest.getDefaultInstance()) return this;
|
|
||||||
if (!other.getName().isEmpty()) {
|
|
||||||
name_ = other.name_;
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.ledger.CreateLedgerRequest) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private java.lang.Object name_ = "";
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The name.
|
|
||||||
*/
|
|
||||||
public java.lang.String getName() {
|
|
||||||
java.lang.Object ref = name_;
|
|
||||||
if (!(ref instanceof java.lang.String)) {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
name_ = s;
|
|
||||||
return s;
|
|
||||||
} else {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The bytes for name.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getNameBytes() {
|
|
||||||
java.lang.Object ref = name_;
|
|
||||||
if (ref instanceof String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
name_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @param value The name to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setName(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
name_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearName() {
|
|
||||||
|
|
||||||
name_ = getDefaultInstance().getName();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @param value The bytes for name to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setNameBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
|
|
||||||
name_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.CreateLedgerRequest)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.CreateLedgerRequest)
|
|
||||||
private static final bdledger.api.grpc.ledger.CreateLedgerRequest DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.ledger.CreateLedgerRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerRequest getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<CreateLedgerRequest>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<CreateLedgerRequest>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public CreateLedgerRequest parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new CreateLedgerRequest(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<CreateLedgerRequest> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<CreateLedgerRequest> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerRequest getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,21 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public interface CreateLedgerRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.CreateLedgerRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The name.
|
|
||||||
*/
|
|
||||||
java.lang.String getName();
|
|
||||||
/**
|
|
||||||
* <code>string name = 1;</code>
|
|
||||||
* @return The bytes for name.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getNameBytes();
|
|
||||||
}
|
|
@ -1,482 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CreateLedgerResponse}
|
|
||||||
*/
|
|
||||||
public final class CreateLedgerResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.CreateLedgerResponse)
|
|
||||||
CreateLedgerResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use CreateLedgerResponse.newBuilder() to construct.
|
|
||||||
private CreateLedgerResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private CreateLedgerResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new CreateLedgerResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private CreateLedgerResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 8: {
|
|
||||||
|
|
||||||
ok_ = input.readBool();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse.class, bdledger.api.grpc.ledger.CreateLedgerResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int OK_FIELD_NUMBER = 1;
|
|
||||||
private boolean ok_;
|
|
||||||
/**
|
|
||||||
* <code>bool ok = 1;</code>
|
|
||||||
* @return The ok.
|
|
||||||
*/
|
|
||||||
public boolean getOk() {
|
|
||||||
return ok_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (ok_ != false) {
|
|
||||||
output.writeBool(1, ok_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (ok_ != false) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBoolSize(1, ok_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.ledger.CreateLedgerResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse other = (bdledger.api.grpc.ledger.CreateLedgerResponse) obj;
|
|
||||||
|
|
||||||
if (getOk()
|
|
||||||
!= other.getOk()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + OK_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
|
|
||||||
getOk());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.ledger.CreateLedgerResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CreateLedgerResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.CreateLedgerResponse)
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse.class, bdledger.api.grpc.ledger.CreateLedgerResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.ledger.CreateLedgerResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
ok_ = false;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_CreateLedgerResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.ledger.CreateLedgerResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerResponse build() {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse result = new bdledger.api.grpc.ledger.CreateLedgerResponse(this);
|
|
||||||
result.ok_ = ok_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.ledger.CreateLedgerResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.ledger.CreateLedgerResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.ledger.CreateLedgerResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.ledger.CreateLedgerResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.getOk() != false) {
|
|
||||||
setOk(other.getOk());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.ledger.CreateLedgerResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean ok_ ;
|
|
||||||
/**
|
|
||||||
* <code>bool ok = 1;</code>
|
|
||||||
* @return The ok.
|
|
||||||
*/
|
|
||||||
public boolean getOk() {
|
|
||||||
return ok_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bool ok = 1;</code>
|
|
||||||
* @param value The ok to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setOk(boolean value) {
|
|
||||||
|
|
||||||
ok_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bool ok = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearOk() {
|
|
||||||
|
|
||||||
ok_ = false;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.CreateLedgerResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.CreateLedgerResponse)
|
|
||||||
private static final bdledger.api.grpc.ledger.CreateLedgerResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.ledger.CreateLedgerResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.CreateLedgerResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<CreateLedgerResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<CreateLedgerResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public CreateLedgerResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new CreateLedgerResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<CreateLedgerResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<CreateLedgerResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public interface CreateLedgerResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.CreateLedgerResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bool ok = 1;</code>
|
|
||||||
* @return The ok.
|
|
||||||
*/
|
|
||||||
boolean getOk();
|
|
||||||
}
|
|
@ -1,614 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetLedgersResponse}
|
|
||||||
*/
|
|
||||||
public final class GetLedgersResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetLedgersResponse)
|
|
||||||
GetLedgersResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetLedgersResponse.newBuilder() to construct.
|
|
||||||
private GetLedgersResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetLedgersResponse() {
|
|
||||||
ledgers_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetLedgersResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetLedgersResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
int mutable_bitField0_ = 0;
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
ledgers_ = new com.google.protobuf.LazyStringArrayList();
|
|
||||||
mutable_bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
ledgers_.add(s);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
if (((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
ledgers_ = ledgers_.getUnmodifiableView();
|
|
||||||
}
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_GetLedgersResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_GetLedgersResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse.class, bdledger.api.grpc.ledger.GetLedgersResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int LEDGERS_FIELD_NUMBER = 1;
|
|
||||||
private com.google.protobuf.LazyStringList ledgers_;
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return A list containing the ledgers.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ProtocolStringList
|
|
||||||
getLedgersList() {
|
|
||||||
return ledgers_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return The count of ledgers.
|
|
||||||
*/
|
|
||||||
public int getLedgersCount() {
|
|
||||||
return ledgers_.size();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The ledgers at the given index.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedgers(int index) {
|
|
||||||
return ledgers_.get(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the value to return.
|
|
||||||
* @return The bytes of the ledgers at the given index.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgersBytes(int index) {
|
|
||||||
return ledgers_.getByteString(index);
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
for (int i = 0; i < ledgers_.size(); i++) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, ledgers_.getRaw(i));
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
{
|
|
||||||
int dataSize = 0;
|
|
||||||
for (int i = 0; i < ledgers_.size(); i++) {
|
|
||||||
dataSize += computeStringSizeNoTag(ledgers_.getRaw(i));
|
|
||||||
}
|
|
||||||
size += dataSize;
|
|
||||||
size += 1 * getLedgersList().size();
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.ledger.GetLedgersResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse other = (bdledger.api.grpc.ledger.GetLedgersResponse) obj;
|
|
||||||
|
|
||||||
if (!getLedgersList()
|
|
||||||
.equals(other.getLedgersList())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (getLedgersCount() > 0) {
|
|
||||||
hash = (37 * hash) + LEDGERS_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getLedgersList().hashCode();
|
|
||||||
}
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.ledger.GetLedgersResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetLedgersResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetLedgersResponse)
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_GetLedgersResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_GetLedgersResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse.class, bdledger.api.grpc.ledger.GetLedgersResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.ledger.GetLedgersResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
ledgers_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_GetLedgersResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.GetLedgersResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.ledger.GetLedgersResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.GetLedgersResponse build() {
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.GetLedgersResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse result = new bdledger.api.grpc.ledger.GetLedgersResponse(this);
|
|
||||||
int from_bitField0_ = bitField0_;
|
|
||||||
if (((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
ledgers_ = ledgers_.getUnmodifiableView();
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
}
|
|
||||||
result.ledgers_ = ledgers_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.ledger.GetLedgersResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.ledger.GetLedgersResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.ledger.GetLedgersResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.ledger.GetLedgersResponse.getDefaultInstance()) return this;
|
|
||||||
if (!other.ledgers_.isEmpty()) {
|
|
||||||
if (ledgers_.isEmpty()) {
|
|
||||||
ledgers_ = other.ledgers_;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
} else {
|
|
||||||
ensureLedgersIsMutable();
|
|
||||||
ledgers_.addAll(other.ledgers_);
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.ledger.GetLedgersResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
private int bitField0_;
|
|
||||||
|
|
||||||
private com.google.protobuf.LazyStringList ledgers_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
|
||||||
private void ensureLedgersIsMutable() {
|
|
||||||
if (!((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
ledgers_ = new com.google.protobuf.LazyStringArrayList(ledgers_);
|
|
||||||
bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return A list containing the ledgers.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ProtocolStringList
|
|
||||||
getLedgersList() {
|
|
||||||
return ledgers_.getUnmodifiableView();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return The count of ledgers.
|
|
||||||
*/
|
|
||||||
public int getLedgersCount() {
|
|
||||||
return ledgers_.size();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The ledgers at the given index.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedgers(int index) {
|
|
||||||
return ledgers_.get(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the value to return.
|
|
||||||
* @return The bytes of the ledgers at the given index.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgersBytes(int index) {
|
|
||||||
return ledgers_.getByteString(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index to set the value at.
|
|
||||||
* @param value The ledgers to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedgers(
|
|
||||||
int index, java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureLedgersIsMutable();
|
|
||||||
ledgers_.set(index, value);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param value The ledgers to add.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder addLedgers(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureLedgersIsMutable();
|
|
||||||
ledgers_.add(value);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param values The ledgers to add.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder addAllLedgers(
|
|
||||||
java.lang.Iterable<java.lang.String> values) {
|
|
||||||
ensureLedgersIsMutable();
|
|
||||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
|
||||||
values, ledgers_);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearLedgers() {
|
|
||||||
ledgers_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param value The bytes of the ledgers to add.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder addLedgersBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
ensureLedgersIsMutable();
|
|
||||||
ledgers_.add(value);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetLedgersResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetLedgersResponse)
|
|
||||||
private static final bdledger.api.grpc.ledger.GetLedgersResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.ledger.GetLedgersResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.GetLedgersResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetLedgersResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetLedgersResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetLedgersResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetLedgersResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetLedgersResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetLedgersResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.GetLedgersResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,34 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public interface GetLedgersResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetLedgersResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return A list containing the ledgers.
|
|
||||||
*/
|
|
||||||
java.util.List<java.lang.String>
|
|
||||||
getLedgersList();
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @return The count of ledgers.
|
|
||||||
*/
|
|
||||||
int getLedgersCount();
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the element to return.
|
|
||||||
* @return The ledgers at the given index.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedgers(int index);
|
|
||||||
/**
|
|
||||||
* <code>repeated string ledgers = 1;</code>
|
|
||||||
* @param index The index of the value to return.
|
|
||||||
* @return The bytes of the ledgers at the given index.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgersBytes(int index);
|
|
||||||
}
|
|
@ -1,125 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public final class LedgerProto {
|
|
||||||
private LedgerProto() {}
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistry registry) {
|
|
||||||
registerAllExtensions(
|
|
||||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
|
||||||
}
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_CreateLedgerRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_CreateLedgerRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_CreateLedgerResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_CreateLedgerResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetLedgersResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetLedgersResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_Transaction_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_Transaction_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_SendTransactionResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_SendTransactionResponse_fieldAccessorTable;
|
|
||||||
|
|
||||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return descriptor;
|
|
||||||
}
|
|
||||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
descriptor;
|
|
||||||
static {
|
|
||||||
java.lang.String[] descriptorData = {
|
|
||||||
"\n\031bdledger/api/ledger.proto\022\014bdledger.ap" +
|
|
||||||
"i\032\033google/protobuf/empty.proto\032\031bdledger" +
|
|
||||||
"/api/common.proto\"#\n\023CreateLedgerRequest" +
|
|
||||||
"\022\014\n\004name\030\001 \001(\t\"\"\n\024CreateLedgerResponse\022\n" +
|
|
||||||
"\n\002ok\030\001 \001(\010\"%\n\022GetLedgersResponse\022\017\n\007ledg" +
|
|
||||||
"ers\030\001 \003(\t\"\323\001\n\026SendTransactionRequest\022\016\n\006" +
|
|
||||||
"ledger\030\001 \001(\t\022E\n\013transaction\030\002 \001(\01320.bdle" +
|
|
||||||
"dger.api.SendTransactionRequest.Transact" +
|
|
||||||
"ion\032b\n\013Transaction\022+\n\004type\030\001 \001(\0162\035.bdled" +
|
|
||||||
"ger.api.TransactionType\022\014\n\004from\030\002 \001(\014\022\n\n" +
|
|
||||||
"\002to\030\003 \001(\014\022\014\n\004data\030\004 \001(\014\"\'\n\027SendTransacti" +
|
|
||||||
"onResponse\022\014\n\004hash\030\001 \001(\0142\207\002\n\006Ledger\022U\n\014C" +
|
|
||||||
"reateLedger\022!.bdledger.api.CreateLedgerR" +
|
|
||||||
"equest\032\".bdledger.api.CreateLedgerRespon" +
|
|
||||||
"se\022F\n\nGetLedgers\022\026.google.protobuf.Empty" +
|
|
||||||
"\032 .bdledger.api.GetLedgersResponse\022^\n\017Se" +
|
|
||||||
"ndTransaction\022$.bdledger.api.SendTransac" +
|
|
||||||
"tionRequest\032%.bdledger.api.SendTransacti" +
|
|
||||||
"onResponseBQ\n\030bdledger.api.grpc.ledgerB\013" +
|
|
||||||
"LedgerProtoP\001Z&bdware.org/bdledger/pkg/a" +
|
|
||||||
"pi/grpc/protob\006proto3"
|
|
||||||
};
|
|
||||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
.internalBuildGeneratedFileFrom(descriptorData,
|
|
||||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
||||||
com.google.protobuf.EmptyProto.getDescriptor(),
|
|
||||||
bdledger.api.grpc.common.CommonProto.getDescriptor(),
|
|
||||||
});
|
|
||||||
internal_static_bdledger_api_CreateLedgerRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(0);
|
|
||||||
internal_static_bdledger_api_CreateLedgerRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_CreateLedgerRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Name", });
|
|
||||||
internal_static_bdledger_api_CreateLedgerResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(1);
|
|
||||||
internal_static_bdledger_api_CreateLedgerResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_CreateLedgerResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Ok", });
|
|
||||||
internal_static_bdledger_api_GetLedgersResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(2);
|
|
||||||
internal_static_bdledger_api_GetLedgersResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetLedgersResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Ledgers", });
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(3);
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "Transaction", });
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_Transaction_descriptor =
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_descriptor.getNestedTypes().get(0);
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_Transaction_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_SendTransactionRequest_Transaction_descriptor,
|
|
||||||
new java.lang.String[] { "Type", "From", "To", "Data", });
|
|
||||||
internal_static_bdledger_api_SendTransactionResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(4);
|
|
||||||
internal_static_bdledger_api_SendTransactionResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_SendTransactionResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Hash", });
|
|
||||||
com.google.protobuf.EmptyProto.getDescriptor();
|
|
||||||
bdledger.api.grpc.common.CommonProto.getDescriptor();
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(outer_class_scope)
|
|
||||||
}
|
|
File diff suppressed because it is too large
Load Diff
@ -1,36 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public interface SendTransactionRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.SendTransactionRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
boolean hasTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionRequest.Transaction getTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.SendTransactionRequest.Transaction transaction = 2;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionRequest.TransactionOrBuilder getTransactionOrBuilder();
|
|
||||||
}
|
|
@ -1,485 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.SendTransactionResponse}
|
|
||||||
*/
|
|
||||||
public final class SendTransactionResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.SendTransactionResponse)
|
|
||||||
SendTransactionResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use SendTransactionResponse.newBuilder() to construct.
|
|
||||||
private SendTransactionResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private SendTransactionResponse() {
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new SendTransactionResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private SendTransactionResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
|
|
||||||
hash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_SendTransactionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_SendTransactionResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse.class, bdledger.api.grpc.ledger.SendTransactionResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int HASH_FIELD_NUMBER = 1;
|
|
||||||
private com.google.protobuf.ByteString hash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
output.writeBytes(1, hash_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(1, hash_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.ledger.SendTransactionResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse other = (bdledger.api.grpc.ledger.SendTransactionResponse) obj;
|
|
||||||
|
|
||||||
if (!getHash()
|
|
||||||
.equals(other.getHash())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getHash().hashCode();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.ledger.SendTransactionResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.SendTransactionResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.SendTransactionResponse)
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_SendTransactionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_SendTransactionResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse.class, bdledger.api.grpc.ledger.SendTransactionResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.ledger.SendTransactionResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.internal_static_bdledger_api_SendTransactionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.SendTransactionResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.ledger.SendTransactionResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.SendTransactionResponse build() {
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.SendTransactionResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse result = new bdledger.api.grpc.ledger.SendTransactionResponse(this);
|
|
||||||
result.hash_ = hash_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.ledger.SendTransactionResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.ledger.SendTransactionResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.ledger.SendTransactionResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.ledger.SendTransactionResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.getHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setHash(other.getHash());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.ledger.SendTransactionResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @param value The hash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
hash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearHash() {
|
|
||||||
|
|
||||||
hash_ = getDefaultInstance().getHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.SendTransactionResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.SendTransactionResponse)
|
|
||||||
private static final bdledger.api.grpc.ledger.SendTransactionResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.ledger.SendTransactionResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.ledger.SendTransactionResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<SendTransactionResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<SendTransactionResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public SendTransactionResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new SendTransactionResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<SendTransactionResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<SendTransactionResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.ledger.SendTransactionResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/ledger.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.ledger;
|
|
||||||
|
|
||||||
public interface SendTransactionResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.SendTransactionResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
}
|
|
@ -1,583 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/node.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.node;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.ClientVersionResponse}
|
|
||||||
*/
|
|
||||||
public final class ClientVersionResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.ClientVersionResponse)
|
|
||||||
ClientVersionResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use ClientVersionResponse.newBuilder() to construct.
|
|
||||||
private ClientVersionResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private ClientVersionResponse() {
|
|
||||||
version_ = "";
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new ClientVersionResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private ClientVersionResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
|
|
||||||
version_ = s;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.node.NodeProto.internal_static_bdledger_api_ClientVersionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.node.NodeProto.internal_static_bdledger_api_ClientVersionResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse.class, bdledger.api.grpc.node.ClientVersionResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int VERSION_FIELD_NUMBER = 1;
|
|
||||||
private volatile java.lang.Object version_;
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The version.
|
|
||||||
*/
|
|
||||||
public java.lang.String getVersion() {
|
|
||||||
java.lang.Object ref = version_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
} else {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
version_ = s;
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The bytes for version.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getVersionBytes() {
|
|
||||||
java.lang.Object ref = version_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
version_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!getVersionBytes().isEmpty()) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!getVersionBytes().isEmpty()) {
|
|
||||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.node.ClientVersionResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse other = (bdledger.api.grpc.node.ClientVersionResponse) obj;
|
|
||||||
|
|
||||||
if (!getVersion()
|
|
||||||
.equals(other.getVersion())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + VERSION_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getVersion().hashCode();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.node.ClientVersionResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.ClientVersionResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.ClientVersionResponse)
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.node.NodeProto.internal_static_bdledger_api_ClientVersionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.node.NodeProto.internal_static_bdledger_api_ClientVersionResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse.class, bdledger.api.grpc.node.ClientVersionResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.node.ClientVersionResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
version_ = "";
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.node.NodeProto.internal_static_bdledger_api_ClientVersionResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.node.ClientVersionResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.node.ClientVersionResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.node.ClientVersionResponse build() {
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.node.ClientVersionResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse result = new bdledger.api.grpc.node.ClientVersionResponse(this);
|
|
||||||
result.version_ = version_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.node.ClientVersionResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.node.ClientVersionResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.node.ClientVersionResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.node.ClientVersionResponse.getDefaultInstance()) return this;
|
|
||||||
if (!other.getVersion().isEmpty()) {
|
|
||||||
version_ = other.version_;
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.node.ClientVersionResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.node.ClientVersionResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private java.lang.Object version_ = "";
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The version.
|
|
||||||
*/
|
|
||||||
public java.lang.String getVersion() {
|
|
||||||
java.lang.Object ref = version_;
|
|
||||||
if (!(ref instanceof java.lang.String)) {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
version_ = s;
|
|
||||||
return s;
|
|
||||||
} else {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The bytes for version.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getVersionBytes() {
|
|
||||||
java.lang.Object ref = version_;
|
|
||||||
if (ref instanceof String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
version_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @param value The version to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setVersion(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
version_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearVersion() {
|
|
||||||
|
|
||||||
version_ = getDefaultInstance().getVersion();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @param value The bytes for version to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setVersionBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
|
|
||||||
version_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.ClientVersionResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.ClientVersionResponse)
|
|
||||||
private static final bdledger.api.grpc.node.ClientVersionResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.node.ClientVersionResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.node.ClientVersionResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<ClientVersionResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<ClientVersionResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public ClientVersionResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new ClientVersionResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<ClientVersionResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<ClientVersionResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.node.ClientVersionResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,29 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/node.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.node;
|
|
||||||
|
|
||||||
public interface ClientVersionResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.ClientVersionResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The version.
|
|
||||||
*/
|
|
||||||
java.lang.String getVersion();
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* 节点客户端版本
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>string version = 1;</code>
|
|
||||||
* @return The bytes for version.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getVersionBytes();
|
|
||||||
}
|
|
@ -1,55 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/node.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.node;
|
|
||||||
|
|
||||||
public final class NodeProto {
|
|
||||||
private NodeProto() {}
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistry registry) {
|
|
||||||
registerAllExtensions(
|
|
||||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
|
||||||
}
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_ClientVersionResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_ClientVersionResponse_fieldAccessorTable;
|
|
||||||
|
|
||||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return descriptor;
|
|
||||||
}
|
|
||||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
descriptor;
|
|
||||||
static {
|
|
||||||
java.lang.String[] descriptorData = {
|
|
||||||
"\n\027bdledger/api/node.proto\022\014bdledger.api\032" +
|
|
||||||
"\033google/protobuf/empty.proto\"(\n\025ClientVe" +
|
|
||||||
"rsionResponse\022\017\n\007version\030\001 \001(\t2T\n\004Node\022L" +
|
|
||||||
"\n\rClientVersion\022\026.google.protobuf.Empty\032" +
|
|
||||||
"#.bdledger.api.ClientVersionResponseBM\n\026" +
|
|
||||||
"bdledger.api.grpc.nodeB\tNodeProtoP\001Z&bdw" +
|
|
||||||
"are.org/bdledger/pkg/api/grpc/protob\006pro" +
|
|
||||||
"to3"
|
|
||||||
};
|
|
||||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
.internalBuildGeneratedFileFrom(descriptorData,
|
|
||||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
||||||
com.google.protobuf.EmptyProto.getDescriptor(),
|
|
||||||
});
|
|
||||||
internal_static_bdledger_api_ClientVersionResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(0);
|
|
||||||
internal_static_bdledger_api_ClientVersionResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_ClientVersionResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Version", });
|
|
||||||
com.google.protobuf.EmptyProto.getDescriptor();
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(outer_class_scope)
|
|
||||||
}
|
|
@ -1,548 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.BlockFilter}
|
|
||||||
*/
|
|
||||||
public final class BlockFilter extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.BlockFilter)
|
|
||||||
BlockFilterOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use BlockFilter.newBuilder() to construct.
|
|
||||||
private BlockFilter(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private BlockFilter() {
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new BlockFilter();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private BlockFilter(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
|
|
||||||
hash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 16: {
|
|
||||||
|
|
||||||
timestamp_ = input.readInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_BlockFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_BlockFilter_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.BlockFilter.class, bdledger.api.grpc.query.BlockFilter.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int HASH_FIELD_NUMBER = 1;
|
|
||||||
private com.google.protobuf.ByteString hash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TIMESTAMP_FIELD_NUMBER = 2;
|
|
||||||
private long timestamp_;
|
|
||||||
/**
|
|
||||||
* <code>int64 timestamp = 2;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
public long getTimestamp() {
|
|
||||||
return timestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
output.writeBytes(1, hash_);
|
|
||||||
}
|
|
||||||
if (timestamp_ != 0L) {
|
|
||||||
output.writeInt64(2, timestamp_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(1, hash_);
|
|
||||||
}
|
|
||||||
if (timestamp_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeInt64Size(2, timestamp_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.BlockFilter)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.BlockFilter other = (bdledger.api.grpc.query.BlockFilter) obj;
|
|
||||||
|
|
||||||
if (!getHash()
|
|
||||||
.equals(other.getHash())) return false;
|
|
||||||
if (getTimestamp()
|
|
||||||
!= other.getTimestamp()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getHash().hashCode();
|
|
||||||
hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getTimestamp());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.BlockFilter prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.BlockFilter}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.BlockFilter)
|
|
||||||
bdledger.api.grpc.query.BlockFilterOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_BlockFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_BlockFilter_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.BlockFilter.class, bdledger.api.grpc.query.BlockFilter.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.BlockFilter.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
timestamp_ = 0L;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_BlockFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.BlockFilter getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.BlockFilter.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.BlockFilter build() {
|
|
||||||
bdledger.api.grpc.query.BlockFilter result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.BlockFilter buildPartial() {
|
|
||||||
bdledger.api.grpc.query.BlockFilter result = new bdledger.api.grpc.query.BlockFilter(this);
|
|
||||||
result.hash_ = hash_;
|
|
||||||
result.timestamp_ = timestamp_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.BlockFilter) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.BlockFilter)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.BlockFilter other) {
|
|
||||||
if (other == bdledger.api.grpc.query.BlockFilter.getDefaultInstance()) return this;
|
|
||||||
if (other.getHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setHash(other.getHash());
|
|
||||||
}
|
|
||||||
if (other.getTimestamp() != 0L) {
|
|
||||||
setTimestamp(other.getTimestamp());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.BlockFilter parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.BlockFilter) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @param value The hash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
hash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearHash() {
|
|
||||||
|
|
||||||
hash_ = getDefaultInstance().getHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long timestamp_ ;
|
|
||||||
/**
|
|
||||||
* <code>int64 timestamp = 2;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
public long getTimestamp() {
|
|
||||||
return timestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 timestamp = 2;</code>
|
|
||||||
* @param value The timestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setTimestamp(long value) {
|
|
||||||
|
|
||||||
timestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 timestamp = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearTimestamp() {
|
|
||||||
|
|
||||||
timestamp_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.BlockFilter)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.BlockFilter)
|
|
||||||
private static final bdledger.api.grpc.query.BlockFilter DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.BlockFilter();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.BlockFilter getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<BlockFilter>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<BlockFilter>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public BlockFilter parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new BlockFilter(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<BlockFilter> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<BlockFilter> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.BlockFilter getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,21 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface BlockFilterOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.BlockFilter)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 timestamp = 2;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
long getTimestamp();
|
|
||||||
}
|
|
File diff suppressed because it is too large
Load Diff
@ -1,57 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface BlocksRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.BlocksRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
long getStartTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
long getEndTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.BlockFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.query.BlockFilter>
|
|
||||||
getFiltersList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.BlockFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.query.BlockFilter getFilters(int index);
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.BlockFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
int getFiltersCount();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.BlockFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.query.BlockFilterOrBuilder>
|
|
||||||
getFiltersOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.BlockFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.query.BlockFilterOrBuilder getFiltersOrBuilder(
|
|
||||||
int index);
|
|
||||||
}
|
|
@ -1,482 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CountBlocksResponse}
|
|
||||||
*/
|
|
||||||
public final class CountBlocksResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.CountBlocksResponse)
|
|
||||||
CountBlocksResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use CountBlocksResponse.newBuilder() to construct.
|
|
||||||
private CountBlocksResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private CountBlocksResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new CountBlocksResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private CountBlocksResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 8: {
|
|
||||||
|
|
||||||
count_ = input.readUInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountBlocksResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse.class, bdledger.api.grpc.query.CountBlocksResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int COUNT_FIELD_NUMBER = 1;
|
|
||||||
private long count_;
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
public long getCount() {
|
|
||||||
return count_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (count_ != 0L) {
|
|
||||||
output.writeUInt64(1, count_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (count_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeUInt64Size(1, count_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.CountBlocksResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse other = (bdledger.api.grpc.query.CountBlocksResponse) obj;
|
|
||||||
|
|
||||||
if (getCount()
|
|
||||||
!= other.getCount()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + COUNT_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getCount());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.CountBlocksResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CountBlocksResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.CountBlocksResponse)
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountBlocksResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse.class, bdledger.api.grpc.query.CountBlocksResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.CountBlocksResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
count_ = 0L;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountBlocksResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.CountBlocksResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountBlocksResponse build() {
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountBlocksResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse result = new bdledger.api.grpc.query.CountBlocksResponse(this);
|
|
||||||
result.count_ = count_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.CountBlocksResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.CountBlocksResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.CountBlocksResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.CountBlocksResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.getCount() != 0L) {
|
|
||||||
setCount(other.getCount());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.CountBlocksResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long count_ ;
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
public long getCount() {
|
|
||||||
return count_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @param value The count to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setCount(long value) {
|
|
||||||
|
|
||||||
count_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearCount() {
|
|
||||||
|
|
||||||
count_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.CountBlocksResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.CountBlocksResponse)
|
|
||||||
private static final bdledger.api.grpc.query.CountBlocksResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.CountBlocksResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.CountBlocksResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<CountBlocksResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<CountBlocksResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public CountBlocksResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new CountBlocksResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<CountBlocksResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<CountBlocksResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountBlocksResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface CountBlocksResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.CountBlocksResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
long getCount();
|
|
||||||
}
|
|
@ -1,482 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CountTransactionsResponse}
|
|
||||||
*/
|
|
||||||
public final class CountTransactionsResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.CountTransactionsResponse)
|
|
||||||
CountTransactionsResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use CountTransactionsResponse.newBuilder() to construct.
|
|
||||||
private CountTransactionsResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private CountTransactionsResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new CountTransactionsResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private CountTransactionsResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 8: {
|
|
||||||
|
|
||||||
count_ = input.readUInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountTransactionsResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse.class, bdledger.api.grpc.query.CountTransactionsResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int COUNT_FIELD_NUMBER = 1;
|
|
||||||
private long count_;
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
public long getCount() {
|
|
||||||
return count_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (count_ != 0L) {
|
|
||||||
output.writeUInt64(1, count_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (count_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeUInt64Size(1, count_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.CountTransactionsResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse other = (bdledger.api.grpc.query.CountTransactionsResponse) obj;
|
|
||||||
|
|
||||||
if (getCount()
|
|
||||||
!= other.getCount()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + COUNT_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getCount());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.CountTransactionsResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.CountTransactionsResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.CountTransactionsResponse)
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountTransactionsResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse.class, bdledger.api.grpc.query.CountTransactionsResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.CountTransactionsResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
count_ = 0L;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_CountTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountTransactionsResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.CountTransactionsResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountTransactionsResponse build() {
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountTransactionsResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse result = new bdledger.api.grpc.query.CountTransactionsResponse(this);
|
|
||||||
result.count_ = count_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.CountTransactionsResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.CountTransactionsResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.CountTransactionsResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.CountTransactionsResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.getCount() != 0L) {
|
|
||||||
setCount(other.getCount());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.CountTransactionsResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long count_ ;
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
public long getCount() {
|
|
||||||
return count_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @param value The count to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setCount(long value) {
|
|
||||||
|
|
||||||
count_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearCount() {
|
|
||||||
|
|
||||||
count_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.CountTransactionsResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.CountTransactionsResponse)
|
|
||||||
private static final bdledger.api.grpc.query.CountTransactionsResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.CountTransactionsResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.CountTransactionsResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<CountTransactionsResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<CountTransactionsResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public CountTransactionsResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new CountTransactionsResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<CountTransactionsResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<CountTransactionsResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.CountTransactionsResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,15 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface CountTransactionsResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.CountTransactionsResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>uint64 count = 1;</code>
|
|
||||||
* @return The count.
|
|
||||||
*/
|
|
||||||
long getCount();
|
|
||||||
}
|
|
@ -1,684 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlockByHashRequest}
|
|
||||||
*/
|
|
||||||
public final class GetBlockByHashRequest extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetBlockByHashRequest)
|
|
||||||
GetBlockByHashRequestOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetBlockByHashRequest.newBuilder() to construct.
|
|
||||||
private GetBlockByHashRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetBlockByHashRequest() {
|
|
||||||
ledger_ = "";
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetBlockByHashRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetBlockByHashRequest(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
|
|
||||||
ledger_ = s;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 18: {
|
|
||||||
|
|
||||||
hash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 24: {
|
|
||||||
|
|
||||||
fullTransactions_ = input.readBool();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest.class, bdledger.api.grpc.query.GetBlockByHashRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int LEDGER_FIELD_NUMBER = 1;
|
|
||||||
private volatile java.lang.Object ledger_;
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
} else {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int HASH_FIELD_NUMBER = 2;
|
|
||||||
private com.google.protobuf.ByteString hash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int FULL_TRANSACTIONS_FIELD_NUMBER = 3;
|
|
||||||
private boolean fullTransactions_;
|
|
||||||
/**
|
|
||||||
* <code>bool full_transactions = 3;</code>
|
|
||||||
* @return The fullTransactions.
|
|
||||||
*/
|
|
||||||
public boolean getFullTransactions() {
|
|
||||||
return fullTransactions_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, ledger_);
|
|
||||||
}
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
output.writeBytes(2, hash_);
|
|
||||||
}
|
|
||||||
if (fullTransactions_ != false) {
|
|
||||||
output.writeBool(3, fullTransactions_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, ledger_);
|
|
||||||
}
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(2, hash_);
|
|
||||||
}
|
|
||||||
if (fullTransactions_ != false) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBoolSize(3, fullTransactions_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetBlockByHashRequest)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest other = (bdledger.api.grpc.query.GetBlockByHashRequest) obj;
|
|
||||||
|
|
||||||
if (!getLedger()
|
|
||||||
.equals(other.getLedger())) return false;
|
|
||||||
if (!getHash()
|
|
||||||
.equals(other.getHash())) return false;
|
|
||||||
if (getFullTransactions()
|
|
||||||
!= other.getFullTransactions()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + LEDGER_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getLedger().hashCode();
|
|
||||||
hash = (37 * hash) + HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getHash().hashCode();
|
|
||||||
hash = (37 * hash) + FULL_TRANSACTIONS_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(
|
|
||||||
getFullTransactions());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetBlockByHashRequest prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlockByHashRequest}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetBlockByHashRequest)
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequestOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest.class, bdledger.api.grpc.query.GetBlockByHashRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetBlockByHashRequest.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
ledger_ = "";
|
|
||||||
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
fullTransactions_ = false;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashRequest getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetBlockByHashRequest.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashRequest build() {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashRequest buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest result = new bdledger.api.grpc.query.GetBlockByHashRequest(this);
|
|
||||||
result.ledger_ = ledger_;
|
|
||||||
result.hash_ = hash_;
|
|
||||||
result.fullTransactions_ = fullTransactions_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetBlockByHashRequest) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetBlockByHashRequest)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetBlockByHashRequest other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetBlockByHashRequest.getDefaultInstance()) return this;
|
|
||||||
if (!other.getLedger().isEmpty()) {
|
|
||||||
ledger_ = other.ledger_;
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
if (other.getHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setHash(other.getHash());
|
|
||||||
}
|
|
||||||
if (other.getFullTransactions() != false) {
|
|
||||||
setFullTransactions(other.getFullTransactions());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetBlockByHashRequest) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private java.lang.Object ledger_ = "";
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (!(ref instanceof java.lang.String)) {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
} else {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedger(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearLedger() {
|
|
||||||
|
|
||||||
ledger_ = getDefaultInstance().getLedger();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The bytes for ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedgerBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @param value The hash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
hash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearHash() {
|
|
||||||
|
|
||||||
hash_ = getDefaultInstance().getHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private boolean fullTransactions_ ;
|
|
||||||
/**
|
|
||||||
* <code>bool full_transactions = 3;</code>
|
|
||||||
* @return The fullTransactions.
|
|
||||||
*/
|
|
||||||
public boolean getFullTransactions() {
|
|
||||||
return fullTransactions_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bool full_transactions = 3;</code>
|
|
||||||
* @param value The fullTransactions to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setFullTransactions(boolean value) {
|
|
||||||
|
|
||||||
fullTransactions_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bool full_transactions = 3;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearFullTransactions() {
|
|
||||||
|
|
||||||
fullTransactions_ = false;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetBlockByHashRequest)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetBlockByHashRequest)
|
|
||||||
private static final bdledger.api.grpc.query.GetBlockByHashRequest DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetBlockByHashRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashRequest getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetBlockByHashRequest>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetBlockByHashRequest>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetBlockByHashRequest parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetBlockByHashRequest(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetBlockByHashRequest> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetBlockByHashRequest> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashRequest getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,33 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetBlockByHashRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetBlockByHashRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bool full_transactions = 3;</code>
|
|
||||||
* @return The fullTransactions.
|
|
||||||
*/
|
|
||||||
boolean getFullTransactions();
|
|
||||||
}
|
|
@ -1,604 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlockByHashResponse}
|
|
||||||
*/
|
|
||||||
public final class GetBlockByHashResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetBlockByHashResponse)
|
|
||||||
GetBlockByHashResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetBlockByHashResponse.newBuilder() to construct.
|
|
||||||
private GetBlockByHashResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetBlockByHashResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetBlockByHashResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetBlockByHashResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
bdledger.api.grpc.common.Block.Builder subBuilder = null;
|
|
||||||
if (block_ != null) {
|
|
||||||
subBuilder = block_.toBuilder();
|
|
||||||
}
|
|
||||||
block_ = input.readMessage(bdledger.api.grpc.common.Block.parser(), extensionRegistry);
|
|
||||||
if (subBuilder != null) {
|
|
||||||
subBuilder.mergeFrom(block_);
|
|
||||||
block_ = subBuilder.buildPartial();
|
|
||||||
}
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse.class, bdledger.api.grpc.query.GetBlockByHashResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int BLOCK_FIELD_NUMBER = 1;
|
|
||||||
private bdledger.api.grpc.common.Block block_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return Whether the block field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasBlock() {
|
|
||||||
return block_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return The block.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block getBlock() {
|
|
||||||
return block_ == null ? bdledger.api.grpc.common.Block.getDefaultInstance() : block_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.BlockOrBuilder getBlockOrBuilder() {
|
|
||||||
return getBlock();
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (block_ != null) {
|
|
||||||
output.writeMessage(1, getBlock());
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (block_ != null) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeMessageSize(1, getBlock());
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetBlockByHashResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse other = (bdledger.api.grpc.query.GetBlockByHashResponse) obj;
|
|
||||||
|
|
||||||
if (hasBlock() != other.hasBlock()) return false;
|
|
||||||
if (hasBlock()) {
|
|
||||||
if (!getBlock()
|
|
||||||
.equals(other.getBlock())) return false;
|
|
||||||
}
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (hasBlock()) {
|
|
||||||
hash = (37 * hash) + BLOCK_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getBlock().hashCode();
|
|
||||||
}
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetBlockByHashResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlockByHashResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetBlockByHashResponse)
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse.class, bdledger.api.grpc.query.GetBlockByHashResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetBlockByHashResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
block_ = null;
|
|
||||||
} else {
|
|
||||||
block_ = null;
|
|
||||||
blockBuilder_ = null;
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlockByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetBlockByHashResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashResponse build() {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse result = new bdledger.api.grpc.query.GetBlockByHashResponse(this);
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
result.block_ = block_;
|
|
||||||
} else {
|
|
||||||
result.block_ = blockBuilder_.build();
|
|
||||||
}
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetBlockByHashResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetBlockByHashResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetBlockByHashResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetBlockByHashResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.hasBlock()) {
|
|
||||||
mergeBlock(other.getBlock());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetBlockByHashResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private bdledger.api.grpc.common.Block block_;
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder> blockBuilder_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return Whether the block field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasBlock() {
|
|
||||||
return blockBuilder_ != null || block_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return The block.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block getBlock() {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
return block_ == null ? bdledger.api.grpc.common.Block.getDefaultInstance() : block_;
|
|
||||||
} else {
|
|
||||||
return blockBuilder_.getMessage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setBlock(bdledger.api.grpc.common.Block value) {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
block_ = value;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blockBuilder_.setMessage(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setBlock(
|
|
||||||
bdledger.api.grpc.common.Block.Builder builderForValue) {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
block_ = builderForValue.build();
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blockBuilder_.setMessage(builderForValue.build());
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder mergeBlock(bdledger.api.grpc.common.Block value) {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
if (block_ != null) {
|
|
||||||
block_ =
|
|
||||||
bdledger.api.grpc.common.Block.newBuilder(block_).mergeFrom(value).buildPartial();
|
|
||||||
} else {
|
|
||||||
block_ = value;
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blockBuilder_.mergeFrom(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder clearBlock() {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
block_ = null;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
block_ = null;
|
|
||||||
blockBuilder_ = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block.Builder getBlockBuilder() {
|
|
||||||
|
|
||||||
onChanged();
|
|
||||||
return getBlockFieldBuilder().getBuilder();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.BlockOrBuilder getBlockOrBuilder() {
|
|
||||||
if (blockBuilder_ != null) {
|
|
||||||
return blockBuilder_.getMessageOrBuilder();
|
|
||||||
} else {
|
|
||||||
return block_ == null ?
|
|
||||||
bdledger.api.grpc.common.Block.getDefaultInstance() : block_;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder>
|
|
||||||
getBlockFieldBuilder() {
|
|
||||||
if (blockBuilder_ == null) {
|
|
||||||
blockBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder>(
|
|
||||||
getBlock(),
|
|
||||||
getParentForChildren(),
|
|
||||||
isClean());
|
|
||||||
block_ = null;
|
|
||||||
}
|
|
||||||
return blockBuilder_;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetBlockByHashResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetBlockByHashResponse)
|
|
||||||
private static final bdledger.api.grpc.query.GetBlockByHashResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetBlockByHashResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlockByHashResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetBlockByHashResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetBlockByHashResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetBlockByHashResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetBlockByHashResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetBlockByHashResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetBlockByHashResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,24 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetBlockByHashResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetBlockByHashResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return Whether the block field is set.
|
|
||||||
*/
|
|
||||||
boolean hasBlock();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
* @return The block.
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Block getBlock();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Block block = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.BlockOrBuilder getBlockOrBuilder();
|
|
||||||
}
|
|
@ -1,891 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlocksResponse}
|
|
||||||
*/
|
|
||||||
public final class GetBlocksResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetBlocksResponse)
|
|
||||||
GetBlocksResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetBlocksResponse.newBuilder() to construct.
|
|
||||||
private GetBlocksResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetBlocksResponse() {
|
|
||||||
blocks_ = java.util.Collections.emptyList();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetBlocksResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetBlocksResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
int mutable_bitField0_ = 0;
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
blocks_ = new java.util.ArrayList<bdledger.api.grpc.common.Block>();
|
|
||||||
mutable_bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
blocks_.add(
|
|
||||||
input.readMessage(bdledger.api.grpc.common.Block.parser(), extensionRegistry));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 16: {
|
|
||||||
|
|
||||||
startTimestamp_ = input.readInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 24: {
|
|
||||||
|
|
||||||
endTimestamp_ = input.readInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
if (((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
blocks_ = java.util.Collections.unmodifiableList(blocks_);
|
|
||||||
}
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlocksResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse.class, bdledger.api.grpc.query.GetBlocksResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int BLOCKS_FIELD_NUMBER = 1;
|
|
||||||
private java.util.List<bdledger.api.grpc.common.Block> blocks_;
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Block> getBlocksList() {
|
|
||||||
return blocks_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<? extends bdledger.api.grpc.common.BlockOrBuilder>
|
|
||||||
getBlocksOrBuilderList() {
|
|
||||||
return blocks_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public int getBlocksCount() {
|
|
||||||
return blocks_.size();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block getBlocks(int index) {
|
|
||||||
return blocks_.get(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.BlockOrBuilder getBlocksOrBuilder(
|
|
||||||
int index) {
|
|
||||||
return blocks_.get(index);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int START_TIMESTAMP_FIELD_NUMBER = 2;
|
|
||||||
private long startTimestamp_;
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
public long getStartTimestamp() {
|
|
||||||
return startTimestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int END_TIMESTAMP_FIELD_NUMBER = 3;
|
|
||||||
private long endTimestamp_;
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
public long getEndTimestamp() {
|
|
||||||
return endTimestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
for (int i = 0; i < blocks_.size(); i++) {
|
|
||||||
output.writeMessage(1, blocks_.get(i));
|
|
||||||
}
|
|
||||||
if (startTimestamp_ != 0L) {
|
|
||||||
output.writeInt64(2, startTimestamp_);
|
|
||||||
}
|
|
||||||
if (endTimestamp_ != 0L) {
|
|
||||||
output.writeInt64(3, endTimestamp_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
for (int i = 0; i < blocks_.size(); i++) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeMessageSize(1, blocks_.get(i));
|
|
||||||
}
|
|
||||||
if (startTimestamp_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeInt64Size(2, startTimestamp_);
|
|
||||||
}
|
|
||||||
if (endTimestamp_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeInt64Size(3, endTimestamp_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetBlocksResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse other = (bdledger.api.grpc.query.GetBlocksResponse) obj;
|
|
||||||
|
|
||||||
if (!getBlocksList()
|
|
||||||
.equals(other.getBlocksList())) return false;
|
|
||||||
if (getStartTimestamp()
|
|
||||||
!= other.getStartTimestamp()) return false;
|
|
||||||
if (getEndTimestamp()
|
|
||||||
!= other.getEndTimestamp()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (getBlocksCount() > 0) {
|
|
||||||
hash = (37 * hash) + BLOCKS_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getBlocksList().hashCode();
|
|
||||||
}
|
|
||||||
hash = (37 * hash) + START_TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getStartTimestamp());
|
|
||||||
hash = (37 * hash) + END_TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getEndTimestamp());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetBlocksResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetBlocksResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetBlocksResponse)
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlocksResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse.class, bdledger.api.grpc.query.GetBlocksResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetBlocksResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
getBlocksFieldBuilder();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
blocks_ = java.util.Collections.emptyList();
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.clear();
|
|
||||||
}
|
|
||||||
startTimestamp_ = 0L;
|
|
||||||
|
|
||||||
endTimestamp_ = 0L;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetBlocksResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlocksResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetBlocksResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlocksResponse build() {
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlocksResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse result = new bdledger.api.grpc.query.GetBlocksResponse(this);
|
|
||||||
int from_bitField0_ = bitField0_;
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
if (((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
blocks_ = java.util.Collections.unmodifiableList(blocks_);
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
}
|
|
||||||
result.blocks_ = blocks_;
|
|
||||||
} else {
|
|
||||||
result.blocks_ = blocksBuilder_.build();
|
|
||||||
}
|
|
||||||
result.startTimestamp_ = startTimestamp_;
|
|
||||||
result.endTimestamp_ = endTimestamp_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetBlocksResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetBlocksResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetBlocksResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetBlocksResponse.getDefaultInstance()) return this;
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
if (!other.blocks_.isEmpty()) {
|
|
||||||
if (blocks_.isEmpty()) {
|
|
||||||
blocks_ = other.blocks_;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
} else {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.addAll(other.blocks_);
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if (!other.blocks_.isEmpty()) {
|
|
||||||
if (blocksBuilder_.isEmpty()) {
|
|
||||||
blocksBuilder_.dispose();
|
|
||||||
blocksBuilder_ = null;
|
|
||||||
blocks_ = other.blocks_;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
blocksBuilder_ =
|
|
||||||
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
|
|
||||||
getBlocksFieldBuilder() : null;
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addAllMessages(other.blocks_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (other.getStartTimestamp() != 0L) {
|
|
||||||
setStartTimestamp(other.getStartTimestamp());
|
|
||||||
}
|
|
||||||
if (other.getEndTimestamp() != 0L) {
|
|
||||||
setEndTimestamp(other.getEndTimestamp());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetBlocksResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
private int bitField0_;
|
|
||||||
|
|
||||||
private java.util.List<bdledger.api.grpc.common.Block> blocks_ =
|
|
||||||
java.util.Collections.emptyList();
|
|
||||||
private void ensureBlocksIsMutable() {
|
|
||||||
if (!((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
blocks_ = new java.util.ArrayList<bdledger.api.grpc.common.Block>(blocks_);
|
|
||||||
bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder> blocksBuilder_;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Block> getBlocksList() {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
return java.util.Collections.unmodifiableList(blocks_);
|
|
||||||
} else {
|
|
||||||
return blocksBuilder_.getMessageList();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public int getBlocksCount() {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
return blocks_.size();
|
|
||||||
} else {
|
|
||||||
return blocksBuilder_.getCount();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block getBlocks(int index) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
return blocks_.get(index);
|
|
||||||
} else {
|
|
||||||
return blocksBuilder_.getMessage(index);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setBlocks(
|
|
||||||
int index, bdledger.api.grpc.common.Block value) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.set(index, value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.setMessage(index, value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setBlocks(
|
|
||||||
int index, bdledger.api.grpc.common.Block.Builder builderForValue) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.set(index, builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.setMessage(index, builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addBlocks(bdledger.api.grpc.common.Block value) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.add(value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addMessage(value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addBlocks(
|
|
||||||
int index, bdledger.api.grpc.common.Block value) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.add(index, value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addMessage(index, value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addBlocks(
|
|
||||||
bdledger.api.grpc.common.Block.Builder builderForValue) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.add(builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addMessage(builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addBlocks(
|
|
||||||
int index, bdledger.api.grpc.common.Block.Builder builderForValue) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.add(index, builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addMessage(index, builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addAllBlocks(
|
|
||||||
java.lang.Iterable<? extends bdledger.api.grpc.common.Block> values) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
|
||||||
values, blocks_);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.addAllMessages(values);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder clearBlocks() {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
blocks_ = java.util.Collections.emptyList();
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.clear();
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder removeBlocks(int index) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
ensureBlocksIsMutable();
|
|
||||||
blocks_.remove(index);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
blocksBuilder_.remove(index);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block.Builder getBlocksBuilder(
|
|
||||||
int index) {
|
|
||||||
return getBlocksFieldBuilder().getBuilder(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.BlockOrBuilder getBlocksOrBuilder(
|
|
||||||
int index) {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
return blocks_.get(index); } else {
|
|
||||||
return blocksBuilder_.getMessageOrBuilder(index);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<? extends bdledger.api.grpc.common.BlockOrBuilder>
|
|
||||||
getBlocksOrBuilderList() {
|
|
||||||
if (blocksBuilder_ != null) {
|
|
||||||
return blocksBuilder_.getMessageOrBuilderList();
|
|
||||||
} else {
|
|
||||||
return java.util.Collections.unmodifiableList(blocks_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block.Builder addBlocksBuilder() {
|
|
||||||
return getBlocksFieldBuilder().addBuilder(
|
|
||||||
bdledger.api.grpc.common.Block.getDefaultInstance());
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Block.Builder addBlocksBuilder(
|
|
||||||
int index) {
|
|
||||||
return getBlocksFieldBuilder().addBuilder(
|
|
||||||
index, bdledger.api.grpc.common.Block.getDefaultInstance());
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Block.Builder>
|
|
||||||
getBlocksBuilderList() {
|
|
||||||
return getBlocksFieldBuilder().getBuilderList();
|
|
||||||
}
|
|
||||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder>
|
|
||||||
getBlocksFieldBuilder() {
|
|
||||||
if (blocksBuilder_ == null) {
|
|
||||||
blocksBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Block, bdledger.api.grpc.common.Block.Builder, bdledger.api.grpc.common.BlockOrBuilder>(
|
|
||||||
blocks_,
|
|
||||||
((bitField0_ & 0x00000001) != 0),
|
|
||||||
getParentForChildren(),
|
|
||||||
isClean());
|
|
||||||
blocks_ = null;
|
|
||||||
}
|
|
||||||
return blocksBuilder_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long startTimestamp_ ;
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
public long getStartTimestamp() {
|
|
||||||
return startTimestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @param value The startTimestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setStartTimestamp(long value) {
|
|
||||||
|
|
||||||
startTimestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearStartTimestamp() {
|
|
||||||
|
|
||||||
startTimestamp_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long endTimestamp_ ;
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
public long getEndTimestamp() {
|
|
||||||
return endTimestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @param value The endTimestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setEndTimestamp(long value) {
|
|
||||||
|
|
||||||
endTimestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearEndTimestamp() {
|
|
||||||
|
|
||||||
endTimestamp_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetBlocksResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetBlocksResponse)
|
|
||||||
private static final bdledger.api.grpc.query.GetBlocksResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetBlocksResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetBlocksResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetBlocksResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetBlocksResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetBlocksResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetBlocksResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetBlocksResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetBlocksResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetBlocksResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetBlocksResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetBlocksResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.common.Block>
|
|
||||||
getBlocksList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Block getBlocks(int index);
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
int getBlocksCount();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.common.BlockOrBuilder>
|
|
||||||
getBlocksOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Block blocks = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.BlockOrBuilder getBlocksOrBuilder(
|
|
||||||
int index);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
long getStartTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
long getEndTimestamp();
|
|
||||||
}
|
|
@ -1,683 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByBlockHashAndIndexRequest}
|
|
||||||
*/
|
|
||||||
public final class GetTransactionByBlockHashAndIndexRequest extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetTransactionByBlockHashAndIndexRequest)
|
|
||||||
GetTransactionByBlockHashAndIndexRequestOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetTransactionByBlockHashAndIndexRequest.newBuilder() to construct.
|
|
||||||
private GetTransactionByBlockHashAndIndexRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetTransactionByBlockHashAndIndexRequest() {
|
|
||||||
ledger_ = "";
|
|
||||||
blockHash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetTransactionByBlockHashAndIndexRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetTransactionByBlockHashAndIndexRequest(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
|
|
||||||
ledger_ = s;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 18: {
|
|
||||||
|
|
||||||
blockHash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 24: {
|
|
||||||
|
|
||||||
index_ = input.readUInt32();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.class, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int LEDGER_FIELD_NUMBER = 1;
|
|
||||||
private volatile java.lang.Object ledger_;
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
} else {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int BLOCK_HASH_FIELD_NUMBER = 2;
|
|
||||||
private com.google.protobuf.ByteString blockHash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes block_hash = 2;</code>
|
|
||||||
* @return The blockHash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getBlockHash() {
|
|
||||||
return blockHash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int INDEX_FIELD_NUMBER = 3;
|
|
||||||
private int index_;
|
|
||||||
/**
|
|
||||||
* <code>uint32 index = 3;</code>
|
|
||||||
* @return The index.
|
|
||||||
*/
|
|
||||||
public int getIndex() {
|
|
||||||
return index_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, ledger_);
|
|
||||||
}
|
|
||||||
if (!blockHash_.isEmpty()) {
|
|
||||||
output.writeBytes(2, blockHash_);
|
|
||||||
}
|
|
||||||
if (index_ != 0) {
|
|
||||||
output.writeUInt32(3, index_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, ledger_);
|
|
||||||
}
|
|
||||||
if (!blockHash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(2, blockHash_);
|
|
||||||
}
|
|
||||||
if (index_ != 0) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeUInt32Size(3, index_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest other = (bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest) obj;
|
|
||||||
|
|
||||||
if (!getLedger()
|
|
||||||
.equals(other.getLedger())) return false;
|
|
||||||
if (!getBlockHash()
|
|
||||||
.equals(other.getBlockHash())) return false;
|
|
||||||
if (getIndex()
|
|
||||||
!= other.getIndex()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + LEDGER_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getLedger().hashCode();
|
|
||||||
hash = (37 * hash) + BLOCK_HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getBlockHash().hashCode();
|
|
||||||
hash = (37 * hash) + INDEX_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getIndex();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByBlockHashAndIndexRequest}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetTransactionByBlockHashAndIndexRequest)
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequestOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.class, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
ledger_ = "";
|
|
||||||
|
|
||||||
blockHash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
index_ = 0;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest build() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest result = new bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest(this);
|
|
||||||
result.ledger_ = ledger_;
|
|
||||||
result.blockHash_ = blockHash_;
|
|
||||||
result.index_ = index_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.getDefaultInstance()) return this;
|
|
||||||
if (!other.getLedger().isEmpty()) {
|
|
||||||
ledger_ = other.ledger_;
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
if (other.getBlockHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setBlockHash(other.getBlockHash());
|
|
||||||
}
|
|
||||||
if (other.getIndex() != 0) {
|
|
||||||
setIndex(other.getIndex());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private java.lang.Object ledger_ = "";
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (!(ref instanceof java.lang.String)) {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
} else {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedger(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearLedger() {
|
|
||||||
|
|
||||||
ledger_ = getDefaultInstance().getLedger();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The bytes for ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedgerBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString blockHash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes block_hash = 2;</code>
|
|
||||||
* @return The blockHash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getBlockHash() {
|
|
||||||
return blockHash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes block_hash = 2;</code>
|
|
||||||
* @param value The blockHash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setBlockHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
blockHash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes block_hash = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearBlockHash() {
|
|
||||||
|
|
||||||
blockHash_ = getDefaultInstance().getBlockHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private int index_ ;
|
|
||||||
/**
|
|
||||||
* <code>uint32 index = 3;</code>
|
|
||||||
* @return The index.
|
|
||||||
*/
|
|
||||||
public int getIndex() {
|
|
||||||
return index_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint32 index = 3;</code>
|
|
||||||
* @param value The index to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setIndex(int value) {
|
|
||||||
|
|
||||||
index_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>uint32 index = 3;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearIndex() {
|
|
||||||
|
|
||||||
index_ = 0;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetTransactionByBlockHashAndIndexRequest)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetTransactionByBlockHashAndIndexRequest)
|
|
||||||
private static final bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexRequest>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetTransactionByBlockHashAndIndexRequest>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetTransactionByBlockHashAndIndexRequest parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetTransactionByBlockHashAndIndexRequest(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexRequest> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexRequest> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,33 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetTransactionByBlockHashAndIndexRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetTransactionByBlockHashAndIndexRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes block_hash = 2;</code>
|
|
||||||
* @return The blockHash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getBlockHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>uint32 index = 3;</code>
|
|
||||||
* @return The index.
|
|
||||||
*/
|
|
||||||
int getIndex();
|
|
||||||
}
|
|
@ -1,604 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByBlockHashAndIndexResponse}
|
|
||||||
*/
|
|
||||||
public final class GetTransactionByBlockHashAndIndexResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetTransactionByBlockHashAndIndexResponse)
|
|
||||||
GetTransactionByBlockHashAndIndexResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetTransactionByBlockHashAndIndexResponse.newBuilder() to construct.
|
|
||||||
private GetTransactionByBlockHashAndIndexResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetTransactionByBlockHashAndIndexResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetTransactionByBlockHashAndIndexResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetTransactionByBlockHashAndIndexResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
bdledger.api.grpc.common.Transaction.Builder subBuilder = null;
|
|
||||||
if (transaction_ != null) {
|
|
||||||
subBuilder = transaction_.toBuilder();
|
|
||||||
}
|
|
||||||
transaction_ = input.readMessage(bdledger.api.grpc.common.Transaction.parser(), extensionRegistry);
|
|
||||||
if (subBuilder != null) {
|
|
||||||
subBuilder.mergeFrom(transaction_);
|
|
||||||
transaction_ = subBuilder.buildPartial();
|
|
||||||
}
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.class, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TRANSACTION_FIELD_NUMBER = 1;
|
|
||||||
private bdledger.api.grpc.common.Transaction transaction_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasTransaction() {
|
|
||||||
return transaction_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransaction() {
|
|
||||||
return transaction_ == null ? bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder() {
|
|
||||||
return getTransaction();
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (transaction_ != null) {
|
|
||||||
output.writeMessage(1, getTransaction());
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (transaction_ != null) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeMessageSize(1, getTransaction());
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse other = (bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse) obj;
|
|
||||||
|
|
||||||
if (hasTransaction() != other.hasTransaction()) return false;
|
|
||||||
if (hasTransaction()) {
|
|
||||||
if (!getTransaction()
|
|
||||||
.equals(other.getTransaction())) return false;
|
|
||||||
}
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (hasTransaction()) {
|
|
||||||
hash = (37 * hash) + TRANSACTION_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getTransaction().hashCode();
|
|
||||||
}
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByBlockHashAndIndexResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetTransactionByBlockHashAndIndexResponse)
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.class, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = null;
|
|
||||||
} else {
|
|
||||||
transaction_ = null;
|
|
||||||
transactionBuilder_ = null;
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse build() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse result = new bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse(this);
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
result.transaction_ = transaction_;
|
|
||||||
} else {
|
|
||||||
result.transaction_ = transactionBuilder_.build();
|
|
||||||
}
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.hasTransaction()) {
|
|
||||||
mergeTransaction(other.getTransaction());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private bdledger.api.grpc.common.Transaction transaction_;
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder> transactionBuilder_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasTransaction() {
|
|
||||||
return transactionBuilder_ != null || transaction_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransaction() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
return transaction_ == null ? bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
} else {
|
|
||||||
return transactionBuilder_.getMessage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransaction(bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
transaction_ = value;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.setMessage(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransaction(
|
|
||||||
bdledger.api.grpc.common.Transaction.Builder builderForValue) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = builderForValue.build();
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.setMessage(builderForValue.build());
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder mergeTransaction(bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
if (transaction_ != null) {
|
|
||||||
transaction_ =
|
|
||||||
bdledger.api.grpc.common.Transaction.newBuilder(transaction_).mergeFrom(value).buildPartial();
|
|
||||||
} else {
|
|
||||||
transaction_ = value;
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.mergeFrom(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder clearTransaction() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = null;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transaction_ = null;
|
|
||||||
transactionBuilder_ = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction.Builder getTransactionBuilder() {
|
|
||||||
|
|
||||||
onChanged();
|
|
||||||
return getTransactionFieldBuilder().getBuilder();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder() {
|
|
||||||
if (transactionBuilder_ != null) {
|
|
||||||
return transactionBuilder_.getMessageOrBuilder();
|
|
||||||
} else {
|
|
||||||
return transaction_ == null ?
|
|
||||||
bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionFieldBuilder() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transactionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>(
|
|
||||||
getTransaction(),
|
|
||||||
getParentForChildren(),
|
|
||||||
isClean());
|
|
||||||
transaction_ = null;
|
|
||||||
}
|
|
||||||
return transactionBuilder_;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetTransactionByBlockHashAndIndexResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetTransactionByBlockHashAndIndexResponse)
|
|
||||||
private static final bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetTransactionByBlockHashAndIndexResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetTransactionByBlockHashAndIndexResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetTransactionByBlockHashAndIndexResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetTransactionByBlockHashAndIndexResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,24 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetTransactionByBlockHashAndIndexResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetTransactionByBlockHashAndIndexResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
boolean hasTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Transaction getTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder();
|
|
||||||
}
|
|
@ -1,621 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByHashRequest}
|
|
||||||
*/
|
|
||||||
public final class GetTransactionByHashRequest extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetTransactionByHashRequest)
|
|
||||||
GetTransactionByHashRequestOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetTransactionByHashRequest.newBuilder() to construct.
|
|
||||||
private GetTransactionByHashRequest(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetTransactionByHashRequest() {
|
|
||||||
ledger_ = "";
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetTransactionByHashRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetTransactionByHashRequest(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
java.lang.String s = input.readStringRequireUtf8();
|
|
||||||
|
|
||||||
ledger_ = s;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 18: {
|
|
||||||
|
|
||||||
hash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest.class, bdledger.api.grpc.query.GetTransactionByHashRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int LEDGER_FIELD_NUMBER = 1;
|
|
||||||
private volatile java.lang.Object ledger_;
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
} else {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof java.lang.String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int HASH_FIELD_NUMBER = 2;
|
|
||||||
private com.google.protobuf.ByteString hash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, ledger_);
|
|
||||||
}
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
output.writeBytes(2, hash_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!getLedgerBytes().isEmpty()) {
|
|
||||||
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, ledger_);
|
|
||||||
}
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(2, hash_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetTransactionByHashRequest)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest other = (bdledger.api.grpc.query.GetTransactionByHashRequest) obj;
|
|
||||||
|
|
||||||
if (!getLedger()
|
|
||||||
.equals(other.getLedger())) return false;
|
|
||||||
if (!getHash()
|
|
||||||
.equals(other.getHash())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + LEDGER_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getLedger().hashCode();
|
|
||||||
hash = (37 * hash) + HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getHash().hashCode();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetTransactionByHashRequest prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByHashRequest}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetTransactionByHashRequest)
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequestOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashRequest_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest.class, bdledger.api.grpc.query.GetTransactionByHashRequest.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetTransactionByHashRequest.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
ledger_ = "";
|
|
||||||
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashRequest_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashRequest getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetTransactionByHashRequest.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashRequest build() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashRequest buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest result = new bdledger.api.grpc.query.GetTransactionByHashRequest(this);
|
|
||||||
result.ledger_ = ledger_;
|
|
||||||
result.hash_ = hash_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetTransactionByHashRequest) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetTransactionByHashRequest)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetTransactionByHashRequest other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetTransactionByHashRequest.getDefaultInstance()) return this;
|
|
||||||
if (!other.getLedger().isEmpty()) {
|
|
||||||
ledger_ = other.ledger_;
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
if (other.getHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setHash(other.getHash());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetTransactionByHashRequest) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private java.lang.Object ledger_ = "";
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
public java.lang.String getLedger() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (!(ref instanceof java.lang.String)) {
|
|
||||||
com.google.protobuf.ByteString bs =
|
|
||||||
(com.google.protobuf.ByteString) ref;
|
|
||||||
java.lang.String s = bs.toStringUtf8();
|
|
||||||
ledger_ = s;
|
|
||||||
return s;
|
|
||||||
} else {
|
|
||||||
return (java.lang.String) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes() {
|
|
||||||
java.lang.Object ref = ledger_;
|
|
||||||
if (ref instanceof String) {
|
|
||||||
com.google.protobuf.ByteString b =
|
|
||||||
com.google.protobuf.ByteString.copyFromUtf8(
|
|
||||||
(java.lang.String) ref);
|
|
||||||
ledger_ = b;
|
|
||||||
return b;
|
|
||||||
} else {
|
|
||||||
return (com.google.protobuf.ByteString) ref;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedger(
|
|
||||||
java.lang.String value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearLedger() {
|
|
||||||
|
|
||||||
ledger_ = getDefaultInstance().getLedger();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @param value The bytes for ledger to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setLedgerBytes(
|
|
||||||
com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
checkByteStringIsUtf8(value);
|
|
||||||
|
|
||||||
ledger_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @param value The hash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
hash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearHash() {
|
|
||||||
|
|
||||||
hash_ = getDefaultInstance().getHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetTransactionByHashRequest)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetTransactionByHashRequest)
|
|
||||||
private static final bdledger.api.grpc.query.GetTransactionByHashRequest DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetTransactionByHashRequest();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashRequest getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetTransactionByHashRequest>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetTransactionByHashRequest>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetTransactionByHashRequest parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetTransactionByHashRequest(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetTransactionByHashRequest> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetTransactionByHashRequest> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashRequest getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,27 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetTransactionByHashRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetTransactionByHashRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 2;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
}
|
|
@ -1,604 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByHashResponse}
|
|
||||||
*/
|
|
||||||
public final class GetTransactionByHashResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetTransactionByHashResponse)
|
|
||||||
GetTransactionByHashResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetTransactionByHashResponse.newBuilder() to construct.
|
|
||||||
private GetTransactionByHashResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetTransactionByHashResponse() {
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetTransactionByHashResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetTransactionByHashResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
bdledger.api.grpc.common.Transaction.Builder subBuilder = null;
|
|
||||||
if (transaction_ != null) {
|
|
||||||
subBuilder = transaction_.toBuilder();
|
|
||||||
}
|
|
||||||
transaction_ = input.readMessage(bdledger.api.grpc.common.Transaction.parser(), extensionRegistry);
|
|
||||||
if (subBuilder != null) {
|
|
||||||
subBuilder.mergeFrom(transaction_);
|
|
||||||
transaction_ = subBuilder.buildPartial();
|
|
||||||
}
|
|
||||||
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse.class, bdledger.api.grpc.query.GetTransactionByHashResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TRANSACTION_FIELD_NUMBER = 1;
|
|
||||||
private bdledger.api.grpc.common.Transaction transaction_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasTransaction() {
|
|
||||||
return transaction_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransaction() {
|
|
||||||
return transaction_ == null ? bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder() {
|
|
||||||
return getTransaction();
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (transaction_ != null) {
|
|
||||||
output.writeMessage(1, getTransaction());
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (transaction_ != null) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeMessageSize(1, getTransaction());
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetTransactionByHashResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse other = (bdledger.api.grpc.query.GetTransactionByHashResponse) obj;
|
|
||||||
|
|
||||||
if (hasTransaction() != other.hasTransaction()) return false;
|
|
||||||
if (hasTransaction()) {
|
|
||||||
if (!getTransaction()
|
|
||||||
.equals(other.getTransaction())) return false;
|
|
||||||
}
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (hasTransaction()) {
|
|
||||||
hash = (37 * hash) + TRANSACTION_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getTransaction().hashCode();
|
|
||||||
}
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetTransactionByHashResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionByHashResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetTransactionByHashResponse)
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse.class, bdledger.api.grpc.query.GetTransactionByHashResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetTransactionByHashResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = null;
|
|
||||||
} else {
|
|
||||||
transaction_ = null;
|
|
||||||
transactionBuilder_ = null;
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionByHashResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetTransactionByHashResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashResponse build() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse result = new bdledger.api.grpc.query.GetTransactionByHashResponse(this);
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
result.transaction_ = transaction_;
|
|
||||||
} else {
|
|
||||||
result.transaction_ = transactionBuilder_.build();
|
|
||||||
}
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetTransactionByHashResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetTransactionByHashResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetTransactionByHashResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetTransactionByHashResponse.getDefaultInstance()) return this;
|
|
||||||
if (other.hasTransaction()) {
|
|
||||||
mergeTransaction(other.getTransaction());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetTransactionByHashResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private bdledger.api.grpc.common.Transaction transaction_;
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder> transactionBuilder_;
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
public boolean hasTransaction() {
|
|
||||||
return transactionBuilder_ != null || transaction_ != null;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransaction() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
return transaction_ == null ? bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
} else {
|
|
||||||
return transactionBuilder_.getMessage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransaction(bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
transaction_ = value;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.setMessage(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransaction(
|
|
||||||
bdledger.api.grpc.common.Transaction.Builder builderForValue) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = builderForValue.build();
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.setMessage(builderForValue.build());
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder mergeTransaction(bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
if (transaction_ != null) {
|
|
||||||
transaction_ =
|
|
||||||
bdledger.api.grpc.common.Transaction.newBuilder(transaction_).mergeFrom(value).buildPartial();
|
|
||||||
} else {
|
|
||||||
transaction_ = value;
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionBuilder_.mergeFrom(value);
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder clearTransaction() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transaction_ = null;
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transaction_ = null;
|
|
||||||
transactionBuilder_ = null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction.Builder getTransactionBuilder() {
|
|
||||||
|
|
||||||
onChanged();
|
|
||||||
return getTransactionFieldBuilder().getBuilder();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder() {
|
|
||||||
if (transactionBuilder_ != null) {
|
|
||||||
return transactionBuilder_.getMessageOrBuilder();
|
|
||||||
} else {
|
|
||||||
return transaction_ == null ?
|
|
||||||
bdledger.api.grpc.common.Transaction.getDefaultInstance() : transaction_;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
private com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionFieldBuilder() {
|
|
||||||
if (transactionBuilder_ == null) {
|
|
||||||
transactionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>(
|
|
||||||
getTransaction(),
|
|
||||||
getParentForChildren(),
|
|
||||||
isClean());
|
|
||||||
transaction_ = null;
|
|
||||||
}
|
|
||||||
return transactionBuilder_;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetTransactionByHashResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetTransactionByHashResponse)
|
|
||||||
private static final bdledger.api.grpc.query.GetTransactionByHashResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetTransactionByHashResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionByHashResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetTransactionByHashResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetTransactionByHashResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetTransactionByHashResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetTransactionByHashResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetTransactionByHashResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetTransactionByHashResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,24 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetTransactionByHashResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetTransactionByHashResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return Whether the transaction field is set.
|
|
||||||
*/
|
|
||||||
boolean hasTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
* @return The transaction.
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Transaction getTransaction();
|
|
||||||
/**
|
|
||||||
* <code>.bdledger.api.Transaction transaction = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.TransactionOrBuilder getTransactionOrBuilder();
|
|
||||||
}
|
|
@ -1,891 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionsResponse}
|
|
||||||
*/
|
|
||||||
public final class GetTransactionsResponse extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.GetTransactionsResponse)
|
|
||||||
GetTransactionsResponseOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use GetTransactionsResponse.newBuilder() to construct.
|
|
||||||
private GetTransactionsResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private GetTransactionsResponse() {
|
|
||||||
transactions_ = java.util.Collections.emptyList();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new GetTransactionsResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private GetTransactionsResponse(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
int mutable_bitField0_ = 0;
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
if (!((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
transactions_ = new java.util.ArrayList<bdledger.api.grpc.common.Transaction>();
|
|
||||||
mutable_bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
transactions_.add(
|
|
||||||
input.readMessage(bdledger.api.grpc.common.Transaction.parser(), extensionRegistry));
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 16: {
|
|
||||||
|
|
||||||
startTimestamp_ = input.readInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 24: {
|
|
||||||
|
|
||||||
endTimestamp_ = input.readInt64();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
if (((mutable_bitField0_ & 0x00000001) != 0)) {
|
|
||||||
transactions_ = java.util.Collections.unmodifiableList(transactions_);
|
|
||||||
}
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionsResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse.class, bdledger.api.grpc.query.GetTransactionsResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TRANSACTIONS_FIELD_NUMBER = 1;
|
|
||||||
private java.util.List<bdledger.api.grpc.common.Transaction> transactions_;
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Transaction> getTransactionsList() {
|
|
||||||
return transactions_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<? extends bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionsOrBuilderList() {
|
|
||||||
return transactions_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public int getTransactionsCount() {
|
|
||||||
return transactions_.size();
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransactions(int index) {
|
|
||||||
return transactions_.get(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionsOrBuilder(
|
|
||||||
int index) {
|
|
||||||
return transactions_.get(index);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int START_TIMESTAMP_FIELD_NUMBER = 2;
|
|
||||||
private long startTimestamp_;
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
public long getStartTimestamp() {
|
|
||||||
return startTimestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int END_TIMESTAMP_FIELD_NUMBER = 3;
|
|
||||||
private long endTimestamp_;
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
public long getEndTimestamp() {
|
|
||||||
return endTimestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
for (int i = 0; i < transactions_.size(); i++) {
|
|
||||||
output.writeMessage(1, transactions_.get(i));
|
|
||||||
}
|
|
||||||
if (startTimestamp_ != 0L) {
|
|
||||||
output.writeInt64(2, startTimestamp_);
|
|
||||||
}
|
|
||||||
if (endTimestamp_ != 0L) {
|
|
||||||
output.writeInt64(3, endTimestamp_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
for (int i = 0; i < transactions_.size(); i++) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeMessageSize(1, transactions_.get(i));
|
|
||||||
}
|
|
||||||
if (startTimestamp_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeInt64Size(2, startTimestamp_);
|
|
||||||
}
|
|
||||||
if (endTimestamp_ != 0L) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeInt64Size(3, endTimestamp_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.GetTransactionsResponse)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse other = (bdledger.api.grpc.query.GetTransactionsResponse) obj;
|
|
||||||
|
|
||||||
if (!getTransactionsList()
|
|
||||||
.equals(other.getTransactionsList())) return false;
|
|
||||||
if (getStartTimestamp()
|
|
||||||
!= other.getStartTimestamp()) return false;
|
|
||||||
if (getEndTimestamp()
|
|
||||||
!= other.getEndTimestamp()) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
if (getTransactionsCount() > 0) {
|
|
||||||
hash = (37 * hash) + TRANSACTIONS_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getTransactionsList().hashCode();
|
|
||||||
}
|
|
||||||
hash = (37 * hash) + START_TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getStartTimestamp());
|
|
||||||
hash = (37 * hash) + END_TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + com.google.protobuf.Internal.hashLong(
|
|
||||||
getEndTimestamp());
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.GetTransactionsResponse prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* Protobuf type {@code bdledger.api.GetTransactionsResponse}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.GetTransactionsResponse)
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponseOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionsResponse_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse.class, bdledger.api.grpc.query.GetTransactionsResponse.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.GetTransactionsResponse.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
getTransactionsFieldBuilder();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
transactions_ = java.util.Collections.emptyList();
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.clear();
|
|
||||||
}
|
|
||||||
startTimestamp_ = 0L;
|
|
||||||
|
|
||||||
endTimestamp_ = 0L;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_GetTransactionsResponse_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionsResponse getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.GetTransactionsResponse.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionsResponse build() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionsResponse buildPartial() {
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse result = new bdledger.api.grpc.query.GetTransactionsResponse(this);
|
|
||||||
int from_bitField0_ = bitField0_;
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
if (((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
transactions_ = java.util.Collections.unmodifiableList(transactions_);
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
}
|
|
||||||
result.transactions_ = transactions_;
|
|
||||||
} else {
|
|
||||||
result.transactions_ = transactionsBuilder_.build();
|
|
||||||
}
|
|
||||||
result.startTimestamp_ = startTimestamp_;
|
|
||||||
result.endTimestamp_ = endTimestamp_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.GetTransactionsResponse) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.GetTransactionsResponse)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.GetTransactionsResponse other) {
|
|
||||||
if (other == bdledger.api.grpc.query.GetTransactionsResponse.getDefaultInstance()) return this;
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
if (!other.transactions_.isEmpty()) {
|
|
||||||
if (transactions_.isEmpty()) {
|
|
||||||
transactions_ = other.transactions_;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
} else {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.addAll(other.transactions_);
|
|
||||||
}
|
|
||||||
onChanged();
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
if (!other.transactions_.isEmpty()) {
|
|
||||||
if (transactionsBuilder_.isEmpty()) {
|
|
||||||
transactionsBuilder_.dispose();
|
|
||||||
transactionsBuilder_ = null;
|
|
||||||
transactions_ = other.transactions_;
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
transactionsBuilder_ =
|
|
||||||
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
|
|
||||||
getTransactionsFieldBuilder() : null;
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addAllMessages(other.transactions_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (other.getStartTimestamp() != 0L) {
|
|
||||||
setStartTimestamp(other.getStartTimestamp());
|
|
||||||
}
|
|
||||||
if (other.getEndTimestamp() != 0L) {
|
|
||||||
setEndTimestamp(other.getEndTimestamp());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.GetTransactionsResponse) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
private int bitField0_;
|
|
||||||
|
|
||||||
private java.util.List<bdledger.api.grpc.common.Transaction> transactions_ =
|
|
||||||
java.util.Collections.emptyList();
|
|
||||||
private void ensureTransactionsIsMutable() {
|
|
||||||
if (!((bitField0_ & 0x00000001) != 0)) {
|
|
||||||
transactions_ = new java.util.ArrayList<bdledger.api.grpc.common.Transaction>(transactions_);
|
|
||||||
bitField0_ |= 0x00000001;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder> transactionsBuilder_;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Transaction> getTransactionsList() {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
return java.util.Collections.unmodifiableList(transactions_);
|
|
||||||
} else {
|
|
||||||
return transactionsBuilder_.getMessageList();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public int getTransactionsCount() {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
return transactions_.size();
|
|
||||||
} else {
|
|
||||||
return transactionsBuilder_.getCount();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction getTransactions(int index) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
return transactions_.get(index);
|
|
||||||
} else {
|
|
||||||
return transactionsBuilder_.getMessage(index);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransactions(
|
|
||||||
int index, bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.set(index, value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.setMessage(index, value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder setTransactions(
|
|
||||||
int index, bdledger.api.grpc.common.Transaction.Builder builderForValue) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.set(index, builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.setMessage(index, builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addTransactions(bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.add(value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addMessage(value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addTransactions(
|
|
||||||
int index, bdledger.api.grpc.common.Transaction value) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.add(index, value);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addMessage(index, value);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addTransactions(
|
|
||||||
bdledger.api.grpc.common.Transaction.Builder builderForValue) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.add(builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addMessage(builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addTransactions(
|
|
||||||
int index, bdledger.api.grpc.common.Transaction.Builder builderForValue) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.add(index, builderForValue.build());
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addMessage(index, builderForValue.build());
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder addAllTransactions(
|
|
||||||
java.lang.Iterable<? extends bdledger.api.grpc.common.Transaction> values) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
|
||||||
values, transactions_);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.addAllMessages(values);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder clearTransactions() {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
transactions_ = java.util.Collections.emptyList();
|
|
||||||
bitField0_ = (bitField0_ & ~0x00000001);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.clear();
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public Builder removeTransactions(int index) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
ensureTransactionsIsMutable();
|
|
||||||
transactions_.remove(index);
|
|
||||||
onChanged();
|
|
||||||
} else {
|
|
||||||
transactionsBuilder_.remove(index);
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction.Builder getTransactionsBuilder(
|
|
||||||
int index) {
|
|
||||||
return getTransactionsFieldBuilder().getBuilder(index);
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.TransactionOrBuilder getTransactionsOrBuilder(
|
|
||||||
int index) {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
return transactions_.get(index); } else {
|
|
||||||
return transactionsBuilder_.getMessageOrBuilder(index);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<? extends bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionsOrBuilderList() {
|
|
||||||
if (transactionsBuilder_ != null) {
|
|
||||||
return transactionsBuilder_.getMessageOrBuilderList();
|
|
||||||
} else {
|
|
||||||
return java.util.Collections.unmodifiableList(transactions_);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction.Builder addTransactionsBuilder() {
|
|
||||||
return getTransactionsFieldBuilder().addBuilder(
|
|
||||||
bdledger.api.grpc.common.Transaction.getDefaultInstance());
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.common.Transaction.Builder addTransactionsBuilder(
|
|
||||||
int index) {
|
|
||||||
return getTransactionsFieldBuilder().addBuilder(
|
|
||||||
index, bdledger.api.grpc.common.Transaction.getDefaultInstance());
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
public java.util.List<bdledger.api.grpc.common.Transaction.Builder>
|
|
||||||
getTransactionsBuilderList() {
|
|
||||||
return getTransactionsFieldBuilder().getBuilderList();
|
|
||||||
}
|
|
||||||
private com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionsFieldBuilder() {
|
|
||||||
if (transactionsBuilder_ == null) {
|
|
||||||
transactionsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
|
|
||||||
bdledger.api.grpc.common.Transaction, bdledger.api.grpc.common.Transaction.Builder, bdledger.api.grpc.common.TransactionOrBuilder>(
|
|
||||||
transactions_,
|
|
||||||
((bitField0_ & 0x00000001) != 0),
|
|
||||||
getParentForChildren(),
|
|
||||||
isClean());
|
|
||||||
transactions_ = null;
|
|
||||||
}
|
|
||||||
return transactionsBuilder_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long startTimestamp_ ;
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
public long getStartTimestamp() {
|
|
||||||
return startTimestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @param value The startTimestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setStartTimestamp(long value) {
|
|
||||||
|
|
||||||
startTimestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearStartTimestamp() {
|
|
||||||
|
|
||||||
startTimestamp_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private long endTimestamp_ ;
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
public long getEndTimestamp() {
|
|
||||||
return endTimestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @param value The endTimestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setEndTimestamp(long value) {
|
|
||||||
|
|
||||||
endTimestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearEndTimestamp() {
|
|
||||||
|
|
||||||
endTimestamp_ = 0L;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.GetTransactionsResponse)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.GetTransactionsResponse)
|
|
||||||
private static final bdledger.api.grpc.query.GetTransactionsResponse DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.GetTransactionsResponse();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.GetTransactionsResponse getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<GetTransactionsResponse>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<GetTransactionsResponse>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public GetTransactionsResponse parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new GetTransactionsResponse(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<GetTransactionsResponse> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<GetTransactionsResponse> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.GetTransactionsResponse getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,45 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface GetTransactionsResponseOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.GetTransactionsResponse)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.common.Transaction>
|
|
||||||
getTransactionsList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.Transaction getTransactions(int index);
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
int getTransactionsCount();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.common.TransactionOrBuilder>
|
|
||||||
getTransactionsOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.Transaction transactions = 1;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.common.TransactionOrBuilder getTransactionsOrBuilder(
|
|
||||||
int index);
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
long getStartTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
long getEndTimestamp();
|
|
||||||
}
|
|
@ -1,744 +0,0 @@
|
|||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
|
||||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
|
||||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
|
|
||||||
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
@javax.annotation.Generated(
|
|
||||||
value = "by gRPC proto compiler (version 1.27.0)",
|
|
||||||
comments = "Source: bdledger/api/query.proto")
|
|
||||||
public final class QueryGrpc {
|
|
||||||
|
|
||||||
private QueryGrpc() {}
|
|
||||||
|
|
||||||
public static final String SERVICE_NAME = "bdledger.api.Query";
|
|
||||||
|
|
||||||
// Static method descriptors that strictly reflect the proto.
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetBlockByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse> getGetBlockByHashMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetBlockByHash",
|
|
||||||
requestType = bdledger.api.grpc.query.GetBlockByHashRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.GetBlockByHashResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetBlockByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse> getGetBlockByHashMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetBlockByHashRequest, bdledger.api.grpc.query.GetBlockByHashResponse> getGetBlockByHashMethod;
|
|
||||||
if ((getGetBlockByHashMethod = QueryGrpc.getGetBlockByHashMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getGetBlockByHashMethod = QueryGrpc.getGetBlockByHashMethod) == null) {
|
|
||||||
QueryGrpc.getGetBlockByHashMethod = getGetBlockByHashMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.GetBlockByHashRequest, bdledger.api.grpc.query.GetBlockByHashResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBlockByHash"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetBlockByHash"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getGetBlockByHashMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse> getGetBlocksMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetBlocks",
|
|
||||||
requestType = bdledger.api.grpc.query.BlocksRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.GetBlocksResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse> getGetBlocksMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest, bdledger.api.grpc.query.GetBlocksResponse> getGetBlocksMethod;
|
|
||||||
if ((getGetBlocksMethod = QueryGrpc.getGetBlocksMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getGetBlocksMethod = QueryGrpc.getGetBlocksMethod) == null) {
|
|
||||||
QueryGrpc.getGetBlocksMethod = getGetBlocksMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.BlocksRequest, bdledger.api.grpc.query.GetBlocksResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBlocks"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.BlocksRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetBlocks"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getGetBlocksMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse> getCountBlocksMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "CountBlocks",
|
|
||||||
requestType = bdledger.api.grpc.query.BlocksRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.CountBlocksResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse> getCountBlocksMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.BlocksRequest, bdledger.api.grpc.query.CountBlocksResponse> getCountBlocksMethod;
|
|
||||||
if ((getCountBlocksMethod = QueryGrpc.getCountBlocksMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getCountBlocksMethod = QueryGrpc.getCountBlocksMethod) == null) {
|
|
||||||
QueryGrpc.getCountBlocksMethod = getCountBlocksMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.BlocksRequest, bdledger.api.grpc.query.CountBlocksResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CountBlocks"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.BlocksRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("CountBlocks"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getCountBlocksMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse> getGetTransactionByHashMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetTransactionByHash",
|
|
||||||
requestType = bdledger.api.grpc.query.GetTransactionByHashRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.GetTransactionByHashResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse> getGetTransactionByHashMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByHashRequest, bdledger.api.grpc.query.GetTransactionByHashResponse> getGetTransactionByHashMethod;
|
|
||||||
if ((getGetTransactionByHashMethod = QueryGrpc.getGetTransactionByHashMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getGetTransactionByHashMethod = QueryGrpc.getGetTransactionByHashMethod) == null) {
|
|
||||||
QueryGrpc.getGetTransactionByHashMethod = getGetTransactionByHashMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.GetTransactionByHashRequest, bdledger.api.grpc.query.GetTransactionByHashResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactionByHash"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactionByHash"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getGetTransactionByHashMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetTransactionByBlockHashAndIndex",
|
|
||||||
requestType = bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod;
|
|
||||||
if ((getGetTransactionByBlockHashAndIndexMethod = QueryGrpc.getGetTransactionByBlockHashAndIndexMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getGetTransactionByBlockHashAndIndexMethod = QueryGrpc.getGetTransactionByBlockHashAndIndexMethod) == null) {
|
|
||||||
QueryGrpc.getGetTransactionByBlockHashAndIndexMethod = getGetTransactionByBlockHashAndIndexMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest, bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactionByBlockHashAndIndex"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactionByBlockHashAndIndex"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getGetTransactionByBlockHashAndIndexMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse> getGetTransactionsMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetTransactions",
|
|
||||||
requestType = bdledger.api.grpc.query.TransactionsRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.GetTransactionsResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse> getGetTransactionsMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest, bdledger.api.grpc.query.GetTransactionsResponse> getGetTransactionsMethod;
|
|
||||||
if ((getGetTransactionsMethod = QueryGrpc.getGetTransactionsMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getGetTransactionsMethod = QueryGrpc.getGetTransactionsMethod) == null) {
|
|
||||||
QueryGrpc.getGetTransactionsMethod = getGetTransactionsMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.TransactionsRequest, bdledger.api.grpc.query.GetTransactionsResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactions"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactions"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getGetTransactionsMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse> getCountTransactionsMethod;
|
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
|
||||||
fullMethodName = SERVICE_NAME + '/' + "CountTransactions",
|
|
||||||
requestType = bdledger.api.grpc.query.TransactionsRequest.class,
|
|
||||||
responseType = bdledger.api.grpc.query.CountTransactionsResponse.class,
|
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse> getCountTransactionsMethod() {
|
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.query.TransactionsRequest, bdledger.api.grpc.query.CountTransactionsResponse> getCountTransactionsMethod;
|
|
||||||
if ((getCountTransactionsMethod = QueryGrpc.getCountTransactionsMethod) == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
if ((getCountTransactionsMethod = QueryGrpc.getCountTransactionsMethod) == null) {
|
|
||||||
QueryGrpc.getCountTransactionsMethod = getCountTransactionsMethod =
|
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.query.TransactionsRequest, bdledger.api.grpc.query.CountTransactionsResponse>newBuilder()
|
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CountTransactions"))
|
|
||||||
.setSampledToLocalTracing(true)
|
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest.getDefaultInstance()))
|
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse.getDefaultInstance()))
|
|
||||||
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("CountTransactions"))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return getCountTransactionsMethod;
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Creates a new async stub that supports all call types for the service
|
|
||||||
*/
|
|
||||||
public static QueryStub newStub(io.grpc.Channel channel) {
|
|
||||||
io.grpc.stub.AbstractStub.StubFactory<QueryStub> factory =
|
|
||||||
new io.grpc.stub.AbstractStub.StubFactory<QueryStub>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public QueryStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
return QueryStub.newStub(factory, channel);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Creates a new blocking-style stub that supports unary and streaming output calls on the service
|
|
||||||
*/
|
|
||||||
public static QueryBlockingStub newBlockingStub(
|
|
||||||
io.grpc.Channel channel) {
|
|
||||||
io.grpc.stub.AbstractStub.StubFactory<QueryBlockingStub> factory =
|
|
||||||
new io.grpc.stub.AbstractStub.StubFactory<QueryBlockingStub>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public QueryBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryBlockingStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
return QueryBlockingStub.newStub(factory, channel);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Creates a new ListenableFuture-style stub that supports unary calls on the service
|
|
||||||
*/
|
|
||||||
public static QueryFutureStub newFutureStub(
|
|
||||||
io.grpc.Channel channel) {
|
|
||||||
io.grpc.stub.AbstractStub.StubFactory<QueryFutureStub> factory =
|
|
||||||
new io.grpc.stub.AbstractStub.StubFactory<QueryFutureStub>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public QueryFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryFutureStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
return QueryFutureStub.newStub(factory, channel);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public static abstract class QueryImplBase implements io.grpc.BindableService {
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getBlockByHash(bdledger.api.grpc.query.GetBlockByHashRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlockByHashResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* start_timestamp is required
|
|
||||||
* </pre>
|
|
||||||
*/
|
|
||||||
public void getBlocks(bdledger.api.grpc.query.BlocksRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlocksResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void countBlocks(bdledger.api.grpc.query.BlocksRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountBlocksResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactionByHash(bdledger.api.grpc.query.GetTransactionByHashRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByHashResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactionByBlockHashAndIndex(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactions(bdledger.api.grpc.query.TransactionsRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionsResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void countTransactions(bdledger.api.grpc.query.TransactionsRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountTransactionsResponse> responseObserver) {
|
|
||||||
asyncUnimplementedUnaryCall(getCountTransactionsMethod(), responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
|
|
||||||
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
|
|
||||||
.addMethod(
|
|
||||||
getGetBlockByHashMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashResponse>(
|
|
||||||
this, METHODID_GET_BLOCK_BY_HASH)))
|
|
||||||
.addMethod(
|
|
||||||
getGetBlocksMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.GetBlocksResponse>(
|
|
||||||
this, METHODID_GET_BLOCKS)))
|
|
||||||
.addMethod(
|
|
||||||
getCountBlocksMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.BlocksRequest,
|
|
||||||
bdledger.api.grpc.query.CountBlocksResponse>(
|
|
||||||
this, METHODID_COUNT_BLOCKS)))
|
|
||||||
.addMethod(
|
|
||||||
getGetTransactionByHashMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashResponse>(
|
|
||||||
this, METHODID_GET_TRANSACTION_BY_HASH)))
|
|
||||||
.addMethod(
|
|
||||||
getGetTransactionByBlockHashAndIndexMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse>(
|
|
||||||
this, METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX)))
|
|
||||||
.addMethod(
|
|
||||||
getGetTransactionsMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.GetTransactionsResponse>(
|
|
||||||
this, METHODID_GET_TRANSACTIONS)))
|
|
||||||
.addMethod(
|
|
||||||
getCountTransactionsMethod(),
|
|
||||||
asyncUnaryCall(
|
|
||||||
new MethodHandlers<
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest,
|
|
||||||
bdledger.api.grpc.query.CountTransactionsResponse>(
|
|
||||||
this, METHODID_COUNT_TRANSACTIONS)))
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public static final class QueryStub extends io.grpc.stub.AbstractAsyncStub<QueryStub> {
|
|
||||||
private QueryStub(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
super(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected QueryStub build(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getBlockByHash(bdledger.api.grpc.query.GetBlockByHashRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlockByHashResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* start_timestamp is required
|
|
||||||
* </pre>
|
|
||||||
*/
|
|
||||||
public void getBlocks(bdledger.api.grpc.query.BlocksRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlocksResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void countBlocks(bdledger.api.grpc.query.BlocksRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountBlocksResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactionByHash(bdledger.api.grpc.query.GetTransactionByHashRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByHashResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactionByBlockHashAndIndex(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void getTransactions(bdledger.api.grpc.query.TransactionsRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionsResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public void countTransactions(bdledger.api.grpc.query.TransactionsRequest request,
|
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountTransactionsResponse> responseObserver) {
|
|
||||||
asyncUnaryCall(
|
|
||||||
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request, responseObserver);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public static final class QueryBlockingStub extends io.grpc.stub.AbstractBlockingStub<QueryBlockingStub> {
|
|
||||||
private QueryBlockingStub(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
super(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected QueryBlockingStub build(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryBlockingStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.GetBlockByHashResponse getBlockByHash(bdledger.api.grpc.query.GetBlockByHashRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getGetBlockByHashMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* start_timestamp is required
|
|
||||||
* </pre>
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.GetBlocksResponse getBlocks(bdledger.api.grpc.query.BlocksRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getGetBlocksMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.CountBlocksResponse countBlocks(bdledger.api.grpc.query.BlocksRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getCountBlocksMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByHashResponse getTransactionByHash(bdledger.api.grpc.query.GetTransactionByHashRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getGetTransactionByHashMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse getTransactionByBlockHashAndIndex(bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getGetTransactionByBlockHashAndIndexMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.GetTransactionsResponse getTransactions(bdledger.api.grpc.query.TransactionsRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getGetTransactionsMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public bdledger.api.grpc.query.CountTransactionsResponse countTransactions(bdledger.api.grpc.query.TransactionsRequest request) {
|
|
||||||
return blockingUnaryCall(
|
|
||||||
getChannel(), getCountTransactionsMethod(), getCallOptions(), request);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public static final class QueryFutureStub extends io.grpc.stub.AbstractFutureStub<QueryFutureStub> {
|
|
||||||
private QueryFutureStub(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
super(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected QueryFutureStub build(
|
|
||||||
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
|
||||||
return new QueryFutureStub(channel, callOptions);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.GetBlockByHashResponse> getBlockByHash(
|
|
||||||
bdledger.api.grpc.query.GetBlockByHashRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* start_timestamp is required
|
|
||||||
* </pre>
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.GetBlocksResponse> getBlocks(
|
|
||||||
bdledger.api.grpc.query.BlocksRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.CountBlocksResponse> countBlocks(
|
|
||||||
bdledger.api.grpc.query.BlocksRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.GetTransactionByHashResponse> getTransactionByHash(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByHashRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse> getTransactionByBlockHashAndIndex(
|
|
||||||
bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.GetTransactionsResponse> getTransactions(
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*/
|
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.query.CountTransactionsResponse> countTransactions(
|
|
||||||
bdledger.api.grpc.query.TransactionsRequest request) {
|
|
||||||
return futureUnaryCall(
|
|
||||||
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final int METHODID_GET_BLOCK_BY_HASH = 0;
|
|
||||||
private static final int METHODID_GET_BLOCKS = 1;
|
|
||||||
private static final int METHODID_COUNT_BLOCKS = 2;
|
|
||||||
private static final int METHODID_GET_TRANSACTION_BY_HASH = 3;
|
|
||||||
private static final int METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX = 4;
|
|
||||||
private static final int METHODID_GET_TRANSACTIONS = 5;
|
|
||||||
private static final int METHODID_COUNT_TRANSACTIONS = 6;
|
|
||||||
|
|
||||||
private static final class MethodHandlers<Req, Resp> implements
|
|
||||||
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
|
||||||
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
|
||||||
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
|
||||||
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
|
||||||
private final QueryImplBase serviceImpl;
|
|
||||||
private final int methodId;
|
|
||||||
|
|
||||||
MethodHandlers(QueryImplBase serviceImpl, int methodId) {
|
|
||||||
this.serviceImpl = serviceImpl;
|
|
||||||
this.methodId = methodId;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@java.lang.SuppressWarnings("unchecked")
|
|
||||||
public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
|
||||||
switch (methodId) {
|
|
||||||
case METHODID_GET_BLOCK_BY_HASH:
|
|
||||||
serviceImpl.getBlockByHash((bdledger.api.grpc.query.GetBlockByHashRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlockByHashResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_GET_BLOCKS:
|
|
||||||
serviceImpl.getBlocks((bdledger.api.grpc.query.BlocksRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetBlocksResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_COUNT_BLOCKS:
|
|
||||||
serviceImpl.countBlocks((bdledger.api.grpc.query.BlocksRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountBlocksResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_GET_TRANSACTION_BY_HASH:
|
|
||||||
serviceImpl.getTransactionByHash((bdledger.api.grpc.query.GetTransactionByHashRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByHashResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX:
|
|
||||||
serviceImpl.getTransactionByBlockHashAndIndex((bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionByBlockHashAndIndexResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_GET_TRANSACTIONS:
|
|
||||||
serviceImpl.getTransactions((bdledger.api.grpc.query.TransactionsRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.GetTransactionsResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
case METHODID_COUNT_TRANSACTIONS:
|
|
||||||
serviceImpl.countTransactions((bdledger.api.grpc.query.TransactionsRequest) request,
|
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.query.CountTransactionsResponse>) responseObserver);
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
throw new AssertionError();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@java.lang.SuppressWarnings("unchecked")
|
|
||||||
public io.grpc.stub.StreamObserver<Req> invoke(
|
|
||||||
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
|
||||||
switch (methodId) {
|
|
||||||
default:
|
|
||||||
throw new AssertionError();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static abstract class QueryBaseDescriptorSupplier
|
|
||||||
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
|
|
||||||
QueryBaseDescriptorSupplier() {}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.getDescriptor();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() {
|
|
||||||
return getFileDescriptor().findServiceByName("Query");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final class QueryFileDescriptorSupplier
|
|
||||||
extends QueryBaseDescriptorSupplier {
|
|
||||||
QueryFileDescriptorSupplier() {}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final class QueryMethodDescriptorSupplier
|
|
||||||
extends QueryBaseDescriptorSupplier
|
|
||||||
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
|
|
||||||
private final String methodName;
|
|
||||||
|
|
||||||
QueryMethodDescriptorSupplier(String methodName) {
|
|
||||||
this.methodName = methodName;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() {
|
|
||||||
return getServiceDescriptor().findMethodByName(methodName);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private static volatile io.grpc.ServiceDescriptor serviceDescriptor;
|
|
||||||
|
|
||||||
public static io.grpc.ServiceDescriptor getServiceDescriptor() {
|
|
||||||
io.grpc.ServiceDescriptor result = serviceDescriptor;
|
|
||||||
if (result == null) {
|
|
||||||
synchronized (QueryGrpc.class) {
|
|
||||||
result = serviceDescriptor;
|
|
||||||
if (result == null) {
|
|
||||||
serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
|
|
||||||
.setSchemaDescriptor(new QueryFileDescriptorSupplier())
|
|
||||||
.addMethod(getGetBlockByHashMethod())
|
|
||||||
.addMethod(getGetBlocksMethod())
|
|
||||||
.addMethod(getCountBlocksMethod())
|
|
||||||
.addMethod(getGetTransactionByHashMethod())
|
|
||||||
.addMethod(getGetTransactionByBlockHashAndIndexMethod())
|
|
||||||
.addMethod(getGetTransactionsMethod())
|
|
||||||
.addMethod(getCountTransactionsMethod())
|
|
||||||
.build();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,242 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public final class QueryProto {
|
|
||||||
private QueryProto() {}
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistryLite registry) {
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void registerAllExtensions(
|
|
||||||
com.google.protobuf.ExtensionRegistry registry) {
|
|
||||||
registerAllExtensions(
|
|
||||||
(com.google.protobuf.ExtensionRegistryLite) registry);
|
|
||||||
}
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_BlockFilter_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_BlockFilter_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_TransactionFilter_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_TransactionFilter_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetBlockByHashRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetBlockByHashRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetBlockByHashResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetBlockByHashResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_BlocksRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_BlocksRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetBlocksResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetBlocksResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_CountBlocksResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_CountBlocksResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_TransactionsRequest_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_TransactionsRequest_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_GetTransactionsResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_GetTransactionsResponse_fieldAccessorTable;
|
|
||||||
static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
internal_static_bdledger_api_CountTransactionsResponse_descriptor;
|
|
||||||
static final
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internal_static_bdledger_api_CountTransactionsResponse_fieldAccessorTable;
|
|
||||||
|
|
||||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return descriptor;
|
|
||||||
}
|
|
||||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
descriptor;
|
|
||||||
static {
|
|
||||||
java.lang.String[] descriptorData = {
|
|
||||||
"\n\030bdledger/api/query.proto\022\014bdledger.api" +
|
|
||||||
"\032\031bdledger/api/common.proto\".\n\013BlockFilt" +
|
|
||||||
"er\022\014\n\004hash\030\001 \001(\014\022\021\n\ttimestamp\030\002 \001(\003\"N\n\021T" +
|
|
||||||
"ransactionFilter\022\014\n\004hash\030\001 \001(\014\022\014\n\004from\030\002" +
|
|
||||||
" \001(\014\022\n\n\002to\030\003 \001(\014\022\021\n\ttimestamp\030\004 \001(\014\"P\n\025G" +
|
|
||||||
"etBlockByHashRequest\022\016\n\006ledger\030\001 \001(\t\022\014\n\004" +
|
|
||||||
"hash\030\002 \001(\014\022\031\n\021full_transactions\030\003 \001(\010\"<\n" +
|
|
||||||
"\026GetBlockByHashResponse\022\"\n\005block\030\001 \001(\0132\023" +
|
|
||||||
".bdledger.api.Block\"{\n\rBlocksRequest\022\016\n\006" +
|
|
||||||
"ledger\030\001 \001(\t\022\027\n\017start_timestamp\030\002 \001(\003\022\025\n" +
|
|
||||||
"\rend_timestamp\030\003 \001(\003\022*\n\007filters\030\004 \003(\0132\031." +
|
|
||||||
"bdledger.api.BlockFilter\"h\n\021GetBlocksRes" +
|
|
||||||
"ponse\022#\n\006blocks\030\001 \003(\0132\023.bdledger.api.Blo" +
|
|
||||||
"ck\022\027\n\017start_timestamp\030\002 \001(\003\022\025\n\rend_times" +
|
|
||||||
"tamp\030\003 \001(\003\"$\n\023CountBlocksResponse\022\r\n\005cou" +
|
|
||||||
"nt\030\001 \001(\004\";\n\033GetTransactionByHashRequest\022" +
|
|
||||||
"\016\n\006ledger\030\001 \001(\t\022\014\n\004hash\030\002 \001(\014\"N\n\034GetTran" +
|
|
||||||
"sactionByHashResponse\022.\n\013transaction\030\001 \001" +
|
|
||||||
"(\0132\031.bdledger.api.Transaction\"]\n(GetTran" +
|
|
||||||
"sactionByBlockHashAndIndexRequest\022\016\n\006led" +
|
|
||||||
"ger\030\001 \001(\t\022\022\n\nblock_hash\030\002 \001(\014\022\r\n\005index\030\003" +
|
|
||||||
" \001(\r\"[\n)GetTransactionByBlockHashAndInde" +
|
|
||||||
"xResponse\022.\n\013transaction\030\001 \001(\0132\031.bdledge" +
|
|
||||||
"r.api.Transaction\"\207\001\n\023TransactionsReques" +
|
|
||||||
"t\022\016\n\006ledger\030\001 \001(\t\022\027\n\017start_timestamp\030\002 \001" +
|
|
||||||
"(\003\022\025\n\rend_timestamp\030\003 \001(\003\0220\n\007filters\030\004 \003" +
|
|
||||||
"(\0132\037.bdledger.api.TransactionFilter\"z\n\027G" +
|
|
||||||
"etTransactionsResponse\022/\n\014transactions\030\001" +
|
|
||||||
" \003(\0132\031.bdledger.api.Transaction\022\027\n\017start" +
|
|
||||||
"_timestamp\030\002 \001(\003\022\025\n\rend_timestamp\030\003 \001(\003\"" +
|
|
||||||
"*\n\031CountTransactionsResponse\022\r\n\005count\030\001 " +
|
|
||||||
"\001(\0042\302\005\n\005Query\022[\n\016GetBlockByHash\022#.bdledg" +
|
|
||||||
"er.api.GetBlockByHashRequest\032$.bdledger." +
|
|
||||||
"api.GetBlockByHashResponse\022I\n\tGetBlocks\022" +
|
|
||||||
"\033.bdledger.api.BlocksRequest\032\037.bdledger." +
|
|
||||||
"api.GetBlocksResponse\022M\n\013CountBlocks\022\033.b" +
|
|
||||||
"dledger.api.BlocksRequest\032!.bdledger.api" +
|
|
||||||
".CountBlocksResponse\022m\n\024GetTransactionBy" +
|
|
||||||
"Hash\022).bdledger.api.GetTransactionByHash" +
|
|
||||||
"Request\032*.bdledger.api.GetTransactionByH" +
|
|
||||||
"ashResponse\022\224\001\n!GetTransactionByBlockHas" +
|
|
||||||
"hAndIndex\0226.bdledger.api.GetTransactionB" +
|
|
||||||
"yBlockHashAndIndexRequest\0327.bdledger.api" +
|
|
||||||
".GetTransactionByBlockHashAndIndexRespon" +
|
|
||||||
"se\022[\n\017GetTransactions\022!.bdledger.api.Tra" +
|
|
||||||
"nsactionsRequest\032%.bdledger.api.GetTrans" +
|
|
||||||
"actionsResponse\022_\n\021CountTransactions\022!.b" +
|
|
||||||
"dledger.api.TransactionsRequest\032\'.bdledg" +
|
|
||||||
"er.api.CountTransactionsResponseBO\n\027bdle" +
|
|
||||||
"dger.api.grpc.queryB\nQueryProtoP\001Z&bdwar" +
|
|
||||||
"e.org/bdledger/pkg/api/grpc/protob\006proto" +
|
|
||||||
"3"
|
|
||||||
};
|
|
||||||
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
|
||||||
.internalBuildGeneratedFileFrom(descriptorData,
|
|
||||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
|
||||||
bdledger.api.grpc.common.CommonProto.getDescriptor(),
|
|
||||||
});
|
|
||||||
internal_static_bdledger_api_BlockFilter_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(0);
|
|
||||||
internal_static_bdledger_api_BlockFilter_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_BlockFilter_descriptor,
|
|
||||||
new java.lang.String[] { "Hash", "Timestamp", });
|
|
||||||
internal_static_bdledger_api_TransactionFilter_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(1);
|
|
||||||
internal_static_bdledger_api_TransactionFilter_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_TransactionFilter_descriptor,
|
|
||||||
new java.lang.String[] { "Hash", "From", "To", "Timestamp", });
|
|
||||||
internal_static_bdledger_api_GetBlockByHashRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(2);
|
|
||||||
internal_static_bdledger_api_GetBlockByHashRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetBlockByHashRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "Hash", "FullTransactions", });
|
|
||||||
internal_static_bdledger_api_GetBlockByHashResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(3);
|
|
||||||
internal_static_bdledger_api_GetBlockByHashResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetBlockByHashResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Block", });
|
|
||||||
internal_static_bdledger_api_BlocksRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(4);
|
|
||||||
internal_static_bdledger_api_BlocksRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_BlocksRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "StartTimestamp", "EndTimestamp", "Filters", });
|
|
||||||
internal_static_bdledger_api_GetBlocksResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(5);
|
|
||||||
internal_static_bdledger_api_GetBlocksResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetBlocksResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Blocks", "StartTimestamp", "EndTimestamp", });
|
|
||||||
internal_static_bdledger_api_CountBlocksResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(6);
|
|
||||||
internal_static_bdledger_api_CountBlocksResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_CountBlocksResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Count", });
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(7);
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "Hash", });
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(8);
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetTransactionByHashResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Transaction", });
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(9);
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "BlockHash", "Index", });
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(10);
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetTransactionByBlockHashAndIndexResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Transaction", });
|
|
||||||
internal_static_bdledger_api_TransactionsRequest_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(11);
|
|
||||||
internal_static_bdledger_api_TransactionsRequest_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_TransactionsRequest_descriptor,
|
|
||||||
new java.lang.String[] { "Ledger", "StartTimestamp", "EndTimestamp", "Filters", });
|
|
||||||
internal_static_bdledger_api_GetTransactionsResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(12);
|
|
||||||
internal_static_bdledger_api_GetTransactionsResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_GetTransactionsResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Transactions", "StartTimestamp", "EndTimestamp", });
|
|
||||||
internal_static_bdledger_api_CountTransactionsResponse_descriptor =
|
|
||||||
getDescriptor().getMessageTypes().get(13);
|
|
||||||
internal_static_bdledger_api_CountTransactionsResponse_fieldAccessorTable = new
|
|
||||||
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
|
||||||
internal_static_bdledger_api_CountTransactionsResponse_descriptor,
|
|
||||||
new java.lang.String[] { "Count", });
|
|
||||||
bdledger.api.grpc.common.CommonProto.getDescriptor();
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(outer_class_scope)
|
|
||||||
}
|
|
@ -1,691 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* repeated Transaction/BlockFilters are combined by "&&"(and) operator;
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* Protobuf type {@code bdledger.api.TransactionFilter}
|
|
||||||
*/
|
|
||||||
public final class TransactionFilter extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3 implements
|
|
||||||
// @@protoc_insertion_point(message_implements:bdledger.api.TransactionFilter)
|
|
||||||
TransactionFilterOrBuilder {
|
|
||||||
private static final long serialVersionUID = 0L;
|
|
||||||
// Use TransactionFilter.newBuilder() to construct.
|
|
||||||
private TransactionFilter(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
|
||||||
super(builder);
|
|
||||||
}
|
|
||||||
private TransactionFilter() {
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
from_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
to_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
timestamp_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
@SuppressWarnings({"unused"})
|
|
||||||
protected java.lang.Object newInstance(
|
|
||||||
UnusedPrivateParameter unused) {
|
|
||||||
return new TransactionFilter();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final com.google.protobuf.UnknownFieldSet
|
|
||||||
getUnknownFields() {
|
|
||||||
return this.unknownFields;
|
|
||||||
}
|
|
||||||
private TransactionFilter(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
this();
|
|
||||||
if (extensionRegistry == null) {
|
|
||||||
throw new java.lang.NullPointerException();
|
|
||||||
}
|
|
||||||
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
|
||||||
com.google.protobuf.UnknownFieldSet.newBuilder();
|
|
||||||
try {
|
|
||||||
boolean done = false;
|
|
||||||
while (!done) {
|
|
||||||
int tag = input.readTag();
|
|
||||||
switch (tag) {
|
|
||||||
case 0:
|
|
||||||
done = true;
|
|
||||||
break;
|
|
||||||
case 10: {
|
|
||||||
|
|
||||||
hash_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 18: {
|
|
||||||
|
|
||||||
from_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 26: {
|
|
||||||
|
|
||||||
to_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 34: {
|
|
||||||
|
|
||||||
timestamp_ = input.readBytes();
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default: {
|
|
||||||
if (!parseUnknownField(
|
|
||||||
input, unknownFields, extensionRegistry, tag)) {
|
|
||||||
done = true;
|
|
||||||
}
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
throw e.setUnfinishedMessage(this);
|
|
||||||
} catch (java.io.IOException e) {
|
|
||||||
throw new com.google.protobuf.InvalidProtocolBufferException(
|
|
||||||
e).setUnfinishedMessage(this);
|
|
||||||
} finally {
|
|
||||||
this.unknownFields = unknownFields.build();
|
|
||||||
makeExtensionsImmutable();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_TransactionFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_TransactionFilter_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.TransactionFilter.class, bdledger.api.grpc.query.TransactionFilter.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int HASH_FIELD_NUMBER = 1;
|
|
||||||
private com.google.protobuf.ByteString hash_;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int FROM_FIELD_NUMBER = 2;
|
|
||||||
private com.google.protobuf.ByteString from_;
|
|
||||||
/**
|
|
||||||
* <code>bytes from = 2;</code>
|
|
||||||
* @return The from.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getFrom() {
|
|
||||||
return from_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TO_FIELD_NUMBER = 3;
|
|
||||||
private com.google.protobuf.ByteString to_;
|
|
||||||
/**
|
|
||||||
* <code>bytes to = 3;</code>
|
|
||||||
* @return The to.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getTo() {
|
|
||||||
return to_;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static final int TIMESTAMP_FIELD_NUMBER = 4;
|
|
||||||
private com.google.protobuf.ByteString timestamp_;
|
|
||||||
/**
|
|
||||||
* <code>bytes timestamp = 4;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getTimestamp() {
|
|
||||||
return timestamp_;
|
|
||||||
}
|
|
||||||
|
|
||||||
private byte memoizedIsInitialized = -1;
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
byte isInitialized = memoizedIsInitialized;
|
|
||||||
if (isInitialized == 1) return true;
|
|
||||||
if (isInitialized == 0) return false;
|
|
||||||
|
|
||||||
memoizedIsInitialized = 1;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
|
||||||
throws java.io.IOException {
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
output.writeBytes(1, hash_);
|
|
||||||
}
|
|
||||||
if (!from_.isEmpty()) {
|
|
||||||
output.writeBytes(2, from_);
|
|
||||||
}
|
|
||||||
if (!to_.isEmpty()) {
|
|
||||||
output.writeBytes(3, to_);
|
|
||||||
}
|
|
||||||
if (!timestamp_.isEmpty()) {
|
|
||||||
output.writeBytes(4, timestamp_);
|
|
||||||
}
|
|
||||||
unknownFields.writeTo(output);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int getSerializedSize() {
|
|
||||||
int size = memoizedSize;
|
|
||||||
if (size != -1) return size;
|
|
||||||
|
|
||||||
size = 0;
|
|
||||||
if (!hash_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(1, hash_);
|
|
||||||
}
|
|
||||||
if (!from_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(2, from_);
|
|
||||||
}
|
|
||||||
if (!to_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(3, to_);
|
|
||||||
}
|
|
||||||
if (!timestamp_.isEmpty()) {
|
|
||||||
size += com.google.protobuf.CodedOutputStream
|
|
||||||
.computeBytesSize(4, timestamp_);
|
|
||||||
}
|
|
||||||
size += unknownFields.getSerializedSize();
|
|
||||||
memoizedSize = size;
|
|
||||||
return size;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public boolean equals(final java.lang.Object obj) {
|
|
||||||
if (obj == this) {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
if (!(obj instanceof bdledger.api.grpc.query.TransactionFilter)) {
|
|
||||||
return super.equals(obj);
|
|
||||||
}
|
|
||||||
bdledger.api.grpc.query.TransactionFilter other = (bdledger.api.grpc.query.TransactionFilter) obj;
|
|
||||||
|
|
||||||
if (!getHash()
|
|
||||||
.equals(other.getHash())) return false;
|
|
||||||
if (!getFrom()
|
|
||||||
.equals(other.getFrom())) return false;
|
|
||||||
if (!getTo()
|
|
||||||
.equals(other.getTo())) return false;
|
|
||||||
if (!getTimestamp()
|
|
||||||
.equals(other.getTimestamp())) return false;
|
|
||||||
if (!unknownFields.equals(other.unknownFields)) return false;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public int hashCode() {
|
|
||||||
if (memoizedHashCode != 0) {
|
|
||||||
return memoizedHashCode;
|
|
||||||
}
|
|
||||||
int hash = 41;
|
|
||||||
hash = (19 * hash) + getDescriptor().hashCode();
|
|
||||||
hash = (37 * hash) + HASH_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getHash().hashCode();
|
|
||||||
hash = (37 * hash) + FROM_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getFrom().hashCode();
|
|
||||||
hash = (37 * hash) + TO_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getTo().hashCode();
|
|
||||||
hash = (37 * hash) + TIMESTAMP_FIELD_NUMBER;
|
|
||||||
hash = (53 * hash) + getTimestamp().hashCode();
|
|
||||||
hash = (29 * hash) + unknownFields.hashCode();
|
|
||||||
memoizedHashCode = hash;
|
|
||||||
return hash;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
java.nio.ByteBuffer data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
java.nio.ByteBuffer data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
com.google.protobuf.ByteString data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
com.google.protobuf.ByteString data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(byte[] data)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
byte[] data,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return PARSER.parseFrom(data, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseDelimitedFrom(java.io.InputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseDelimitedFrom(
|
|
||||||
java.io.InputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input);
|
|
||||||
}
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter parseFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
return com.google.protobuf.GeneratedMessageV3
|
|
||||||
.parseWithIOException(PARSER, input, extensionRegistry);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder newBuilderForType() { return newBuilder(); }
|
|
||||||
public static Builder newBuilder() {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder();
|
|
||||||
}
|
|
||||||
public static Builder newBuilder(bdledger.api.grpc.query.TransactionFilter prototype) {
|
|
||||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder toBuilder() {
|
|
||||||
return this == DEFAULT_INSTANCE
|
|
||||||
? new Builder() : new Builder().mergeFrom(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected Builder newBuilderForType(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
Builder builder = new Builder(parent);
|
|
||||||
return builder;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* repeated Transaction/BlockFilters are combined by "&&"(and) operator;
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* Protobuf type {@code bdledger.api.TransactionFilter}
|
|
||||||
*/
|
|
||||||
public static final class Builder extends
|
|
||||||
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
|
||||||
// @@protoc_insertion_point(builder_implements:bdledger.api.TransactionFilter)
|
|
||||||
bdledger.api.grpc.query.TransactionFilterOrBuilder {
|
|
||||||
public static final com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptor() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_TransactionFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
|
||||||
internalGetFieldAccessorTable() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_TransactionFilter_fieldAccessorTable
|
|
||||||
.ensureFieldAccessorsInitialized(
|
|
||||||
bdledger.api.grpc.query.TransactionFilter.class, bdledger.api.grpc.query.TransactionFilter.Builder.class);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Construct using bdledger.api.grpc.query.TransactionFilter.newBuilder()
|
|
||||||
private Builder() {
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
|
|
||||||
private Builder(
|
|
||||||
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
|
||||||
super(parent);
|
|
||||||
maybeForceBuilderInitialization();
|
|
||||||
}
|
|
||||||
private void maybeForceBuilderInitialization() {
|
|
||||||
if (com.google.protobuf.GeneratedMessageV3
|
|
||||||
.alwaysUseFieldBuilders) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clear() {
|
|
||||||
super.clear();
|
|
||||||
hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
from_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
to_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
timestamp_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Descriptors.Descriptor
|
|
||||||
getDescriptorForType() {
|
|
||||||
return bdledger.api.grpc.query.QueryProto.internal_static_bdledger_api_TransactionFilter_descriptor;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.TransactionFilter getDefaultInstanceForType() {
|
|
||||||
return bdledger.api.grpc.query.TransactionFilter.getDefaultInstance();
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.TransactionFilter build() {
|
|
||||||
bdledger.api.grpc.query.TransactionFilter result = buildPartial();
|
|
||||||
if (!result.isInitialized()) {
|
|
||||||
throw newUninitializedMessageException(result);
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.TransactionFilter buildPartial() {
|
|
||||||
bdledger.api.grpc.query.TransactionFilter result = new bdledger.api.grpc.query.TransactionFilter(this);
|
|
||||||
result.hash_ = hash_;
|
|
||||||
result.from_ = from_;
|
|
||||||
result.to_ = to_;
|
|
||||||
result.timestamp_ = timestamp_;
|
|
||||||
onBuilt();
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clone() {
|
|
||||||
return super.clone();
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.setField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
|
||||||
return super.clearField(field);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder clearOneof(
|
|
||||||
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
|
||||||
return super.clearOneof(oneof);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder setRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
int index, java.lang.Object value) {
|
|
||||||
return super.setRepeatedField(field, index, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder addRepeatedField(
|
|
||||||
com.google.protobuf.Descriptors.FieldDescriptor field,
|
|
||||||
java.lang.Object value) {
|
|
||||||
return super.addRepeatedField(field, value);
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
|
||||||
if (other instanceof bdledger.api.grpc.query.TransactionFilter) {
|
|
||||||
return mergeFrom((bdledger.api.grpc.query.TransactionFilter)other);
|
|
||||||
} else {
|
|
||||||
super.mergeFrom(other);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public Builder mergeFrom(bdledger.api.grpc.query.TransactionFilter other) {
|
|
||||||
if (other == bdledger.api.grpc.query.TransactionFilter.getDefaultInstance()) return this;
|
|
||||||
if (other.getHash() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setHash(other.getHash());
|
|
||||||
}
|
|
||||||
if (other.getFrom() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setFrom(other.getFrom());
|
|
||||||
}
|
|
||||||
if (other.getTo() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setTo(other.getTo());
|
|
||||||
}
|
|
||||||
if (other.getTimestamp() != com.google.protobuf.ByteString.EMPTY) {
|
|
||||||
setTimestamp(other.getTimestamp());
|
|
||||||
}
|
|
||||||
this.mergeUnknownFields(other.unknownFields);
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final boolean isInitialized() {
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public Builder mergeFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws java.io.IOException {
|
|
||||||
bdledger.api.grpc.query.TransactionFilter parsedMessage = null;
|
|
||||||
try {
|
|
||||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
|
||||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
|
||||||
parsedMessage = (bdledger.api.grpc.query.TransactionFilter) e.getUnfinishedMessage();
|
|
||||||
throw e.unwrapIOException();
|
|
||||||
} finally {
|
|
||||||
if (parsedMessage != null) {
|
|
||||||
mergeFrom(parsedMessage);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString hash_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getHash() {
|
|
||||||
return hash_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @param value The hash to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setHash(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
hash_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearHash() {
|
|
||||||
|
|
||||||
hash_ = getDefaultInstance().getHash();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString from_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes from = 2;</code>
|
|
||||||
* @return The from.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getFrom() {
|
|
||||||
return from_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes from = 2;</code>
|
|
||||||
* @param value The from to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setFrom(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
from_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes from = 2;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearFrom() {
|
|
||||||
|
|
||||||
from_ = getDefaultInstance().getFrom();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString to_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes to = 3;</code>
|
|
||||||
* @return The to.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getTo() {
|
|
||||||
return to_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes to = 3;</code>
|
|
||||||
* @param value The to to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setTo(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
to_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes to = 3;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearTo() {
|
|
||||||
|
|
||||||
to_ = getDefaultInstance().getTo();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
private com.google.protobuf.ByteString timestamp_ = com.google.protobuf.ByteString.EMPTY;
|
|
||||||
/**
|
|
||||||
* <code>bytes timestamp = 4;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
public com.google.protobuf.ByteString getTimestamp() {
|
|
||||||
return timestamp_;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes timestamp = 4;</code>
|
|
||||||
* @param value The timestamp to set.
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder setTimestamp(com.google.protobuf.ByteString value) {
|
|
||||||
if (value == null) {
|
|
||||||
throw new NullPointerException();
|
|
||||||
}
|
|
||||||
|
|
||||||
timestamp_ = value;
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
/**
|
|
||||||
* <code>bytes timestamp = 4;</code>
|
|
||||||
* @return This builder for chaining.
|
|
||||||
*/
|
|
||||||
public Builder clearTimestamp() {
|
|
||||||
|
|
||||||
timestamp_ = getDefaultInstance().getTimestamp();
|
|
||||||
onChanged();
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder setUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.setUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public final Builder mergeUnknownFields(
|
|
||||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
|
||||||
return super.mergeUnknownFields(unknownFields);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(builder_scope:bdledger.api.TransactionFilter)
|
|
||||||
}
|
|
||||||
|
|
||||||
// @@protoc_insertion_point(class_scope:bdledger.api.TransactionFilter)
|
|
||||||
private static final bdledger.api.grpc.query.TransactionFilter DEFAULT_INSTANCE;
|
|
||||||
static {
|
|
||||||
DEFAULT_INSTANCE = new bdledger.api.grpc.query.TransactionFilter();
|
|
||||||
}
|
|
||||||
|
|
||||||
public static bdledger.api.grpc.query.TransactionFilter getDefaultInstance() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
private static final com.google.protobuf.Parser<TransactionFilter>
|
|
||||||
PARSER = new com.google.protobuf.AbstractParser<TransactionFilter>() {
|
|
||||||
@java.lang.Override
|
|
||||||
public TransactionFilter parsePartialFrom(
|
|
||||||
com.google.protobuf.CodedInputStream input,
|
|
||||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
|
||||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
|
||||||
return new TransactionFilter(input, extensionRegistry);
|
|
||||||
}
|
|
||||||
};
|
|
||||||
|
|
||||||
public static com.google.protobuf.Parser<TransactionFilter> parser() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public com.google.protobuf.Parser<TransactionFilter> getParserForType() {
|
|
||||||
return PARSER;
|
|
||||||
}
|
|
||||||
|
|
||||||
@java.lang.Override
|
|
||||||
public bdledger.api.grpc.query.TransactionFilter getDefaultInstanceForType() {
|
|
||||||
return DEFAULT_INSTANCE;
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
@ -1,33 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface TransactionFilterOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.TransactionFilter)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes hash = 1;</code>
|
|
||||||
* @return The hash.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getHash();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes from = 2;</code>
|
|
||||||
* @return The from.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getFrom();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes to = 3;</code>
|
|
||||||
* @return The to.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getTo();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>bytes timestamp = 4;</code>
|
|
||||||
* @return The timestamp.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString getTimestamp();
|
|
||||||
}
|
|
File diff suppressed because it is too large
Load Diff
@ -1,61 +0,0 @@
|
|||||||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
||||||
// source: bdledger/api/query.proto
|
|
||||||
|
|
||||||
package bdledger.api.grpc.query;
|
|
||||||
|
|
||||||
public interface TransactionsRequestOrBuilder extends
|
|
||||||
// @@protoc_insertion_point(interface_extends:bdledger.api.TransactionsRequest)
|
|
||||||
com.google.protobuf.MessageOrBuilder {
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The ledger.
|
|
||||||
*/
|
|
||||||
java.lang.String getLedger();
|
|
||||||
/**
|
|
||||||
* <code>string ledger = 1;</code>
|
|
||||||
* @return The bytes for ledger.
|
|
||||||
*/
|
|
||||||
com.google.protobuf.ByteString
|
|
||||||
getLedgerBytes();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <pre>
|
|
||||||
* required
|
|
||||||
* </pre>
|
|
||||||
*
|
|
||||||
* <code>int64 start_timestamp = 2;</code>
|
|
||||||
* @return The startTimestamp.
|
|
||||||
*/
|
|
||||||
long getStartTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>int64 end_timestamp = 3;</code>
|
|
||||||
* @return The endTimestamp.
|
|
||||||
*/
|
|
||||||
long getEndTimestamp();
|
|
||||||
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.TransactionFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<bdledger.api.grpc.query.TransactionFilter>
|
|
||||||
getFiltersList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.TransactionFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.query.TransactionFilter getFilters(int index);
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.TransactionFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
int getFiltersCount();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.TransactionFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
java.util.List<? extends bdledger.api.grpc.query.TransactionFilterOrBuilder>
|
|
||||||
getFiltersOrBuilderList();
|
|
||||||
/**
|
|
||||||
* <code>repeated .bdledger.api.TransactionFilter filters = 4;</code>
|
|
||||||
*/
|
|
||||||
bdledger.api.grpc.query.TransactionFilterOrBuilder getFiltersOrBuilder(
|
|
||||||
int index);
|
|
||||||
}
|
|
@ -1,10 +1,11 @@
|
|||||||
package bdledger.api;
|
package org.bdware.bdledger.api.grpc;
|
||||||
|
|
||||||
import bdledger.api.grpc.common.TransactionType;
|
import org.bdware.bdledger.api.grpc.pb.*;
|
||||||
import bdledger.api.grpc.ledger.*;
|
import org.bdware.bdledger.api.grpc.pb.Common.TransactionType;
|
||||||
import bdledger.api.grpc.node.ClientVersionResponse;
|
import org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.*;
|
||||||
import bdledger.api.grpc.node.NodeGrpc;
|
import org.bdware.bdledger.api.grpc.pb.NodeOuterClass.*;
|
||||||
import bdledger.api.grpc.query.*;
|
import org.bdware.bdledger.api.grpc.pb.QueryOuterClass.*;
|
||||||
|
import org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest.IncludeTransactions;
|
||||||
import com.google.common.util.concurrent.ListenableFuture;
|
import com.google.common.util.concurrent.ListenableFuture;
|
||||||
import com.google.protobuf.ByteString;
|
import com.google.protobuf.ByteString;
|
||||||
import com.google.protobuf.Empty;
|
import com.google.protobuf.Empty;
|
||||||
@ -20,7 +21,7 @@ import java.util.logging.Logger;
|
|||||||
/**
|
/**
|
||||||
* 事务账本客户端
|
* 事务账本客户端
|
||||||
*
|
*
|
||||||
* <p>如有更灵活的需求可直接使用{@link bdledger.api.grpc.ledger.LedgerGrpc}类。
|
* <p>如有更灵活的需求可直接使用{@link org.bdware.bdledger.api.grpc.pb.LedgerGrpc}类。
|
||||||
*
|
*
|
||||||
* @author nex
|
* @author nex
|
||||||
* @see <a href="#">事务账本API</a>
|
* @see <a href="#">事务账本API</a>
|
||||||
@ -229,7 +230,7 @@ public class Client {
|
|||||||
* href="#">返回哈希所指定的区块</a>
|
* href="#">返回哈希所指定的区块</a>
|
||||||
* (非阻塞)
|
* (非阻塞)
|
||||||
*/
|
*/
|
||||||
public ListenableFuture<GetBlockByHashResponse> getBlockByHash(
|
public ListenableFuture<QueryOuterClass.GetBlockByHashResponse> getBlockByHash(
|
||||||
String ledger, String hash, boolean fullTransactions) {
|
String ledger, String hash, boolean fullTransactions) {
|
||||||
|
|
||||||
info(
|
info(
|
||||||
@ -280,8 +281,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (非阻塞)
|
* (非阻塞)
|
||||||
*/
|
*/
|
||||||
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, ZonedDateTime startDateTime) {
|
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, ZonedDateTime startDateTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocks(ledger, startDateTime.toEpochSecond());
|
return getBlocks(ledger, startDateTime.toEpochSecond(), includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -289,8 +290,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (非阻塞)
|
* (非阻塞)
|
||||||
*/
|
*/
|
||||||
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, ZonedDateTime startDateTime, ZonedDateTime endDateTime) {
|
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, ZonedDateTime startDateTime, ZonedDateTime endDateTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocks(ledger, startDateTime.toEpochSecond(), endDateTime.toEpochSecond());
|
return getBlocks(ledger, startDateTime.toEpochSecond(), endDateTime.toEpochSecond(), includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -298,8 +299,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (阻塞)
|
* (阻塞)
|
||||||
*/
|
*/
|
||||||
public GetBlocksResponse getBlocksSync(String ledger, ZonedDateTime startDateTime) {
|
public GetBlocksResponse getBlocksSync(String ledger, ZonedDateTime startDateTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocksSync(ledger, startDateTime.toEpochSecond());
|
return getBlocksSync(ledger, startDateTime.toEpochSecond(), includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -307,8 +308,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (阻塞)
|
* (阻塞)
|
||||||
*/
|
*/
|
||||||
public GetBlocksResponse getBlocksSync(String ledger, ZonedDateTime startDateTime, ZonedDateTime endDateTime) {
|
public GetBlocksResponse getBlocksSync(String ledger, ZonedDateTime startDateTime, ZonedDateTime endDateTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocksSync(ledger, startDateTime.toEpochSecond(), endDateTime.toEpochSecond());
|
return getBlocksSync(ledger, startDateTime.toEpochSecond(), endDateTime.toEpochSecond(), includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -316,8 +317,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (非阻塞)
|
* (非阻塞)
|
||||||
*/
|
*/
|
||||||
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, long startUnixTime) {
|
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, long startUnixTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocks(ledger, startUnixTime, -1);
|
return getBlocks(ledger, startUnixTime, -1, includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -325,14 +326,14 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (非阻塞)
|
* (非阻塞)
|
||||||
*/
|
*/
|
||||||
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, long startUnixTime, long endUnixTime) {
|
public ListenableFuture<GetBlocksResponse> getBlocks(String ledger, long startUnixTime, long endUnixTime, IncludeTransactions includeTransactions) {
|
||||||
|
|
||||||
info(
|
info(
|
||||||
"*** getBlocks: ledger={0} startUnixTime={1} endUnixTime={2}",
|
"*** getBlocks: ledger={0} startUnixTime={1} endUnixTime={2}",
|
||||||
ledger, startUnixTime, endUnixTime);
|
ledger, startUnixTime, endUnixTime);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return queryFutureStub.getBlocks(blocksRequest(ledger, startUnixTime, endUnixTime));
|
return queryFutureStub.getBlocks(blocksRequest(ledger, startUnixTime, endUnixTime, includeTransactions));
|
||||||
} catch (StatusRuntimeException e) {
|
} catch (StatusRuntimeException e) {
|
||||||
warning("RPC failed: {0}", e.getStatus());
|
warning("RPC failed: {0}", e.getStatus());
|
||||||
return null;
|
return null;
|
||||||
@ -344,8 +345,8 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (阻塞)
|
* (阻塞)
|
||||||
*/
|
*/
|
||||||
public GetBlocksResponse getBlocksSync(String ledger, long startUnixTime) {
|
public GetBlocksResponse getBlocksSync(String ledger, long startUnixTime, IncludeTransactions includeTransactions) {
|
||||||
return getBlocksSync(ledger, startUnixTime, -1);
|
return getBlocksSync(ledger, startUnixTime, -1, includeTransactions);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -353,14 +354,14 @@ public class Client {
|
|||||||
* href="#">返回时间范围内的区块</a>
|
* href="#">返回时间范围内的区块</a>
|
||||||
* (阻塞)
|
* (阻塞)
|
||||||
*/
|
*/
|
||||||
public GetBlocksResponse getBlocksSync(String ledger, long startUnixTime, long endUnixTime) {
|
public GetBlocksResponse getBlocksSync(String ledger, long startUnixTime, long endUnixTime, IncludeTransactions includeTransactions) {
|
||||||
|
|
||||||
info(
|
info(
|
||||||
"*** getBlocksSync: ledger={0} startUnixTime={1} endUnixTime={2}",
|
"*** getBlocksSync: ledger={0} startUnixTime={1} endUnixTime={2}",
|
||||||
ledger, startUnixTime, endUnixTime);
|
ledger, startUnixTime, endUnixTime);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return queryBlockingStub.getBlocks(blocksRequest(ledger, startUnixTime, endUnixTime));
|
return queryBlockingStub.getBlocks(blocksRequest(ledger, startUnixTime, endUnixTime, includeTransactions));
|
||||||
} catch (StatusRuntimeException e) {
|
} catch (StatusRuntimeException e) {
|
||||||
warning("RPC failed: {0}", e.getStatus());
|
warning("RPC failed: {0}", e.getStatus());
|
||||||
return null;
|
return null;
|
||||||
@ -377,7 +378,7 @@ public class Client {
|
|||||||
info("*** blockNumber: ledger={0}", ledger);
|
info("*** blockNumber: ledger={0}", ledger);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return queryFutureStub.countBlocks(blocksRequest(ledger, -1, -1));
|
return queryFutureStub.countBlocks(blocksRequest(ledger, -1, -1, null));
|
||||||
} catch (StatusRuntimeException e) {
|
} catch (StatusRuntimeException e) {
|
||||||
warning("RPC failed: {0}", e.getStatus());
|
warning("RPC failed: {0}", e.getStatus());
|
||||||
return null;
|
return null;
|
||||||
@ -394,14 +395,14 @@ public class Client {
|
|||||||
info("*** blockNumberSync: ledger={0}", ledger);
|
info("*** blockNumberSync: ledger={0}", ledger);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return queryBlockingStub.countBlocks(blocksRequest(ledger, -1, -1));
|
return queryBlockingStub.countBlocks(blocksRequest(ledger, -1, -1, null));
|
||||||
} catch (StatusRuntimeException e) {
|
} catch (StatusRuntimeException e) {
|
||||||
warning("RPC failed: {0}", e.getStatus());
|
warning("RPC failed: {0}", e.getStatus());
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private BlocksRequest blocksRequest(String ledger, long startTimestamp, long endTimestamp) {
|
private BlocksRequest blocksRequest(String ledger, long startTimestamp, long endTimestamp, BlocksRequest.IncludeTransactions includeTransactions) {
|
||||||
|
|
||||||
BlocksRequest.Builder reqBuilder =
|
BlocksRequest.Builder reqBuilder =
|
||||||
BlocksRequest.newBuilder().setLedger(ledger);
|
BlocksRequest.newBuilder().setLedger(ledger);
|
||||||
@ -411,6 +412,10 @@ public class Client {
|
|||||||
if (endTimestamp != -1) {
|
if (endTimestamp != -1) {
|
||||||
reqBuilder.setEndTimestamp(endTimestamp);
|
reqBuilder.setEndTimestamp(endTimestamp);
|
||||||
}
|
}
|
||||||
|
if (includeTransactions == null) {
|
||||||
|
includeTransactions = BlocksRequest.IncludeTransactions.NONE;
|
||||||
|
}
|
||||||
|
reqBuilder.setIncludeTransactions(includeTransactions);
|
||||||
|
|
||||||
return reqBuilder.build();
|
return reqBuilder.build();
|
||||||
}
|
}
|
@ -1,4 +1,4 @@
|
|||||||
package bdledger.api;
|
package org.bdware.bdledger.api.grpc;
|
||||||
|
|
||||||
public class Utils {
|
public class Utils {
|
||||||
|
|
5013
src/main/java/org/bdware/bdledger/api/grpc/pb/Common.java
Normal file
5013
src/main/java/org/bdware/bdledger/api/grpc/pb/Common.java
Normal file
File diff suppressed because it is too large
Load Diff
1790
src/main/java/org/bdware/bdledger/api/grpc/pb/ErrorDetails.java
Normal file
1790
src/main/java/org/bdware/bdledger/api/grpc/pb/ErrorDetails.java
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
|||||||
package bdledger.api.grpc.ledger;
|
package org.bdware.bdledger.api.grpc.pb;
|
||||||
|
|
||||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||||
@ -19,37 +19,37 @@ import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(
|
@javax.annotation.Generated(
|
||||||
value = "by gRPC proto compiler (version 1.27.0)",
|
value = "by gRPC proto compiler (version 1.27.0)",
|
||||||
comments = "Source: bdledger/api/ledger.proto")
|
comments = "Source: bdware/bdledger/api/ledger.proto")
|
||||||
public final class LedgerGrpc {
|
public final class LedgerGrpc {
|
||||||
|
|
||||||
private LedgerGrpc() {}
|
private LedgerGrpc() {}
|
||||||
|
|
||||||
public static final String SERVICE_NAME = "bdledger.api.Ledger";
|
public static final String SERVICE_NAME = "bdware.bdledger.api.Ledger";
|
||||||
|
|
||||||
// Static method descriptors that strictly reflect the proto.
|
// Static method descriptors that strictly reflect the proto.
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.CreateLedgerRequest,
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest,
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse> getCreateLedgerMethod;
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> getCreateLedgerMethod;
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
fullMethodName = SERVICE_NAME + '/' + "CreateLedger",
|
fullMethodName = SERVICE_NAME + '/' + "CreateLedger",
|
||||||
requestType = bdledger.api.grpc.ledger.CreateLedgerRequest.class,
|
requestType = org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest.class,
|
||||||
responseType = bdledger.api.grpc.ledger.CreateLedgerResponse.class,
|
responseType = org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse.class,
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.CreateLedgerRequest,
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest,
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse> getCreateLedgerMethod() {
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> getCreateLedgerMethod() {
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.CreateLedgerRequest, bdledger.api.grpc.ledger.CreateLedgerResponse> getCreateLedgerMethod;
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> getCreateLedgerMethod;
|
||||||
if ((getCreateLedgerMethod = LedgerGrpc.getCreateLedgerMethod) == null) {
|
if ((getCreateLedgerMethod = LedgerGrpc.getCreateLedgerMethod) == null) {
|
||||||
synchronized (LedgerGrpc.class) {
|
synchronized (LedgerGrpc.class) {
|
||||||
if ((getCreateLedgerMethod = LedgerGrpc.getCreateLedgerMethod) == null) {
|
if ((getCreateLedgerMethod = LedgerGrpc.getCreateLedgerMethod) == null) {
|
||||||
LedgerGrpc.getCreateLedgerMethod = getCreateLedgerMethod =
|
LedgerGrpc.getCreateLedgerMethod = getCreateLedgerMethod =
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.ledger.CreateLedgerRequest, bdledger.api.grpc.ledger.CreateLedgerResponse>newBuilder()
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse>newBuilder()
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateLedger"))
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateLedger"))
|
||||||
.setSampledToLocalTracing(true)
|
.setSampledToLocalTracing(true)
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest.getDefaultInstance()))
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse.getDefaultInstance()))
|
||||||
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("CreateLedger"))
|
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("CreateLedger"))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -59,28 +59,28 @@ public final class LedgerGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse> getGetLedgersMethod;
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> getGetLedgersMethod;
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
fullMethodName = SERVICE_NAME + '/' + "GetLedgers",
|
fullMethodName = SERVICE_NAME + '/' + "GetLedgers",
|
||||||
requestType = com.google.protobuf.Empty.class,
|
requestType = com.google.protobuf.Empty.class,
|
||||||
responseType = bdledger.api.grpc.ledger.GetLedgersResponse.class,
|
responseType = org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse.class,
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
public static io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
public static io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse> getGetLedgersMethod() {
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> getGetLedgersMethod() {
|
||||||
io.grpc.MethodDescriptor<com.google.protobuf.Empty, bdledger.api.grpc.ledger.GetLedgersResponse> getGetLedgersMethod;
|
io.grpc.MethodDescriptor<com.google.protobuf.Empty, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> getGetLedgersMethod;
|
||||||
if ((getGetLedgersMethod = LedgerGrpc.getGetLedgersMethod) == null) {
|
if ((getGetLedgersMethod = LedgerGrpc.getGetLedgersMethod) == null) {
|
||||||
synchronized (LedgerGrpc.class) {
|
synchronized (LedgerGrpc.class) {
|
||||||
if ((getGetLedgersMethod = LedgerGrpc.getGetLedgersMethod) == null) {
|
if ((getGetLedgersMethod = LedgerGrpc.getGetLedgersMethod) == null) {
|
||||||
LedgerGrpc.getGetLedgersMethod = getGetLedgersMethod =
|
LedgerGrpc.getGetLedgersMethod = getGetLedgersMethod =
|
||||||
io.grpc.MethodDescriptor.<com.google.protobuf.Empty, bdledger.api.grpc.ledger.GetLedgersResponse>newBuilder()
|
io.grpc.MethodDescriptor.<com.google.protobuf.Empty, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse>newBuilder()
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetLedgers"))
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetLedgers"))
|
||||||
.setSampledToLocalTracing(true)
|
.setSampledToLocalTracing(true)
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
com.google.protobuf.Empty.getDefaultInstance()))
|
com.google.protobuf.Empty.getDefaultInstance()))
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse.getDefaultInstance()))
|
||||||
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("GetLedgers"))
|
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("GetLedgers"))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -89,29 +89,29 @@ public final class LedgerGrpc {
|
|||||||
return getGetLedgersMethod;
|
return getGetLedgersMethod;
|
||||||
}
|
}
|
||||||
|
|
||||||
private static volatile io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.SendTransactionRequest,
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest,
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse> getSendTransactionMethod;
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> getSendTransactionMethod;
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
fullMethodName = SERVICE_NAME + '/' + "SendTransaction",
|
fullMethodName = SERVICE_NAME + '/' + "SendTransaction",
|
||||||
requestType = bdledger.api.grpc.ledger.SendTransactionRequest.class,
|
requestType = org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest.class,
|
||||||
responseType = bdledger.api.grpc.ledger.SendTransactionResponse.class,
|
responseType = org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse.class,
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
public static io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.SendTransactionRequest,
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest,
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse> getSendTransactionMethod() {
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> getSendTransactionMethod() {
|
||||||
io.grpc.MethodDescriptor<bdledger.api.grpc.ledger.SendTransactionRequest, bdledger.api.grpc.ledger.SendTransactionResponse> getSendTransactionMethod;
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> getSendTransactionMethod;
|
||||||
if ((getSendTransactionMethod = LedgerGrpc.getSendTransactionMethod) == null) {
|
if ((getSendTransactionMethod = LedgerGrpc.getSendTransactionMethod) == null) {
|
||||||
synchronized (LedgerGrpc.class) {
|
synchronized (LedgerGrpc.class) {
|
||||||
if ((getSendTransactionMethod = LedgerGrpc.getSendTransactionMethod) == null) {
|
if ((getSendTransactionMethod = LedgerGrpc.getSendTransactionMethod) == null) {
|
||||||
LedgerGrpc.getSendTransactionMethod = getSendTransactionMethod =
|
LedgerGrpc.getSendTransactionMethod = getSendTransactionMethod =
|
||||||
io.grpc.MethodDescriptor.<bdledger.api.grpc.ledger.SendTransactionRequest, bdledger.api.grpc.ledger.SendTransactionResponse>newBuilder()
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest, org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse>newBuilder()
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "SendTransaction"))
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "SendTransaction"))
|
||||||
.setSampledToLocalTracing(true)
|
.setSampledToLocalTracing(true)
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.ledger.SendTransactionRequest.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest.getDefaultInstance()))
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse.getDefaultInstance()))
|
||||||
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("SendTransaction"))
|
.setSchemaDescriptor(new LedgerMethodDescriptorSupplier("SendTransaction"))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -169,23 +169,38 @@ public final class LedgerGrpc {
|
|||||||
public static abstract class LedgerImplBase implements io.grpc.BindableService {
|
public static abstract class LedgerImplBase implements io.grpc.BindableService {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Create a new ledger
|
||||||
|
* 创建一个新账本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void createLedger(bdledger.api.grpc.ledger.CreateLedgerRequest request,
|
public void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.CreateLedgerResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> responseObserver) {
|
||||||
asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver);
|
asyncUnimplementedUnaryCall(getCreateLedgerMethod(), responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get all ledgers
|
||||||
|
* 查询所有帐本列表
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void getLedgers(com.google.protobuf.Empty request,
|
public void getLedgers(com.google.protobuf.Empty request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.GetLedgersResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> responseObserver) {
|
||||||
asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver);
|
asyncUnimplementedUnaryCall(getGetLedgersMethod(), responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Send a new transaction
|
||||||
|
* 发送一个新事务
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void sendTransaction(bdledger.api.grpc.ledger.SendTransactionRequest request,
|
public void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.SendTransactionResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> responseObserver) {
|
||||||
asyncUnimplementedUnaryCall(getSendTransactionMethod(), responseObserver);
|
asyncUnimplementedUnaryCall(getSendTransactionMethod(), responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -195,22 +210,22 @@ public final class LedgerGrpc {
|
|||||||
getCreateLedgerMethod(),
|
getCreateLedgerMethod(),
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
new MethodHandlers<
|
new MethodHandlers<
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest,
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest,
|
||||||
bdledger.api.grpc.ledger.CreateLedgerResponse>(
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse>(
|
||||||
this, METHODID_CREATE_LEDGER)))
|
this, METHODID_CREATE_LEDGER)))
|
||||||
.addMethod(
|
.addMethod(
|
||||||
getGetLedgersMethod(),
|
getGetLedgersMethod(),
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
new MethodHandlers<
|
new MethodHandlers<
|
||||||
com.google.protobuf.Empty,
|
com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.ledger.GetLedgersResponse>(
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse>(
|
||||||
this, METHODID_GET_LEDGERS)))
|
this, METHODID_GET_LEDGERS)))
|
||||||
.addMethod(
|
.addMethod(
|
||||||
getSendTransactionMethod(),
|
getSendTransactionMethod(),
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
new MethodHandlers<
|
new MethodHandlers<
|
||||||
bdledger.api.grpc.ledger.SendTransactionRequest,
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest,
|
||||||
bdledger.api.grpc.ledger.SendTransactionResponse>(
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse>(
|
||||||
this, METHODID_SEND_TRANSACTION)))
|
this, METHODID_SEND_TRANSACTION)))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -231,25 +246,40 @@ public final class LedgerGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Create a new ledger
|
||||||
|
* 创建一个新账本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void createLedger(bdledger.api.grpc.ledger.CreateLedgerRequest request,
|
public void createLedger(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.CreateLedgerResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> responseObserver) {
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request, responseObserver);
|
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request, responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get all ledgers
|
||||||
|
* 查询所有帐本列表
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void getLedgers(com.google.protobuf.Empty request,
|
public void getLedgers(com.google.protobuf.Empty request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.GetLedgersResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> responseObserver) {
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request, responseObserver);
|
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request, responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Send a new transaction
|
||||||
|
* 发送一个新事务
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void sendTransaction(bdledger.api.grpc.ledger.SendTransactionRequest request,
|
public void sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.SendTransactionResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> responseObserver) {
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request, responseObserver);
|
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request, responseObserver);
|
||||||
}
|
}
|
||||||
@ -270,22 +300,37 @@ public final class LedgerGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Create a new ledger
|
||||||
|
* 创建一个新账本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public bdledger.api.grpc.ledger.CreateLedgerResponse createLedger(bdledger.api.grpc.ledger.CreateLedgerRequest request) {
|
public org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse createLedger(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest request) {
|
||||||
return blockingUnaryCall(
|
return blockingUnaryCall(
|
||||||
getChannel(), getCreateLedgerMethod(), getCallOptions(), request);
|
getChannel(), getCreateLedgerMethod(), getCallOptions(), request);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get all ledgers
|
||||||
|
* 查询所有帐本列表
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public bdledger.api.grpc.ledger.GetLedgersResponse getLedgers(com.google.protobuf.Empty request) {
|
public org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse getLedgers(com.google.protobuf.Empty request) {
|
||||||
return blockingUnaryCall(
|
return blockingUnaryCall(
|
||||||
getChannel(), getGetLedgersMethod(), getCallOptions(), request);
|
getChannel(), getGetLedgersMethod(), getCallOptions(), request);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Send a new transaction
|
||||||
|
* 发送一个新事务
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public bdledger.api.grpc.ledger.SendTransactionResponse sendTransaction(bdledger.api.grpc.ledger.SendTransactionRequest request) {
|
public org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse sendTransaction(org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest request) {
|
||||||
return blockingUnaryCall(
|
return blockingUnaryCall(
|
||||||
getChannel(), getSendTransactionMethod(), getCallOptions(), request);
|
getChannel(), getSendTransactionMethod(), getCallOptions(), request);
|
||||||
}
|
}
|
||||||
@ -306,25 +351,40 @@ public final class LedgerGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Create a new ledger
|
||||||
|
* 创建一个新账本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.ledger.CreateLedgerResponse> createLedger(
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse> createLedger(
|
||||||
bdledger.api.grpc.ledger.CreateLedgerRequest request) {
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest request) {
|
||||||
return futureUnaryCall(
|
return futureUnaryCall(
|
||||||
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request);
|
getChannel().newCall(getCreateLedgerMethod(), getCallOptions()), request);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get all ledgers
|
||||||
|
* 查询所有帐本列表
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.ledger.GetLedgersResponse> getLedgers(
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse> getLedgers(
|
||||||
com.google.protobuf.Empty request) {
|
com.google.protobuf.Empty request) {
|
||||||
return futureUnaryCall(
|
return futureUnaryCall(
|
||||||
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request);
|
getChannel().newCall(getGetLedgersMethod(), getCallOptions()), request);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Send a new transaction
|
||||||
|
* 发送一个新事务
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.ledger.SendTransactionResponse> sendTransaction(
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse> sendTransaction(
|
||||||
bdledger.api.grpc.ledger.SendTransactionRequest request) {
|
org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest request) {
|
||||||
return futureUnaryCall(
|
return futureUnaryCall(
|
||||||
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request);
|
getChannel().newCall(getSendTransactionMethod(), getCallOptions()), request);
|
||||||
}
|
}
|
||||||
@ -352,16 +412,16 @@ public final class LedgerGrpc {
|
|||||||
public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||||
switch (methodId) {
|
switch (methodId) {
|
||||||
case METHODID_CREATE_LEDGER:
|
case METHODID_CREATE_LEDGER:
|
||||||
serviceImpl.createLedger((bdledger.api.grpc.ledger.CreateLedgerRequest) request,
|
serviceImpl.createLedger((org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerRequest) request,
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.CreateLedgerResponse>) responseObserver);
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.CreateLedgerResponse>) responseObserver);
|
||||||
break;
|
break;
|
||||||
case METHODID_GET_LEDGERS:
|
case METHODID_GET_LEDGERS:
|
||||||
serviceImpl.getLedgers((com.google.protobuf.Empty) request,
|
serviceImpl.getLedgers((com.google.protobuf.Empty) request,
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.GetLedgersResponse>) responseObserver);
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse>) responseObserver);
|
||||||
break;
|
break;
|
||||||
case METHODID_SEND_TRANSACTION:
|
case METHODID_SEND_TRANSACTION:
|
||||||
serviceImpl.sendTransaction((bdledger.api.grpc.ledger.SendTransactionRequest) request,
|
serviceImpl.sendTransaction((org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionRequest) request,
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.ledger.SendTransactionResponse>) responseObserver);
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.SendTransactionResponse>) responseObserver);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new AssertionError();
|
throw new AssertionError();
|
||||||
@ -385,7 +445,7 @@ public final class LedgerGrpc {
|
|||||||
|
|
||||||
@java.lang.Override
|
@java.lang.Override
|
||||||
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
||||||
return bdledger.api.grpc.ledger.LedgerProto.getDescriptor();
|
return org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.getDescriptor();
|
||||||
}
|
}
|
||||||
|
|
||||||
@java.lang.Override
|
@java.lang.Override
|
3812
src/main/java/org/bdware/bdledger/api/grpc/pb/LedgerOuterClass.java
Normal file
3812
src/main/java/org/bdware/bdledger/api/grpc/pb/LedgerOuterClass.java
Normal file
File diff suppressed because it is too large
Load Diff
@ -1,4 +1,4 @@
|
|||||||
package bdledger.api.grpc.node;
|
package org.bdware.bdledger.api.grpc.pb;
|
||||||
|
|
||||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||||
@ -19,37 +19,37 @@ import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
|||||||
*/
|
*/
|
||||||
@javax.annotation.Generated(
|
@javax.annotation.Generated(
|
||||||
value = "by gRPC proto compiler (version 1.27.0)",
|
value = "by gRPC proto compiler (version 1.27.0)",
|
||||||
comments = "Source: bdledger/api/node.proto")
|
comments = "Source: bdware/bdledger/api/node.proto")
|
||||||
public final class NodeGrpc {
|
public final class NodeGrpc {
|
||||||
|
|
||||||
private NodeGrpc() {}
|
private NodeGrpc() {}
|
||||||
|
|
||||||
public static final String SERVICE_NAME = "bdledger.api.Node";
|
public static final String SERVICE_NAME = "bdware.bdledger.api.Node";
|
||||||
|
|
||||||
// Static method descriptors that strictly reflect the proto.
|
// Static method descriptors that strictly reflect the proto.
|
||||||
private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
private static volatile io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.node.ClientVersionResponse> getClientVersionMethod;
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> getClientVersionMethod;
|
||||||
|
|
||||||
@io.grpc.stub.annotations.RpcMethod(
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
fullMethodName = SERVICE_NAME + '/' + "ClientVersion",
|
fullMethodName = SERVICE_NAME + '/' + "ClientVersion",
|
||||||
requestType = com.google.protobuf.Empty.class,
|
requestType = com.google.protobuf.Empty.class,
|
||||||
responseType = bdledger.api.grpc.node.ClientVersionResponse.class,
|
responseType = org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.class,
|
||||||
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
public static io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
public static io.grpc.MethodDescriptor<com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.node.ClientVersionResponse> getClientVersionMethod() {
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> getClientVersionMethod() {
|
||||||
io.grpc.MethodDescriptor<com.google.protobuf.Empty, bdledger.api.grpc.node.ClientVersionResponse> getClientVersionMethod;
|
io.grpc.MethodDescriptor<com.google.protobuf.Empty, org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> getClientVersionMethod;
|
||||||
if ((getClientVersionMethod = NodeGrpc.getClientVersionMethod) == null) {
|
if ((getClientVersionMethod = NodeGrpc.getClientVersionMethod) == null) {
|
||||||
synchronized (NodeGrpc.class) {
|
synchronized (NodeGrpc.class) {
|
||||||
if ((getClientVersionMethod = NodeGrpc.getClientVersionMethod) == null) {
|
if ((getClientVersionMethod = NodeGrpc.getClientVersionMethod) == null) {
|
||||||
NodeGrpc.getClientVersionMethod = getClientVersionMethod =
|
NodeGrpc.getClientVersionMethod = getClientVersionMethod =
|
||||||
io.grpc.MethodDescriptor.<com.google.protobuf.Empty, bdledger.api.grpc.node.ClientVersionResponse>newBuilder()
|
io.grpc.MethodDescriptor.<com.google.protobuf.Empty, org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse>newBuilder()
|
||||||
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "ClientVersion"))
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "ClientVersion"))
|
||||||
.setSampledToLocalTracing(true)
|
.setSampledToLocalTracing(true)
|
||||||
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
com.google.protobuf.Empty.getDefaultInstance()))
|
com.google.protobuf.Empty.getDefaultInstance()))
|
||||||
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
bdledger.api.grpc.node.ClientVersionResponse.getDefaultInstance()))
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.getDefaultInstance()))
|
||||||
.setSchemaDescriptor(new NodeMethodDescriptorSupplier("ClientVersion"))
|
.setSchemaDescriptor(new NodeMethodDescriptorSupplier("ClientVersion"))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -107,9 +107,14 @@ public final class NodeGrpc {
|
|||||||
public static abstract class NodeImplBase implements io.grpc.BindableService {
|
public static abstract class NodeImplBase implements io.grpc.BindableService {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get BDLedger node version
|
||||||
|
* 查询BDLedger节点版本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void clientVersion(com.google.protobuf.Empty request,
|
public void clientVersion(com.google.protobuf.Empty request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.node.ClientVersionResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> responseObserver) {
|
||||||
asyncUnimplementedUnaryCall(getClientVersionMethod(), responseObserver);
|
asyncUnimplementedUnaryCall(getClientVersionMethod(), responseObserver);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -120,7 +125,7 @@ public final class NodeGrpc {
|
|||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
new MethodHandlers<
|
new MethodHandlers<
|
||||||
com.google.protobuf.Empty,
|
com.google.protobuf.Empty,
|
||||||
bdledger.api.grpc.node.ClientVersionResponse>(
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse>(
|
||||||
this, METHODID_CLIENT_VERSION)))
|
this, METHODID_CLIENT_VERSION)))
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
@ -141,9 +146,14 @@ public final class NodeGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get BDLedger node version
|
||||||
|
* 查询BDLedger节点版本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public void clientVersion(com.google.protobuf.Empty request,
|
public void clientVersion(com.google.protobuf.Empty request,
|
||||||
io.grpc.stub.StreamObserver<bdledger.api.grpc.node.ClientVersionResponse> responseObserver) {
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> responseObserver) {
|
||||||
asyncUnaryCall(
|
asyncUnaryCall(
|
||||||
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request, responseObserver);
|
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request, responseObserver);
|
||||||
}
|
}
|
||||||
@ -164,8 +174,13 @@ public final class NodeGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get BDLedger node version
|
||||||
|
* 查询BDLedger节点版本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public bdledger.api.grpc.node.ClientVersionResponse clientVersion(com.google.protobuf.Empty request) {
|
public org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse clientVersion(com.google.protobuf.Empty request) {
|
||||||
return blockingUnaryCall(
|
return blockingUnaryCall(
|
||||||
getChannel(), getClientVersionMethod(), getCallOptions(), request);
|
getChannel(), getClientVersionMethod(), getCallOptions(), request);
|
||||||
}
|
}
|
||||||
@ -186,8 +201,13 @@ public final class NodeGrpc {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get BDLedger node version
|
||||||
|
* 查询BDLedger节点版本
|
||||||
|
* </pre>
|
||||||
*/
|
*/
|
||||||
public com.google.common.util.concurrent.ListenableFuture<bdledger.api.grpc.node.ClientVersionResponse> clientVersion(
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse> clientVersion(
|
||||||
com.google.protobuf.Empty request) {
|
com.google.protobuf.Empty request) {
|
||||||
return futureUnaryCall(
|
return futureUnaryCall(
|
||||||
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request);
|
getChannel().newCall(getClientVersionMethod(), getCallOptions()), request);
|
||||||
@ -215,7 +235,7 @@ public final class NodeGrpc {
|
|||||||
switch (methodId) {
|
switch (methodId) {
|
||||||
case METHODID_CLIENT_VERSION:
|
case METHODID_CLIENT_VERSION:
|
||||||
serviceImpl.clientVersion((com.google.protobuf.Empty) request,
|
serviceImpl.clientVersion((com.google.protobuf.Empty) request,
|
||||||
(io.grpc.stub.StreamObserver<bdledger.api.grpc.node.ClientVersionResponse>) responseObserver);
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse>) responseObserver);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
throw new AssertionError();
|
throw new AssertionError();
|
||||||
@ -239,7 +259,7 @@ public final class NodeGrpc {
|
|||||||
|
|
||||||
@java.lang.Override
|
@java.lang.Override
|
||||||
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
||||||
return bdledger.api.grpc.node.NodeProto.getDescriptor();
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.getDescriptor();
|
||||||
}
|
}
|
||||||
|
|
||||||
@java.lang.Override
|
@java.lang.Override
|
@ -0,0 +1,657 @@
|
|||||||
|
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||||
|
// source: bdware/bdledger/api/node.proto
|
||||||
|
|
||||||
|
package org.bdware.bdledger.api.grpc.pb;
|
||||||
|
|
||||||
|
public final class NodeOuterClass {
|
||||||
|
private NodeOuterClass() {}
|
||||||
|
public static void registerAllExtensions(
|
||||||
|
com.google.protobuf.ExtensionRegistryLite registry) {
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void registerAllExtensions(
|
||||||
|
com.google.protobuf.ExtensionRegistry registry) {
|
||||||
|
registerAllExtensions(
|
||||||
|
(com.google.protobuf.ExtensionRegistryLite) registry);
|
||||||
|
}
|
||||||
|
public interface ClientVersionResponseOrBuilder extends
|
||||||
|
// @@protoc_insertion_point(interface_extends:bdware.bdledger.api.ClientVersionResponse)
|
||||||
|
com.google.protobuf.MessageOrBuilder {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The version.
|
||||||
|
*/
|
||||||
|
java.lang.String getVersion();
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The bytes for version.
|
||||||
|
*/
|
||||||
|
com.google.protobuf.ByteString
|
||||||
|
getVersionBytes();
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Protobuf type {@code bdware.bdledger.api.ClientVersionResponse}
|
||||||
|
*/
|
||||||
|
public static final class ClientVersionResponse extends
|
||||||
|
com.google.protobuf.GeneratedMessageV3 implements
|
||||||
|
// @@protoc_insertion_point(message_implements:bdware.bdledger.api.ClientVersionResponse)
|
||||||
|
ClientVersionResponseOrBuilder {
|
||||||
|
private static final long serialVersionUID = 0L;
|
||||||
|
// Use ClientVersionResponse.newBuilder() to construct.
|
||||||
|
private ClientVersionResponse(com.google.protobuf.GeneratedMessageV3.Builder<?> builder) {
|
||||||
|
super(builder);
|
||||||
|
}
|
||||||
|
private ClientVersionResponse() {
|
||||||
|
version_ = "";
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
@SuppressWarnings({"unused"})
|
||||||
|
protected java.lang.Object newInstance(
|
||||||
|
UnusedPrivateParameter unused) {
|
||||||
|
return new ClientVersionResponse();
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public final com.google.protobuf.UnknownFieldSet
|
||||||
|
getUnknownFields() {
|
||||||
|
return this.unknownFields;
|
||||||
|
}
|
||||||
|
private ClientVersionResponse(
|
||||||
|
com.google.protobuf.CodedInputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
this();
|
||||||
|
if (extensionRegistry == null) {
|
||||||
|
throw new java.lang.NullPointerException();
|
||||||
|
}
|
||||||
|
com.google.protobuf.UnknownFieldSet.Builder unknownFields =
|
||||||
|
com.google.protobuf.UnknownFieldSet.newBuilder();
|
||||||
|
try {
|
||||||
|
boolean done = false;
|
||||||
|
while (!done) {
|
||||||
|
int tag = input.readTag();
|
||||||
|
switch (tag) {
|
||||||
|
case 0:
|
||||||
|
done = true;
|
||||||
|
break;
|
||||||
|
case 10: {
|
||||||
|
java.lang.String s = input.readStringRequireUtf8();
|
||||||
|
|
||||||
|
version_ = s;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default: {
|
||||||
|
if (!parseUnknownField(
|
||||||
|
input, unknownFields, extensionRegistry, tag)) {
|
||||||
|
done = true;
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||||
|
throw e.setUnfinishedMessage(this);
|
||||||
|
} catch (java.io.IOException e) {
|
||||||
|
throw new com.google.protobuf.InvalidProtocolBufferException(
|
||||||
|
e).setUnfinishedMessage(this);
|
||||||
|
} finally {
|
||||||
|
this.unknownFields = unknownFields.build();
|
||||||
|
makeExtensionsImmutable();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
public static final com.google.protobuf.Descriptors.Descriptor
|
||||||
|
getDescriptor() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||||
|
internalGetFieldAccessorTable() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.internal_static_bdware_bdledger_api_ClientVersionResponse_fieldAccessorTable
|
||||||
|
.ensureFieldAccessorsInitialized(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.class, org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.Builder.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static final int VERSION_FIELD_NUMBER = 1;
|
||||||
|
private volatile java.lang.Object version_;
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The version.
|
||||||
|
*/
|
||||||
|
public java.lang.String getVersion() {
|
||||||
|
java.lang.Object ref = version_;
|
||||||
|
if (ref instanceof java.lang.String) {
|
||||||
|
return (java.lang.String) ref;
|
||||||
|
} else {
|
||||||
|
com.google.protobuf.ByteString bs =
|
||||||
|
(com.google.protobuf.ByteString) ref;
|
||||||
|
java.lang.String s = bs.toStringUtf8();
|
||||||
|
version_ = s;
|
||||||
|
return s;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The bytes for version.
|
||||||
|
*/
|
||||||
|
public com.google.protobuf.ByteString
|
||||||
|
getVersionBytes() {
|
||||||
|
java.lang.Object ref = version_;
|
||||||
|
if (ref instanceof java.lang.String) {
|
||||||
|
com.google.protobuf.ByteString b =
|
||||||
|
com.google.protobuf.ByteString.copyFromUtf8(
|
||||||
|
(java.lang.String) ref);
|
||||||
|
version_ = b;
|
||||||
|
return b;
|
||||||
|
} else {
|
||||||
|
return (com.google.protobuf.ByteString) ref;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private byte memoizedIsInitialized = -1;
|
||||||
|
@java.lang.Override
|
||||||
|
public final boolean isInitialized() {
|
||||||
|
byte isInitialized = memoizedIsInitialized;
|
||||||
|
if (isInitialized == 1) return true;
|
||||||
|
if (isInitialized == 0) return false;
|
||||||
|
|
||||||
|
memoizedIsInitialized = 1;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||||
|
throws java.io.IOException {
|
||||||
|
if (!getVersionBytes().isEmpty()) {
|
||||||
|
com.google.protobuf.GeneratedMessageV3.writeString(output, 1, version_);
|
||||||
|
}
|
||||||
|
unknownFields.writeTo(output);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public int getSerializedSize() {
|
||||||
|
int size = memoizedSize;
|
||||||
|
if (size != -1) return size;
|
||||||
|
|
||||||
|
size = 0;
|
||||||
|
if (!getVersionBytes().isEmpty()) {
|
||||||
|
size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, version_);
|
||||||
|
}
|
||||||
|
size += unknownFields.getSerializedSize();
|
||||||
|
memoizedSize = size;
|
||||||
|
return size;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public boolean equals(final java.lang.Object obj) {
|
||||||
|
if (obj == this) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!(obj instanceof org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse)) {
|
||||||
|
return super.equals(obj);
|
||||||
|
}
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse other = (org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse) obj;
|
||||||
|
|
||||||
|
if (!getVersion()
|
||||||
|
.equals(other.getVersion())) return false;
|
||||||
|
if (!unknownFields.equals(other.unknownFields)) return false;
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public int hashCode() {
|
||||||
|
if (memoizedHashCode != 0) {
|
||||||
|
return memoizedHashCode;
|
||||||
|
}
|
||||||
|
int hash = 41;
|
||||||
|
hash = (19 * hash) + getDescriptor().hashCode();
|
||||||
|
hash = (37 * hash) + VERSION_FIELD_NUMBER;
|
||||||
|
hash = (53 * hash) + getVersion().hashCode();
|
||||||
|
hash = (29 * hash) + unknownFields.hashCode();
|
||||||
|
memoizedHashCode = hash;
|
||||||
|
return hash;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
java.nio.ByteBuffer data)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
java.nio.ByteBuffer data,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data, extensionRegistry);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
com.google.protobuf.ByteString data)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
com.google.protobuf.ByteString data,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data, extensionRegistry);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(byte[] data)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
byte[] data,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return PARSER.parseFrom(data, extensionRegistry);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(java.io.InputStream input)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseWithIOException(PARSER, input);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
java.io.InputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseDelimitedFrom(java.io.InputStream input)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseDelimitedWithIOException(PARSER, input);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseDelimitedFrom(
|
||||||
|
java.io.InputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
com.google.protobuf.CodedInputStream input)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseWithIOException(PARSER, input);
|
||||||
|
}
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parseFrom(
|
||||||
|
com.google.protobuf.CodedInputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws java.io.IOException {
|
||||||
|
return com.google.protobuf.GeneratedMessageV3
|
||||||
|
.parseWithIOException(PARSER, input, extensionRegistry);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder newBuilderForType() { return newBuilder(); }
|
||||||
|
public static Builder newBuilder() {
|
||||||
|
return DEFAULT_INSTANCE.toBuilder();
|
||||||
|
}
|
||||||
|
public static Builder newBuilder(org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse prototype) {
|
||||||
|
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder toBuilder() {
|
||||||
|
return this == DEFAULT_INSTANCE
|
||||||
|
? new Builder() : new Builder().mergeFrom(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected Builder newBuilderForType(
|
||||||
|
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||||
|
Builder builder = new Builder(parent);
|
||||||
|
return builder;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* Protobuf type {@code bdware.bdledger.api.ClientVersionResponse}
|
||||||
|
*/
|
||||||
|
public static final class Builder extends
|
||||||
|
com.google.protobuf.GeneratedMessageV3.Builder<Builder> implements
|
||||||
|
// @@protoc_insertion_point(builder_implements:bdware.bdledger.api.ClientVersionResponse)
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponseOrBuilder {
|
||||||
|
public static final com.google.protobuf.Descriptors.Descriptor
|
||||||
|
getDescriptor() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||||
|
internalGetFieldAccessorTable() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.internal_static_bdware_bdledger_api_ClientVersionResponse_fieldAccessorTable
|
||||||
|
.ensureFieldAccessorsInitialized(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.class, org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.Builder.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
// Construct using org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.newBuilder()
|
||||||
|
private Builder() {
|
||||||
|
maybeForceBuilderInitialization();
|
||||||
|
}
|
||||||
|
|
||||||
|
private Builder(
|
||||||
|
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
|
||||||
|
super(parent);
|
||||||
|
maybeForceBuilderInitialization();
|
||||||
|
}
|
||||||
|
private void maybeForceBuilderInitialization() {
|
||||||
|
if (com.google.protobuf.GeneratedMessageV3
|
||||||
|
.alwaysUseFieldBuilders) {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder clear() {
|
||||||
|
super.clear();
|
||||||
|
version_ = "";
|
||||||
|
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public com.google.protobuf.Descriptors.Descriptor
|
||||||
|
getDescriptorForType() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse getDefaultInstanceForType() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.getDefaultInstance();
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse build() {
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse result = buildPartial();
|
||||||
|
if (!result.isInitialized()) {
|
||||||
|
throw newUninitializedMessageException(result);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse buildPartial() {
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse result = new org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse(this);
|
||||||
|
result.version_ = version_;
|
||||||
|
onBuilt();
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder clone() {
|
||||||
|
return super.clone();
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder setField(
|
||||||
|
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||||
|
java.lang.Object value) {
|
||||||
|
return super.setField(field, value);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder clearField(
|
||||||
|
com.google.protobuf.Descriptors.FieldDescriptor field) {
|
||||||
|
return super.clearField(field);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder clearOneof(
|
||||||
|
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
|
||||||
|
return super.clearOneof(oneof);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder setRepeatedField(
|
||||||
|
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||||
|
int index, java.lang.Object value) {
|
||||||
|
return super.setRepeatedField(field, index, value);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder addRepeatedField(
|
||||||
|
com.google.protobuf.Descriptors.FieldDescriptor field,
|
||||||
|
java.lang.Object value) {
|
||||||
|
return super.addRepeatedField(field, value);
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||||
|
if (other instanceof org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse) {
|
||||||
|
return mergeFrom((org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse)other);
|
||||||
|
} else {
|
||||||
|
super.mergeFrom(other);
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public Builder mergeFrom(org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse other) {
|
||||||
|
if (other == org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse.getDefaultInstance()) return this;
|
||||||
|
if (!other.getVersion().isEmpty()) {
|
||||||
|
version_ = other.version_;
|
||||||
|
onChanged();
|
||||||
|
}
|
||||||
|
this.mergeUnknownFields(other.unknownFields);
|
||||||
|
onChanged();
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public final boolean isInitialized() {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public Builder mergeFrom(
|
||||||
|
com.google.protobuf.CodedInputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws java.io.IOException {
|
||||||
|
org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse parsedMessage = null;
|
||||||
|
try {
|
||||||
|
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||||
|
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||||
|
parsedMessage = (org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse) e.getUnfinishedMessage();
|
||||||
|
throw e.unwrapIOException();
|
||||||
|
} finally {
|
||||||
|
if (parsedMessage != null) {
|
||||||
|
mergeFrom(parsedMessage);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
private java.lang.Object version_ = "";
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The version.
|
||||||
|
*/
|
||||||
|
public java.lang.String getVersion() {
|
||||||
|
java.lang.Object ref = version_;
|
||||||
|
if (!(ref instanceof java.lang.String)) {
|
||||||
|
com.google.protobuf.ByteString bs =
|
||||||
|
(com.google.protobuf.ByteString) ref;
|
||||||
|
java.lang.String s = bs.toStringUtf8();
|
||||||
|
version_ = s;
|
||||||
|
return s;
|
||||||
|
} else {
|
||||||
|
return (java.lang.String) ref;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return The bytes for version.
|
||||||
|
*/
|
||||||
|
public com.google.protobuf.ByteString
|
||||||
|
getVersionBytes() {
|
||||||
|
java.lang.Object ref = version_;
|
||||||
|
if (ref instanceof String) {
|
||||||
|
com.google.protobuf.ByteString b =
|
||||||
|
com.google.protobuf.ByteString.copyFromUtf8(
|
||||||
|
(java.lang.String) ref);
|
||||||
|
version_ = b;
|
||||||
|
return b;
|
||||||
|
} else {
|
||||||
|
return (com.google.protobuf.ByteString) ref;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @param value The version to set.
|
||||||
|
* @return This builder for chaining.
|
||||||
|
*/
|
||||||
|
public Builder setVersion(
|
||||||
|
java.lang.String value) {
|
||||||
|
if (value == null) {
|
||||||
|
throw new NullPointerException();
|
||||||
|
}
|
||||||
|
|
||||||
|
version_ = value;
|
||||||
|
onChanged();
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @return This builder for chaining.
|
||||||
|
*/
|
||||||
|
public Builder clearVersion() {
|
||||||
|
|
||||||
|
version_ = getDefaultInstance().getVersion();
|
||||||
|
onChanged();
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
* 节点客户端版本
|
||||||
|
* </pre>
|
||||||
|
*
|
||||||
|
* <code>string version = 1;</code>
|
||||||
|
* @param value The bytes for version to set.
|
||||||
|
* @return This builder for chaining.
|
||||||
|
*/
|
||||||
|
public Builder setVersionBytes(
|
||||||
|
com.google.protobuf.ByteString value) {
|
||||||
|
if (value == null) {
|
||||||
|
throw new NullPointerException();
|
||||||
|
}
|
||||||
|
checkByteStringIsUtf8(value);
|
||||||
|
|
||||||
|
version_ = value;
|
||||||
|
onChanged();
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
@java.lang.Override
|
||||||
|
public final Builder setUnknownFields(
|
||||||
|
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||||
|
return super.setUnknownFields(unknownFields);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public final Builder mergeUnknownFields(
|
||||||
|
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||||
|
return super.mergeUnknownFields(unknownFields);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
// @@protoc_insertion_point(builder_scope:bdware.bdledger.api.ClientVersionResponse)
|
||||||
|
}
|
||||||
|
|
||||||
|
// @@protoc_insertion_point(class_scope:bdware.bdledger.api.ClientVersionResponse)
|
||||||
|
private static final org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse DEFAULT_INSTANCE;
|
||||||
|
static {
|
||||||
|
DEFAULT_INSTANCE = new org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse();
|
||||||
|
}
|
||||||
|
|
||||||
|
public static org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse getDefaultInstance() {
|
||||||
|
return DEFAULT_INSTANCE;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final com.google.protobuf.Parser<ClientVersionResponse>
|
||||||
|
PARSER = new com.google.protobuf.AbstractParser<ClientVersionResponse>() {
|
||||||
|
@java.lang.Override
|
||||||
|
public ClientVersionResponse parsePartialFrom(
|
||||||
|
com.google.protobuf.CodedInputStream input,
|
||||||
|
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||||
|
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||||
|
return new ClientVersionResponse(input, extensionRegistry);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
public static com.google.protobuf.Parser<ClientVersionResponse> parser() {
|
||||||
|
return PARSER;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public com.google.protobuf.Parser<ClientVersionResponse> getParserForType() {
|
||||||
|
return PARSER;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.NodeOuterClass.ClientVersionResponse getDefaultInstanceForType() {
|
||||||
|
return DEFAULT_INSTANCE;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final com.google.protobuf.Descriptors.Descriptor
|
||||||
|
internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor;
|
||||||
|
private static final
|
||||||
|
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
|
||||||
|
internal_static_bdware_bdledger_api_ClientVersionResponse_fieldAccessorTable;
|
||||||
|
|
||||||
|
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||||
|
getDescriptor() {
|
||||||
|
return descriptor;
|
||||||
|
}
|
||||||
|
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||||
|
descriptor;
|
||||||
|
static {
|
||||||
|
java.lang.String[] descriptorData = {
|
||||||
|
"\n\036bdware/bdledger/api/node.proto\022\023bdware" +
|
||||||
|
".bdledger.api\032\033google/protobuf/empty.pro" +
|
||||||
|
"to\"(\n\025ClientVersionResponse\022\017\n\007version\030\001" +
|
||||||
|
" \001(\t2[\n\004Node\022S\n\rClientVersion\022\026.google.p" +
|
||||||
|
"rotobuf.Empty\032*.bdware.bdledger.api.Clie" +
|
||||||
|
"ntVersionResponseBF\n\037org.bdware.bdledger" +
|
||||||
|
".api.grpc.pbZ#bdware.org/bdledger/pkg/ap" +
|
||||||
|
"i/grpc/pbb\006proto3"
|
||||||
|
};
|
||||||
|
descriptor = com.google.protobuf.Descriptors.FileDescriptor
|
||||||
|
.internalBuildGeneratedFileFrom(descriptorData,
|
||||||
|
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||||
|
com.google.protobuf.EmptyProto.getDescriptor(),
|
||||||
|
});
|
||||||
|
internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor =
|
||||||
|
getDescriptor().getMessageTypes().get(0);
|
||||||
|
internal_static_bdware_bdledger_api_ClientVersionResponse_fieldAccessorTable = new
|
||||||
|
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
|
||||||
|
internal_static_bdware_bdledger_api_ClientVersionResponse_descriptor,
|
||||||
|
new java.lang.String[] { "Version", });
|
||||||
|
com.google.protobuf.EmptyProto.getDescriptor();
|
||||||
|
}
|
||||||
|
|
||||||
|
// @@protoc_insertion_point(outer_class_scope)
|
||||||
|
}
|
880
src/main/java/org/bdware/bdledger/api/grpc/pb/QueryGrpc.java
Normal file
880
src/main/java/org/bdware/bdledger/api/grpc/pb/QueryGrpc.java
Normal file
@ -0,0 +1,880 @@
|
|||||||
|
package org.bdware.bdledger.api.grpc.pb;
|
||||||
|
|
||||||
|
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||||
|
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||||
|
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
|
||||||
|
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
@javax.annotation.Generated(
|
||||||
|
value = "by gRPC proto compiler (version 1.27.0)",
|
||||||
|
comments = "Source: bdware/bdledger/api/query.proto")
|
||||||
|
public final class QueryGrpc {
|
||||||
|
|
||||||
|
private QueryGrpc() {}
|
||||||
|
|
||||||
|
public static final String SERVICE_NAME = "bdware.bdledger.api.Query";
|
||||||
|
|
||||||
|
// Static method descriptors that strictly reflect the proto.
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> getGetBlockByHashMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "GetBlockByHash",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> getGetBlockByHashMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> getGetBlockByHashMethod;
|
||||||
|
if ((getGetBlockByHashMethod = QueryGrpc.getGetBlockByHashMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getGetBlockByHashMethod = QueryGrpc.getGetBlockByHashMethod) == null) {
|
||||||
|
QueryGrpc.getGetBlockByHashMethod = getGetBlockByHashMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBlockByHash"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetBlockByHash"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getGetBlockByHashMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> getGetBlocksMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "GetBlocks",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> getGetBlocksMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> getGetBlocksMethod;
|
||||||
|
if ((getGetBlocksMethod = QueryGrpc.getGetBlocksMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getGetBlocksMethod = QueryGrpc.getGetBlocksMethod) == null) {
|
||||||
|
QueryGrpc.getGetBlocksMethod = getGetBlocksMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBlocks"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetBlocks"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getGetBlocksMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> getCountBlocksMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "CountBlocks",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> getCountBlocksMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> getCountBlocksMethod;
|
||||||
|
if ((getCountBlocksMethod = QueryGrpc.getCountBlocksMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getCountBlocksMethod = QueryGrpc.getCountBlocksMethod) == null) {
|
||||||
|
QueryGrpc.getCountBlocksMethod = getCountBlocksMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CountBlocks"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("CountBlocks"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getCountBlocksMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> getGetTransactionByHashMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "GetTransactionByHash",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> getGetTransactionByHashMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> getGetTransactionByHashMethod;
|
||||||
|
if ((getGetTransactionByHashMethod = QueryGrpc.getGetTransactionByHashMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getGetTransactionByHashMethod = QueryGrpc.getGetTransactionByHashMethod) == null) {
|
||||||
|
QueryGrpc.getGetTransactionByHashMethod = getGetTransactionByHashMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactionByHash"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactionByHash"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getGetTransactionByHashMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "GetTransactionByBlockHashAndIndex",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> getGetTransactionByBlockHashAndIndexMethod;
|
||||||
|
if ((getGetTransactionByBlockHashAndIndexMethod = QueryGrpc.getGetTransactionByBlockHashAndIndexMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getGetTransactionByBlockHashAndIndexMethod = QueryGrpc.getGetTransactionByBlockHashAndIndexMethod) == null) {
|
||||||
|
QueryGrpc.getGetTransactionByBlockHashAndIndexMethod = getGetTransactionByBlockHashAndIndexMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactionByBlockHashAndIndex"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactionByBlockHashAndIndex"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getGetTransactionByBlockHashAndIndexMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> getGetTransactionsMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "GetTransactions",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> getGetTransactionsMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> getGetTransactionsMethod;
|
||||||
|
if ((getGetTransactionsMethod = QueryGrpc.getGetTransactionsMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getGetTransactionsMethod = QueryGrpc.getGetTransactionsMethod) == null) {
|
||||||
|
QueryGrpc.getGetTransactionsMethod = getGetTransactionsMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetTransactions"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("GetTransactions"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getGetTransactionsMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> getCountTransactionsMethod;
|
||||||
|
|
||||||
|
@io.grpc.stub.annotations.RpcMethod(
|
||||||
|
fullMethodName = SERVICE_NAME + '/' + "CountTransactions",
|
||||||
|
requestType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest.class,
|
||||||
|
responseType = org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse.class,
|
||||||
|
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
public static io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> getCountTransactionsMethod() {
|
||||||
|
io.grpc.MethodDescriptor<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> getCountTransactionsMethod;
|
||||||
|
if ((getCountTransactionsMethod = QueryGrpc.getCountTransactionsMethod) == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
if ((getCountTransactionsMethod = QueryGrpc.getCountTransactionsMethod) == null) {
|
||||||
|
QueryGrpc.getCountTransactionsMethod = getCountTransactionsMethod =
|
||||||
|
io.grpc.MethodDescriptor.<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest, org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse>newBuilder()
|
||||||
|
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
|
||||||
|
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "CountTransactions"))
|
||||||
|
.setSampledToLocalTracing(true)
|
||||||
|
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest.getDefaultInstance()))
|
||||||
|
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse.getDefaultInstance()))
|
||||||
|
.setSchemaDescriptor(new QueryMethodDescriptorSupplier("CountTransactions"))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return getCountTransactionsMethod;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new async stub that supports all call types for the service
|
||||||
|
*/
|
||||||
|
public static QueryStub newStub(io.grpc.Channel channel) {
|
||||||
|
io.grpc.stub.AbstractStub.StubFactory<QueryStub> factory =
|
||||||
|
new io.grpc.stub.AbstractStub.StubFactory<QueryStub>() {
|
||||||
|
@java.lang.Override
|
||||||
|
public QueryStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return QueryStub.newStub(factory, channel);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new blocking-style stub that supports unary and streaming output calls on the service
|
||||||
|
*/
|
||||||
|
public static QueryBlockingStub newBlockingStub(
|
||||||
|
io.grpc.Channel channel) {
|
||||||
|
io.grpc.stub.AbstractStub.StubFactory<QueryBlockingStub> factory =
|
||||||
|
new io.grpc.stub.AbstractStub.StubFactory<QueryBlockingStub>() {
|
||||||
|
@java.lang.Override
|
||||||
|
public QueryBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryBlockingStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return QueryBlockingStub.newStub(factory, channel);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates a new ListenableFuture-style stub that supports unary calls on the service
|
||||||
|
*/
|
||||||
|
public static QueryFutureStub newFutureStub(
|
||||||
|
io.grpc.Channel channel) {
|
||||||
|
io.grpc.stub.AbstractStub.StubFactory<QueryFutureStub> factory =
|
||||||
|
new io.grpc.stub.AbstractStub.StubFactory<QueryFutureStub>() {
|
||||||
|
@java.lang.Override
|
||||||
|
public QueryFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryFutureStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
return QueryFutureStub.newStub(factory, channel);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
public static abstract class QueryImplBase implements io.grpc.BindableService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a block identified by its hash
|
||||||
|
* 查询哈希所指定的区块
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getGetBlockByHashMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get blocks in a timestamp range
|
||||||
|
* 查询时间范围内的区块
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getGetBlocksMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||||
|
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getCountBlocksMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by its hash
|
||||||
|
* 查询哈希所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getGetTransactionByHashMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by hash of the block it belongs to and its index inside the block
|
||||||
|
* 查询所在区块的哈希与其在区块中的index所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getGetTransactionByBlockHashAndIndexMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get transactions in a timestamp range
|
||||||
|
* 查询时间范围内的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getGetTransactionsMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||||
|
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> responseObserver) {
|
||||||
|
asyncUnimplementedUnaryCall(getCountTransactionsMethod(), responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
|
||||||
|
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
|
||||||
|
.addMethod(
|
||||||
|
getGetBlockByHashMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse>(
|
||||||
|
this, METHODID_GET_BLOCK_BY_HASH)))
|
||||||
|
.addMethod(
|
||||||
|
getGetBlocksMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse>(
|
||||||
|
this, METHODID_GET_BLOCKS)))
|
||||||
|
.addMethod(
|
||||||
|
getCountBlocksMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse>(
|
||||||
|
this, METHODID_COUNT_BLOCKS)))
|
||||||
|
.addMethod(
|
||||||
|
getGetTransactionByHashMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse>(
|
||||||
|
this, METHODID_GET_TRANSACTION_BY_HASH)))
|
||||||
|
.addMethod(
|
||||||
|
getGetTransactionByBlockHashAndIndexMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse>(
|
||||||
|
this, METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX)))
|
||||||
|
.addMethod(
|
||||||
|
getGetTransactionsMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse>(
|
||||||
|
this, METHODID_GET_TRANSACTIONS)))
|
||||||
|
.addMethod(
|
||||||
|
getCountTransactionsMethod(),
|
||||||
|
asyncUnaryCall(
|
||||||
|
new MethodHandlers<
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest,
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse>(
|
||||||
|
this, METHODID_COUNT_TRANSACTIONS)))
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
public static final class QueryStub extends io.grpc.stub.AbstractAsyncStub<QueryStub> {
|
||||||
|
private QueryStub(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
super(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected QueryStub build(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a block identified by its hash
|
||||||
|
* 查询哈希所指定的区块
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get blocks in a timestamp range
|
||||||
|
* 查询时间范围内的区块
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||||
|
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void countBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by its hash
|
||||||
|
* 查询哈希所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by hash of the block it belongs to and its index inside the block
|
||||||
|
* 查询所在区块的哈希与其在区块中的index所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get transactions in a timestamp range
|
||||||
|
* 查询时间范围内的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void getTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||||
|
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public void countTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request,
|
||||||
|
io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> responseObserver) {
|
||||||
|
asyncUnaryCall(
|
||||||
|
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request, responseObserver);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
public static final class QueryBlockingStub extends io.grpc.stub.AbstractBlockingStub<QueryBlockingStub> {
|
||||||
|
private QueryBlockingStub(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
super(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected QueryBlockingStub build(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryBlockingStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a block identified by its hash
|
||||||
|
* 查询哈希所指定的区块
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse getBlockByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getGetBlockByHashMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get blocks in a timestamp range
|
||||||
|
* 查询时间范围内的区块
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse getBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getGetBlocksMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||||
|
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse countBlocks(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getCountBlocksMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by its hash
|
||||||
|
* 查询哈希所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse getTransactionByHash(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getGetTransactionByHashMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by hash of the block it belongs to and its index inside the block
|
||||||
|
* 查询所在区块的哈希与其在区块中的index所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse getTransactionByBlockHashAndIndex(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getGetTransactionByBlockHashAndIndexMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get transactions in a timestamp range
|
||||||
|
* 查询时间范围内的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse getTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getGetTransactionsMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||||
|
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse countTransactions(org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request) {
|
||||||
|
return blockingUnaryCall(
|
||||||
|
getChannel(), getCountTransactionsMethod(), getCallOptions(), request);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*/
|
||||||
|
public static final class QueryFutureStub extends io.grpc.stub.AbstractFutureStub<QueryFutureStub> {
|
||||||
|
private QueryFutureStub(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
super(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
protected QueryFutureStub build(
|
||||||
|
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
|
||||||
|
return new QueryFutureStub(channel, callOptions);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a block identified by its hash
|
||||||
|
* 查询哈希所指定的区块
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse> getBlockByHash(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getGetBlockByHashMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get blocks in a timestamp range
|
||||||
|
* 查询时间范围内的区块
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse> getBlocks(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getGetBlocksMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all blocks in a ledger, or blocks in a timestamp range
|
||||||
|
* 查询帐本中的所有区块数量,或时间范围内的区块数量
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse> countBlocks(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getCountBlocksMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by its hash
|
||||||
|
* 查询哈希所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse> getTransactionByHash(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionByHashMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get a transaction identified by hash of the block it belongs to and its index inside the block
|
||||||
|
* 查询所在区块的哈希与其在区块中的index所指定的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse> getTransactionByBlockHashAndIndex(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionByBlockHashAndIndexMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Get transactions in a timestamp range
|
||||||
|
* 查询时间范围内的事务
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse> getTransactions(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getGetTransactionsMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <pre>
|
||||||
|
**
|
||||||
|
* Count all transactions in a ledger, or transactions in a timestamp range
|
||||||
|
* 查询帐本中的所有事务数量,或时间范围内的事务数量
|
||||||
|
* start_timestamp is required
|
||||||
|
* </pre>
|
||||||
|
*/
|
||||||
|
public com.google.common.util.concurrent.ListenableFuture<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse> countTransactions(
|
||||||
|
org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest request) {
|
||||||
|
return futureUnaryCall(
|
||||||
|
getChannel().newCall(getCountTransactionsMethod(), getCallOptions()), request);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final int METHODID_GET_BLOCK_BY_HASH = 0;
|
||||||
|
private static final int METHODID_GET_BLOCKS = 1;
|
||||||
|
private static final int METHODID_COUNT_BLOCKS = 2;
|
||||||
|
private static final int METHODID_GET_TRANSACTION_BY_HASH = 3;
|
||||||
|
private static final int METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX = 4;
|
||||||
|
private static final int METHODID_GET_TRANSACTIONS = 5;
|
||||||
|
private static final int METHODID_COUNT_TRANSACTIONS = 6;
|
||||||
|
|
||||||
|
private static final class MethodHandlers<Req, Resp> implements
|
||||||
|
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
||||||
|
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
||||||
|
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
||||||
|
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
||||||
|
private final QueryImplBase serviceImpl;
|
||||||
|
private final int methodId;
|
||||||
|
|
||||||
|
MethodHandlers(QueryImplBase serviceImpl, int methodId) {
|
||||||
|
this.serviceImpl = serviceImpl;
|
||||||
|
this.methodId = methodId;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
@java.lang.SuppressWarnings("unchecked")
|
||||||
|
public void invoke(Req request, io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||||
|
switch (methodId) {
|
||||||
|
case METHODID_GET_BLOCK_BY_HASH:
|
||||||
|
serviceImpl.getBlockByHash((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlockByHashResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_GET_BLOCKS:
|
||||||
|
serviceImpl.getBlocks((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetBlocksResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_COUNT_BLOCKS:
|
||||||
|
serviceImpl.countBlocks((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.BlocksRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountBlocksResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_GET_TRANSACTION_BY_HASH:
|
||||||
|
serviceImpl.getTransactionByHash((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByHashResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_GET_TRANSACTION_BY_BLOCK_HASH_AND_INDEX:
|
||||||
|
serviceImpl.getTransactionByBlockHashAndIndex((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionByBlockHashAndIndexResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_GET_TRANSACTIONS:
|
||||||
|
serviceImpl.getTransactions((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.GetTransactionsResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
case METHODID_COUNT_TRANSACTIONS:
|
||||||
|
serviceImpl.countTransactions((org.bdware.bdledger.api.grpc.pb.QueryOuterClass.TransactionsRequest) request,
|
||||||
|
(io.grpc.stub.StreamObserver<org.bdware.bdledger.api.grpc.pb.QueryOuterClass.CountTransactionsResponse>) responseObserver);
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
throw new AssertionError();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
@java.lang.SuppressWarnings("unchecked")
|
||||||
|
public io.grpc.stub.StreamObserver<Req> invoke(
|
||||||
|
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||||
|
switch (methodId) {
|
||||||
|
default:
|
||||||
|
throw new AssertionError();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static abstract class QueryBaseDescriptorSupplier
|
||||||
|
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
|
||||||
|
QueryBaseDescriptorSupplier() {}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
|
||||||
|
return org.bdware.bdledger.api.grpc.pb.QueryOuterClass.getDescriptor();
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() {
|
||||||
|
return getFileDescriptor().findServiceByName("Query");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final class QueryFileDescriptorSupplier
|
||||||
|
extends QueryBaseDescriptorSupplier {
|
||||||
|
QueryFileDescriptorSupplier() {}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static final class QueryMethodDescriptorSupplier
|
||||||
|
extends QueryBaseDescriptorSupplier
|
||||||
|
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
|
||||||
|
private final String methodName;
|
||||||
|
|
||||||
|
QueryMethodDescriptorSupplier(String methodName) {
|
||||||
|
this.methodName = methodName;
|
||||||
|
}
|
||||||
|
|
||||||
|
@java.lang.Override
|
||||||
|
public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() {
|
||||||
|
return getServiceDescriptor().findMethodByName(methodName);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static volatile io.grpc.ServiceDescriptor serviceDescriptor;
|
||||||
|
|
||||||
|
public static io.grpc.ServiceDescriptor getServiceDescriptor() {
|
||||||
|
io.grpc.ServiceDescriptor result = serviceDescriptor;
|
||||||
|
if (result == null) {
|
||||||
|
synchronized (QueryGrpc.class) {
|
||||||
|
result = serviceDescriptor;
|
||||||
|
if (result == null) {
|
||||||
|
serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
|
||||||
|
.setSchemaDescriptor(new QueryFileDescriptorSupplier())
|
||||||
|
.addMethod(getGetBlockByHashMethod())
|
||||||
|
.addMethod(getGetBlocksMethod())
|
||||||
|
.addMethod(getCountBlocksMethod())
|
||||||
|
.addMethod(getGetTransactionByHashMethod())
|
||||||
|
.addMethod(getGetTransactionByBlockHashAndIndexMethod())
|
||||||
|
.addMethod(getGetTransactionsMethod())
|
||||||
|
.addMethod(getCountTransactionsMethod())
|
||||||
|
.build();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
}
|
10941
src/main/java/org/bdware/bdledger/api/grpc/pb/QueryOuterClass.java
Normal file
10941
src/main/java/org/bdware/bdledger/api/grpc/pb/QueryOuterClass.java
Normal file
File diff suppressed because it is too large
Load Diff
@ -1 +0,0 @@
|
|||||||
Subproject commit bbe9b2123d74617b82f51a2016d8578cb3e4e8da
|
|
@ -1,12 +1,14 @@
|
|||||||
package bdledger.api;
|
package org.bdware.bdledger.api.grpc;
|
||||||
|
|
||||||
import bdledger.api.grpc.common.Block;
|
import org.bdware.bdledger.api.grpc.pb.Common.Block;
|
||||||
import bdledger.api.grpc.common.Transaction;
|
import org.bdware.bdledger.api.grpc.pb.Common.Transaction;
|
||||||
import bdledger.api.grpc.common.TransactionType;
|
import org.bdware.bdledger.api.grpc.pb.Common.TransactionType;
|
||||||
import bdledger.api.grpc.ledger.GetLedgersResponse;
|
import org.bdware.bdledger.api.grpc.pb.LedgerOuterClass.GetLedgersResponse;
|
||||||
import com.google.protobuf.ByteString;
|
import com.google.protobuf.ByteString;
|
||||||
import io.grpc.Status;
|
import io.grpc.Status;
|
||||||
|
import org.bdware.bdledger.api.grpc.pb.QueryOuterClass;
|
||||||
import org.junit.jupiter.api.AfterAll;
|
import org.junit.jupiter.api.AfterAll;
|
||||||
|
import org.junit.jupiter.api.Assertions;
|
||||||
import org.junit.jupiter.api.BeforeAll;
|
import org.junit.jupiter.api.BeforeAll;
|
||||||
import org.junit.jupiter.api.DisplayName;
|
import org.junit.jupiter.api.DisplayName;
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
@ -105,23 +107,23 @@ class ClientTests {
|
|||||||
@Test
|
@Test
|
||||||
@DisplayName("ClientVersion#1")
|
@DisplayName("ClientVersion#1")
|
||||||
void clientVersion1() throws ExecutionException, InterruptedException {
|
void clientVersion1() throws ExecutionException, InterruptedException {
|
||||||
assertEquals(
|
Assertions.assertEquals(
|
||||||
"TxLedgerGo/v0.0.1alpha/darwin/go1.11", client.clientVersion().get().getVersion());
|
"TxLedgerGo/v0.0.1alpha/darwin/go1.11", client.clientVersion().get().getVersion());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CreateLedger#1")
|
@DisplayName("CreateLedger#1")
|
||||||
void createLedger1() throws ExecutionException, InterruptedException {
|
void createLedger1() throws ExecutionException, InterruptedException {
|
||||||
assertTrue(client.createLedger(ledger).get().getOk());
|
Assertions.assertTrue(client.createLedger(ledger).get().getOk());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CreateLedger#2")
|
@DisplayName("CreateLedger#2")
|
||||||
void createLedger2() {
|
void createLedger2() {
|
||||||
Throwable e = assertThrows(Exception.class, () -> client.createLedger("").get());
|
Throwable e = Assertions.assertThrows(Exception.class, () -> client.createLedger("").get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("name must not be empty", s.getDescription());
|
Assertions.assertEquals("name must not be empty", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@ -130,7 +132,7 @@ class ClientTests {
|
|||||||
GetLedgersResponse r = client.getLedgers().get();
|
GetLedgersResponse r = client.getLedgers().get();
|
||||||
assertEquals(3, r.getLedgersCount());
|
assertEquals(3, r.getLedgersCount());
|
||||||
String[] expected = new String[]{"first", "second", "third"};
|
String[] expected = new String[]{"first", "second", "third"};
|
||||||
assertAll(
|
Assertions.assertAll(
|
||||||
IntStream.range(0, 3).boxed().map(i -> () -> assertEquals(expected[i], r.getLedgers(i))));
|
IntStream.range(0, 3).boxed().map(i -> () -> assertEquals(expected[i], r.getLedgers(i))));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -149,22 +151,22 @@ class ClientTests {
|
|||||||
.get()
|
.get()
|
||||||
.getHash()
|
.getHash()
|
||||||
.toByteArray());
|
.toByteArray());
|
||||||
assertEquals("d15ea5edd15ea5edd15ea5edd15ea5edd15ea5ed", hash);
|
Assertions.assertEquals("d15ea5edd15ea5edd15ea5edd15ea5edd15ea5ed", hash);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("SendTransaction#2")
|
@DisplayName("SendTransaction#2")
|
||||||
void sendTransaction2() {
|
void sendTransaction2() {
|
||||||
Throwable e =
|
Throwable e =
|
||||||
assertThrows(
|
Assertions.assertThrows(
|
||||||
Exception.class,
|
Exception.class,
|
||||||
() ->
|
() ->
|
||||||
client
|
client
|
||||||
.sendTransaction(ledger, TransactionType.MESSAGE, null, "50bada55", null)
|
.sendTransaction(ledger, TransactionType.MESSAGE, null, "50bada55", null)
|
||||||
.get());
|
.get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("Multiple invalid arguments", s.getDescription());
|
Assertions.assertEquals("Multiple invalid arguments", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@ -178,38 +180,38 @@ class ClientTests {
|
|||||||
@Test
|
@Test
|
||||||
@DisplayName("getBlocks#1")
|
@DisplayName("getBlocks#1")
|
||||||
void getBlocks1() throws ExecutionException, InterruptedException {
|
void getBlocks1() throws ExecutionException, InterruptedException {
|
||||||
client.getBlocks(ledger, 0).get();
|
client.getBlocks(ledger, 0, null).get();
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO
|
// TODO
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("getBlocks#2")
|
@DisplayName("getBlocks#2")
|
||||||
void getBlocks2() throws ExecutionException, InterruptedException {
|
void getBlocks2() throws ExecutionException, InterruptedException {
|
||||||
client.getBlocks(ledger, 0, 0).get();
|
client.getBlocks(ledger, 0, 0, null).get();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("getBlocks#3")
|
@DisplayName("getBlocks#3")
|
||||||
void getBlocks3() {
|
void getBlocks3() {
|
||||||
Throwable e = assertThrows(Exception.class, () -> client.getBlocks("", 0, 0).get());
|
Throwable e = Assertions.assertThrows(Exception.class, () -> client.getBlocks("", 0, 0, null).get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("ledger must not be empty", s.getDescription());
|
Assertions.assertEquals("ledger must not be empty", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CountBlocks#1")
|
@DisplayName("CountBlocks#1")
|
||||||
void blockNumber1() throws ExecutionException, InterruptedException {
|
void blockNumber1() throws ExecutionException, InterruptedException {
|
||||||
assertEquals(blockCount, client.countBlocks(ledger).get().getCount());
|
Assertions.assertEquals(blockCount, client.countBlocks(ledger).get().getCount());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CountBlocks#2")
|
@DisplayName("CountBlocks#2")
|
||||||
void blockNumber2() {
|
void blockNumber2() {
|
||||||
Throwable e = assertThrows(Exception.class, () -> client.countBlocks("").get());
|
Throwable e = Assertions.assertThrows(Exception.class, () -> client.countBlocks("").get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("ledger must not be empty", s.getDescription());
|
Assertions.assertEquals("ledger must not be empty", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@ -243,25 +245,25 @@ class ClientTests {
|
|||||||
@Test
|
@Test
|
||||||
@DisplayName("getTransactions#3")
|
@DisplayName("getTransactions#3")
|
||||||
void getTransactions3() {
|
void getTransactions3() {
|
||||||
Throwable e = assertThrows(Exception.class, () -> client.getTransactions("", 0, 0).get());
|
Throwable e = Assertions.assertThrows(Exception.class, () -> client.getTransactions("", 0, 0).get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("ledger must not be empty", s.getDescription());
|
Assertions.assertEquals("ledger must not be empty", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CountTransactions#1")
|
@DisplayName("CountTransactions#1")
|
||||||
void CountTransactions1() throws ExecutionException, InterruptedException {
|
void CountTransactions1() throws ExecutionException, InterruptedException {
|
||||||
assertEquals(transactionCount, client.countTransactions(ledger).get().getCount());
|
Assertions.assertEquals(transactionCount, client.countTransactions(ledger).get().getCount());
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@DisplayName("CountTransactions#2")
|
@DisplayName("CountTransactions#2")
|
||||||
void CountTransactions2() {
|
void CountTransactions2() {
|
||||||
Throwable e = assertThrows(Exception.class, () -> client.countTransactions("").get());
|
Throwable e = Assertions.assertThrows(Exception.class, () -> client.countTransactions("").get());
|
||||||
Status s = Status.fromThrowable(e);
|
Status s = Status.fromThrowable(e);
|
||||||
assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
Assertions.assertEquals(Status.Code.INVALID_ARGUMENT, s.getCode());
|
||||||
assertEquals("ledger must not be empty", s.getDescription());
|
Assertions.assertEquals("ledger must not be empty", s.getDescription());
|
||||||
}
|
}
|
||||||
|
|
||||||
@AfterAll
|
@AfterAll
|
Loading…
x
Reference in New Issue
Block a user