All Downloads are FREE. Search and download functionalities are using the official Maven repository.

ru.tinkoff.piapi.contract.v1.Operation Maven / Gradle / Ivy

There is a newer version: 1.25
Show newest version
// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: operations.proto

package ru.tinkoff.piapi.contract.v1;

/**
 * 
 *Данные по операции.
 * 
* * Protobuf type {@code tinkoff.public.invest.api.contract.v1.Operation} */ public final class Operation extends com.google.protobuf.GeneratedMessageV3 implements // @@protoc_insertion_point(message_implements:tinkoff.public.invest.api.contract.v1.Operation) OperationOrBuilder { private static final long serialVersionUID = 0L; // Use Operation.newBuilder() to construct. private Operation(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } private Operation() { id_ = ""; parentOperationId_ = ""; currency_ = ""; state_ = 0; figi_ = ""; instrumentType_ = ""; type_ = ""; operationType_ = 0; trades_ = java.util.Collections.emptyList(); assetUid_ = ""; positionUid_ = ""; instrumentUid_ = ""; } @java.lang.Override @SuppressWarnings({"unused"}) protected java.lang.Object newInstance( UnusedPrivateParameter unused) { return new Operation(); } public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_Operation_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_Operation_fieldAccessorTable .ensureFieldAccessorsInitialized( ru.tinkoff.piapi.contract.v1.Operation.class, ru.tinkoff.piapi.contract.v1.Operation.Builder.class); } public static final int ID_FIELD_NUMBER = 1; @SuppressWarnings("serial") private volatile java.lang.Object id_ = ""; /** *
   *Идентификатор операции.
   * 
