Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse Maven / Gradle / Ivy
// 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.PortfolioStreamResponse}
*/
public final class PortfolioStreamResponse extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:tinkoff.public.invest.api.contract.v1.PortfolioStreamResponse)
PortfolioStreamResponseOrBuilder {
private static final long serialVersionUID = 0L;
// Use PortfolioStreamResponse.newBuilder() to construct.
private PortfolioStreamResponse(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private PortfolioStreamResponse() {
}
@java.lang.Override
@SuppressWarnings({"unused"})
protected java.lang.Object newInstance(
UnusedPrivateParameter unused) {
return new PortfolioStreamResponse();
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_PortfolioStreamResponse_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_PortfolioStreamResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.class, ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.Builder.class);
}
private int payloadCase_ = 0;
@SuppressWarnings("serial")
private java.lang.Object payload_;
public enum PayloadCase
implements com.google.protobuf.Internal.EnumLite,
com.google.protobuf.AbstractMessage.InternalOneOfEnum {
SUBSCRIPTIONS(1),
PORTFOLIO(2),
PING(3),
PAYLOAD_NOT_SET(0);
private final int value;
private PayloadCase(int value) {
this.value = value;
}
/**
* @param value The number of the enum to look for.
* @return The enum associated with the given number.
* @deprecated Use {@link #forNumber(int)} instead.
*/
@java.lang.Deprecated
public static PayloadCase valueOf(int value) {
return forNumber(value);
}
public static PayloadCase forNumber(int value) {
switch (value) {
case 1: return SUBSCRIPTIONS;
case 2: return PORTFOLIO;
case 3: return PING;
case 0: return PAYLOAD_NOT_SET;
default: return null;
}
}
public int getNumber() {
return this.value;
}
};
public PayloadCase
getPayloadCase() {
return PayloadCase.forNumber(
payloadCase_);
}
public static final int SUBSCRIPTIONS_FIELD_NUMBER = 1;
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
* @return Whether the subscriptions field is set.
*/
@java.lang.Override
public boolean hasSubscriptions() {
return payloadCase_ == 1;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
* @return The subscriptions.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult getSubscriptions() {
if (payloadCase_ == 1) {
return (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResultOrBuilder getSubscriptionsOrBuilder() {
if (payloadCase_ == 1) {
return (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
}
public static final int PORTFOLIO_FIELD_NUMBER = 2;
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
* @return Whether the portfolio field is set.
*/
@java.lang.Override
public boolean hasPortfolio() {
return payloadCase_ == 2;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
* @return The portfolio.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioResponse getPortfolio() {
if (payloadCase_ == 2) {
return (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioResponseOrBuilder getPortfolioOrBuilder() {
if (payloadCase_ == 2) {
return (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
}
public static final int PING_FIELD_NUMBER = 3;
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
* @return Whether the ping field is set.
*/
@java.lang.Override
public boolean hasPing() {
return payloadCase_ == 3;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
* @return The ping.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.Ping getPing() {
if (payloadCase_ == 3) {
return (ru.tinkoff.piapi.contract.v1.Ping) payload_;
}
return ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PingOrBuilder getPingOrBuilder() {
if (payloadCase_ == 3) {
return (ru.tinkoff.piapi.contract.v1.Ping) payload_;
}
return ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
}
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 (payloadCase_ == 1) {
output.writeMessage(1, (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_);
}
if (payloadCase_ == 2) {
output.writeMessage(2, (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_);
}
if (payloadCase_ == 3) {
output.writeMessage(3, (ru.tinkoff.piapi.contract.v1.Ping) payload_);
}
getUnknownFields().writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (payloadCase_ == 1) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_);
}
if (payloadCase_ == 2) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_);
}
if (payloadCase_ == 3) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, (ru.tinkoff.piapi.contract.v1.Ping) payload_);
}
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.PortfolioStreamResponse)) {
return super.equals(obj);
}
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse other = (ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse) obj;
if (!getPayloadCase().equals(other.getPayloadCase())) return false;
switch (payloadCase_) {
case 1:
if (!getSubscriptions()
.equals(other.getSubscriptions())) return false;
break;
case 2:
if (!getPortfolio()
.equals(other.getPortfolio())) return false;
break;
case 3:
if (!getPing()
.equals(other.getPing())) return false;
break;
case 0:
default:
}
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();
switch (payloadCase_) {
case 1:
hash = (37 * hash) + SUBSCRIPTIONS_FIELD_NUMBER;
hash = (53 * hash) + getSubscriptions().hashCode();
break;
case 2:
hash = (37 * hash) + PORTFOLIO_FIELD_NUMBER;
hash = (53 * hash) + getPortfolio().hashCode();
break;
case 3:
hash = (37 * hash) + PING_FIELD_NUMBER;
hash = (53 * hash) + getPing().hashCode();
break;
case 0:
default:
}
hash = (29 * hash) + getUnknownFields().hashCode();
memoizedHashCode = hash;
return hash;
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse 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.PortfolioStreamResponse parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse 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.PortfolioStreamResponse parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse 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.PortfolioStreamResponse parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse 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.PortfolioStreamResponse parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse 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.PortfolioStreamResponse 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.PortfolioStreamResponse 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.PortfolioStreamResponse 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.PortfolioStreamResponse}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:tinkoff.public.invest.api.contract.v1.PortfolioStreamResponse)
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponseOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return ru.tinkoff.piapi.contract.v1.Operations.internal_static_tinkoff_public_invest_api_contract_v1_PortfolioStreamResponse_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_PortfolioStreamResponse_fieldAccessorTable
.ensureFieldAccessorsInitialized(
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.class, ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.Builder.class);
}
// Construct using ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.newBuilder()
private Builder() {
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
}
@java.lang.Override
public Builder clear() {
super.clear();
bitField0_ = 0;
if (subscriptionsBuilder_ != null) {
subscriptionsBuilder_.clear();
}
if (portfolioBuilder_ != null) {
portfolioBuilder_.clear();
}
if (pingBuilder_ != null) {
pingBuilder_.clear();
}
payloadCase_ = 0;
payload_ = null;
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_PortfolioStreamResponse_descriptor;
}
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse getDefaultInstanceForType() {
return ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.getDefaultInstance();
}
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse build() {
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse buildPartial() {
ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse result = new ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse(this);
if (bitField0_ != 0) { buildPartial0(result); }
buildPartialOneofs(result);
onBuilt();
return result;
}
private void buildPartial0(ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse result) {
int from_bitField0_ = bitField0_;
}
private void buildPartialOneofs(ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse result) {
result.payloadCase_ = payloadCase_;
result.payload_ = this.payload_;
if (payloadCase_ == 1 &&
subscriptionsBuilder_ != null) {
result.payload_ = subscriptionsBuilder_.build();
}
if (payloadCase_ == 2 &&
portfolioBuilder_ != null) {
result.payload_ = portfolioBuilder_.build();
}
if (payloadCase_ == 3 &&
pingBuilder_ != null) {
result.payload_ = pingBuilder_.build();
}
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse) {
return mergeFrom((ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse other) {
if (other == ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse.getDefaultInstance()) return this;
switch (other.getPayloadCase()) {
case SUBSCRIPTIONS: {
mergeSubscriptions(other.getSubscriptions());
break;
}
case PORTFOLIO: {
mergePortfolio(other.getPortfolio());
break;
}
case PING: {
mergePing(other.getPing());
break;
}
case PAYLOAD_NOT_SET: {
break;
}
}
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: {
input.readMessage(
getSubscriptionsFieldBuilder().getBuilder(),
extensionRegistry);
payloadCase_ = 1;
break;
} // case 10
case 18: {
input.readMessage(
getPortfolioFieldBuilder().getBuilder(),
extensionRegistry);
payloadCase_ = 2;
break;
} // case 18
case 26: {
input.readMessage(
getPingFieldBuilder().getBuilder(),
extensionRegistry);
payloadCase_ = 3;
break;
} // case 26
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 payloadCase_ = 0;
private java.lang.Object payload_;
public PayloadCase
getPayloadCase() {
return PayloadCase.forNumber(
payloadCase_);
}
public Builder clearPayload() {
payloadCase_ = 0;
payload_ = null;
onChanged();
return this;
}
private int bitField0_;
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.Builder, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResultOrBuilder> subscriptionsBuilder_;
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
* @return Whether the subscriptions field is set.
*/
@java.lang.Override
public boolean hasSubscriptions() {
return payloadCase_ == 1;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
* @return The subscriptions.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult getSubscriptions() {
if (subscriptionsBuilder_ == null) {
if (payloadCase_ == 1) {
return (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
} else {
if (payloadCase_ == 1) {
return subscriptionsBuilder_.getMessage();
}
return ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
}
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
public Builder setSubscriptions(ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult value) {
if (subscriptionsBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
payload_ = value;
onChanged();
} else {
subscriptionsBuilder_.setMessage(value);
}
payloadCase_ = 1;
return this;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
public Builder setSubscriptions(
ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.Builder builderForValue) {
if (subscriptionsBuilder_ == null) {
payload_ = builderForValue.build();
onChanged();
} else {
subscriptionsBuilder_.setMessage(builderForValue.build());
}
payloadCase_ = 1;
return this;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
public Builder mergeSubscriptions(ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult value) {
if (subscriptionsBuilder_ == null) {
if (payloadCase_ == 1 &&
payload_ != ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance()) {
payload_ = ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.newBuilder((ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_)
.mergeFrom(value).buildPartial();
} else {
payload_ = value;
}
onChanged();
} else {
if (payloadCase_ == 1) {
subscriptionsBuilder_.mergeFrom(value);
} else {
subscriptionsBuilder_.setMessage(value);
}
}
payloadCase_ = 1;
return this;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
public Builder clearSubscriptions() {
if (subscriptionsBuilder_ == null) {
if (payloadCase_ == 1) {
payloadCase_ = 0;
payload_ = null;
onChanged();
}
} else {
if (payloadCase_ == 1) {
payloadCase_ = 0;
payload_ = null;
}
subscriptionsBuilder_.clear();
}
return this;
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
public ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.Builder getSubscriptionsBuilder() {
return getSubscriptionsFieldBuilder().getBuilder();
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResultOrBuilder getSubscriptionsOrBuilder() {
if ((payloadCase_ == 1) && (subscriptionsBuilder_ != null)) {
return subscriptionsBuilder_.getMessageOrBuilder();
} else {
if (payloadCase_ == 1) {
return (ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
}
}
/**
*
*Объект результата подписки.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioSubscriptionResult subscriptions = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.Builder, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResultOrBuilder>
getSubscriptionsFieldBuilder() {
if (subscriptionsBuilder_ == null) {
if (!(payloadCase_ == 1)) {
payload_ = ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.getDefaultInstance();
}
subscriptionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult.Builder, ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResultOrBuilder>(
(ru.tinkoff.piapi.contract.v1.PortfolioSubscriptionResult) payload_,
getParentForChildren(),
isClean());
payload_ = null;
}
payloadCase_ = 1;
onChanged();
return subscriptionsBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioResponse, ru.tinkoff.piapi.contract.v1.PortfolioResponse.Builder, ru.tinkoff.piapi.contract.v1.PortfolioResponseOrBuilder> portfolioBuilder_;
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
* @return Whether the portfolio field is set.
*/
@java.lang.Override
public boolean hasPortfolio() {
return payloadCase_ == 2;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
* @return The portfolio.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioResponse getPortfolio() {
if (portfolioBuilder_ == null) {
if (payloadCase_ == 2) {
return (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
} else {
if (payloadCase_ == 2) {
return portfolioBuilder_.getMessage();
}
return ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
}
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
public Builder setPortfolio(ru.tinkoff.piapi.contract.v1.PortfolioResponse value) {
if (portfolioBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
payload_ = value;
onChanged();
} else {
portfolioBuilder_.setMessage(value);
}
payloadCase_ = 2;
return this;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
public Builder setPortfolio(
ru.tinkoff.piapi.contract.v1.PortfolioResponse.Builder builderForValue) {
if (portfolioBuilder_ == null) {
payload_ = builderForValue.build();
onChanged();
} else {
portfolioBuilder_.setMessage(builderForValue.build());
}
payloadCase_ = 2;
return this;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
public Builder mergePortfolio(ru.tinkoff.piapi.contract.v1.PortfolioResponse value) {
if (portfolioBuilder_ == null) {
if (payloadCase_ == 2 &&
payload_ != ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance()) {
payload_ = ru.tinkoff.piapi.contract.v1.PortfolioResponse.newBuilder((ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_)
.mergeFrom(value).buildPartial();
} else {
payload_ = value;
}
onChanged();
} else {
if (payloadCase_ == 2) {
portfolioBuilder_.mergeFrom(value);
} else {
portfolioBuilder_.setMessage(value);
}
}
payloadCase_ = 2;
return this;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
public Builder clearPortfolio() {
if (portfolioBuilder_ == null) {
if (payloadCase_ == 2) {
payloadCase_ = 0;
payload_ = null;
onChanged();
}
} else {
if (payloadCase_ == 2) {
payloadCase_ = 0;
payload_ = null;
}
portfolioBuilder_.clear();
}
return this;
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
public ru.tinkoff.piapi.contract.v1.PortfolioResponse.Builder getPortfolioBuilder() {
return getPortfolioFieldBuilder().getBuilder();
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PortfolioResponseOrBuilder getPortfolioOrBuilder() {
if ((payloadCase_ == 2) && (portfolioBuilder_ != null)) {
return portfolioBuilder_.getMessageOrBuilder();
} else {
if (payloadCase_ == 2) {
return (ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_;
}
return ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
}
}
/**
*
*Объект стриминга портфеля.
*
*
* .tinkoff.public.invest.api.contract.v1.PortfolioResponse portfolio = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioResponse, ru.tinkoff.piapi.contract.v1.PortfolioResponse.Builder, ru.tinkoff.piapi.contract.v1.PortfolioResponseOrBuilder>
getPortfolioFieldBuilder() {
if (portfolioBuilder_ == null) {
if (!(payloadCase_ == 2)) {
payload_ = ru.tinkoff.piapi.contract.v1.PortfolioResponse.getDefaultInstance();
}
portfolioBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.PortfolioResponse, ru.tinkoff.piapi.contract.v1.PortfolioResponse.Builder, ru.tinkoff.piapi.contract.v1.PortfolioResponseOrBuilder>(
(ru.tinkoff.piapi.contract.v1.PortfolioResponse) payload_,
getParentForChildren(),
isClean());
payload_ = null;
}
payloadCase_ = 2;
onChanged();
return portfolioBuilder_;
}
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.Ping, ru.tinkoff.piapi.contract.v1.Ping.Builder, ru.tinkoff.piapi.contract.v1.PingOrBuilder> pingBuilder_;
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
* @return Whether the ping field is set.
*/
@java.lang.Override
public boolean hasPing() {
return payloadCase_ == 3;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
* @return The ping.
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.Ping getPing() {
if (pingBuilder_ == null) {
if (payloadCase_ == 3) {
return (ru.tinkoff.piapi.contract.v1.Ping) payload_;
}
return ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
} else {
if (payloadCase_ == 3) {
return pingBuilder_.getMessage();
}
return ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
}
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
public Builder setPing(ru.tinkoff.piapi.contract.v1.Ping value) {
if (pingBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
payload_ = value;
onChanged();
} else {
pingBuilder_.setMessage(value);
}
payloadCase_ = 3;
return this;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
public Builder setPing(
ru.tinkoff.piapi.contract.v1.Ping.Builder builderForValue) {
if (pingBuilder_ == null) {
payload_ = builderForValue.build();
onChanged();
} else {
pingBuilder_.setMessage(builderForValue.build());
}
payloadCase_ = 3;
return this;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
public Builder mergePing(ru.tinkoff.piapi.contract.v1.Ping value) {
if (pingBuilder_ == null) {
if (payloadCase_ == 3 &&
payload_ != ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance()) {
payload_ = ru.tinkoff.piapi.contract.v1.Ping.newBuilder((ru.tinkoff.piapi.contract.v1.Ping) payload_)
.mergeFrom(value).buildPartial();
} else {
payload_ = value;
}
onChanged();
} else {
if (payloadCase_ == 3) {
pingBuilder_.mergeFrom(value);
} else {
pingBuilder_.setMessage(value);
}
}
payloadCase_ = 3;
return this;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
public Builder clearPing() {
if (pingBuilder_ == null) {
if (payloadCase_ == 3) {
payloadCase_ = 0;
payload_ = null;
onChanged();
}
} else {
if (payloadCase_ == 3) {
payloadCase_ = 0;
payload_ = null;
}
pingBuilder_.clear();
}
return this;
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
public ru.tinkoff.piapi.contract.v1.Ping.Builder getPingBuilder() {
return getPingFieldBuilder().getBuilder();
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
@java.lang.Override
public ru.tinkoff.piapi.contract.v1.PingOrBuilder getPingOrBuilder() {
if ((payloadCase_ == 3) && (pingBuilder_ != null)) {
return pingBuilder_.getMessageOrBuilder();
} else {
if (payloadCase_ == 3) {
return (ru.tinkoff.piapi.contract.v1.Ping) payload_;
}
return ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
}
}
/**
*
*Проверка активности стрима.
*
*
* .tinkoff.public.invest.api.contract.v1.Ping ping = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.Ping, ru.tinkoff.piapi.contract.v1.Ping.Builder, ru.tinkoff.piapi.contract.v1.PingOrBuilder>
getPingFieldBuilder() {
if (pingBuilder_ == null) {
if (!(payloadCase_ == 3)) {
payload_ = ru.tinkoff.piapi.contract.v1.Ping.getDefaultInstance();
}
pingBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
ru.tinkoff.piapi.contract.v1.Ping, ru.tinkoff.piapi.contract.v1.Ping.Builder, ru.tinkoff.piapi.contract.v1.PingOrBuilder>(
(ru.tinkoff.piapi.contract.v1.Ping) payload_,
getParentForChildren(),
isClean());
payload_ = null;
}
payloadCase_ = 3;
onChanged();
return pingBuilder_;
}
@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.PortfolioStreamResponse)
}
// @@protoc_insertion_point(class_scope:tinkoff.public.invest.api.contract.v1.PortfolioStreamResponse)
private static final ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse();
}
public static ru.tinkoff.piapi.contract.v1.PortfolioStreamResponse getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public PortfolioStreamResponse 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.PortfolioStreamResponse getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}