http://git-wip-us.apache.org/repos/asf/incubator-myriad/blob/b5b468b9/myriad-commons/src/main/java/org/apache/mesos/v1/executor/Protos.java ---------------------------------------------------------------------- diff --git a/myriad-commons/src/main/java/org/apache/mesos/v1/executor/Protos.java b/myriad-commons/src/main/java/org/apache/mesos/v1/executor/Protos.java new file mode 100644 index 0000000..c83d2a4 --- /dev/null +++ b/myriad-commons/src/main/java/org/apache/mesos/v1/executor/Protos.java @@ -0,0 +1,10785 @@ +// Generated by the protocol buffer compiler. DO NOT EDIT! +// source: mesos/v1/executor.proto + +package org.apache.mesos.v1.executor; + +public final class Protos { + private Protos() {} + public static void registerAllExtensions( + com.google.protobuf.ExtensionRegistry registry) { + } + public interface EventOrBuilder + extends com.google.protobuf.MessageOrBuilder { + + // optional .mesos.v1.executor.Event.Type type = 1; + /** + * <code>optional .mesos.v1.executor.Event.Type type = 1;</code> + * + * <pre> + * Type of the event, indicates which optional field below should be + * present if that type has a nested message definition. + * Enum fields should be optional, see: MESOS-4997. + * </pre> + */ + boolean hasType(); + /** + * <code>optional .mesos.v1.executor.Event.Type type = 1;</code> + * + * <pre> + * Type of the event, indicates which optional field below should be + * present if that type has a nested message definition. + * Enum fields should be optional, see: MESOS-4997. + * </pre> + */ + org.apache.mesos.v1.executor.Protos.Event.Type getType(); + + // optional .mesos.v1.executor.Event.Subscribed subscribed = 2; + /** + * <code>optional .mesos.v1.executor.Event.Subscribed subscribed = 2;</code> + */ + boolean hasSubscribed(); + /** + * <code>optional .mesos.v1.executor.Event.Subscribed subscribed = 2;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Subscribed getSubscribed(); + /** + * <code>optional .mesos.v1.executor.Event.Subscribed subscribed = 2;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.SubscribedOrBuilder getSubscribedOrBuilder(); + + // optional .mesos.v1.executor.Event.Acknowledged acknowledged = 3; + /** + * <code>optional .mesos.v1.executor.Event.Acknowledged acknowledged = 3;</code> + */ + boolean hasAcknowledged(); + /** + * <code>optional .mesos.v1.executor.Event.Acknowledged acknowledged = 3;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Acknowledged getAcknowledged(); + /** + * <code>optional .mesos.v1.executor.Event.Acknowledged acknowledged = 3;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.AcknowledgedOrBuilder getAcknowledgedOrBuilder(); + + // optional .mesos.v1.executor.Event.Launch launch = 4; + /** + * <code>optional .mesos.v1.executor.Event.Launch launch = 4;</code> + */ + boolean hasLaunch(); + /** + * <code>optional .mesos.v1.executor.Event.Launch launch = 4;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Launch getLaunch(); + /** + * <code>optional .mesos.v1.executor.Event.Launch launch = 4;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.LaunchOrBuilder getLaunchOrBuilder(); + + // optional .mesos.v1.executor.Event.LaunchGroup launch_group = 8; + /** + * <code>optional .mesos.v1.executor.Event.LaunchGroup launch_group = 8;</code> + */ + boolean hasLaunchGroup(); + /** + * <code>optional .mesos.v1.executor.Event.LaunchGroup launch_group = 8;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.LaunchGroup getLaunchGroup(); + /** + * <code>optional .mesos.v1.executor.Event.LaunchGroup launch_group = 8;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.LaunchGroupOrBuilder getLaunchGroupOrBuilder(); + + // optional .mesos.v1.executor.Event.Kill kill = 5; + /** + * <code>optional .mesos.v1.executor.Event.Kill kill = 5;</code> + */ + boolean hasKill(); + /** + * <code>optional .mesos.v1.executor.Event.Kill kill = 5;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Kill getKill(); + /** + * <code>optional .mesos.v1.executor.Event.Kill kill = 5;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.KillOrBuilder getKillOrBuilder(); + + // optional .mesos.v1.executor.Event.Message message = 6; + /** + * <code>optional .mesos.v1.executor.Event.Message message = 6;</code> + */ + boolean hasMessage(); + /** + * <code>optional .mesos.v1.executor.Event.Message message = 6;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Message getMessage(); + /** + * <code>optional .mesos.v1.executor.Event.Message message = 6;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.MessageOrBuilder getMessageOrBuilder(); + + // optional .mesos.v1.executor.Event.Error error = 7; + /** + * <code>optional .mesos.v1.executor.Event.Error error = 7;</code> + */ + boolean hasError(); + /** + * <code>optional .mesos.v1.executor.Event.Error error = 7;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.Error getError(); + /** + * <code>optional .mesos.v1.executor.Event.Error error = 7;</code> + */ + org.apache.mesos.v1.executor.Protos.Event.ErrorOrBuilder getErrorOrBuilder(); + } + /** + * Protobuf type {@code mesos.v1.executor.Event} + * + * <pre> + ** + * Executor event API. + * + * An event is described using the standard protocol buffer "union" + * trick, see https://developers.google.com/protocol-buffers/docs/techniques#union. + * </pre> + */ + public static final class Event extends + com.google.protobuf.GeneratedMessage + implements EventOrBuilder { + // Use Event.newBuilder() to construct. + private Event(com.google.protobuf.GeneratedMessage.Builder<?> builder) { + super(builder); + this.unknownFields = builder.getUnknownFields(); + } + private Event(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } + + private static final Event defaultInstance; + public static Event getDefaultInstance() { + return defaultInstance; + } + + public Event getDefaultInstanceForType() { + return defaultInstance; + } + + private final com.google.protobuf.UnknownFieldSet unknownFields; + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private Event( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + initFields(); + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: { + if (!parseUnknownField(input, unknownFields, + extensionRegistry, tag)) { + done = true; + } + break; + } + case 8: { + int rawValue = input.readEnum(); + org.apache.mesos.v1.executor.Protos.Event.Type value = org.apache.mesos.v1.executor.Protos.Event.Type.valueOf(rawValue); + if (value == null) { + unknownFields.mergeVarintField(1, rawValue); + } else { + bitField0_ |= 0x00000001; + type_ = value; + } + break; + } + case 18: { + org.apache.mesos.v1.executor.Protos.Event.Subscribed.Builder subBuilder = null; + if (((bitField0_ & 0x00000002) == 0x00000002)) { + subBuilder = subscribed_.toBuilder(); + } + subscribed_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Subscribed.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(subscribed_); + subscribed_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000002; + break; + } + case 26: { + org.apache.mesos.v1.executor.Protos.Event.Acknowledged.Builder subBuilder = null; + if (((bitField0_ & 0x00000004) == 0x00000004)) { + subBuilder = acknowledged_.toBuilder(); + } + acknowledged_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Acknowledged.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(acknowledged_); + acknowledged_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000004; + break; + } + case 34: { + org.apache.mesos.v1.executor.Protos.Event.Launch.Builder subBuilder = null; + if (((bitField0_ & 0x00000008) == 0x00000008)) { + subBuilder = launch_.toBuilder(); + } + launch_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Launch.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(launch_); + launch_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000008; + break; + } + case 42: { + org.apache.mesos.v1.executor.Protos.Event.Kill.Builder subBuilder = null; + if (((bitField0_ & 0x00000020) == 0x00000020)) { + subBuilder = kill_.toBuilder(); + } + kill_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Kill.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(kill_); + kill_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000020; + break; + } + case 50: { + org.apache.mesos.v1.executor.Protos.Event.Message.Builder subBuilder = null; + if (((bitField0_ & 0x00000040) == 0x00000040)) { + subBuilder = message_.toBuilder(); + } + message_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Message.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(message_); + message_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000040; + break; + } + case 58: { + org.apache.mesos.v1.executor.Protos.Event.Error.Builder subBuilder = null; + if (((bitField0_ & 0x00000080) == 0x00000080)) { + subBuilder = error_.toBuilder(); + } + error_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.Error.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(error_); + error_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000080; + break; + } + case 66: { + org.apache.mesos.v1.executor.Protos.Event.LaunchGroup.Builder subBuilder = null; + if (((bitField0_ & 0x00000010) == 0x00000010)) { + subBuilder = launchGroup_.toBuilder(); + } + launchGroup_ = input.readMessage(org.apache.mesos.v1.executor.Protos.Event.LaunchGroup.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(launchGroup_); + launchGroup_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000010; + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e.getMessage()).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_descriptor; + } + + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_fieldAccessorTable + .ensureFieldAccessorsInitialized( + org.apache.mesos.v1.executor.Protos.Event.class, org.apache.mesos.v1.executor.Protos.Event.Builder.class); + } + + public static com.google.protobuf.Parser<Event> PARSER = + new com.google.protobuf.AbstractParser<Event>() { + public Event parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Event(input, extensionRegistry); + } + }; + + @java.lang.Override + public com.google.protobuf.Parser<Event> getParserForType() { + return PARSER; + } + + /** + * Protobuf enum {@code mesos.v1.executor.Event.Type} + * + * <pre> + * Possible event types, followed by message definitions if + * applicable. + * </pre> + */ + public enum Type + implements com.google.protobuf.ProtocolMessageEnum { + /** + * <code>UNKNOWN = 0;</code> + * + * <pre> + * This must be the first enum value in this list, to + * ensure that if 'type' is not set, the default value + * is UNKNOWN. This enables enum values to be added + * in a backwards-compatible way. See: MESOS-4997. + * </pre> + */ + UNKNOWN(0, 0), + /** + * <code>SUBSCRIBED = 1;</code> + * + * <pre> + * See 'Subscribed' below. + * </pre> + */ + SUBSCRIBED(1, 1), + /** + * <code>LAUNCH = 2;</code> + * + * <pre> + * See 'Launch' below. + * </pre> + */ + LAUNCH(2, 2), + /** + * <code>LAUNCH_GROUP = 8;</code> + * + * <pre> + * See 'LaunchGroup' below. + * </pre> + */ + LAUNCH_GROUP(3, 8), + /** + * <code>KILL = 3;</code> + * + * <pre> + * See 'Kill' below. + * </pre> + */ + KILL(4, 3), + /** + * <code>ACKNOWLEDGED = 4;</code> + * + * <pre> + * See 'Acknowledged' below. + * </pre> + */ + ACKNOWLEDGED(5, 4), + /** + * <code>MESSAGE = 5;</code> + * + * <pre> + * See 'Message' below. + * </pre> + */ + MESSAGE(6, 5), + /** + * <code>ERROR = 6;</code> + * + * <pre> + * See 'Error' below. + * </pre> + */ + ERROR(7, 6), + /** + * <code>SHUTDOWN = 7;</code> + * + * <pre> + * Received when the agent asks the executor to shutdown/kill itself. + * The executor is then required to kill all its active tasks, send + * `TASK_KILLED` status updates and gracefully exit. The executor + * should terminate within a `MESOS_EXECUTOR_SHUTDOWN_GRACE_PERIOD` + * (an environment variable set by the agent upon executor startup); + * it can be configured via `ExecutorInfo.shutdown_grace_period`. If + * the executor fails to do so, the agent will forcefully destroy the + * container where the executor is running. The agent would then send + * `TASK_LOST` updates for any remaining active tasks of this executor. + * + * NOTE: The executor must not assume that it will always be allotted + * the full grace period, as the agent may decide to allot a shorter + * period and failures / forcible terminations may occur. + * + * TODO(alexr): Consider adding a duration field into the `Shutdown` + * message so that the agent can communicate when a shorter period + * has been allotted. + * </pre> + */ + SHUTDOWN(8, 7), + ; + + /** + * <code>UNKNOWN = 0;</code> + * + * <pre> + * This must be the first enum value in this list, to + * ensure that if 'type' is not set, the default value + * is UNKNOWN. This enables enum values to be added + * in a backwards-compatible way. See: MESOS-4997. + * </pre> + */ + public static final int UNKNOWN_VALUE = 0; + /** + * <code>SUBSCRIBED = 1;</code> + * + * <pre> + * See 'Subscribed' below. + * </pre> + */ + public static final int SUBSCRIBED_VALUE = 1; + /** + * <code>LAUNCH = 2;</code> + * + * <pre> + * See 'Launch' below. + * </pre> + */ + public static final int LAUNCH_VALUE = 2; + /** + * <code>LAUNCH_GROUP = 8;</code> + * + * <pre> + * See 'LaunchGroup' below. + * </pre> + */ + public static final int LAUNCH_GROUP_VALUE = 8; + /** + * <code>KILL = 3;</code> + * + * <pre> + * See 'Kill' below. + * </pre> + */ + public static final int KILL_VALUE = 3; + /** + * <code>ACKNOWLEDGED = 4;</code> + * + * <pre> + * See 'Acknowledged' below. + * </pre> + */ + public static final int ACKNOWLEDGED_VALUE = 4; + /** + * <code>MESSAGE = 5;</code> + * + * <pre> + * See 'Message' below. + * </pre> + */ + public static final int MESSAGE_VALUE = 5; + /** + * <code>ERROR = 6;</code> + * + * <pre> + * See 'Error' below. + * </pre> + */ + public static final int ERROR_VALUE = 6; + /** + * <code>SHUTDOWN = 7;</code> + * + * <pre> + * Received when the agent asks the executor to shutdown/kill itself. + * The executor is then required to kill all its active tasks, send + * `TASK_KILLED` status updates and gracefully exit. The executor + * should terminate within a `MESOS_EXECUTOR_SHUTDOWN_GRACE_PERIOD` + * (an environment variable set by the agent upon executor startup); + * it can be configured via `ExecutorInfo.shutdown_grace_period`. If + * the executor fails to do so, the agent will forcefully destroy the + * container where the executor is running. The agent would then send + * `TASK_LOST` updates for any remaining active tasks of this executor. + * + * NOTE: The executor must not assume that it will always be allotted + * the full grace period, as the agent may decide to allot a shorter + * period and failures / forcible terminations may occur. + * + * TODO(alexr): Consider adding a duration field into the `Shutdown` + * message so that the agent can communicate when a shorter period + * has been allotted. + * </pre> + */ + public static final int SHUTDOWN_VALUE = 7; + + + public final int getNumber() { return value; } + + public static Type valueOf(int value) { + switch (value) { + case 0: return UNKNOWN; + case 1: return SUBSCRIBED; + case 2: return LAUNCH; + case 8: return LAUNCH_GROUP; + case 3: return KILL; + case 4: return ACKNOWLEDGED; + case 5: return MESSAGE; + case 6: return ERROR; + case 7: return SHUTDOWN; + default: return null; + } + } + + public static com.google.protobuf.Internal.EnumLiteMap<Type> + internalGetValueMap() { + return internalValueMap; + } + private static com.google.protobuf.Internal.EnumLiteMap<Type> + internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap<Type>() { + public Type findValueByNumber(int number) { + return Type.valueOf(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor + getValueDescriptor() { + return getDescriptor().getValues().get(index); + } + public final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptorForType() { + return getDescriptor(); + } + public static final com.google.protobuf.Descriptors.EnumDescriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.Event.getDescriptor().getEnumTypes().get(0); + } + + private static final Type[] VALUES = values(); + + public static Type valueOf( + com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + if (desc.getType() != getDescriptor()) { + throw new java.lang.IllegalArgumentException( + "EnumValueDescriptor is not for this type."); + } + return VALUES[desc.getIndex()]; + } + + private final int index; + private final int value; + + private Type(int index, int value) { + this.index = index; + this.value = value; + } + + // @@protoc_insertion_point(enum_scope:mesos.v1.executor.Event.Type) + } + + public interface SubscribedOrBuilder + extends com.google.protobuf.MessageOrBuilder { + + // required .mesos.v1.ExecutorInfo executor_info = 1; + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + boolean hasExecutorInfo(); + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + org.apache.mesos.v1.Protos.ExecutorInfo getExecutorInfo(); + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder getExecutorInfoOrBuilder(); + + // required .mesos.v1.FrameworkInfo framework_info = 2; + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + boolean hasFrameworkInfo(); + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + org.apache.mesos.v1.Protos.FrameworkInfo getFrameworkInfo(); + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder getFrameworkInfoOrBuilder(); + + // required .mesos.v1.AgentInfo agent_info = 3; + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + boolean hasAgentInfo(); + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + org.apache.mesos.v1.Protos.AgentInfo getAgentInfo(); + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + org.apache.mesos.v1.Protos.AgentInfoOrBuilder getAgentInfoOrBuilder(); + + // optional .mesos.v1.ContainerID container_id = 4; + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + boolean hasContainerId(); + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + org.apache.mesos.v1.Protos.ContainerID getContainerId(); + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + org.apache.mesos.v1.Protos.ContainerIDOrBuilder getContainerIdOrBuilder(); + } + /** + * Protobuf type {@code mesos.v1.executor.Event.Subscribed} + * + * <pre> + * First event received when the executor subscribes. + * The 'id' field in the 'framework_info' will be set. + * </pre> + */ + public static final class Subscribed extends + com.google.protobuf.GeneratedMessage + implements SubscribedOrBuilder { + // Use Subscribed.newBuilder() to construct. + private Subscribed(com.google.protobuf.GeneratedMessage.Builder<?> builder) { + super(builder); + this.unknownFields = builder.getUnknownFields(); + } + private Subscribed(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } + + private static final Subscribed defaultInstance; + public static Subscribed getDefaultInstance() { + return defaultInstance; + } + + public Subscribed getDefaultInstanceForType() { + return defaultInstance; + } + + private final com.google.protobuf.UnknownFieldSet unknownFields; + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private Subscribed( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + initFields(); + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: { + if (!parseUnknownField(input, unknownFields, + extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + org.apache.mesos.v1.Protos.ExecutorInfo.Builder subBuilder = null; + if (((bitField0_ & 0x00000001) == 0x00000001)) { + subBuilder = executorInfo_.toBuilder(); + } + executorInfo_ = input.readMessage(org.apache.mesos.v1.Protos.ExecutorInfo.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(executorInfo_); + executorInfo_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000001; + break; + } + case 18: { + org.apache.mesos.v1.Protos.FrameworkInfo.Builder subBuilder = null; + if (((bitField0_ & 0x00000002) == 0x00000002)) { + subBuilder = frameworkInfo_.toBuilder(); + } + frameworkInfo_ = input.readMessage(org.apache.mesos.v1.Protos.FrameworkInfo.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(frameworkInfo_); + frameworkInfo_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000002; + break; + } + case 26: { + org.apache.mesos.v1.Protos.AgentInfo.Builder subBuilder = null; + if (((bitField0_ & 0x00000004) == 0x00000004)) { + subBuilder = agentInfo_.toBuilder(); + } + agentInfo_ = input.readMessage(org.apache.mesos.v1.Protos.AgentInfo.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(agentInfo_); + agentInfo_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000004; + break; + } + case 34: { + org.apache.mesos.v1.Protos.ContainerID.Builder subBuilder = null; + if (((bitField0_ & 0x00000008) == 0x00000008)) { + subBuilder = containerId_.toBuilder(); + } + containerId_ = input.readMessage(org.apache.mesos.v1.Protos.ContainerID.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(containerId_); + containerId_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000008; + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e.getMessage()).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Subscribed_descriptor; + } + + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Subscribed_fieldAccessorTable + .ensureFieldAccessorsInitialized( + org.apache.mesos.v1.executor.Protos.Event.Subscribed.class, org.apache.mesos.v1.executor.Protos.Event.Subscribed.Builder.class); + } + + public static com.google.protobuf.Parser<Subscribed> PARSER = + new com.google.protobuf.AbstractParser<Subscribed>() { + public Subscribed parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Subscribed(input, extensionRegistry); + } + }; + + @java.lang.Override + public com.google.protobuf.Parser<Subscribed> getParserForType() { + return PARSER; + } + + private int bitField0_; + // required .mesos.v1.ExecutorInfo executor_info = 1; + public static final int EXECUTOR_INFO_FIELD_NUMBER = 1; + private org.apache.mesos.v1.Protos.ExecutorInfo executorInfo_; + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public boolean hasExecutorInfo() { + return ((bitField0_ & 0x00000001) == 0x00000001); + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public org.apache.mesos.v1.Protos.ExecutorInfo getExecutorInfo() { + return executorInfo_; + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder getExecutorInfoOrBuilder() { + return executorInfo_; + } + + // required .mesos.v1.FrameworkInfo framework_info = 2; + public static final int FRAMEWORK_INFO_FIELD_NUMBER = 2; + private org.apache.mesos.v1.Protos.FrameworkInfo frameworkInfo_; + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public boolean hasFrameworkInfo() { + return ((bitField0_ & 0x00000002) == 0x00000002); + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public org.apache.mesos.v1.Protos.FrameworkInfo getFrameworkInfo() { + return frameworkInfo_; + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder getFrameworkInfoOrBuilder() { + return frameworkInfo_; + } + + // required .mesos.v1.AgentInfo agent_info = 3; + public static final int AGENT_INFO_FIELD_NUMBER = 3; + private org.apache.mesos.v1.Protos.AgentInfo agentInfo_; + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public boolean hasAgentInfo() { + return ((bitField0_ & 0x00000004) == 0x00000004); + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public org.apache.mesos.v1.Protos.AgentInfo getAgentInfo() { + return agentInfo_; + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public org.apache.mesos.v1.Protos.AgentInfoOrBuilder getAgentInfoOrBuilder() { + return agentInfo_; + } + + // optional .mesos.v1.ContainerID container_id = 4; + public static final int CONTAINER_ID_FIELD_NUMBER = 4; + private org.apache.mesos.v1.Protos.ContainerID containerId_; + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public boolean hasContainerId() { + return ((bitField0_ & 0x00000008) == 0x00000008); + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public org.apache.mesos.v1.Protos.ContainerID getContainerId() { + return containerId_; + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public org.apache.mesos.v1.Protos.ContainerIDOrBuilder getContainerIdOrBuilder() { + return containerId_; + } + + private void initFields() { + executorInfo_ = org.apache.mesos.v1.Protos.ExecutorInfo.getDefaultInstance(); + frameworkInfo_ = org.apache.mesos.v1.Protos.FrameworkInfo.getDefaultInstance(); + agentInfo_ = org.apache.mesos.v1.Protos.AgentInfo.getDefaultInstance(); + containerId_ = org.apache.mesos.v1.Protos.ContainerID.getDefaultInstance(); + } + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized != -1) return isInitialized == 1; + + if (!hasExecutorInfo()) { + memoizedIsInitialized = 0; + return false; + } + if (!hasFrameworkInfo()) { + memoizedIsInitialized = 0; + return false; + } + if (!hasAgentInfo()) { + memoizedIsInitialized = 0; + return false; + } + if (!getExecutorInfo().isInitialized()) { + memoizedIsInitialized = 0; + return false; + } + if (!getFrameworkInfo().isInitialized()) { + memoizedIsInitialized = 0; + return false; + } + if (!getAgentInfo().isInitialized()) { + memoizedIsInitialized = 0; + return false; + } + if (hasContainerId()) { + if (!getContainerId().isInitialized()) { + memoizedIsInitialized = 0; + return false; + } + } + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + getSerializedSize(); + if (((bitField0_ & 0x00000001) == 0x00000001)) { + output.writeMessage(1, executorInfo_); + } + if (((bitField0_ & 0x00000002) == 0x00000002)) { + output.writeMessage(2, frameworkInfo_); + } + if (((bitField0_ & 0x00000004) == 0x00000004)) { + output.writeMessage(3, agentInfo_); + } + if (((bitField0_ & 0x00000008) == 0x00000008)) { + output.writeMessage(4, containerId_); + } + getUnknownFields().writeTo(output); + } + + private int memoizedSerializedSize = -1; + public int getSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) == 0x00000001)) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, executorInfo_); + } + if (((bitField0_ & 0x00000002) == 0x00000002)) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(2, frameworkInfo_); + } + if (((bitField0_ & 0x00000004) == 0x00000004)) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(3, agentInfo_); + } + if (((bitField0_ & 0x00000008) == 0x00000008)) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(4, containerId_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSerializedSize = size; + return size; + } + + private static final long serialVersionUID = 0L; + @java.lang.Override + protected java.lang.Object writeReplace() + throws java.io.ObjectStreamException { + return super.writeReplace(); + } + + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom(java.io.InputStream input) + throws java.io.IOException { + return PARSER.parseFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseFrom(input, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return PARSER.parseDelimitedFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseDelimitedFrom(input, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return PARSER.parseFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Subscribed parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseFrom(input, extensionRegistry); + } + + public static Builder newBuilder() { return Builder.create(); } + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder(org.apache.mesos.v1.executor.Protos.Event.Subscribed prototype) { + return newBuilder().mergeFrom(prototype); + } + public Builder toBuilder() { return newBuilder(this); } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * Protobuf type {@code mesos.v1.executor.Event.Subscribed} + * + * <pre> + * First event received when the executor subscribes. + * The 'id' field in the 'framework_info' will be set. + * </pre> + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessage.Builder<Builder> + implements org.apache.mesos.v1.executor.Protos.Event.SubscribedOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Subscribed_descriptor; + } + + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Subscribed_fieldAccessorTable + .ensureFieldAccessorsInitialized( + org.apache.mesos.v1.executor.Protos.Event.Subscribed.class, org.apache.mesos.v1.executor.Protos.Event.Subscribed.Builder.class); + } + + // Construct using org.apache.mesos.v1.executor.Protos.Event.Subscribed.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + getExecutorInfoFieldBuilder(); + getFrameworkInfoFieldBuilder(); + getAgentInfoFieldBuilder(); + getContainerIdFieldBuilder(); + } + } + private static Builder create() { + return new Builder(); + } + + public Builder clear() { + super.clear(); + if (executorInfoBuilder_ == null) { + executorInfo_ = org.apache.mesos.v1.Protos.ExecutorInfo.getDefaultInstance(); + } else { + executorInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + if (frameworkInfoBuilder_ == null) { + frameworkInfo_ = org.apache.mesos.v1.Protos.FrameworkInfo.getDefaultInstance(); + } else { + frameworkInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + if (agentInfoBuilder_ == null) { + agentInfo_ = org.apache.mesos.v1.Protos.AgentInfo.getDefaultInstance(); + } else { + agentInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000004); + if (containerIdBuilder_ == null) { + containerId_ = org.apache.mesos.v1.Protos.ContainerID.getDefaultInstance(); + } else { + containerIdBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000008); + return this; + } + + public Builder clone() { + return create().mergeFrom(buildPartial()); + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Subscribed_descriptor; + } + + public org.apache.mesos.v1.executor.Protos.Event.Subscribed getDefaultInstanceForType() { + return org.apache.mesos.v1.executor.Protos.Event.Subscribed.getDefaultInstance(); + } + + public org.apache.mesos.v1.executor.Protos.Event.Subscribed build() { + org.apache.mesos.v1.executor.Protos.Event.Subscribed result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public org.apache.mesos.v1.executor.Protos.Event.Subscribed buildPartial() { + org.apache.mesos.v1.executor.Protos.Event.Subscribed result = new org.apache.mesos.v1.executor.Protos.Event.Subscribed(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) == 0x00000001)) { + to_bitField0_ |= 0x00000001; + } + if (executorInfoBuilder_ == null) { + result.executorInfo_ = executorInfo_; + } else { + result.executorInfo_ = executorInfoBuilder_.build(); + } + if (((from_bitField0_ & 0x00000002) == 0x00000002)) { + to_bitField0_ |= 0x00000002; + } + if (frameworkInfoBuilder_ == null) { + result.frameworkInfo_ = frameworkInfo_; + } else { + result.frameworkInfo_ = frameworkInfoBuilder_.build(); + } + if (((from_bitField0_ & 0x00000004) == 0x00000004)) { + to_bitField0_ |= 0x00000004; + } + if (agentInfoBuilder_ == null) { + result.agentInfo_ = agentInfo_; + } else { + result.agentInfo_ = agentInfoBuilder_.build(); + } + if (((from_bitField0_ & 0x00000008) == 0x00000008)) { + to_bitField0_ |= 0x00000008; + } + if (containerIdBuilder_ == null) { + result.containerId_ = containerId_; + } else { + result.containerId_ = containerIdBuilder_.build(); + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof org.apache.mesos.v1.executor.Protos.Event.Subscribed) { + return mergeFrom((org.apache.mesos.v1.executor.Protos.Event.Subscribed)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(org.apache.mesos.v1.executor.Protos.Event.Subscribed other) { + if (other == org.apache.mesos.v1.executor.Protos.Event.Subscribed.getDefaultInstance()) return this; + if (other.hasExecutorInfo()) { + mergeExecutorInfo(other.getExecutorInfo()); + } + if (other.hasFrameworkInfo()) { + mergeFrameworkInfo(other.getFrameworkInfo()); + } + if (other.hasAgentInfo()) { + mergeAgentInfo(other.getAgentInfo()); + } + if (other.hasContainerId()) { + mergeContainerId(other.getContainerId()); + } + this.mergeUnknownFields(other.getUnknownFields()); + return this; + } + + public final boolean isInitialized() { + if (!hasExecutorInfo()) { + + return false; + } + if (!hasFrameworkInfo()) { + + return false; + } + if (!hasAgentInfo()) { + + return false; + } + if (!getExecutorInfo().isInitialized()) { + + return false; + } + if (!getFrameworkInfo().isInitialized()) { + + return false; + } + if (!getAgentInfo().isInitialized()) { + + return false; + } + if (hasContainerId()) { + if (!getContainerId().isInitialized()) { + + return false; + } + } + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + org.apache.mesos.v1.executor.Protos.Event.Subscribed parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (org.apache.mesos.v1.executor.Protos.Event.Subscribed) e.getUnfinishedMessage(); + throw e; + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + // required .mesos.v1.ExecutorInfo executor_info = 1; + private org.apache.mesos.v1.Protos.ExecutorInfo executorInfo_ = org.apache.mesos.v1.Protos.ExecutorInfo.getDefaultInstance(); + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ExecutorInfo, org.apache.mesos.v1.Protos.ExecutorInfo.Builder, org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder> executorInfoBuilder_; + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public boolean hasExecutorInfo() { + return ((bitField0_ & 0x00000001) == 0x00000001); + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public org.apache.mesos.v1.Protos.ExecutorInfo getExecutorInfo() { + if (executorInfoBuilder_ == null) { + return executorInfo_; + } else { + return executorInfoBuilder_.getMessage(); + } + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public Builder setExecutorInfo(org.apache.mesos.v1.Protos.ExecutorInfo value) { + if (executorInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + executorInfo_ = value; + onChanged(); + } else { + executorInfoBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public Builder setExecutorInfo( + org.apache.mesos.v1.Protos.ExecutorInfo.Builder builderForValue) { + if (executorInfoBuilder_ == null) { + executorInfo_ = builderForValue.build(); + onChanged(); + } else { + executorInfoBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public Builder mergeExecutorInfo(org.apache.mesos.v1.Protos.ExecutorInfo value) { + if (executorInfoBuilder_ == null) { + if (((bitField0_ & 0x00000001) == 0x00000001) && + executorInfo_ != org.apache.mesos.v1.Protos.ExecutorInfo.getDefaultInstance()) { + executorInfo_ = + org.apache.mesos.v1.Protos.ExecutorInfo.newBuilder(executorInfo_).mergeFrom(value).buildPartial(); + } else { + executorInfo_ = value; + } + onChanged(); + } else { + executorInfoBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public Builder clearExecutorInfo() { + if (executorInfoBuilder_ == null) { + executorInfo_ = org.apache.mesos.v1.Protos.ExecutorInfo.getDefaultInstance(); + onChanged(); + } else { + executorInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public org.apache.mesos.v1.Protos.ExecutorInfo.Builder getExecutorInfoBuilder() { + bitField0_ |= 0x00000001; + onChanged(); + return getExecutorInfoFieldBuilder().getBuilder(); + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + public org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder getExecutorInfoOrBuilder() { + if (executorInfoBuilder_ != null) { + return executorInfoBuilder_.getMessageOrBuilder(); + } else { + return executorInfo_; + } + } + /** + * <code>required .mesos.v1.ExecutorInfo executor_info = 1;</code> + */ + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ExecutorInfo, org.apache.mesos.v1.Protos.ExecutorInfo.Builder, org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder> + getExecutorInfoFieldBuilder() { + if (executorInfoBuilder_ == null) { + executorInfoBuilder_ = new com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ExecutorInfo, org.apache.mesos.v1.Protos.ExecutorInfo.Builder, org.apache.mesos.v1.Protos.ExecutorInfoOrBuilder>( + executorInfo_, + getParentForChildren(), + isClean()); + executorInfo_ = null; + } + return executorInfoBuilder_; + } + + // required .mesos.v1.FrameworkInfo framework_info = 2; + private org.apache.mesos.v1.Protos.FrameworkInfo frameworkInfo_ = org.apache.mesos.v1.Protos.FrameworkInfo.getDefaultInstance(); + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.FrameworkInfo, org.apache.mesos.v1.Protos.FrameworkInfo.Builder, org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder> frameworkInfoBuilder_; + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public boolean hasFrameworkInfo() { + return ((bitField0_ & 0x00000002) == 0x00000002); + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public org.apache.mesos.v1.Protos.FrameworkInfo getFrameworkInfo() { + if (frameworkInfoBuilder_ == null) { + return frameworkInfo_; + } else { + return frameworkInfoBuilder_.getMessage(); + } + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public Builder setFrameworkInfo(org.apache.mesos.v1.Protos.FrameworkInfo value) { + if (frameworkInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + frameworkInfo_ = value; + onChanged(); + } else { + frameworkInfoBuilder_.setMessage(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public Builder setFrameworkInfo( + org.apache.mesos.v1.Protos.FrameworkInfo.Builder builderForValue) { + if (frameworkInfoBuilder_ == null) { + frameworkInfo_ = builderForValue.build(); + onChanged(); + } else { + frameworkInfoBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public Builder mergeFrameworkInfo(org.apache.mesos.v1.Protos.FrameworkInfo value) { + if (frameworkInfoBuilder_ == null) { + if (((bitField0_ & 0x00000002) == 0x00000002) && + frameworkInfo_ != org.apache.mesos.v1.Protos.FrameworkInfo.getDefaultInstance()) { + frameworkInfo_ = + org.apache.mesos.v1.Protos.FrameworkInfo.newBuilder(frameworkInfo_).mergeFrom(value).buildPartial(); + } else { + frameworkInfo_ = value; + } + onChanged(); + } else { + frameworkInfoBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000002; + return this; + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public Builder clearFrameworkInfo() { + if (frameworkInfoBuilder_ == null) { + frameworkInfo_ = org.apache.mesos.v1.Protos.FrameworkInfo.getDefaultInstance(); + onChanged(); + } else { + frameworkInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000002); + return this; + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public org.apache.mesos.v1.Protos.FrameworkInfo.Builder getFrameworkInfoBuilder() { + bitField0_ |= 0x00000002; + onChanged(); + return getFrameworkInfoFieldBuilder().getBuilder(); + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + public org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder getFrameworkInfoOrBuilder() { + if (frameworkInfoBuilder_ != null) { + return frameworkInfoBuilder_.getMessageOrBuilder(); + } else { + return frameworkInfo_; + } + } + /** + * <code>required .mesos.v1.FrameworkInfo framework_info = 2;</code> + */ + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.FrameworkInfo, org.apache.mesos.v1.Protos.FrameworkInfo.Builder, org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder> + getFrameworkInfoFieldBuilder() { + if (frameworkInfoBuilder_ == null) { + frameworkInfoBuilder_ = new com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.FrameworkInfo, org.apache.mesos.v1.Protos.FrameworkInfo.Builder, org.apache.mesos.v1.Protos.FrameworkInfoOrBuilder>( + frameworkInfo_, + getParentForChildren(), + isClean()); + frameworkInfo_ = null; + } + return frameworkInfoBuilder_; + } + + // required .mesos.v1.AgentInfo agent_info = 3; + private org.apache.mesos.v1.Protos.AgentInfo agentInfo_ = org.apache.mesos.v1.Protos.AgentInfo.getDefaultInstance(); + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.AgentInfo, org.apache.mesos.v1.Protos.AgentInfo.Builder, org.apache.mesos.v1.Protos.AgentInfoOrBuilder> agentInfoBuilder_; + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public boolean hasAgentInfo() { + return ((bitField0_ & 0x00000004) == 0x00000004); + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public org.apache.mesos.v1.Protos.AgentInfo getAgentInfo() { + if (agentInfoBuilder_ == null) { + return agentInfo_; + } else { + return agentInfoBuilder_.getMessage(); + } + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public Builder setAgentInfo(org.apache.mesos.v1.Protos.AgentInfo value) { + if (agentInfoBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + agentInfo_ = value; + onChanged(); + } else { + agentInfoBuilder_.setMessage(value); + } + bitField0_ |= 0x00000004; + return this; + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public Builder setAgentInfo( + org.apache.mesos.v1.Protos.AgentInfo.Builder builderForValue) { + if (agentInfoBuilder_ == null) { + agentInfo_ = builderForValue.build(); + onChanged(); + } else { + agentInfoBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000004; + return this; + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public Builder mergeAgentInfo(org.apache.mesos.v1.Protos.AgentInfo value) { + if (agentInfoBuilder_ == null) { + if (((bitField0_ & 0x00000004) == 0x00000004) && + agentInfo_ != org.apache.mesos.v1.Protos.AgentInfo.getDefaultInstance()) { + agentInfo_ = + org.apache.mesos.v1.Protos.AgentInfo.newBuilder(agentInfo_).mergeFrom(value).buildPartial(); + } else { + agentInfo_ = value; + } + onChanged(); + } else { + agentInfoBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000004; + return this; + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public Builder clearAgentInfo() { + if (agentInfoBuilder_ == null) { + agentInfo_ = org.apache.mesos.v1.Protos.AgentInfo.getDefaultInstance(); + onChanged(); + } else { + agentInfoBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000004); + return this; + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public org.apache.mesos.v1.Protos.AgentInfo.Builder getAgentInfoBuilder() { + bitField0_ |= 0x00000004; + onChanged(); + return getAgentInfoFieldBuilder().getBuilder(); + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + public org.apache.mesos.v1.Protos.AgentInfoOrBuilder getAgentInfoOrBuilder() { + if (agentInfoBuilder_ != null) { + return agentInfoBuilder_.getMessageOrBuilder(); + } else { + return agentInfo_; + } + } + /** + * <code>required .mesos.v1.AgentInfo agent_info = 3;</code> + */ + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.AgentInfo, org.apache.mesos.v1.Protos.AgentInfo.Builder, org.apache.mesos.v1.Protos.AgentInfoOrBuilder> + getAgentInfoFieldBuilder() { + if (agentInfoBuilder_ == null) { + agentInfoBuilder_ = new com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.AgentInfo, org.apache.mesos.v1.Protos.AgentInfo.Builder, org.apache.mesos.v1.Protos.AgentInfoOrBuilder>( + agentInfo_, + getParentForChildren(), + isClean()); + agentInfo_ = null; + } + return agentInfoBuilder_; + } + + // optional .mesos.v1.ContainerID container_id = 4; + private org.apache.mesos.v1.Protos.ContainerID containerId_ = org.apache.mesos.v1.Protos.ContainerID.getDefaultInstance(); + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ContainerID, org.apache.mesos.v1.Protos.ContainerID.Builder, org.apache.mesos.v1.Protos.ContainerIDOrBuilder> containerIdBuilder_; + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public boolean hasContainerId() { + return ((bitField0_ & 0x00000008) == 0x00000008); + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public org.apache.mesos.v1.Protos.ContainerID getContainerId() { + if (containerIdBuilder_ == null) { + return containerId_; + } else { + return containerIdBuilder_.getMessage(); + } + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public Builder setContainerId(org.apache.mesos.v1.Protos.ContainerID value) { + if (containerIdBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + containerId_ = value; + onChanged(); + } else { + containerIdBuilder_.setMessage(value); + } + bitField0_ |= 0x00000008; + return this; + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public Builder setContainerId( + org.apache.mesos.v1.Protos.ContainerID.Builder builderForValue) { + if (containerIdBuilder_ == null) { + containerId_ = builderForValue.build(); + onChanged(); + } else { + containerIdBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000008; + return this; + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public Builder mergeContainerId(org.apache.mesos.v1.Protos.ContainerID value) { + if (containerIdBuilder_ == null) { + if (((bitField0_ & 0x00000008) == 0x00000008) && + containerId_ != org.apache.mesos.v1.Protos.ContainerID.getDefaultInstance()) { + containerId_ = + org.apache.mesos.v1.Protos.ContainerID.newBuilder(containerId_).mergeFrom(value).buildPartial(); + } else { + containerId_ = value; + } + onChanged(); + } else { + containerIdBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000008; + return this; + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public Builder clearContainerId() { + if (containerIdBuilder_ == null) { + containerId_ = org.apache.mesos.v1.Protos.ContainerID.getDefaultInstance(); + onChanged(); + } else { + containerIdBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000008); + return this; + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public org.apache.mesos.v1.Protos.ContainerID.Builder getContainerIdBuilder() { + bitField0_ |= 0x00000008; + onChanged(); + return getContainerIdFieldBuilder().getBuilder(); + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + public org.apache.mesos.v1.Protos.ContainerIDOrBuilder getContainerIdOrBuilder() { + if (containerIdBuilder_ != null) { + return containerIdBuilder_.getMessageOrBuilder(); + } else { + return containerId_; + } + } + /** + * <code>optional .mesos.v1.ContainerID container_id = 4;</code> + * + * <pre> + * Uniquely identifies the container of an executor run. + * </pre> + */ + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ContainerID, org.apache.mesos.v1.Protos.ContainerID.Builder, org.apache.mesos.v1.Protos.ContainerIDOrBuilder> + getContainerIdFieldBuilder() { + if (containerIdBuilder_ == null) { + containerIdBuilder_ = new com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.ContainerID, org.apache.mesos.v1.Protos.ContainerID.Builder, org.apache.mesos.v1.Protos.ContainerIDOrBuilder>( + containerId_, + getParentForChildren(), + isClean()); + containerId_ = null; + } + return containerIdBuilder_; + } + + // @@protoc_insertion_point(builder_scope:mesos.v1.executor.Event.Subscribed) + } + + static { + defaultInstance = new Subscribed(true); + defaultInstance.initFields(); + } + + // @@protoc_insertion_point(class_scope:mesos.v1.executor.Event.Subscribed) + } + + public interface LaunchOrBuilder + extends com.google.protobuf.MessageOrBuilder { + + // required .mesos.v1.TaskInfo task = 1; + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + boolean hasTask(); + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + org.apache.mesos.v1.Protos.TaskInfo getTask(); + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + org.apache.mesos.v1.Protos.TaskInfoOrBuilder getTaskOrBuilder(); + } + /** + * Protobuf type {@code mesos.v1.executor.Event.Launch} + * + * <pre> + * Received when the framework attempts to launch a task. Once + * the task is successfully launched, the executor must respond with + * a TASK_RUNNING update (See TaskState in v1/mesos.proto). + * </pre> + */ + public static final class Launch extends + com.google.protobuf.GeneratedMessage + implements LaunchOrBuilder { + // Use Launch.newBuilder() to construct. + private Launch(com.google.protobuf.GeneratedMessage.Builder<?> builder) { + super(builder); + this.unknownFields = builder.getUnknownFields(); + } + private Launch(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } + + private static final Launch defaultInstance; + public static Launch getDefaultInstance() { + return defaultInstance; + } + + public Launch getDefaultInstanceForType() { + return defaultInstance; + } + + private final com.google.protobuf.UnknownFieldSet unknownFields; + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet + getUnknownFields() { + return this.unknownFields; + } + private Launch( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + initFields(); + int mutable_bitField0_ = 0; + com.google.protobuf.UnknownFieldSet.Builder unknownFields = + com.google.protobuf.UnknownFieldSet.newBuilder(); + try { + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: { + if (!parseUnknownField(input, unknownFields, + extensionRegistry, tag)) { + done = true; + } + break; + } + case 10: { + org.apache.mesos.v1.Protos.TaskInfo.Builder subBuilder = null; + if (((bitField0_ & 0x00000001) == 0x00000001)) { + subBuilder = task_.toBuilder(); + } + task_ = input.readMessage(org.apache.mesos.v1.Protos.TaskInfo.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(task_); + task_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000001; + break; + } + } + } + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(this); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException( + e.getMessage()).setUnfinishedMessage(this); + } finally { + this.unknownFields = unknownFields.build(); + makeExtensionsImmutable(); + } + } + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Launch_descriptor; + } + + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Launch_fieldAccessorTable + .ensureFieldAccessorsInitialized( + org.apache.mesos.v1.executor.Protos.Event.Launch.class, org.apache.mesos.v1.executor.Protos.Event.Launch.Builder.class); + } + + public static com.google.protobuf.Parser<Launch> PARSER = + new com.google.protobuf.AbstractParser<Launch>() { + public Launch parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Launch(input, extensionRegistry); + } + }; + + @java.lang.Override + public com.google.protobuf.Parser<Launch> getParserForType() { + return PARSER; + } + + private int bitField0_; + // required .mesos.v1.TaskInfo task = 1; + public static final int TASK_FIELD_NUMBER = 1; + private org.apache.mesos.v1.Protos.TaskInfo task_; + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public boolean hasTask() { + return ((bitField0_ & 0x00000001) == 0x00000001); + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public org.apache.mesos.v1.Protos.TaskInfo getTask() { + return task_; + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public org.apache.mesos.v1.Protos.TaskInfoOrBuilder getTaskOrBuilder() { + return task_; + } + + private void initFields() { + task_ = org.apache.mesos.v1.Protos.TaskInfo.getDefaultInstance(); + } + private byte memoizedIsInitialized = -1; + public final boolean isInitialized() { + byte isInitialized = memoizedIsInitialized; + if (isInitialized != -1) return isInitialized == 1; + + if (!hasTask()) { + memoizedIsInitialized = 0; + return false; + } + if (!getTask().isInitialized()) { + memoizedIsInitialized = 0; + return false; + } + memoizedIsInitialized = 1; + return true; + } + + public void writeTo(com.google.protobuf.CodedOutputStream output) + throws java.io.IOException { + getSerializedSize(); + if (((bitField0_ & 0x00000001) == 0x00000001)) { + output.writeMessage(1, task_); + } + getUnknownFields().writeTo(output); + } + + private int memoizedSerializedSize = -1; + public int getSerializedSize() { + int size = memoizedSerializedSize; + if (size != -1) return size; + + size = 0; + if (((bitField0_ & 0x00000001) == 0x00000001)) { + size += com.google.protobuf.CodedOutputStream + .computeMessageSize(1, task_); + } + size += getUnknownFields().getSerializedSize(); + memoizedSerializedSize = size; + return size; + } + + private static final long serialVersionUID = 0L; + @java.lang.Override + protected java.lang.Object writeReplace() + throws java.io.ObjectStreamException { + return super.writeReplace(); + } + + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + com.google.protobuf.ByteString data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + com.google.protobuf.ByteString data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom(byte[] data) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + byte[] data, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return PARSER.parseFrom(data, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom(java.io.InputStream input) + throws java.io.IOException { + return PARSER.parseFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseFrom(input, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseDelimitedFrom(java.io.InputStream input) + throws java.io.IOException { + return PARSER.parseDelimitedFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseDelimitedFrom( + java.io.InputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseDelimitedFrom(input, extensionRegistry); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + com.google.protobuf.CodedInputStream input) + throws java.io.IOException { + return PARSER.parseFrom(input); + } + public static org.apache.mesos.v1.executor.Protos.Event.Launch parseFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + return PARSER.parseFrom(input, extensionRegistry); + } + + public static Builder newBuilder() { return Builder.create(); } + public Builder newBuilderForType() { return newBuilder(); } + public static Builder newBuilder(org.apache.mesos.v1.executor.Protos.Event.Launch prototype) { + return newBuilder().mergeFrom(prototype); + } + public Builder toBuilder() { return newBuilder(this); } + + @java.lang.Override + protected Builder newBuilderForType( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + Builder builder = new Builder(parent); + return builder; + } + /** + * Protobuf type {@code mesos.v1.executor.Event.Launch} + * + * <pre> + * Received when the framework attempts to launch a task. Once + * the task is successfully launched, the executor must respond with + * a TASK_RUNNING update (See TaskState in v1/mesos.proto). + * </pre> + */ + public static final class Builder extends + com.google.protobuf.GeneratedMessage.Builder<Builder> + implements org.apache.mesos.v1.executor.Protos.Event.LaunchOrBuilder { + public static final com.google.protobuf.Descriptors.Descriptor + getDescriptor() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Launch_descriptor; + } + + protected com.google.protobuf.GeneratedMessage.FieldAccessorTable + internalGetFieldAccessorTable() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Launch_fieldAccessorTable + .ensureFieldAccessorsInitialized( + org.apache.mesos.v1.executor.Protos.Event.Launch.class, org.apache.mesos.v1.executor.Protos.Event.Launch.Builder.class); + } + + // Construct using org.apache.mesos.v1.executor.Protos.Event.Launch.newBuilder() + private Builder() { + maybeForceBuilderInitialization(); + } + + private Builder( + com.google.protobuf.GeneratedMessage.BuilderParent parent) { + super(parent); + maybeForceBuilderInitialization(); + } + private void maybeForceBuilderInitialization() { + if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { + getTaskFieldBuilder(); + } + } + private static Builder create() { + return new Builder(); + } + + public Builder clear() { + super.clear(); + if (taskBuilder_ == null) { + task_ = org.apache.mesos.v1.Protos.TaskInfo.getDefaultInstance(); + } else { + taskBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000001); + return this; + } + + public Builder clone() { + return create().mergeFrom(buildPartial()); + } + + public com.google.protobuf.Descriptors.Descriptor + getDescriptorForType() { + return org.apache.mesos.v1.executor.Protos.internal_static_mesos_v1_executor_Event_Launch_descriptor; + } + + public org.apache.mesos.v1.executor.Protos.Event.Launch getDefaultInstanceForType() { + return org.apache.mesos.v1.executor.Protos.Event.Launch.getDefaultInstance(); + } + + public org.apache.mesos.v1.executor.Protos.Event.Launch build() { + org.apache.mesos.v1.executor.Protos.Event.Launch result = buildPartial(); + if (!result.isInitialized()) { + throw newUninitializedMessageException(result); + } + return result; + } + + public org.apache.mesos.v1.executor.Protos.Event.Launch buildPartial() { + org.apache.mesos.v1.executor.Protos.Event.Launch result = new org.apache.mesos.v1.executor.Protos.Event.Launch(this); + int from_bitField0_ = bitField0_; + int to_bitField0_ = 0; + if (((from_bitField0_ & 0x00000001) == 0x00000001)) { + to_bitField0_ |= 0x00000001; + } + if (taskBuilder_ == null) { + result.task_ = task_; + } else { + result.task_ = taskBuilder_.build(); + } + result.bitField0_ = to_bitField0_; + onBuilt(); + return result; + } + + public Builder mergeFrom(com.google.protobuf.Message other) { + if (other instanceof org.apache.mesos.v1.executor.Protos.Event.Launch) { + return mergeFrom((org.apache.mesos.v1.executor.Protos.Event.Launch)other); + } else { + super.mergeFrom(other); + return this; + } + } + + public Builder mergeFrom(org.apache.mesos.v1.executor.Protos.Event.Launch other) { + if (other == org.apache.mesos.v1.executor.Protos.Event.Launch.getDefaultInstance()) return this; + if (other.hasTask()) { + mergeTask(other.getTask()); + } + this.mergeUnknownFields(other.getUnknownFields()); + return this; + } + + public final boolean isInitialized() { + if (!hasTask()) { + + return false; + } + if (!getTask().isInitialized()) { + + return false; + } + return true; + } + + public Builder mergeFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws java.io.IOException { + org.apache.mesos.v1.executor.Protos.Event.Launch parsedMessage = null; + try { + parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + parsedMessage = (org.apache.mesos.v1.executor.Protos.Event.Launch) e.getUnfinishedMessage(); + throw e; + } finally { + if (parsedMessage != null) { + mergeFrom(parsedMessage); + } + } + return this; + } + private int bitField0_; + + // required .mesos.v1.TaskInfo task = 1; + private org.apache.mesos.v1.Protos.TaskInfo task_ = org.apache.mesos.v1.Protos.TaskInfo.getDefaultInstance(); + private com.google.protobuf.SingleFieldBuilder< + org.apache.mesos.v1.Protos.TaskInfo, org.apache.mesos.v1.Protos.TaskInfo.Builder, org.apache.mesos.v1.Protos.TaskInfoOrBuilder> taskBuilder_; + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public boolean hasTask() { + return ((bitField0_ & 0x00000001) == 0x00000001); + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public org.apache.mesos.v1.Protos.TaskInfo getTask() { + if (taskBuilder_ == null) { + return task_; + } else { + return taskBuilder_.getMessage(); + } + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public Builder setTask(org.apache.mesos.v1.Protos.TaskInfo value) { + if (taskBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + task_ = value; + onChanged(); + } else { + taskBuilder_.setMessage(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public Builder setTask( + org.apache.mesos.v1.Protos.TaskInfo.Builder builderForValue) { + if (taskBuilder_ == null) { + task_ = builderForValue.build(); + onChanged(); + } else { + taskBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public Builder mergeTask(org.apache.mesos.v1.Protos.TaskInfo value) { + if (taskBuilder_ == null) { + if (((bitField0_ & 0x00000001) == 0x00000001) && + task_ != org.apache.mesos.v1.Protos.TaskInfo.getDefaultInstance()) { + task_ = + org.apache.mesos.v1.Protos.TaskInfo.newBuilder(task_).mergeFrom(value).buildPartial(); + } else { + task_ = value; + } + onChanged(); + } else { + taskBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000001; + return this; + } + /** + * <code>required .mesos.v1.TaskInfo task = 1;</code> + */ + public Builder clearTask() { + if (taskBuilder_ == null) { + task_ = o
<TRUNCATED>