* * string id = 1; * @return The id. */ @java.lang.Override public java.lang.String getId() { java.lang.Object ref = id_; 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(); id_ = s; return s; } } /** *
   *Идентификатор операции.
   * 
* * string id = 1; * @return The bytes for id. */ @java.lang.Override public com.google.protobuf.ByteString getIdBytes() { java.lang.Object ref = id_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); id_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int PARENT_OPERATION_ID_FIELD_NUMBER = 2; @SuppressWarnings("serial") private volatile java.lang.Object parentOperationId_ = ""; /** *
   *Идентификатор родительской операции.
   * 
* * string parent_operation_id = 2; * @return The parentOperationId. */ @java.lang.Override public java.lang.String getParentOperationId() { java.lang.Object ref = parentOperationId_; 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(); parentOperationId_ = s; return s; } } /** *
   *Идентификатор родительской операции.
   * 
* * string parent_operation_id = 2; * @return The bytes for parentOperationId. */ @java.lang.Override public com.google.protobuf.ByteString getParentOperationIdBytes() { java.lang.Object ref = parentOperationId_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); parentOperationId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int CURRENCY_FIELD_NUMBER = 3; @SuppressWarnings("serial") private volatile java.lang.Object currency_ = ""; /** *
   *Валюта операции.
   * 
* * string currency = 3; * @return The currency. */ @java.lang.Override public java.lang.String getCurrency() { java.lang.Object ref = currency_; 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(); currency_ = s; return s; } } /** *
   *Валюта операции.
   * 
* * string currency = 3; * @return The bytes for currency. */ @java.lang.Override public com.google.protobuf.ByteString getCurrencyBytes() { java.lang.Object ref = currency_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); currency_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int PAYMENT_FIELD_NUMBER = 4; private ru.tinkoff.piapi.contract.v1.MoneyValue payment_; /** *
   *Сумма операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; * @return Whether the payment field is set. */ @java.lang.Override public boolean hasPayment() { return payment_ != null; } /** *
   *Сумма операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; * @return The payment. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.MoneyValue getPayment() { return payment_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : payment_; } /** *
   *Сумма операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder getPaymentOrBuilder() { return payment_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : payment_; } public static final int PRICE_FIELD_NUMBER = 5; private ru.tinkoff.piapi.contract.v1.MoneyValue price_; /** *
   *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; * @return Whether the price field is set. */ @java.lang.Override public boolean hasPrice() { return price_ != null; } /** *
   *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; * @return The price. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.MoneyValue getPrice() { return price_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : price_; } /** *
   *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
   * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder getPriceOrBuilder() { return price_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : price_; } public static final int STATE_FIELD_NUMBER = 6; private int state_ = 0; /** *
   *Статус операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** *
   *Статус операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @return The state. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationState getState() { ru.tinkoff.piapi.contract.v1.OperationState result = ru.tinkoff.piapi.contract.v1.OperationState.forNumber(state_); return result == null ? ru.tinkoff.piapi.contract.v1.OperationState.UNRECOGNIZED : result; } public static final int QUANTITY_FIELD_NUMBER = 7; private long quantity_ = 0L; /** *
   *Количество единиц инструмента.
   * 
* * int64 quantity = 7; * @return The quantity. */ @java.lang.Override public long getQuantity() { return quantity_; } public static final int QUANTITY_REST_FIELD_NUMBER = 8; private long quantityRest_ = 0L; /** *
   *Неисполненный остаток по сделке.
   * 
* * int64 quantity_rest = 8; * @return The quantityRest. */ @java.lang.Override public long getQuantityRest() { return quantityRest_; } public static final int FIGI_FIELD_NUMBER = 9; @SuppressWarnings("serial") private volatile java.lang.Object figi_ = ""; /** *
   *Figi-идентификатор инструмента, связанного с операцией.
   * 
* * string figi = 9; * @return The figi. */ @java.lang.Override public java.lang.String getFigi() { java.lang.Object ref = figi_; 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(); figi_ = s; return s; } } /** *
   *Figi-идентификатор инструмента, связанного с операцией.
   * 
* * string figi = 9; * @return The bytes for figi. */ @java.lang.Override public com.google.protobuf.ByteString getFigiBytes() { java.lang.Object ref = figi_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); figi_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int INSTRUMENT_TYPE_FIELD_NUMBER = 10; @SuppressWarnings("serial") private volatile java.lang.Object instrumentType_ = ""; /** *
   *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
   * 
* * string instrument_type = 10; * @return The instrumentType. */ @java.lang.Override public java.lang.String getInstrumentType() { java.lang.Object ref = instrumentType_; 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(); instrumentType_ = s; return s; } } /** *
   *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
   * 
* * string instrument_type = 10; * @return The bytes for instrumentType. */ @java.lang.Override public com.google.protobuf.ByteString getInstrumentTypeBytes() { java.lang.Object ref = instrumentType_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); instrumentType_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int DATE_FIELD_NUMBER = 11; private com.google.protobuf.Timestamp date_; /** *
   *Дата и время операции в формате часовом поясе UTC.
   * 
* * .google.protobuf.Timestamp date = 11; * @return Whether the date field is set. */ @java.lang.Override public boolean hasDate() { return date_ != null; } /** *
   *Дата и время операции в формате часовом поясе UTC.
   * 
* * .google.protobuf.Timestamp date = 11; * @return The date. */ @java.lang.Override public com.google.protobuf.Timestamp getDate() { return date_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : date_; } /** *
   *Дата и время операции в формате часовом поясе UTC.
   * 
* * .google.protobuf.Timestamp date = 11; */ @java.lang.Override public com.google.protobuf.TimestampOrBuilder getDateOrBuilder() { return date_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : date_; } public static final int TYPE_FIELD_NUMBER = 12; @SuppressWarnings("serial") private volatile java.lang.Object type_ = ""; /** *
   *Текстовое описание типа операции.
   * 
* * string type = 12; * @return The type. */ @java.lang.Override public java.lang.String getType() { java.lang.Object ref = type_; 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(); type_ = s; return s; } } /** *
   *Текстовое описание типа операции.
   * 
* * string type = 12; * @return The bytes for type. */ @java.lang.Override public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int OPERATION_TYPE_FIELD_NUMBER = 13; private int operationType_ = 0; /** *
   *Тип операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @return The enum numeric value on the wire for operationType. */ @java.lang.Override public int getOperationTypeValue() { return operationType_; } /** *
   *Тип операции.
   * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @return The operationType. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationType getOperationType() { ru.tinkoff.piapi.contract.v1.OperationType result = ru.tinkoff.piapi.contract.v1.OperationType.forNumber(operationType_); return result == null ? ru.tinkoff.piapi.contract.v1.OperationType.UNRECOGNIZED : result; } public static final int TRADES_FIELD_NUMBER = 14; @SuppressWarnings("serial") private java.util.List trades_; /** *
   *Массив сделок.
   * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ @java.lang.Override public java.util.List getTradesList() { return trades_; } /** *
   *Массив сделок.
   * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ @java.lang.Override public java.util.List getTradesOrBuilderList() { return trades_; } /** *
   *Массив сделок.
   * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ @java.lang.Override public int getTradesCount() { return trades_.size(); } /** *
   *Массив сделок.
   * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationTrade getTrades(int index) { return trades_.get(index); } /** *
   *Массив сделок.
   * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationTradeOrBuilder getTradesOrBuilder( int index) { return trades_.get(index); } public static final int ASSET_UID_FIELD_NUMBER = 16; @SuppressWarnings("serial") private volatile java.lang.Object assetUid_ = ""; /** *
   *Идентификатор актива
   * 
* * string asset_uid = 16; * @return The assetUid. */ @java.lang.Override public java.lang.String getAssetUid() { java.lang.Object ref = assetUid_; 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(); assetUid_ = s; return s; } } /** *
   *Идентификатор актива
   * 
* * string asset_uid = 16; * @return The bytes for assetUid. */ @java.lang.Override public com.google.protobuf.ByteString getAssetUidBytes() { java.lang.Object ref = assetUid_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); assetUid_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int POSITION_UID_FIELD_NUMBER = 17; @SuppressWarnings("serial") private volatile java.lang.Object positionUid_ = ""; /** *
   *position_uid-идентификатора инструмента.
   * 
* * string position_uid = 17; * @return The positionUid. */ @java.lang.Override public java.lang.String getPositionUid() { java.lang.Object ref = positionUid_; 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(); positionUid_ = s; return s; } } /** *
   *position_uid-идентификатора инструмента.
   * 
* * string position_uid = 17; * @return The bytes for positionUid. */ @java.lang.Override public com.google.protobuf.ByteString getPositionUidBytes() { java.lang.Object ref = positionUid_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); positionUid_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } public static final int INSTRUMENT_UID_FIELD_NUMBER = 18; @SuppressWarnings("serial") private volatile java.lang.Object instrumentUid_ = ""; /** *
   *Уникальный идентификатор инструмента.
   * 
* * string instrument_uid = 18; * @return The instrumentUid. */ @java.lang.Override public java.lang.String getInstrumentUid() { java.lang.Object ref = instrumentUid_; 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(); instrumentUid_ = s; return s; } } /** *
   *Уникальный идентификатор инструмента.
   * 
* * string instrument_uid = 18; * @return The bytes for instrumentUid. */ @java.lang.Override public com.google.protobuf.ByteString getInstrumentUidBytes() { java.lang.Object ref = instrumentUid_; if (ref instanceof java.lang.String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); instrumentUid_ = 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 (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parentOperationId_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, parentOperationId_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(currency_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, currency_); } if (payment_ != null) { output.writeMessage(4, getPayment()); } if (price_ != null) { output.writeMessage(5, getPrice()); } if (state_ != ru.tinkoff.piapi.contract.v1.OperationState.OPERATION_STATE_UNSPECIFIED.getNumber()) { output.writeEnum(6, state_); } if (quantity_ != 0L) { output.writeInt64(7, quantity_); } if (quantityRest_ != 0L) { output.writeInt64(8, quantityRest_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(figi_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 9, figi_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(instrumentType_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 10, instrumentType_); } if (date_ != null) { output.writeMessage(11, getDate()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 12, type_); } if (operationType_ != ru.tinkoff.piapi.contract.v1.OperationType.OPERATION_TYPE_UNSPECIFIED.getNumber()) { output.writeEnum(13, operationType_); } for (int i = 0; i < trades_.size(); i++) { output.writeMessage(14, trades_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(assetUid_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 16, assetUid_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(positionUid_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 17, positionUid_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(instrumentUid_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 18, instrumentUid_); } getUnknownFields().writeTo(output); } @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parentOperationId_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, parentOperationId_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(currency_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, currency_); } if (payment_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(4, getPayment()); } if (price_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(5, getPrice()); } if (state_ != ru.tinkoff.piapi.contract.v1.OperationState.OPERATION_STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(6, state_); } if (quantity_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(7, quantity_); } if (quantityRest_ != 0L) { size += com.google.protobuf.CodedOutputStream .computeInt64Size(8, quantityRest_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(figi_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, figi_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(instrumentType_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, instrumentType_); } if (date_ != null) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(11, getDate()); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(type_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(12, type_); } if (operationType_ != ru.tinkoff.piapi.contract.v1.OperationType.OPERATION_TYPE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream .computeEnumSize(13, operationType_); } for (int i = 0; i < trades_.size(); i++) { size += com.google.protobuf.CodedOutputStream .computeMessageSize(14, trades_.get(i)); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(assetUid_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(16, assetUid_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(positionUid_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(17, positionUid_); } if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(instrumentUid_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(18, instrumentUid_); } size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof ru.tinkoff.piapi.contract.v1.Operation)) { return super.equals(obj); } ru.tinkoff.piapi.contract.v1.Operation other = (ru.tinkoff.piapi.contract.v1.Operation) obj; if (!getId() .equals(other.getId())) return false; if (!getParentOperationId() .equals(other.getParentOperationId())) return false; if (!getCurrency() .equals(other.getCurrency())) return false; if (hasPayment() != other.hasPayment()) return false; if (hasPayment()) { if (!getPayment() .equals(other.getPayment())) return false; } if (hasPrice() != other.hasPrice()) return false; if (hasPrice()) { if (!getPrice() .equals(other.getPrice())) return false; } if (state_ != other.state_) return false; if (getQuantity() != other.getQuantity()) return false; if (getQuantityRest() != other.getQuantityRest()) return false; if (!getFigi() .equals(other.getFigi())) return false; if (!getInstrumentType() .equals(other.getInstrumentType())) return false; if (hasDate() != other.hasDate()) return false; if (hasDate()) { if (!getDate() .equals(other.getDate())) return false; } if (!getType() .equals(other.getType())) return false; if (operationType_ != other.operationType_) return false; if (!getTradesList() .equals(other.getTradesList())) return false; if (!getAssetUid() .equals(other.getAssetUid())) return false; if (!getPositionUid() .equals(other.getPositionUid())) return false; if (!getInstrumentUid() .equals(other.getInstrumentUid())) return false; if (!getUnknownFields().equals(other.getUnknownFields())) 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) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); hash = (37 * hash) + PARENT_OPERATION_ID_FIELD_NUMBER; hash = (53 * hash) + getParentOperationId().hashCode(); hash = (37 * hash) + CURRENCY_FIELD_NUMBER; hash = (53 * hash) + getCurrency().hashCode(); if (hasPayment()) { hash = (37 * hash) + PAYMENT_FIELD_NUMBER; hash = (53 * hash) + getPayment().hashCode(); } if (hasPrice()) { hash = (37 * hash) + PRICE_FIELD_NUMBER; hash = (53 * hash) + getPrice().hashCode(); } hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; hash = (37 * hash) + QUANTITY_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getQuantity()); hash = (37 * hash) + QUANTITY_REST_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong( getQuantityRest()); hash = (37 * hash) + FIGI_FIELD_NUMBER; hash = (53 * hash) + getFigi().hashCode(); hash = (37 * hash) + INSTRUMENT_TYPE_FIELD_NUMBER; hash = (53 * hash) + getInstrumentType().hashCode(); if (hasDate()) { hash = (37 * hash) + DATE_FIELD_NUMBER; hash = (53 * hash) + getDate().hashCode(); } hash = (37 * hash) + TYPE_FIELD_NUMBER; hash = (53 * hash) + getType().hashCode(); hash = (37 * hash) + OPERATION_TYPE_FIELD_NUMBER; hash = (53 * hash) + operationType_; if (getTradesCount() > 0) { hash = (37 * hash) + TRADES_FIELD_NUMBER; hash = (53 * hash) + getTradesList().hashCode(); } hash = (37 * hash) + ASSET_UID_FIELD_NUMBER; hash = (53 * hash) + getAssetUid().hashCode(); hash = (37 * hash) + POSITION_UID_FIELD_NUMBER; hash = (53 * hash) + getPositionUid().hashCode(); hash = (37 * hash) + INSTRUMENT_UID_FIELD_NUMBER; hash = (53 * hash) + getInstrumentUid().hashCode(); hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom( java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom( java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom( byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } public static ru.tinkoff.piapi.contract.v1.Operation parseFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static ru.tinkoff.piapi.contract.v1.Operation 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 ru.tinkoff.piapi.contract.v1.Operation parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseDelimitedWithIOException(PARSER, input); } public static ru.tinkoff.piapi.contract.v1.Operation 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 ru.tinkoff.piapi.contract.v1.Operation parseFrom( com.google.protobuf.CodedInputStream input) throws java.io.IOException { return com.google.protobuf.GeneratedMessageV3 .parseWithIOException(PARSER, input); } public static ru.tinkoff.piapi.contract.v1.Operation 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(ru.tinkoff.piapi.contract.v1.Operation 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 tinkoff.public.invest.api.contract.v1.Operation} */ public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder implements // @@protoc_insertion_point(builder_implements:tinkoff.public.invest.api.contract.v1.Operation) ru.tinkoff.piapi.contract.v1.OperationOrBuilder { public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_Operation_descriptor; } @java.lang.Override protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_Operation_fieldAccessorTable .ensureFieldAccessorsInitialized( ru.tinkoff.piapi.contract.v1.Operation.class, ru.tinkoff.piapi.contract.v1.Operation.Builder.class); } // Construct using ru.tinkoff.piapi.contract.v1.Operation.newBuilder() private Builder() { } private Builder( com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); } @java.lang.Override public Builder clear() { super.clear(); bitField0_ = 0; id_ = ""; parentOperationId_ = ""; currency_ = ""; payment_ = null; if (paymentBuilder_ != null) { paymentBuilder_.dispose(); paymentBuilder_ = null; } price_ = null; if (priceBuilder_ != null) { priceBuilder_.dispose(); priceBuilder_ = null; } state_ = 0; quantity_ = 0L; quantityRest_ = 0L; figi_ = ""; instrumentType_ = ""; date_ = null; if (dateBuilder_ != null) { dateBuilder_.dispose(); dateBuilder_ = null; } type_ = ""; operationType_ = 0; if (tradesBuilder_ == null) { trades_ = java.util.Collections.emptyList(); } else { trades_ = null; tradesBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00002000); assetUid_ = ""; positionUid_ = ""; instrumentUid_ = ""; return this; } @java.lang.Override public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_Operation_descriptor; } @java.lang.Override public ru.tinkoff.piapi.contract.v1.Operation getDefaultInstanceForType() { return ru.tinkoff.piapi.contract.v1.Operation.getDefaultInstance(); } @java.lang.Override public ru.tinkoff.piapi.contract.v1.Operation build() { ru.tinkoff.piapi.contract.v1.Operation result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } @java.lang.Override public ru.tinkoff.piapi.contract.v1.Operation buildPartial() { ru.tinkoff.piapi.contract.v1.Operation result = new ru.tinkoff.piapi.contract.v1.Operation(this); buildPartialRepeatedFields(result); if (bitField0_ != 0) { buildPartial0(result); } onBuilt(); return result; } private void buildPartialRepeatedFields(ru.tinkoff.piapi.contract.v1.Operation result) { if (tradesBuilder_ == null) { if (((bitField0_ & 0x00002000) != 0)) { trades_ = java.util.Collections.unmodifiableList(trades_); bitField0_ = (bitField0_ & ~0x00002000); } result.trades_ = trades_; } else { result.trades_ = tradesBuilder_.build(); } } private void buildPartial0(ru.tinkoff.piapi.contract.v1.Operation result) { int from_bitField0_ = bitField0_; if (((from_bitField0_ & 0x00000001) != 0)) { result.id_ = id_; } if (((from_bitField0_ & 0x00000002) != 0)) { result.parentOperationId_ = parentOperationId_; } if (((from_bitField0_ & 0x00000004) != 0)) { result.currency_ = currency_; } if (((from_bitField0_ & 0x00000008) != 0)) { result.payment_ = paymentBuilder_ == null ? payment_ : paymentBuilder_.build(); } if (((from_bitField0_ & 0x00000010) != 0)) { result.price_ = priceBuilder_ == null ? price_ : priceBuilder_.build(); } if (((from_bitField0_ & 0x00000020) != 0)) { result.state_ = state_; } if (((from_bitField0_ & 0x00000040) != 0)) { result.quantity_ = quantity_; } if (((from_bitField0_ & 0x00000080) != 0)) { result.quantityRest_ = quantityRest_; } if (((from_bitField0_ & 0x00000100) != 0)) { result.figi_ = figi_; } if (((from_bitField0_ & 0x00000200) != 0)) { result.instrumentType_ = instrumentType_; } if (((from_bitField0_ & 0x00000400) != 0)) { result.date_ = dateBuilder_ == null ? date_ : dateBuilder_.build(); } if (((from_bitField0_ & 0x00000800) != 0)) { result.type_ = type_; } if (((from_bitField0_ & 0x00001000) != 0)) { result.operationType_ = operationType_; } if (((from_bitField0_ & 0x00004000) != 0)) { result.assetUid_ = assetUid_; } if (((from_bitField0_ & 0x00008000) != 0)) { result.positionUid_ = positionUid_; } if (((from_bitField0_ & 0x00010000) != 0)) { result.instrumentUid_ = instrumentUid_; } } @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { if (other instanceof ru.tinkoff.piapi.contract.v1.Operation) { return mergeFrom((ru.tinkoff.piapi.contract.v1.Operation)other); } else { super.mergeFrom(other); return this; } } public Builder mergeFrom(ru.tinkoff.piapi.contract.v1.Operation other) { if (other == ru.tinkoff.piapi.contract.v1.Operation.getDefaultInstance()) return this; if (!other.getId().isEmpty()) { id_ = other.id_; bitField0_ |= 0x00000001; onChanged(); } if (!other.getParentOperationId().isEmpty()) { parentOperationId_ = other.parentOperationId_; bitField0_ |= 0x00000002; onChanged(); } if (!other.getCurrency().isEmpty()) { currency_ = other.currency_; bitField0_ |= 0x00000004; onChanged(); } if (other.hasPayment()) { mergePayment(other.getPayment()); } if (other.hasPrice()) { mergePrice(other.getPrice()); } if (other.state_ != 0) { setStateValue(other.getStateValue()); } if (other.getQuantity() != 0L) { setQuantity(other.getQuantity()); } if (other.getQuantityRest() != 0L) { setQuantityRest(other.getQuantityRest()); } if (!other.getFigi().isEmpty()) { figi_ = other.figi_; bitField0_ |= 0x00000100; onChanged(); } if (!other.getInstrumentType().isEmpty()) { instrumentType_ = other.instrumentType_; bitField0_ |= 0x00000200; onChanged(); } if (other.hasDate()) { mergeDate(other.getDate()); } if (!other.getType().isEmpty()) { type_ = other.type_; bitField0_ |= 0x00000800; onChanged(); } if (other.operationType_ != 0) { setOperationTypeValue(other.getOperationTypeValue()); } if (tradesBuilder_ == null) { if (!other.trades_.isEmpty()) { if (trades_.isEmpty()) { trades_ = other.trades_; bitField0_ = (bitField0_ & ~0x00002000); } else { ensureTradesIsMutable(); trades_.addAll(other.trades_); } onChanged(); } } else { if (!other.trades_.isEmpty()) { if (tradesBuilder_.isEmpty()) { tradesBuilder_.dispose(); tradesBuilder_ = null; trades_ = other.trades_; bitField0_ = (bitField0_ & ~0x00002000); tradesBuilder_ = com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? getTradesFieldBuilder() : null; } else { tradesBuilder_.addAllMessages(other.trades_); } } } if (!other.getAssetUid().isEmpty()) { assetUid_ = other.assetUid_; bitField0_ |= 0x00004000; onChanged(); } if (!other.getPositionUid().isEmpty()) { positionUid_ = other.positionUid_; bitField0_ |= 0x00008000; onChanged(); } if (!other.getInstrumentUid().isEmpty()) { instrumentUid_ = other.instrumentUid_; bitField0_ |= 0x00010000; onChanged(); } this.mergeUnknownFields(other.getUnknownFields()); 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 { if (extensionRegistry == null) { throw new java.lang.NullPointerException(); } try { boolean done = false; while (!done) { int tag = input.readTag(); switch (tag) { case 0: done = true; break; case 10: { id_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000001; break; } // case 10 case 18: { parentOperationId_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000002; break; } // case 18 case 26: { currency_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000004; break; } // case 26 case 34: { input.readMessage( getPaymentFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000008; break; } // case 34 case 42: { input.readMessage( getPriceFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000010; break; } // case 42 case 48: { state_ = input.readEnum(); bitField0_ |= 0x00000020; break; } // case 48 case 56: { quantity_ = input.readInt64(); bitField0_ |= 0x00000040; break; } // case 56 case 64: { quantityRest_ = input.readInt64(); bitField0_ |= 0x00000080; break; } // case 64 case 74: { figi_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000100; break; } // case 74 case 82: { instrumentType_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000200; break; } // case 82 case 90: { input.readMessage( getDateFieldBuilder().getBuilder(), extensionRegistry); bitField0_ |= 0x00000400; break; } // case 90 case 98: { type_ = input.readStringRequireUtf8(); bitField0_ |= 0x00000800; break; } // case 98 case 104: { operationType_ = input.readEnum(); bitField0_ |= 0x00001000; break; } // case 104 case 114: { ru.tinkoff.piapi.contract.v1.OperationTrade m = input.readMessage( ru.tinkoff.piapi.contract.v1.OperationTrade.parser(), extensionRegistry); if (tradesBuilder_ == null) { ensureTradesIsMutable(); trades_.add(m); } else { tradesBuilder_.addMessage(m); } break; } // case 114 case 130: { assetUid_ = input.readStringRequireUtf8(); bitField0_ |= 0x00004000; break; } // case 130 case 138: { positionUid_ = input.readStringRequireUtf8(); bitField0_ |= 0x00008000; break; } // case 138 case 146: { instrumentUid_ = input.readStringRequireUtf8(); bitField0_ |= 0x00010000; break; } // case 146 default: { if (!super.parseUnknownField(input, extensionRegistry, tag)) { done = true; // was an endgroup tag } break; } // default: } // switch (tag) } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.unwrapIOException(); } finally { onChanged(); } // finally return this; } private int bitField0_; private java.lang.Object id_ = ""; /** *
     *Идентификатор операции.
     * 
* * string id = 1; * @return The id. */ public java.lang.String getId() { java.lang.Object ref = id_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); id_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Идентификатор операции.
     * 
* * string id = 1; * @return The bytes for id. */ public com.google.protobuf.ByteString getIdBytes() { java.lang.Object ref = id_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); id_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Идентификатор операции.
     * 
* * string id = 1; * @param value The id to set. * @return This builder for chaining. */ public Builder setId( java.lang.String value) { if (value == null) { throw new NullPointerException(); } id_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } /** *
     *Идентификатор операции.
     * 
* * string id = 1; * @return This builder for chaining. */ public Builder clearId() { id_ = getDefaultInstance().getId(); bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** *
     *Идентификатор операции.
     * 
* * string id = 1; * @param value The bytes for id to set. * @return This builder for chaining. */ public Builder setIdBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); id_ = value; bitField0_ |= 0x00000001; onChanged(); return this; } private java.lang.Object parentOperationId_ = ""; /** *
     *Идентификатор родительской операции.
     * 
* * string parent_operation_id = 2; * @return The parentOperationId. */ public java.lang.String getParentOperationId() { java.lang.Object ref = parentOperationId_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); parentOperationId_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Идентификатор родительской операции.
     * 
* * string parent_operation_id = 2; * @return The bytes for parentOperationId. */ public com.google.protobuf.ByteString getParentOperationIdBytes() { java.lang.Object ref = parentOperationId_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); parentOperationId_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Идентификатор родительской операции.
     * 
* * string parent_operation_id = 2; * @param value The parentOperationId to set. * @return This builder for chaining. */ public Builder setParentOperationId( java.lang.String value) { if (value == null) { throw new NullPointerException(); } parentOperationId_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } /** *
     *Идентификатор родительской операции.
     * 
* * string parent_operation_id = 2; * @return This builder for chaining. */ public Builder clearParentOperationId() { parentOperationId_ = getDefaultInstance().getParentOperationId(); bitField0_ = (bitField0_ & ~0x00000002); onChanged(); return this; } /** *
     *Идентификатор родительской операции.
     * 
* * string parent_operation_id = 2; * @param value The bytes for parentOperationId to set. * @return This builder for chaining. */ public Builder setParentOperationIdBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); parentOperationId_ = value; bitField0_ |= 0x00000002; onChanged(); return this; } private java.lang.Object currency_ = ""; /** *
     *Валюта операции.
     * 
* * string currency = 3; * @return The currency. */ public java.lang.String getCurrency() { java.lang.Object ref = currency_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); currency_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Валюта операции.
     * 
* * string currency = 3; * @return The bytes for currency. */ public com.google.protobuf.ByteString getCurrencyBytes() { java.lang.Object ref = currency_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); currency_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Валюта операции.
     * 
* * string currency = 3; * @param value The currency to set. * @return This builder for chaining. */ public Builder setCurrency( java.lang.String value) { if (value == null) { throw new NullPointerException(); } currency_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } /** *
     *Валюта операции.
     * 
* * string currency = 3; * @return This builder for chaining. */ public Builder clearCurrency() { currency_ = getDefaultInstance().getCurrency(); bitField0_ = (bitField0_ & ~0x00000004); onChanged(); return this; } /** *
     *Валюта операции.
     * 
* * string currency = 3; * @param value The bytes for currency to set. * @return This builder for chaining. */ public Builder setCurrencyBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); currency_ = value; bitField0_ |= 0x00000004; onChanged(); return this; } private ru.tinkoff.piapi.contract.v1.MoneyValue payment_; private com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder> paymentBuilder_; /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; * @return Whether the payment field is set. */ public boolean hasPayment() { return ((bitField0_ & 0x00000008) != 0); } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; * @return The payment. */ public ru.tinkoff.piapi.contract.v1.MoneyValue getPayment() { if (paymentBuilder_ == null) { return payment_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : payment_; } else { return paymentBuilder_.getMessage(); } } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public Builder setPayment(ru.tinkoff.piapi.contract.v1.MoneyValue value) { if (paymentBuilder_ == null) { if (value == null) { throw new NullPointerException(); } payment_ = value; } else { paymentBuilder_.setMessage(value); } bitField0_ |= 0x00000008; onChanged(); return this; } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public Builder setPayment( ru.tinkoff.piapi.contract.v1.MoneyValue.Builder builderForValue) { if (paymentBuilder_ == null) { payment_ = builderForValue.build(); } else { paymentBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000008; onChanged(); return this; } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public Builder mergePayment(ru.tinkoff.piapi.contract.v1.MoneyValue value) { if (paymentBuilder_ == null) { if (((bitField0_ & 0x00000008) != 0) && payment_ != null && payment_ != ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance()) { getPaymentBuilder().mergeFrom(value); } else { payment_ = value; } } else { paymentBuilder_.mergeFrom(value); } bitField0_ |= 0x00000008; onChanged(); return this; } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public Builder clearPayment() { bitField0_ = (bitField0_ & ~0x00000008); payment_ = null; if (paymentBuilder_ != null) { paymentBuilder_.dispose(); paymentBuilder_ = null; } onChanged(); return this; } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public ru.tinkoff.piapi.contract.v1.MoneyValue.Builder getPaymentBuilder() { bitField0_ |= 0x00000008; onChanged(); return getPaymentFieldBuilder().getBuilder(); } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ public ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder getPaymentOrBuilder() { if (paymentBuilder_ != null) { return paymentBuilder_.getMessageOrBuilder(); } else { return payment_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : payment_; } } /** *
     *Сумма операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue payment = 4; */ private com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder> getPaymentFieldBuilder() { if (paymentBuilder_ == null) { paymentBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder>( getPayment(), getParentForChildren(), isClean()); payment_ = null; } return paymentBuilder_; } private ru.tinkoff.piapi.contract.v1.MoneyValue price_; private com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder> priceBuilder_; /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; * @return Whether the price field is set. */ public boolean hasPrice() { return ((bitField0_ & 0x00000010) != 0); } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; * @return The price. */ public ru.tinkoff.piapi.contract.v1.MoneyValue getPrice() { if (priceBuilder_ == null) { return price_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : price_; } else { return priceBuilder_.getMessage(); } } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public Builder setPrice(ru.tinkoff.piapi.contract.v1.MoneyValue value) { if (priceBuilder_ == null) { if (value == null) { throw new NullPointerException(); } price_ = value; } else { priceBuilder_.setMessage(value); } bitField0_ |= 0x00000010; onChanged(); return this; } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public Builder setPrice( ru.tinkoff.piapi.contract.v1.MoneyValue.Builder builderForValue) { if (priceBuilder_ == null) { price_ = builderForValue.build(); } else { priceBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000010; onChanged(); return this; } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public Builder mergePrice(ru.tinkoff.piapi.contract.v1.MoneyValue value) { if (priceBuilder_ == null) { if (((bitField0_ & 0x00000010) != 0) && price_ != null && price_ != ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance()) { getPriceBuilder().mergeFrom(value); } else { price_ = value; } } else { priceBuilder_.mergeFrom(value); } bitField0_ |= 0x00000010; onChanged(); return this; } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public Builder clearPrice() { bitField0_ = (bitField0_ & ~0x00000010); price_ = null; if (priceBuilder_ != null) { priceBuilder_.dispose(); priceBuilder_ = null; } onChanged(); return this; } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public ru.tinkoff.piapi.contract.v1.MoneyValue.Builder getPriceBuilder() { bitField0_ |= 0x00000010; onChanged(); return getPriceFieldBuilder().getBuilder(); } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ public ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder getPriceOrBuilder() { if (priceBuilder_ != null) { return priceBuilder_.getMessageOrBuilder(); } else { return price_ == null ? ru.tinkoff.piapi.contract.v1.MoneyValue.getDefaultInstance() : price_; } } /** *
     *Цена операции за 1 инструмент. Для получения стоимости лота требуется умножить на лотность инструмента.
     * 
* * .tinkoff.public.invest.api.contract.v1.MoneyValue price = 5; */ private com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder> getPriceFieldBuilder() { if (priceBuilder_ == null) { priceBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< ru.tinkoff.piapi.contract.v1.MoneyValue, ru.tinkoff.piapi.contract.v1.MoneyValue.Builder, ru.tinkoff.piapi.contract.v1.MoneyValueOrBuilder>( getPrice(), getParentForChildren(), isClean()); price_ = null; } return priceBuilder_; } private int state_ = 0; /** *
     *Статус операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @return The enum numeric value on the wire for state. */ @java.lang.Override public int getStateValue() { return state_; } /** *
     *Статус операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @param value The enum numeric value on the wire for state to set. * @return This builder for chaining. */ public Builder setStateValue(int value) { state_ = value; bitField0_ |= 0x00000020; onChanged(); return this; } /** *
     *Статус операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @return The state. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationState getState() { ru.tinkoff.piapi.contract.v1.OperationState result = ru.tinkoff.piapi.contract.v1.OperationState.forNumber(state_); return result == null ? ru.tinkoff.piapi.contract.v1.OperationState.UNRECOGNIZED : result; } /** *
     *Статус операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @param value The state to set. * @return This builder for chaining. */ public Builder setState(ru.tinkoff.piapi.contract.v1.OperationState value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00000020; state_ = value.getNumber(); onChanged(); return this; } /** *
     *Статус операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationState state = 6; * @return This builder for chaining. */ public Builder clearState() { bitField0_ = (bitField0_ & ~0x00000020); state_ = 0; onChanged(); return this; } private long quantity_ ; /** *
     *Количество единиц инструмента.
     * 
* * int64 quantity = 7; * @return The quantity. */ @java.lang.Override public long getQuantity() { return quantity_; } /** *
     *Количество единиц инструмента.
     * 
* * int64 quantity = 7; * @param value The quantity to set. * @return This builder for chaining. */ public Builder setQuantity(long value) { quantity_ = value; bitField0_ |= 0x00000040; onChanged(); return this; } /** *
     *Количество единиц инструмента.
     * 
* * int64 quantity = 7; * @return This builder for chaining. */ public Builder clearQuantity() { bitField0_ = (bitField0_ & ~0x00000040); quantity_ = 0L; onChanged(); return this; } private long quantityRest_ ; /** *
     *Неисполненный остаток по сделке.
     * 
* * int64 quantity_rest = 8; * @return The quantityRest. */ @java.lang.Override public long getQuantityRest() { return quantityRest_; } /** *
     *Неисполненный остаток по сделке.
     * 
* * int64 quantity_rest = 8; * @param value The quantityRest to set. * @return This builder for chaining. */ public Builder setQuantityRest(long value) { quantityRest_ = value; bitField0_ |= 0x00000080; onChanged(); return this; } /** *
     *Неисполненный остаток по сделке.
     * 
* * int64 quantity_rest = 8; * @return This builder for chaining. */ public Builder clearQuantityRest() { bitField0_ = (bitField0_ & ~0x00000080); quantityRest_ = 0L; onChanged(); return this; } private java.lang.Object figi_ = ""; /** *
     *Figi-идентификатор инструмента, связанного с операцией.
     * 
* * string figi = 9; * @return The figi. */ public java.lang.String getFigi() { java.lang.Object ref = figi_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); figi_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Figi-идентификатор инструмента, связанного с операцией.
     * 
* * string figi = 9; * @return The bytes for figi. */ public com.google.protobuf.ByteString getFigiBytes() { java.lang.Object ref = figi_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); figi_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Figi-идентификатор инструмента, связанного с операцией.
     * 
* * string figi = 9; * @param value The figi to set. * @return This builder for chaining. */ public Builder setFigi( java.lang.String value) { if (value == null) { throw new NullPointerException(); } figi_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } /** *
     *Figi-идентификатор инструмента, связанного с операцией.
     * 
* * string figi = 9; * @return This builder for chaining. */ public Builder clearFigi() { figi_ = getDefaultInstance().getFigi(); bitField0_ = (bitField0_ & ~0x00000100); onChanged(); return this; } /** *
     *Figi-идентификатор инструмента, связанного с операцией.
     * 
* * string figi = 9; * @param value The bytes for figi to set. * @return This builder for chaining. */ public Builder setFigiBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); figi_ = value; bitField0_ |= 0x00000100; onChanged(); return this; } private java.lang.Object instrumentType_ = ""; /** *
     *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
     * 
* * string instrument_type = 10; * @return The instrumentType. */ public java.lang.String getInstrumentType() { java.lang.Object ref = instrumentType_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); instrumentType_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
     * 
