/**
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: resources/person.proto

package org.apache.crunch.lib;

public final class PersonProtos {
    private PersonProtos() {}
    public static void registerAllExtensions(
            com.google.protobuf.ExtensionRegistry registry) {
    }
    public interface PersonOrBuilder
            extends com.google.protobuf.MessageOrBuilder {

        // optional string first = 1;
        /**
         * <code>optional string first = 1;</code>
         */
        boolean hasFirst();
        /**
         * <code>optional string first = 1;</code>
         */
        java.lang.String getFirst();
        /**
         * <code>optional string first = 1;</code>
         */
        com.google.protobuf.ByteString
        getFirstBytes();

        // optional string last = 2;
        /**
         * <code>optional string last = 2;</code>
         */
        boolean hasLast();
        /**
         * <code>optional string last = 2;</code>
         */
        java.lang.String getLast();
        /**
         * <code>optional string last = 2;</code>
         */
        com.google.protobuf.ByteString
        getLastBytes();
    }
    /**
     * Protobuf type {@code crunch.Person}
     */
    public static final class Person extends
            com.google.protobuf.GeneratedMessage
            implements PersonOrBuilder {
        // Use Person.newBuilder() to construct.
        private Person(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
            super(builder);
            this.unknownFields = builder.getUnknownFields();
        }
        private Person(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); }

        private static final Person defaultInstance;
        public static Person getDefaultInstance() {
            return defaultInstance;
        }

        public Person getDefaultInstanceForType() {
            return defaultInstance;
        }

        private final com.google.protobuf.UnknownFieldSet unknownFields;
        @java.lang.Override
        public final com.google.protobuf.UnknownFieldSet
        getUnknownFields() {
            return this.unknownFields;
        }
        private Person(
                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: {
                            bitField0_ |= 0x00000001;
                            first_ = input.readBytes();
                            break;
                        }
                        case 18: {
                            bitField0_ |= 0x00000002;
                            last_ = input.readBytes();
                            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.crunch.lib.PersonProtos.internal_static_crunch_Person_descriptor;
        }

        protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internalGetFieldAccessorTable() {
            return org.apache.crunch.lib.PersonProtos.internal_static_crunch_Person_fieldAccessorTable
                    .ensureFieldAccessorsInitialized(
                            org.apache.crunch.lib.PersonProtos.Person.class, org.apache.crunch.lib.PersonProtos.Person.Builder.class);
        }

        public static com.google.protobuf.Parser<Person> PARSER =
                new com.google.protobuf.AbstractParser<Person>() {
                    public Person parsePartialFrom(
                            com.google.protobuf.CodedInputStream input,
                            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                            throws com.google.protobuf.InvalidProtocolBufferException {
                        return new Person(input, extensionRegistry);
                    }
                };

        @java.lang.Override
        public com.google.protobuf.Parser<Person> getParserForType() {
            return PARSER;
        }

        private int bitField0_;
        // optional string first = 1;
        public static final int FIRST_FIELD_NUMBER = 1;
        private java.lang.Object first_;
        /**
         * <code>optional string first = 1;</code>
         */
        public boolean hasFirst() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        /**
         * <code>optional string first = 1;</code>
         */
        public java.lang.String getFirst() {
            java.lang.Object ref = first_;
            if (ref instanceof java.lang.String) {
                return (java.lang.String) ref;
            } else {
                com.google.protobuf.ByteString bs =
                        (com.google.protobuf.ByteString) ref;
                java.lang.String s = bs.toStringUtf8();
                if (bs.isValidUtf8()) {
                    first_ = s;
                }
                return s;
            }
        }
        /**
         * <code>optional string first = 1;</code>
         */
        public com.google.protobuf.ByteString
        getFirstBytes() {
            java.lang.Object ref = first_;
            if (ref instanceof java.lang.String) {
                com.google.protobuf.ByteString b =
                        com.google.protobuf.ByteString.copyFromUtf8(
                                (java.lang.String) ref);
                first_ = b;
                return b;
            } else {
                return (com.google.protobuf.ByteString) ref;
            }
        }

        // optional string last = 2;
        public static final int LAST_FIELD_NUMBER = 2;
        private java.lang.Object last_;
        /**
         * <code>optional string last = 2;</code>
         */
        public boolean hasLast() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        /**
         * <code>optional string last = 2;</code>
         */
        public java.lang.String getLast() {
            java.lang.Object ref = last_;
            if (ref instanceof java.lang.String) {
                return (java.lang.String) ref;
            } else {
                com.google.protobuf.ByteString bs =
                        (com.google.protobuf.ByteString) ref;
                java.lang.String s = bs.toStringUtf8();
                if (bs.isValidUtf8()) {
                    last_ = s;
                }
                return s;
            }
        }
        /**
         * <code>optional string last = 2;</code>
         */
        public com.google.protobuf.ByteString
        getLastBytes() {
            java.lang.Object ref = last_;
            if (ref instanceof java.lang.String) {
                com.google.protobuf.ByteString b =
                        com.google.protobuf.ByteString.copyFromUtf8(
                                (java.lang.String) ref);
                last_ = b;
                return b;
            } else {
                return (com.google.protobuf.ByteString) ref;
            }
        }

        private void initFields() {
            first_ = "";
            last_ = "";
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
            byte isInitialized = memoizedIsInitialized;
            if (isInitialized != -1) return isInitialized == 1;

            memoizedIsInitialized = 1;
            return true;
        }

        public void writeTo(com.google.protobuf.CodedOutputStream output)
                throws java.io.IOException {
            getSerializedSize();
            if (((bitField0_ & 0x00000001) == 0x00000001)) {
                output.writeBytes(1, getFirstBytes());
            }
            if (((bitField0_ & 0x00000002) == 0x00000002)) {
                output.writeBytes(2, getLastBytes());
            }
            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
                        .computeBytesSize(1, getFirstBytes());
            }
            if (((bitField0_ & 0x00000002) == 0x00000002)) {
                size += com.google.protobuf.CodedOutputStream
                        .computeBytesSize(2, getLastBytes());
            }
            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.crunch.lib.PersonProtos.Person parseFrom(
                com.google.protobuf.ByteString data)
                throws com.google.protobuf.InvalidProtocolBufferException {
            return PARSER.parseFrom(data);
        }
        public static org.apache.crunch.lib.PersonProtos.Person 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.crunch.lib.PersonProtos.Person parseFrom(byte[] data)
                throws com.google.protobuf.InvalidProtocolBufferException {
            return PARSER.parseFrom(data);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseFrom(
                byte[] data,
                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                throws com.google.protobuf.InvalidProtocolBufferException {
            return PARSER.parseFrom(data, extensionRegistry);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseFrom(java.io.InputStream input)
                throws java.io.IOException {
            return PARSER.parseFrom(input);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseFrom(
                java.io.InputStream input,
                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                throws java.io.IOException {
            return PARSER.parseFrom(input, extensionRegistry);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseDelimitedFrom(java.io.InputStream input)
                throws java.io.IOException {
            return PARSER.parseDelimitedFrom(input);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseDelimitedFrom(
                java.io.InputStream input,
                com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                throws java.io.IOException {
            return PARSER.parseDelimitedFrom(input, extensionRegistry);
        }
        public static org.apache.crunch.lib.PersonProtos.Person parseFrom(
                com.google.protobuf.CodedInputStream input)
                throws java.io.IOException {
            return PARSER.parseFrom(input);
        }
        public static org.apache.crunch.lib.PersonProtos.Person 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.crunch.lib.PersonProtos.Person 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 crunch.Person}
         */
        public static final class Builder extends
                com.google.protobuf.GeneratedMessage.Builder<Builder>
                implements org.apache.crunch.lib.PersonProtos.PersonOrBuilder {
            public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
                return org.apache.crunch.lib.PersonProtos.internal_static_crunch_Person_descriptor;
            }

            protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internalGetFieldAccessorTable() {
                return org.apache.crunch.lib.PersonProtos.internal_static_crunch_Person_fieldAccessorTable
                        .ensureFieldAccessorsInitialized(
                                org.apache.crunch.lib.PersonProtos.Person.class, org.apache.crunch.lib.PersonProtos.Person.Builder.class);
            }

            // Construct using org.apache.crunch.lib.PersonProtos.Person.newBuilder()
            private Builder() {
                maybeForceBuilderInitialization();
            }

            private Builder(
                    com.google.protobuf.GeneratedMessage.BuilderParent parent) {
                super(parent);
                maybeForceBuilderInitialization();
            }
            private void maybeForceBuilderInitialization() {
                if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
                }
            }
            private static Builder create() {
                return new Builder();
            }

            public Builder clear() {
                super.clear();
                first_ = "";
                bitField0_ = (bitField0_ & ~0x00000001);
                last_ = "";
                bitField0_ = (bitField0_ & ~0x00000002);
                return this;
            }

            public Builder clone() {
                return create().mergeFrom(buildPartial());
            }

            public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
                return org.apache.crunch.lib.PersonProtos.internal_static_crunch_Person_descriptor;
            }

            public org.apache.crunch.lib.PersonProtos.Person getDefaultInstanceForType() {
                return org.apache.crunch.lib.PersonProtos.Person.getDefaultInstance();
            }

            public org.apache.crunch.lib.PersonProtos.Person build() {
                org.apache.crunch.lib.PersonProtos.Person result = buildPartial();
                if (!result.isInitialized()) {
                    throw newUninitializedMessageException(result);
                }
                return result;
            }

            public org.apache.crunch.lib.PersonProtos.Person buildPartial() {
                org.apache.crunch.lib.PersonProtos.Person result = new org.apache.crunch.lib.PersonProtos.Person(this);
                int from_bitField0_ = bitField0_;
                int to_bitField0_ = 0;
                if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
                    to_bitField0_ |= 0x00000001;
                }
                result.first_ = first_;
                if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
                    to_bitField0_ |= 0x00000002;
                }
                result.last_ = last_;
                result.bitField0_ = to_bitField0_;
                onBuilt();
                return result;
            }

            public Builder mergeFrom(com.google.protobuf.Message other) {
                if (other instanceof org.apache.crunch.lib.PersonProtos.Person) {
                    return mergeFrom((org.apache.crunch.lib.PersonProtos.Person)other);
                } else {
                    super.mergeFrom(other);
                    return this;
                }
            }

            public Builder mergeFrom(org.apache.crunch.lib.PersonProtos.Person other) {
                if (other == org.apache.crunch.lib.PersonProtos.Person.getDefaultInstance()) return this;
                if (other.hasFirst()) {
                    bitField0_ |= 0x00000001;
                    first_ = other.first_;
                    onChanged();
                }
                if (other.hasLast()) {
                    bitField0_ |= 0x00000002;
                    last_ = other.last_;
                    onChanged();
                }
                this.mergeUnknownFields(other.getUnknownFields());
                return this;
            }

            public final boolean isInitialized() {
                return true;
            }

            public Builder mergeFrom(
                    com.google.protobuf.CodedInputStream input,
                    com.google.protobuf.ExtensionRegistryLite extensionRegistry)
                    throws java.io.IOException {
                org.apache.crunch.lib.PersonProtos.Person parsedMessage = null;
                try {
                    parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
                } catch (com.google.protobuf.InvalidProtocolBufferException e) {
                    parsedMessage = (org.apache.crunch.lib.PersonProtos.Person) e.getUnfinishedMessage();
                    throw e;
                } finally {
                    if (parsedMessage != null) {
                        mergeFrom(parsedMessage);
                    }
                }
                return this;
            }
            private int bitField0_;

            // optional string first = 1;
            private java.lang.Object first_ = "";
            /**
             * <code>optional string first = 1;</code>
             */
            public boolean hasFirst() {
                return ((bitField0_ & 0x00000001) == 0x00000001);
            }
            /**
             * <code>optional string first = 1;</code>
             */
            public java.lang.String getFirst() {
                java.lang.Object ref = first_;
                if (!(ref instanceof java.lang.String)) {
                    java.lang.String s = ((com.google.protobuf.ByteString) ref)
                            .toStringUtf8();
                    first_ = s;
                    return s;
                } else {
                    return (java.lang.String) ref;
                }
            }
            /**
             * <code>optional string first = 1;</code>
             */
            public com.google.protobuf.ByteString
            getFirstBytes() {
                java.lang.Object ref = first_;
                if (ref instanceof String) {
                    com.google.protobuf.ByteString b =
                            com.google.protobuf.ByteString.copyFromUtf8(
                                    (java.lang.String) ref);
                    first_ = b;
                    return b;
                } else {
                    return (com.google.protobuf.ByteString) ref;
                }
            }
            /**
             * <code>optional string first = 1;</code>
             */
            public Builder setFirst(
                    java.lang.String value) {
                if (value == null) {
                    throw new NullPointerException();
                }
                bitField0_ |= 0x00000001;
                first_ = value;
                onChanged();
                return this;
            }
            /**
             * <code>optional string first = 1;</code>
             */
            public Builder clearFirst() {
                bitField0_ = (bitField0_ & ~0x00000001);
                first_ = getDefaultInstance().getFirst();
                onChanged();
                return this;
            }
            /**
             * <code>optional string first = 1;</code>
             */
            public Builder setFirstBytes(
                    com.google.protobuf.ByteString value) {
                if (value == null) {
                    throw new NullPointerException();
                }
                bitField0_ |= 0x00000001;
                first_ = value;
                onChanged();
                return this;
            }

            // optional string last = 2;
            private java.lang.Object last_ = "";
            /**
             * <code>optional string last = 2;</code>
             */
            public boolean hasLast() {
                return ((bitField0_ & 0x00000002) == 0x00000002);
            }
            /**
             * <code>optional string last = 2;</code>
             */
            public java.lang.String getLast() {
                java.lang.Object ref = last_;
                if (!(ref instanceof java.lang.String)) {
                    java.lang.String s = ((com.google.protobuf.ByteString) ref)
                            .toStringUtf8();
                    last_ = s;
                    return s;
                } else {
                    return (java.lang.String) ref;
                }
            }
            /**
             * <code>optional string last = 2;</code>
             */
            public com.google.protobuf.ByteString
            getLastBytes() {
                java.lang.Object ref = last_;
                if (ref instanceof String) {
                    com.google.protobuf.ByteString b =
                            com.google.protobuf.ByteString.copyFromUtf8(
                                    (java.lang.String) ref);
                    last_ = b;
                    return b;
                } else {
                    return (com.google.protobuf.ByteString) ref;
                }
            }
            /**
             * <code>optional string last = 2;</code>
             */
            public Builder setLast(
                    java.lang.String value) {
                if (value == null) {
                    throw new NullPointerException();
                }
                bitField0_ |= 0x00000002;
                last_ = value;
                onChanged();
                return this;
            }
            /**
             * <code>optional string last = 2;</code>
             */
            public Builder clearLast() {
                bitField0_ = (bitField0_ & ~0x00000002);
                last_ = getDefaultInstance().getLast();
                onChanged();
                return this;
            }
            /**
             * <code>optional string last = 2;</code>
             */
            public Builder setLastBytes(
                    com.google.protobuf.ByteString value) {
                if (value == null) {
                    throw new NullPointerException();
                }
                bitField0_ |= 0x00000002;
                last_ = value;
                onChanged();
                return this;
            }

            // @@protoc_insertion_point(builder_scope:crunch.Person)
        }

        static {
            defaultInstance = new Person(true);
            defaultInstance.initFields();
        }

        // @@protoc_insertion_point(class_scope:crunch.Person)
    }

    private static com.google.protobuf.Descriptors.Descriptor
            internal_static_crunch_Person_descriptor;
    private static
    com.google.protobuf.GeneratedMessage.FieldAccessorTable
            internal_static_crunch_Person_fieldAccessorTable;

    public static com.google.protobuf.Descriptors.FileDescriptor
    getDescriptor() {
        return descriptor;
    }
    private static com.google.protobuf.Descriptors.FileDescriptor
            descriptor;
    static {
        java.lang.String[] descriptorData = {
                "\n\ngist.proto\022\006crunch\"%\n\006Person\022\r\n\005first\030" +
                        "\001 \001(\t\022\014\n\004last\030\002 \001(\tB\'\n\025org.apache.crunch" +
                        ".libB\014PersonProtosH\001"
        };
        com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
                new com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner() {
                    public com.google.protobuf.ExtensionRegistry assignDescriptors(
                            com.google.protobuf.Descriptors.FileDescriptor root) {
                        descriptor = root;
                        internal_static_crunch_Person_descriptor =
                                getDescriptor().getMessageTypes().get(0);
                        internal_static_crunch_Person_fieldAccessorTable = new
                                com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                                internal_static_crunch_Person_descriptor,
                                new java.lang.String[] { "First", "Last", });
                        return null;
                    }
                };
        com.google.protobuf.Descriptors.FileDescriptor
                .internalBuildGeneratedFileFrom(descriptorData,
                        new com.google.protobuf.Descriptors.FileDescriptor[] {
                        }, assigner);
    }

    // @@protoc_insertion_point(outer_class_scope)
}