* * string instrument_type = 10; * @return The bytes for instrumentType. */ public com.google.protobuf.ByteString getInstrumentTypeBytes() { java.lang.Object ref = instrumentType_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); instrumentType_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
     * 
* * string instrument_type = 10; * @param value The instrumentType to set. * @return This builder for chaining. */ public Builder setInstrumentType( java.lang.String value) { if (value == null) { throw new NullPointerException(); } instrumentType_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } /** *
     *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
     * 
* * string instrument_type = 10; * @return This builder for chaining. */ public Builder clearInstrumentType() { instrumentType_ = getDefaultInstance().getInstrumentType(); bitField0_ = (bitField0_ & ~0x00000200); onChanged(); return this; } /** *
     *Тип инструмента. Возможные значения: </br>**bond** — облигация; </br>**share** — акция; </br>**currency** — валюта; </br>**etf** — фонд; </br>**futures** — фьючерс.
     * 
* * string instrument_type = 10; * @param value The bytes for instrumentType to set. * @return This builder for chaining. */ public Builder setInstrumentTypeBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); instrumentType_ = value; bitField0_ |= 0x00000200; onChanged(); return this; } private com.google.protobuf.Timestamp date_; private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> dateBuilder_; /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; * @return Whether the date field is set. */ public boolean hasDate() { return ((bitField0_ & 0x00000400) != 0); } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; * @return The date. */ public com.google.protobuf.Timestamp getDate() { if (dateBuilder_ == null) { return date_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : date_; } else { return dateBuilder_.getMessage(); } } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public Builder setDate(com.google.protobuf.Timestamp value) { if (dateBuilder_ == null) { if (value == null) { throw new NullPointerException(); } date_ = value; } else { dateBuilder_.setMessage(value); } bitField0_ |= 0x00000400; onChanged(); return this; } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public Builder setDate( com.google.protobuf.Timestamp.Builder builderForValue) { if (dateBuilder_ == null) { date_ = builderForValue.build(); } else { dateBuilder_.setMessage(builderForValue.build()); } bitField0_ |= 0x00000400; onChanged(); return this; } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public Builder mergeDate(com.google.protobuf.Timestamp value) { if (dateBuilder_ == null) { if (((bitField0_ & 0x00000400) != 0) && date_ != null && date_ != com.google.protobuf.Timestamp.getDefaultInstance()) { getDateBuilder().mergeFrom(value); } else { date_ = value; } } else { dateBuilder_.mergeFrom(value); } bitField0_ |= 0x00000400; onChanged(); return this; } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public Builder clearDate() { bitField0_ = (bitField0_ & ~0x00000400); date_ = null; if (dateBuilder_ != null) { dateBuilder_.dispose(); dateBuilder_ = null; } onChanged(); return this; } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public com.google.protobuf.Timestamp.Builder getDateBuilder() { bitField0_ |= 0x00000400; onChanged(); return getDateFieldBuilder().getBuilder(); } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ public com.google.protobuf.TimestampOrBuilder getDateOrBuilder() { if (dateBuilder_ != null) { return dateBuilder_.getMessageOrBuilder(); } else { return date_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : date_; } } /** *
     *Дата и время операции в формате часовом поясе UTC.
     * 
* * .google.protobuf.Timestamp date = 11; */ private com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder> getDateFieldBuilder() { if (dateBuilder_ == null) { dateBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< com.google.protobuf.Timestamp, com.google.protobuf.Timestamp.Builder, com.google.protobuf.TimestampOrBuilder>( getDate(), getParentForChildren(), isClean()); date_ = null; } return dateBuilder_; } private java.lang.Object type_ = ""; /** *
     *Текстовое описание типа операции.
     * 
* * string type = 12; * @return The type. */ public java.lang.String getType() { java.lang.Object ref = type_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); type_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Текстовое описание типа операции.
     * 
* * string type = 12; * @return The bytes for type. */ public com.google.protobuf.ByteString getTypeBytes() { java.lang.Object ref = type_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); type_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Текстовое описание типа операции.
     * 
* * string type = 12; * @param value The type to set. * @return This builder for chaining. */ public Builder setType( java.lang.String value) { if (value == null) { throw new NullPointerException(); } type_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } /** *
     *Текстовое описание типа операции.
     * 
* * string type = 12; * @return This builder for chaining. */ public Builder clearType() { type_ = getDefaultInstance().getType(); bitField0_ = (bitField0_ & ~0x00000800); onChanged(); return this; } /** *
     *Текстовое описание типа операции.
     * 
* * string type = 12; * @param value The bytes for type to set. * @return This builder for chaining. */ public Builder setTypeBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); type_ = value; bitField0_ |= 0x00000800; onChanged(); return this; } private int operationType_ = 0; /** *
     *Тип операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @return The enum numeric value on the wire for operationType. */ @java.lang.Override public int getOperationTypeValue() { return operationType_; } /** *
     *Тип операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @param value The enum numeric value on the wire for operationType to set. * @return This builder for chaining. */ public Builder setOperationTypeValue(int value) { operationType_ = value; bitField0_ |= 0x00001000; onChanged(); return this; } /** *
     *Тип операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @return The operationType. */ @java.lang.Override public ru.tinkoff.piapi.contract.v1.OperationType getOperationType() { ru.tinkoff.piapi.contract.v1.OperationType result = ru.tinkoff.piapi.contract.v1.OperationType.forNumber(operationType_); return result == null ? ru.tinkoff.piapi.contract.v1.OperationType.UNRECOGNIZED : result; } /** *
     *Тип операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @param value The operationType to set. * @return This builder for chaining. */ public Builder setOperationType(ru.tinkoff.piapi.contract.v1.OperationType value) { if (value == null) { throw new NullPointerException(); } bitField0_ |= 0x00001000; operationType_ = value.getNumber(); onChanged(); return this; } /** *
     *Тип операции.
     * 
* * .tinkoff.public.invest.api.contract.v1.OperationType operation_type = 13; * @return This builder for chaining. */ public Builder clearOperationType() { bitField0_ = (bitField0_ & ~0x00001000); operationType_ = 0; onChanged(); return this; } private java.util.List trades_ = java.util.Collections.emptyList(); private void ensureTradesIsMutable() { if (!((bitField0_ & 0x00002000) != 0)) { trades_ = new java.util.ArrayList(trades_); bitField0_ |= 0x00002000; } } private com.google.protobuf.RepeatedFieldBuilderV3< ru.tinkoff.piapi.contract.v1.OperationTrade, ru.tinkoff.piapi.contract.v1.OperationTrade.Builder, ru.tinkoff.piapi.contract.v1.OperationTradeOrBuilder> tradesBuilder_; /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public java.util.List getTradesList() { if (tradesBuilder_ == null) { return java.util.Collections.unmodifiableList(trades_); } else { return tradesBuilder_.getMessageList(); } } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public int getTradesCount() { if (tradesBuilder_ == null) { return trades_.size(); } else { return tradesBuilder_.getCount(); } } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public ru.tinkoff.piapi.contract.v1.OperationTrade getTrades(int index) { if (tradesBuilder_ == null) { return trades_.get(index); } else { return tradesBuilder_.getMessage(index); } } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder setTrades( int index, ru.tinkoff.piapi.contract.v1.OperationTrade value) { if (tradesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTradesIsMutable(); trades_.set(index, value); onChanged(); } else { tradesBuilder_.setMessage(index, value); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder setTrades( int index, ru.tinkoff.piapi.contract.v1.OperationTrade.Builder builderForValue) { if (tradesBuilder_ == null) { ensureTradesIsMutable(); trades_.set(index, builderForValue.build()); onChanged(); } else { tradesBuilder_.setMessage(index, builderForValue.build()); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder addTrades(ru.tinkoff.piapi.contract.v1.OperationTrade value) { if (tradesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTradesIsMutable(); trades_.add(value); onChanged(); } else { tradesBuilder_.addMessage(value); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder addTrades( int index, ru.tinkoff.piapi.contract.v1.OperationTrade value) { if (tradesBuilder_ == null) { if (value == null) { throw new NullPointerException(); } ensureTradesIsMutable(); trades_.add(index, value); onChanged(); } else { tradesBuilder_.addMessage(index, value); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder addTrades( ru.tinkoff.piapi.contract.v1.OperationTrade.Builder builderForValue) { if (tradesBuilder_ == null) { ensureTradesIsMutable(); trades_.add(builderForValue.build()); onChanged(); } else { tradesBuilder_.addMessage(builderForValue.build()); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder addTrades( int index, ru.tinkoff.piapi.contract.v1.OperationTrade.Builder builderForValue) { if (tradesBuilder_ == null) { ensureTradesIsMutable(); trades_.add(index, builderForValue.build()); onChanged(); } else { tradesBuilder_.addMessage(index, builderForValue.build()); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder addAllTrades( java.lang.Iterable values) { if (tradesBuilder_ == null) { ensureTradesIsMutable(); com.google.protobuf.AbstractMessageLite.Builder.addAll( values, trades_); onChanged(); } else { tradesBuilder_.addAllMessages(values); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder clearTrades() { if (tradesBuilder_ == null) { trades_ = java.util.Collections.emptyList(); bitField0_ = (bitField0_ & ~0x00002000); onChanged(); } else { tradesBuilder_.clear(); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public Builder removeTrades(int index) { if (tradesBuilder_ == null) { ensureTradesIsMutable(); trades_.remove(index); onChanged(); } else { tradesBuilder_.remove(index); } return this; } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public ru.tinkoff.piapi.contract.v1.OperationTrade.Builder getTradesBuilder( int index) { return getTradesFieldBuilder().getBuilder(index); } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public ru.tinkoff.piapi.contract.v1.OperationTradeOrBuilder getTradesOrBuilder( int index) { if (tradesBuilder_ == null) { return trades_.get(index); } else { return tradesBuilder_.getMessageOrBuilder(index); } } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public java.util.List getTradesOrBuilderList() { if (tradesBuilder_ != null) { return tradesBuilder_.getMessageOrBuilderList(); } else { return java.util.Collections.unmodifiableList(trades_); } } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public ru.tinkoff.piapi.contract.v1.OperationTrade.Builder addTradesBuilder() { return getTradesFieldBuilder().addBuilder( ru.tinkoff.piapi.contract.v1.OperationTrade.getDefaultInstance()); } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public ru.tinkoff.piapi.contract.v1.OperationTrade.Builder addTradesBuilder( int index) { return getTradesFieldBuilder().addBuilder( index, ru.tinkoff.piapi.contract.v1.OperationTrade.getDefaultInstance()); } /** *
     *Массив сделок.
     * 
* * repeated .tinkoff.public.invest.api.contract.v1.OperationTrade trades = 14; */ public java.util.List getTradesBuilderList() { return getTradesFieldBuilder().getBuilderList(); } private com.google.protobuf.RepeatedFieldBuilderV3< ru.tinkoff.piapi.contract.v1.OperationTrade, ru.tinkoff.piapi.contract.v1.OperationTrade.Builder, ru.tinkoff.piapi.contract.v1.OperationTradeOrBuilder> getTradesFieldBuilder() { if (tradesBuilder_ == null) { tradesBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< ru.tinkoff.piapi.contract.v1.OperationTrade, ru.tinkoff.piapi.contract.v1.OperationTrade.Builder, ru.tinkoff.piapi.contract.v1.OperationTradeOrBuilder>( trades_, ((bitField0_ & 0x00002000) != 0), getParentForChildren(), isClean()); trades_ = null; } return tradesBuilder_; } private java.lang.Object assetUid_ = ""; /** *
     *Идентификатор актива
     * 
* * string asset_uid = 16; * @return The assetUid. */ public java.lang.String getAssetUid() { java.lang.Object ref = assetUid_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); assetUid_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Идентификатор актива
     * 
* * string asset_uid = 16; * @return The bytes for assetUid. */ public com.google.protobuf.ByteString getAssetUidBytes() { java.lang.Object ref = assetUid_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); assetUid_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Идентификатор актива
     * 
* * string asset_uid = 16; * @param value The assetUid to set. * @return This builder for chaining. */ public Builder setAssetUid( java.lang.String value) { if (value == null) { throw new NullPointerException(); } assetUid_ = value; bitField0_ |= 0x00004000; onChanged(); return this; } /** *
     *Идентификатор актива
     * 
* * string asset_uid = 16; * @return This builder for chaining. */ public Builder clearAssetUid() { assetUid_ = getDefaultInstance().getAssetUid(); bitField0_ = (bitField0_ & ~0x00004000); onChanged(); return this; } /** *
     *Идентификатор актива
     * 
* * string asset_uid = 16; * @param value The bytes for assetUid to set. * @return This builder for chaining. */ public Builder setAssetUidBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); assetUid_ = value; bitField0_ |= 0x00004000; onChanged(); return this; } private java.lang.Object positionUid_ = ""; /** *
     *position_uid-идентификатора инструмента.
     * 
* * string position_uid = 17; * @return The positionUid. */ public java.lang.String getPositionUid() { java.lang.Object ref = positionUid_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); positionUid_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *position_uid-идентификатора инструмента.
     * 
* * string position_uid = 17; * @return The bytes for positionUid. */ public com.google.protobuf.ByteString getPositionUidBytes() { java.lang.Object ref = positionUid_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); positionUid_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *position_uid-идентификатора инструмента.
     * 
* * string position_uid = 17; * @param value The positionUid to set. * @return This builder for chaining. */ public Builder setPositionUid( java.lang.String value) { if (value == null) { throw new NullPointerException(); } positionUid_ = value; bitField0_ |= 0x00008000; onChanged(); return this; } /** *
     *position_uid-идентификатора инструмента.
     * 
* * string position_uid = 17; * @return This builder for chaining. */ public Builder clearPositionUid() { positionUid_ = getDefaultInstance().getPositionUid(); bitField0_ = (bitField0_ & ~0x00008000); onChanged(); return this; } /** *
     *position_uid-идентификатора инструмента.
     * 
* * string position_uid = 17; * @param value The bytes for positionUid to set. * @return This builder for chaining. */ public Builder setPositionUidBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); positionUid_ = value; bitField0_ |= 0x00008000; onChanged(); return this; } private java.lang.Object instrumentUid_ = ""; /** *
     *Уникальный идентификатор инструмента.
     * 
* * string instrument_uid = 18; * @return The instrumentUid. */ public java.lang.String getInstrumentUid() { java.lang.Object ref = instrumentUid_; if (!(ref instanceof java.lang.String)) { com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; java.lang.String s = bs.toStringUtf8(); instrumentUid_ = s; return s; } else { return (java.lang.String) ref; } } /** *
     *Уникальный идентификатор инструмента.
     * 
* * string instrument_uid = 18; * @return The bytes for instrumentUid. */ public com.google.protobuf.ByteString getInstrumentUidBytes() { java.lang.Object ref = instrumentUid_; if (ref instanceof String) { com.google.protobuf.ByteString b = com.google.protobuf.ByteString.copyFromUtf8( (java.lang.String) ref); instrumentUid_ = b; return b; } else { return (com.google.protobuf.ByteString) ref; } } /** *
     *Уникальный идентификатор инструмента.
     * 
* * string instrument_uid = 18; * @param value The instrumentUid to set. * @return This builder for chaining. */ public Builder setInstrumentUid( java.lang.String value) { if (value == null) { throw new NullPointerException(); } instrumentUid_ = value; bitField0_ |= 0x00010000; onChanged(); return this; } /** *
     *Уникальный идентификатор инструмента.
     * 
* * string instrument_uid = 18; * @return This builder for chaining. */ public Builder clearInstrumentUid() { instrumentUid_ = getDefaultInstance().getInstrumentUid(); bitField0_ = (bitField0_ & ~0x00010000); onChanged(); return this; } /** *
     *Уникальный идентификатор инструмента.
     * 
* * string instrument_uid = 18; * @param value The bytes for instrumentUid to set. * @return This builder for chaining. */ public Builder setInstrumentUidBytes( com.google.protobuf.ByteString value) { if (value == null) { throw new NullPointerException(); } checkByteStringIsUtf8(value); instrumentUid_ = value; bitField0_ |= 0x00010000; 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:tinkoff.public.invest.api.contract.v1.Operation) } // @@protoc_insertion_point(class_scope:tinkoff.public.invest.api.contract.v1.Operation) private static final ru.tinkoff.piapi.contract.v1.Operation DEFAULT_INSTANCE; static { DEFAULT_INSTANCE = new ru.tinkoff.piapi.contract.v1.Operation(); } public static ru.tinkoff.piapi.contract.v1.Operation getDefaultInstance() { return DEFAULT_INSTANCE; } private static final com.google.protobuf.Parser PARSER = new com.google.protobuf.AbstractParser() { @java.lang.Override public Operation parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { Builder builder = newBuilder(); try { builder.mergeFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(builder.buildPartial()); } catch (com.google.protobuf.UninitializedMessageException e) { throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); } catch (java.io.IOException e) { throw new com.google.protobuf.InvalidProtocolBufferException(e) .setUnfinishedMessage(builder.buildPartial()); } return builder.buildPartial(); } }; public static com.google.protobuf.Parser parser() { return PARSER; } @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } @java.lang.Override public ru.tinkoff.piapi.contract.v1.Operation getDefaultInstanceForType() { return DEFAULT_INSTANCE; } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy