content: // Generated by the protocol buffer compiler.  DO NOT EDIT!
  // source: lot/expression.proto
  
  package apsara.odps.lot;
  
  import apsara.odps.LanguageProtos;
  import apsara.odps.TypesProtos;
  
  public final class ExpressionProtos {
    private ExpressionProtos() {}
    public static void registerAllExtensions(
        com.google.protobuf.ExtensionRegistry registry) {
    }
    public interface ScalarExpressionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // optional .apsara.odps.Reference Reference = 1;
      boolean hasReference();
      apsara.odps.ExpressionProtos.Reference getReference();
      apsara.odps.ExpressionProtos.ReferenceOrBuilder getReferenceOrBuilder();
      
      // optional .apsara.odps.Constant Constant = 2;
      boolean hasConstant();
      apsara.odps.ExpressionProtos.Constant getConstant();
      apsara.odps.ExpressionProtos.ConstantOrBuilder getConstantOrBuilder();
      
      // optional .apsara.odps.Null Null = 3;
      boolean hasNull();
      apsara.odps.ExpressionProtos.Null getNull();
      apsara.odps.ExpressionProtos.NullOrBuilder getNullOrBuilder();
      
      // optional .apsara.odps.lot.ScalarFunction Expression = 4;
      boolean hasExpression();
      ScalarFunction getExpression();
      ScalarFunctionOrBuilder getExpressionOrBuilder();
    }
    public static final class ScalarExpression extends
        com.google.protobuf.GeneratedMessage
        implements ScalarExpressionOrBuilder {
      // Use ScalarExpression.newBuilder() to construct.
      private ScalarExpression(Builder builder) {
        super(builder);
      }
      private ScalarExpression(boolean noInit) {}
      
      private static final ScalarExpression defaultInstance;
      public static ScalarExpression getDefaultInstance() {
        return defaultInstance;
      }
      
      public ScalarExpression getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_ScalarExpression_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_ScalarExpression_fieldAccessorTable;
      }
      
      private int bitField0_;
      // optional .apsara.odps.Reference Reference = 1;
      public static final int REFERENCE_FIELD_NUMBER = 1;
      private apsara.odps.ExpressionProtos.Reference reference_;
      public boolean hasReference() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public apsara.odps.ExpressionProtos.Reference getReference() {
        return reference_;
      }
      public apsara.odps.ExpressionProtos.ReferenceOrBuilder getReferenceOrBuilder() {
        return reference_;
      }
      
      // optional .apsara.odps.Constant Constant = 2;
      public static final int CONSTANT_FIELD_NUMBER = 2;
      private apsara.odps.ExpressionProtos.Constant constant_;
      public boolean hasConstant() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public apsara.odps.ExpressionProtos.Constant getConstant() {
        return constant_;
      }
      public apsara.odps.ExpressionProtos.ConstantOrBuilder getConstantOrBuilder() {
        return constant_;
      }
      
      // optional .apsara.odps.Null Null = 3;
      public static final int NULL_FIELD_NUMBER = 3;
      private apsara.odps.ExpressionProtos.Null null_;
      public boolean hasNull() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public apsara.odps.ExpressionProtos.Null getNull() {
        return null_;
      }
      public apsara.odps.ExpressionProtos.NullOrBuilder getNullOrBuilder() {
        return null_;
      }
      
      // optional .apsara.odps.lot.ScalarFunction Expression = 4;
      public static final int EXPRESSION_FIELD_NUMBER = 4;
      private ScalarFunction expression_;
      public boolean hasExpression() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      public ScalarFunction getExpression() {
        return expression_;
      }
      public ScalarFunctionOrBuilder getExpressionOrBuilder() {
        return expression_;
      }
      
      private void initFields() {
        reference_ = apsara.odps.ExpressionProtos.Reference.getDefaultInstance();
        constant_ = apsara.odps.ExpressionProtos.Constant.getDefaultInstance();
        null_ = apsara.odps.ExpressionProtos.Null.getDefaultInstance();
        expression_ = ScalarFunction.getDefaultInstance();
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (hasReference()) {
          if (!getReference().isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        if (hasExpression()) {
          if (!getExpression().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, reference_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeMessage(2, constant_);
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeMessage(3, null_);
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeMessage(4, expression_);
        }
        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, reference_);
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(2, constant_);
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(3, null_);
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(4, expression_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static ScalarExpression parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static ScalarExpression parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarExpression parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static ScalarExpression parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarExpression parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static ScalarExpression parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarExpression parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static ScalarExpression parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static ScalarExpression parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static ScalarExpression parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(ScalarExpression prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements ScalarExpressionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_ScalarExpression_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_ScalarExpression_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.ScalarExpression.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getReferenceFieldBuilder();
            getConstantFieldBuilder();
            getNullFieldBuilder();
            getExpressionFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          if (referenceBuilder_ == null) {
            reference_ = apsara.odps.ExpressionProtos.Reference.getDefaultInstance();
          } else {
            referenceBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000001);
          if (constantBuilder_ == null) {
            constant_ = apsara.odps.ExpressionProtos.Constant.getDefaultInstance();
          } else {
            constantBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000002);
          if (nullBuilder_ == null) {
            null_ = apsara.odps.ExpressionProtos.Null.getDefaultInstance();
          } else {
            nullBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          if (expressionBuilder_ == null) {
            expression_ = ScalarFunction.getDefaultInstance();
          } else {
            expressionBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return ScalarExpression.getDescriptor();
        }
        
        public ScalarExpression getDefaultInstanceForType() {
          return ScalarExpression.getDefaultInstance();
        }
        
        public ScalarExpression build() {
          ScalarExpression result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private ScalarExpression buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          ScalarExpression result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public ScalarExpression buildPartial() {
          ScalarExpression result = new ScalarExpression(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          if (referenceBuilder_ == null) {
            result.reference_ = reference_;
          } else {
            result.reference_ = referenceBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          if (constantBuilder_ == null) {
            result.constant_ = constant_;
          } else {
            result.constant_ = constantBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          if (nullBuilder_ == null) {
            result.null_ = null_;
          } else {
            result.null_ = nullBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000008;
          }
          if (expressionBuilder_ == null) {
            result.expression_ = expression_;
          } else {
            result.expression_ = expressionBuilder_.build();
          }
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof ScalarExpression) {
            return mergeFrom((ScalarExpression)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(ScalarExpression other) {
          if (other == ScalarExpression.getDefaultInstance()) return this;
          if (other.hasReference()) {
            mergeReference(other.getReference());
          }
          if (other.hasConstant()) {
            mergeConstant(other.getConstant());
          }
          if (other.hasNull()) {
            mergeNull(other.getNull());
          }
          if (other.hasExpression()) {
            mergeExpression(other.getExpression());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (hasReference()) {
            if (!getReference().isInitialized()) {
              
              return false;
            }
          }
          if (hasExpression()) {
            if (!getExpression().isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                apsara.odps.ExpressionProtos.Reference.Builder subBuilder = apsara.odps.ExpressionProtos.Reference.newBuilder();
                if (hasReference()) {
                  subBuilder.mergeFrom(getReference());
                }
                input.readMessage(subBuilder, extensionRegistry);
                setReference(subBuilder.buildPartial());
                break;
              }
              case 18: {
                apsara.odps.ExpressionProtos.Constant.Builder subBuilder = apsara.odps.ExpressionProtos.Constant.newBuilder();
                if (hasConstant()) {
                  subBuilder.mergeFrom(getConstant());
                }
                input.readMessage(subBuilder, extensionRegistry);
                setConstant(subBuilder.buildPartial());
                break;
              }
              case 26: {
                apsara.odps.ExpressionProtos.Null.Builder subBuilder = apsara.odps.ExpressionProtos.Null.newBuilder();
                if (hasNull()) {
                  subBuilder.mergeFrom(getNull());
                }
                input.readMessage(subBuilder, extensionRegistry);
                setNull(subBuilder.buildPartial());
                break;
              }
              case 34: {
                ScalarFunction.Builder subBuilder = ScalarFunction.newBuilder();
                if (hasExpression()) {
                  subBuilder.mergeFrom(getExpression());
                }
                input.readMessage(subBuilder, extensionRegistry);
                setExpression(subBuilder.buildPartial());
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // optional .apsara.odps.Reference Reference = 1;
        private apsara.odps.ExpressionProtos.Reference reference_ = apsara.odps.ExpressionProtos.Reference.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Reference, apsara.odps.ExpressionProtos.Reference.Builder, apsara.odps.ExpressionProtos.ReferenceOrBuilder> referenceBuilder_;
        public boolean hasReference() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public apsara.odps.ExpressionProtos.Reference getReference() {
          if (referenceBuilder_ == null) {
            return reference_;
          } else {
            return referenceBuilder_.getMessage();
          }
        }
        public Builder setReference(apsara.odps.ExpressionProtos.Reference value) {
          if (referenceBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            reference_ = value;
            onChanged();
          } else {
            referenceBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000001;
          return this;
        }
        public Builder setReference(
            apsara.odps.ExpressionProtos.Reference.Builder builderForValue) {
          if (referenceBuilder_ == null) {
            reference_ = builderForValue.build();
            onChanged();
          } else {
            referenceBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000001;
          return this;
        }
        public Builder mergeReference(apsara.odps.ExpressionProtos.Reference value) {
          if (referenceBuilder_ == null) {
            if (((bitField0_ & 0x00000001) == 0x00000001) &&
                reference_ != apsara.odps.ExpressionProtos.Reference.getDefaultInstance()) {
              reference_ =
                apsara.odps.ExpressionProtos.Reference.newBuilder(reference_).mergeFrom(value).buildPartial();
            } else {
              reference_ = value;
            }
            onChanged();
          } else {
            referenceBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000001;
          return this;
        }
        public Builder clearReference() {
          if (referenceBuilder_ == null) {
            reference_ = apsara.odps.ExpressionProtos.Reference.getDefaultInstance();
            onChanged();
          } else {
            referenceBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000001);
          return this;
        }
        public apsara.odps.ExpressionProtos.Reference.Builder getReferenceBuilder() {
          bitField0_ |= 0x00000001;
          onChanged();
          return getReferenceFieldBuilder().getBuilder();
        }
        public apsara.odps.ExpressionProtos.ReferenceOrBuilder getReferenceOrBuilder() {
          if (referenceBuilder_ != null) {
            return referenceBuilder_.getMessageOrBuilder();
          } else {
            return reference_;
          }
        }
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Reference, apsara.odps.ExpressionProtos.Reference.Builder, apsara.odps.ExpressionProtos.ReferenceOrBuilder> 
            getReferenceFieldBuilder() {
          if (referenceBuilder_ == null) {
            referenceBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                apsara.odps.ExpressionProtos.Reference, apsara.odps.ExpressionProtos.Reference.Builder, apsara.odps.ExpressionProtos.ReferenceOrBuilder>(
                    reference_,
                    getParentForChildren(),
                    isClean());
            reference_ = null;
          }
          return referenceBuilder_;
        }
        
        // optional .apsara.odps.Constant Constant = 2;
        private apsara.odps.ExpressionProtos.Constant constant_ = apsara.odps.ExpressionProtos.Constant.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Constant, apsara.odps.ExpressionProtos.Constant.Builder, apsara.odps.ExpressionProtos.ConstantOrBuilder> constantBuilder_;
        public boolean hasConstant() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public apsara.odps.ExpressionProtos.Constant getConstant() {
          if (constantBuilder_ == null) {
            return constant_;
          } else {
            return constantBuilder_.getMessage();
          }
        }
        public Builder setConstant(apsara.odps.ExpressionProtos.Constant value) {
          if (constantBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            constant_ = value;
            onChanged();
          } else {
            constantBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000002;
          return this;
        }
        public Builder setConstant(
            apsara.odps.ExpressionProtos.Constant.Builder builderForValue) {
          if (constantBuilder_ == null) {
            constant_ = builderForValue.build();
            onChanged();
          } else {
            constantBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000002;
          return this;
        }
        public Builder mergeConstant(apsara.odps.ExpressionProtos.Constant value) {
          if (constantBuilder_ == null) {
            if (((bitField0_ & 0x00000002) == 0x00000002) &&
                constant_ != apsara.odps.ExpressionProtos.Constant.getDefaultInstance()) {
              constant_ =
                apsara.odps.ExpressionProtos.Constant.newBuilder(constant_).mergeFrom(value).buildPartial();
            } else {
              constant_ = value;
            }
            onChanged();
          } else {
            constantBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000002;
          return this;
        }
        public Builder clearConstant() {
          if (constantBuilder_ == null) {
            constant_ = apsara.odps.ExpressionProtos.Constant.getDefaultInstance();
            onChanged();
          } else {
            constantBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000002);
          return this;
        }
        public apsara.odps.ExpressionProtos.Constant.Builder getConstantBuilder() {
          bitField0_ |= 0x00000002;
          onChanged();
          return getConstantFieldBuilder().getBuilder();
        }
        public apsara.odps.ExpressionProtos.ConstantOrBuilder getConstantOrBuilder() {
          if (constantBuilder_ != null) {
            return constantBuilder_.getMessageOrBuilder();
          } else {
            return constant_;
          }
        }
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Constant, apsara.odps.ExpressionProtos.Constant.Builder, apsara.odps.ExpressionProtos.ConstantOrBuilder> 
            getConstantFieldBuilder() {
          if (constantBuilder_ == null) {
            constantBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                apsara.odps.ExpressionProtos.Constant, apsara.odps.ExpressionProtos.Constant.Builder, apsara.odps.ExpressionProtos.ConstantOrBuilder>(
                    constant_,
                    getParentForChildren(),
                    isClean());
            constant_ = null;
          }
          return constantBuilder_;
        }
        
        // optional .apsara.odps.Null Null = 3;
        private apsara.odps.ExpressionProtos.Null null_ = apsara.odps.ExpressionProtos.Null.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Null, apsara.odps.ExpressionProtos.Null.Builder, apsara.odps.ExpressionProtos.NullOrBuilder> nullBuilder_;
        public boolean hasNull() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        public apsara.odps.ExpressionProtos.Null getNull() {
          if (nullBuilder_ == null) {
            return null_;
          } else {
            return nullBuilder_.getMessage();
          }
        }
        public Builder setNull(apsara.odps.ExpressionProtos.Null value) {
          if (nullBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            null_ = value;
            onChanged();
          } else {
            nullBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        public Builder setNull(
            apsara.odps.ExpressionProtos.Null.Builder builderForValue) {
          if (nullBuilder_ == null) {
            null_ = builderForValue.build();
            onChanged();
          } else {
            nullBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        public Builder mergeNull(apsara.odps.ExpressionProtos.Null value) {
          if (nullBuilder_ == null) {
            if (((bitField0_ & 0x00000004) == 0x00000004) &&
                null_ != apsara.odps.ExpressionProtos.Null.getDefaultInstance()) {
              null_ =
                apsara.odps.ExpressionProtos.Null.newBuilder(null_).mergeFrom(value).buildPartial();
            } else {
              null_ = value;
            }
            onChanged();
          } else {
            nullBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000004;
          return this;
        }
        public Builder clearNull() {
          if (nullBuilder_ == null) {
            null_ = apsara.odps.ExpressionProtos.Null.getDefaultInstance();
            onChanged();
          } else {
            nullBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000004);
          return this;
        }
        public apsara.odps.ExpressionProtos.Null.Builder getNullBuilder() {
          bitField0_ |= 0x00000004;
          onChanged();
          return getNullFieldBuilder().getBuilder();
        }
        public apsara.odps.ExpressionProtos.NullOrBuilder getNullOrBuilder() {
          if (nullBuilder_ != null) {
            return nullBuilder_.getMessageOrBuilder();
          } else {
            return null_;
          }
        }
        private com.google.protobuf.SingleFieldBuilder<
            apsara.odps.ExpressionProtos.Null, apsara.odps.ExpressionProtos.Null.Builder, apsara.odps.ExpressionProtos.NullOrBuilder> 
            getNullFieldBuilder() {
          if (nullBuilder_ == null) {
            nullBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                apsara.odps.ExpressionProtos.Null, apsara.odps.ExpressionProtos.Null.Builder, apsara.odps.ExpressionProtos.NullOrBuilder>(
                    null_,
                    getParentForChildren(),
                    isClean());
            null_ = null;
          }
          return nullBuilder_;
        }
        
        // optional .apsara.odps.lot.ScalarFunction Expression = 4;
        private ScalarFunction expression_ = ScalarFunction.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            ScalarFunction, ScalarFunction.Builder, ScalarFunctionOrBuilder> expressionBuilder_;
        public boolean hasExpression() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        public ScalarFunction getExpression() {
          if (expressionBuilder_ == null) {
            return expression_;
          } else {
            return expressionBuilder_.getMessage();
          }
        }
        public Builder setExpression(ScalarFunction value) {
          if (expressionBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            expression_ = value;
            onChanged();
          } else {
            expressionBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        public Builder setExpression(
            ScalarFunction.Builder builderForValue) {
          if (expressionBuilder_ == null) {
            expression_ = builderForValue.build();
            onChanged();
          } else {
            expressionBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        public Builder mergeExpression(ScalarFunction value) {
          if (expressionBuilder_ == null) {
            if (((bitField0_ & 0x00000008) == 0x00000008) &&
                expression_ != ScalarFunction.getDefaultInstance()) {
              expression_ =
                ScalarFunction.newBuilder(expression_).mergeFrom(value).buildPartial();
            } else {
              expression_ = value;
            }
            onChanged();
          } else {
            expressionBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000008;
          return this;
        }
        public Builder clearExpression() {
          if (expressionBuilder_ == null) {
            expression_ = ScalarFunction.getDefaultInstance();
            onChanged();
          } else {
            expressionBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }
        public ScalarFunction.Builder getExpressionBuilder() {
          bitField0_ |= 0x00000008;
          onChanged();
          return getExpressionFieldBuilder().getBuilder();
        }
        public ScalarFunctionOrBuilder getExpressionOrBuilder() {
          if (expressionBuilder_ != null) {
            return expressionBuilder_.getMessageOrBuilder();
          } else {
            return expression_;
          }
        }
        private com.google.protobuf.SingleFieldBuilder<
            ScalarFunction, ScalarFunction.Builder, ScalarFunctionOrBuilder>
            getExpressionFieldBuilder() {
          if (expressionBuilder_ == null) {
            expressionBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                ScalarFunction, ScalarFunction.Builder, ScalarFunctionOrBuilder>(
                    expression_,
                    getParentForChildren(),
                    isClean());
            expression_ = null;
          }
          return expressionBuilder_;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.ScalarExpression)
      }
      
      static {
        defaultInstance = new ScalarExpression(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.ScalarExpression)
    }
    
    public interface ScalarFunctionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // required string Project = 1;
      boolean hasProject();
      String getProject();
      
      // required string Name = 2;
      boolean hasName();
      String getName();
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
      java.util.List<ScalarExpression>
          getParametersList();
      ScalarExpression getParameters(int index);
      int getParametersCount();
      java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList();
      ScalarExpressionOrBuilder getParametersOrBuilder(
          int index);
      
      // optional bool requireBuiltin = 4 [default = false];
      boolean hasRequireBuiltin();
      boolean getRequireBuiltin();
    }
    public static final class ScalarFunction extends
        com.google.protobuf.GeneratedMessage
        implements ScalarFunctionOrBuilder {
      // Use ScalarFunction.newBuilder() to construct.
      private ScalarFunction(Builder builder) {
        super(builder);
      }
      private ScalarFunction(boolean noInit) {}
      
      private static final ScalarFunction defaultInstance;
      public static ScalarFunction getDefaultInstance() {
        return defaultInstance;
      }
      
      public ScalarFunction getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_ScalarFunction_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_ScalarFunction_fieldAccessorTable;
      }
      
      private int bitField0_;
      // required string Project = 1;
      public static final int PROJECT_FIELD_NUMBER = 1;
      private Object project_;
      public boolean hasProject() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public String getProject() {
        Object ref = project_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            project_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getProjectBytes() {
        Object ref = project_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          project_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required string Name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private Object name_;
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public String getName() {
        Object ref = name_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            name_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getNameBytes() {
        Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
      public static final int PARAMETERS_FIELD_NUMBER = 3;
      private java.util.List<ScalarExpression> parameters_;
      public java.util.List<ScalarExpression> getParametersList() {
        return parameters_;
      }
      public java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList() {
        return parameters_;
      }
      public int getParametersCount() {
        return parameters_.size();
      }
      public ScalarExpression getParameters(int index) {
        return parameters_.get(index);
      }
      public ScalarExpressionOrBuilder getParametersOrBuilder(
          int index) {
        return parameters_.get(index);
      }
      
      // optional bool requireBuiltin = 4 [default = false];
      public static final int REQUIREBUILTIN_FIELD_NUMBER = 4;
      private boolean requireBuiltin_;
      public boolean hasRequireBuiltin() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public boolean getRequireBuiltin() {
        return requireBuiltin_;
      }
      
      private void initFields() {
        project_ = "";
        name_ = "";
        parameters_ = java.util.Collections.emptyList();
        requireBuiltin_ = false;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (!hasProject()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getParametersCount(); i++) {
          if (!getParameters(i).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.writeBytes(1, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        for (int i = 0; i < parameters_.size(); i++) {
          output.writeMessage(3, parameters_.get(i));
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBool(4, requireBuiltin_);
        }
        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, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        for (int i = 0; i < parameters_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(3, parameters_.get(i));
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(4, requireBuiltin_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static ScalarFunction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static ScalarFunction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarFunction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static ScalarFunction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarFunction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static ScalarFunction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static ScalarFunction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static ScalarFunction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static ScalarFunction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static ScalarFunction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(ScalarFunction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements ScalarFunctionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_ScalarFunction_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_ScalarFunction_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.ScalarFunction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getParametersFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          project_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000004);
          } else {
            parametersBuilder_.clear();
          }
          requireBuiltin_ = false;
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return ScalarFunction.getDescriptor();
        }
        
        public ScalarFunction getDefaultInstanceForType() {
          return ScalarFunction.getDefaultInstance();
        }
        
        public ScalarFunction build() {
          ScalarFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private ScalarFunction buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          ScalarFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public ScalarFunction buildPartial() {
          ScalarFunction result = new ScalarFunction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.project_ = project_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (parametersBuilder_ == null) {
            if (((bitField0_ & 0x00000004) == 0x00000004)) {
              parameters_ = java.util.Collections.unmodifiableList(parameters_);
              bitField0_ = (bitField0_ & ~0x00000004);
            }
            result.parameters_ = parameters_;
          } else {
            result.parameters_ = parametersBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000004;
          }
          result.requireBuiltin_ = requireBuiltin_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof ScalarFunction) {
            return mergeFrom((ScalarFunction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(ScalarFunction other) {
          if (other == ScalarFunction.getDefaultInstance()) return this;
          if (other.hasProject()) {
            setProject(other.getProject());
          }
          if (other.hasName()) {
            setName(other.getName());
          }
          if (parametersBuilder_ == null) {
            if (!other.parameters_.isEmpty()) {
              if (parameters_.isEmpty()) {
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000004);
              } else {
                ensureParametersIsMutable();
                parameters_.addAll(other.parameters_);
              }
              onChanged();
            }
          } else {
            if (!other.parameters_.isEmpty()) {
              if (parametersBuilder_.isEmpty()) {
                parametersBuilder_.dispose();
                parametersBuilder_ = null;
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000004);
                parametersBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getParametersFieldBuilder() : null;
              } else {
                parametersBuilder_.addAllMessages(other.parameters_);
              }
            }
          }
          if (other.hasRequireBuiltin()) {
            setRequireBuiltin(other.getRequireBuiltin());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (!hasProject()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          for (int i = 0; i < getParametersCount(); i++) {
            if (!getParameters(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                project_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 26: {
                ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                input.readMessage(subBuilder, extensionRegistry);
                addParameters(subBuilder.buildPartial());
                break;
              }
              case 32: {
                bitField0_ |= 0x00000008;
                requireBuiltin_ = input.readBool();
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // required string Project = 1;
        private Object project_ = "";
        public boolean hasProject() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getProject() {
          Object ref = project_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            project_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setProject(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
          return this;
        }
        public Builder clearProject() {
          bitField0_ = (bitField0_ & ~0x00000001);
          project_ = getDefaultInstance().getProject();
          onChanged();
          return this;
        }
        void setProject(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
        }
        
        // required string Name = 2;
        private Object name_ = "";
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getName() {
          Object ref = name_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        void setName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
        }
        
        // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
        private java.util.List<ScalarExpression> parameters_ =
          java.util.Collections.emptyList();
        private void ensureParametersIsMutable() {
          if (!((bitField0_ & 0x00000004) == 0x00000004)) {
            parameters_ = new java.util.ArrayList<ScalarExpression>(parameters_);
            bitField0_ |= 0x00000004;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> parametersBuilder_;
        
        public java.util.List<ScalarExpression> getParametersList() {
          if (parametersBuilder_ == null) {
            return java.util.Collections.unmodifiableList(parameters_);
          } else {
            return parametersBuilder_.getMessageList();
          }
        }
        public int getParametersCount() {
          if (parametersBuilder_ == null) {
            return parameters_.size();
          } else {
            return parametersBuilder_.getCount();
          }
        }
        public ScalarExpression getParameters(int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);
          } else {
            return parametersBuilder_.getMessage(index);
          }
        }
        public Builder setParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.set(index, value);
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.set(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(index, value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addParameters(
            ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllParameters(
            Iterable<? extends ScalarExpression> values) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            super.addAll(values, parameters_);
            onChanged();
          } else {
            parametersBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearParameters() {
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000004);
            onChanged();
          } else {
            parametersBuilder_.clear();
          }
          return this;
        }
        public Builder removeParameters(int index) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.remove(index);
            onChanged();
          } else {
            parametersBuilder_.remove(index);
          }
          return this;
        }
        public ScalarExpression.Builder getParametersBuilder(
            int index) {
          return getParametersFieldBuilder().getBuilder(index);
        }
        public ScalarExpressionOrBuilder getParametersOrBuilder(
            int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);  } else {
            return parametersBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ScalarExpressionOrBuilder>
             getParametersOrBuilderList() {
          if (parametersBuilder_ != null) {
            return parametersBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(parameters_);
          }
        }
        public ScalarExpression.Builder addParametersBuilder() {
          return getParametersFieldBuilder().addBuilder(
              ScalarExpression.getDefaultInstance());
        }
        public ScalarExpression.Builder addParametersBuilder(
            int index) {
          return getParametersFieldBuilder().addBuilder(
              index, ScalarExpression.getDefaultInstance());
        }
        public java.util.List<ScalarExpression.Builder>
             getParametersBuilderList() {
          return getParametersFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
            getParametersFieldBuilder() {
          if (parametersBuilder_ == null) {
            parametersBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                    parameters_,
                    ((bitField0_ & 0x00000004) == 0x00000004),
                    getParentForChildren(),
                    isClean());
            parameters_ = null;
          }
          return parametersBuilder_;
        }
        
        // optional bool requireBuiltin = 4 [default = false];
        private boolean requireBuiltin_ ;
        public boolean hasRequireBuiltin() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        public boolean getRequireBuiltin() {
          return requireBuiltin_;
        }
        public Builder setRequireBuiltin(boolean value) {
          bitField0_ |= 0x00000008;
          requireBuiltin_ = value;
          onChanged();
          return this;
        }
        public Builder clearRequireBuiltin() {
          bitField0_ = (bitField0_ & ~0x00000008);
          requireBuiltin_ = false;
          onChanged();
          return this;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.ScalarFunction)
      }
      
      static {
        defaultInstance = new ScalarFunction(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.ScalarFunction)
    }
    
    public interface AggregationFunctionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // required string Project = 1;
      boolean hasProject();
      String getProject();
      
      // required string Name = 2;
      boolean hasName();
      String getName();
      
      // required bool IsDistinct = 3;
      boolean hasIsDistinct();
      boolean getIsDistinct();
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
      java.util.List<ScalarExpression>
          getParametersList();
      ScalarExpression getParameters(int index);
      int getParametersCount();
      java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList();
      ScalarExpressionOrBuilder getParametersOrBuilder(
          int index);
      
      // optional bool requireBuiltin = 5 [default = false];
      boolean hasRequireBuiltin();
      boolean getRequireBuiltin();
    }
    public static final class AggregationFunction extends
        com.google.protobuf.GeneratedMessage
        implements AggregationFunctionOrBuilder {
      // Use AggregationFunction.newBuilder() to construct.
      private AggregationFunction(Builder builder) {
        super(builder);
      }
      private AggregationFunction(boolean noInit) {}
      
      private static final AggregationFunction defaultInstance;
      public static AggregationFunction getDefaultInstance() {
        return defaultInstance;
      }
      
      public AggregationFunction getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_AggregationFunction_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_AggregationFunction_fieldAccessorTable;
      }
      
      private int bitField0_;
      // required string Project = 1;
      public static final int PROJECT_FIELD_NUMBER = 1;
      private Object project_;
      public boolean hasProject() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public String getProject() {
        Object ref = project_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            project_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getProjectBytes() {
        Object ref = project_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          project_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required string Name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private Object name_;
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public String getName() {
        Object ref = name_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            name_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getNameBytes() {
        Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required bool IsDistinct = 3;
      public static final int ISDISTINCT_FIELD_NUMBER = 3;
      private boolean isDistinct_;
      public boolean hasIsDistinct() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public boolean getIsDistinct() {
        return isDistinct_;
      }
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
      public static final int PARAMETERS_FIELD_NUMBER = 4;
      private java.util.List<ScalarExpression> parameters_;
      public java.util.List<ScalarExpression> getParametersList() {
        return parameters_;
      }
      public java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList() {
        return parameters_;
      }
      public int getParametersCount() {
        return parameters_.size();
      }
      public ScalarExpression getParameters(int index) {
        return parameters_.get(index);
      }
      public ScalarExpressionOrBuilder getParametersOrBuilder(
          int index) {
        return parameters_.get(index);
      }
      
      // optional bool requireBuiltin = 5 [default = false];
      public static final int REQUIREBUILTIN_FIELD_NUMBER = 5;
      private boolean requireBuiltin_;
      public boolean hasRequireBuiltin() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      public boolean getRequireBuiltin() {
        return requireBuiltin_;
      }
      
      private void initFields() {
        project_ = "";
        name_ = "";
        isDistinct_ = false;
        parameters_ = java.util.Collections.emptyList();
        requireBuiltin_ = false;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (!hasProject()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasIsDistinct()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getParametersCount(); i++) {
          if (!getParameters(i).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.writeBytes(1, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBool(3, isDistinct_);
        }
        for (int i = 0; i < parameters_.size(); i++) {
          output.writeMessage(4, parameters_.get(i));
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeBool(5, requireBuiltin_);
        }
        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, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(3, isDistinct_);
        }
        for (int i = 0; i < parameters_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(4, parameters_.get(i));
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(5, requireBuiltin_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static AggregationFunction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static AggregationFunction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static AggregationFunction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static AggregationFunction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static AggregationFunction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static AggregationFunction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static AggregationFunction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static AggregationFunction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static AggregationFunction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static AggregationFunction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(AggregationFunction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements AggregationFunctionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_AggregationFunction_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_AggregationFunction_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.AggregationFunction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getParametersFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          project_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          isDistinct_ = false;
          bitField0_ = (bitField0_ & ~0x00000004);
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
          } else {
            parametersBuilder_.clear();
          }
          requireBuiltin_ = false;
          bitField0_ = (bitField0_ & ~0x00000010);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return AggregationFunction.getDescriptor();
        }
        
        public AggregationFunction getDefaultInstanceForType() {
          return AggregationFunction.getDefaultInstance();
        }
        
        public AggregationFunction build() {
          AggregationFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private AggregationFunction buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          AggregationFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public AggregationFunction buildPartial() {
          AggregationFunction result = new AggregationFunction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.project_ = project_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.isDistinct_ = isDistinct_;
          if (parametersBuilder_ == null) {
            if (((bitField0_ & 0x00000008) == 0x00000008)) {
              parameters_ = java.util.Collections.unmodifiableList(parameters_);
              bitField0_ = (bitField0_ & ~0x00000008);
            }
            result.parameters_ = parameters_;
          } else {
            result.parameters_ = parametersBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000010) == 0x00000010)) {
            to_bitField0_ |= 0x00000008;
          }
          result.requireBuiltin_ = requireBuiltin_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof AggregationFunction) {
            return mergeFrom((AggregationFunction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(AggregationFunction other) {
          if (other == AggregationFunction.getDefaultInstance()) return this;
          if (other.hasProject()) {
            setProject(other.getProject());
          }
          if (other.hasName()) {
            setName(other.getName());
          }
          if (other.hasIsDistinct()) {
            setIsDistinct(other.getIsDistinct());
          }
          if (parametersBuilder_ == null) {
            if (!other.parameters_.isEmpty()) {
              if (parameters_.isEmpty()) {
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000008);
              } else {
                ensureParametersIsMutable();
                parameters_.addAll(other.parameters_);
              }
              onChanged();
            }
          } else {
            if (!other.parameters_.isEmpty()) {
              if (parametersBuilder_.isEmpty()) {
                parametersBuilder_.dispose();
                parametersBuilder_ = null;
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000008);
                parametersBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getParametersFieldBuilder() : null;
              } else {
                parametersBuilder_.addAllMessages(other.parameters_);
              }
            }
          }
          if (other.hasRequireBuiltin()) {
            setRequireBuiltin(other.getRequireBuiltin());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (!hasProject()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          if (!hasIsDistinct()) {
            
            return false;
          }
          for (int i = 0; i < getParametersCount(); i++) {
            if (!getParameters(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                project_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 24: {
                bitField0_ |= 0x00000004;
                isDistinct_ = input.readBool();
                break;
              }
              case 34: {
                ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                input.readMessage(subBuilder, extensionRegistry);
                addParameters(subBuilder.buildPartial());
                break;
              }
              case 40: {
                bitField0_ |= 0x00000010;
                requireBuiltin_ = input.readBool();
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // required string Project = 1;
        private Object project_ = "";
        public boolean hasProject() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getProject() {
          Object ref = project_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            project_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setProject(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
          return this;
        }
        public Builder clearProject() {
          bitField0_ = (bitField0_ & ~0x00000001);
          project_ = getDefaultInstance().getProject();
          onChanged();
          return this;
        }
        void setProject(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
        }
        
        // required string Name = 2;
        private Object name_ = "";
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getName() {
          Object ref = name_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        void setName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
        }
        
        // required bool IsDistinct = 3;
        private boolean isDistinct_ ;
        public boolean hasIsDistinct() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        public boolean getIsDistinct() {
          return isDistinct_;
        }
        public Builder setIsDistinct(boolean value) {
          bitField0_ |= 0x00000004;
          isDistinct_ = value;
          onChanged();
          return this;
        }
        public Builder clearIsDistinct() {
          bitField0_ = (bitField0_ & ~0x00000004);
          isDistinct_ = false;
          onChanged();
          return this;
        }
        
        // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
        private java.util.List<ScalarExpression> parameters_ =
          java.util.Collections.emptyList();
        private void ensureParametersIsMutable() {
          if (!((bitField0_ & 0x00000008) == 0x00000008)) {
            parameters_ = new java.util.ArrayList<ScalarExpression>(parameters_);
            bitField0_ |= 0x00000008;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> parametersBuilder_;
        
        public java.util.List<ScalarExpression> getParametersList() {
          if (parametersBuilder_ == null) {
            return java.util.Collections.unmodifiableList(parameters_);
          } else {
            return parametersBuilder_.getMessageList();
          }
        }
        public int getParametersCount() {
          if (parametersBuilder_ == null) {
            return parameters_.size();
          } else {
            return parametersBuilder_.getCount();
          }
        }
        public ScalarExpression getParameters(int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);
          } else {
            return parametersBuilder_.getMessage(index);
          }
        }
        public Builder setParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.set(index, value);
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.set(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(index, value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addParameters(
            ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllParameters(
            Iterable<? extends ScalarExpression> values) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            super.addAll(values, parameters_);
            onChanged();
          } else {
            parametersBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearParameters() {
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
            onChanged();
          } else {
            parametersBuilder_.clear();
          }
          return this;
        }
        public Builder removeParameters(int index) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.remove(index);
            onChanged();
          } else {
            parametersBuilder_.remove(index);
          }
          return this;
        }
        public ScalarExpression.Builder getParametersBuilder(
            int index) {
          return getParametersFieldBuilder().getBuilder(index);
        }
        public ScalarExpressionOrBuilder getParametersOrBuilder(
            int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);  } else {
            return parametersBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ScalarExpressionOrBuilder>
             getParametersOrBuilderList() {
          if (parametersBuilder_ != null) {
            return parametersBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(parameters_);
          }
        }
        public ScalarExpression.Builder addParametersBuilder() {
          return getParametersFieldBuilder().addBuilder(
              ScalarExpression.getDefaultInstance());
        }
        public ScalarExpression.Builder addParametersBuilder(
            int index) {
          return getParametersFieldBuilder().addBuilder(
              index, ScalarExpression.getDefaultInstance());
        }
        public java.util.List<ScalarExpression.Builder>
             getParametersBuilderList() {
          return getParametersFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
            getParametersFieldBuilder() {
          if (parametersBuilder_ == null) {
            parametersBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                    parameters_,
                    ((bitField0_ & 0x00000008) == 0x00000008),
                    getParentForChildren(),
                    isClean());
            parameters_ = null;
          }
          return parametersBuilder_;
        }
        
        // optional bool requireBuiltin = 5 [default = false];
        private boolean requireBuiltin_ ;
        public boolean hasRequireBuiltin() {
          return ((bitField0_ & 0x00000010) == 0x00000010);
        }
        public boolean getRequireBuiltin() {
          return requireBuiltin_;
        }
        public Builder setRequireBuiltin(boolean value) {
          bitField0_ |= 0x00000010;
          requireBuiltin_ = value;
          onChanged();
          return this;
        }
        public Builder clearRequireBuiltin() {
          bitField0_ = (bitField0_ & ~0x00000010);
          requireBuiltin_ = false;
          onChanged();
          return this;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.AggregationFunction)
      }
      
      static {
        defaultInstance = new AggregationFunction(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.AggregationFunction)
    }
    
    public interface WindowFunctionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // required string Project = 1;
      boolean hasProject();
      String getProject();
      
      // required string Name = 2;
      boolean hasName();
      String getName();
      
      // optional bool IsDistinct = 3;
      boolean hasIsDistinct();
      boolean getIsDistinct();
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
      java.util.List<ScalarExpression>
          getParametersList();
      ScalarExpression getParameters(int index);
      int getParametersCount();
      java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList();
      ScalarExpressionOrBuilder getParametersOrBuilder(
          int index);
      
      // repeated .apsara.odps.lot.ScalarExpression PartitionBy = 5;
      java.util.List<ScalarExpression>
          getPartitionByList();
      ScalarExpression getPartitionBy(int index);
      int getPartitionByCount();
      java.util.List<? extends ScalarExpressionOrBuilder>
          getPartitionByOrBuilderList();
      ScalarExpressionOrBuilder getPartitionByOrBuilder(
          int index);
      
      // repeated group OrderBy = 6 {
      java.util.List<WindowFunction.OrderBy>
          getOrderByList();
      WindowFunction.OrderBy getOrderBy(int index);
      int getOrderByCount();
      java.util.List<? extends WindowFunction.OrderByOrBuilder>
          getOrderByOrBuilderList();
      WindowFunction.OrderByOrBuilder getOrderByOrBuilder(
          int index);
      
      // optional group WindowingClause = 7 {
      boolean hasWindowingClause();
      WindowFunction.WindowingClause getWindowingClause();
      WindowFunction.WindowingClauseOrBuilder getWindowingClauseOrBuilder();
      
      // optional bool requireBuiltin = 8 [default = false];
      boolean hasRequireBuiltin();
      boolean getRequireBuiltin();
    }
    public static final class WindowFunction extends
        com.google.protobuf.GeneratedMessage
        implements WindowFunctionOrBuilder {
      // Use WindowFunction.newBuilder() to construct.
      private WindowFunction(Builder builder) {
        super(builder);
      }
      private WindowFunction(boolean noInit) {}
      
      private static final WindowFunction defaultInstance;
      public static WindowFunction getDefaultInstance() {
        return defaultInstance;
      }
      
      public WindowFunction getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_fieldAccessorTable;
      }
      
      public interface OrderByOrBuilder
          extends com.google.protobuf.MessageOrBuilder {
        
        // required .apsara.odps.lot.ScalarExpression Expression = 1;
        boolean hasExpression();
        ScalarExpression getExpression();
        ScalarExpressionOrBuilder getExpressionOrBuilder();
        
        // optional bool IsAsc = 2 [default = true];
        boolean hasIsAsc();
        boolean getIsAsc();
      }
      public static final class OrderBy extends
          com.google.protobuf.GeneratedMessage
          implements OrderByOrBuilder {
        // Use OrderBy.newBuilder() to construct.
        private OrderBy(Builder builder) {
          super(builder);
        }
        private OrderBy(boolean noInit) {}
        
        private static final OrderBy defaultInstance;
        public static OrderBy getDefaultInstance() {
          return defaultInstance;
        }
        
        public OrderBy getDefaultInstanceForType() {
          return defaultInstance;
        }
        
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_OrderBy_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_OrderBy_fieldAccessorTable;
        }
        
        private int bitField0_;
        // required .apsara.odps.lot.ScalarExpression Expression = 1;
        public static final int EXPRESSION_FIELD_NUMBER = 1;
        private ScalarExpression expression_;
        public boolean hasExpression() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public ScalarExpression getExpression() {
          return expression_;
        }
        public ScalarExpressionOrBuilder getExpressionOrBuilder() {
          return expression_;
        }
        
        // optional bool IsAsc = 2 [default = true];
        public static final int ISASC_FIELD_NUMBER = 2;
        private boolean isAsc_;
        public boolean hasIsAsc() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public boolean getIsAsc() {
          return isAsc_;
        }
        
        private void initFields() {
          expression_ = ScalarExpression.getDefaultInstance();
          isAsc_ = true;
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;
          
          if (!hasExpression()) {
            memoizedIsInitialized = 0;
            return false;
          }
          if (!getExpression().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, expression_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeBool(2, isAsc_);
          }
          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, expression_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBoolSize(2, isAsc_);
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }
        
        private static final long serialVersionUID = 0L;
        @Override
        protected Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }
        
        public static OrderBy parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static OrderBy parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static OrderBy parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static OrderBy parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static OrderBy parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static OrderBy parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        public static OrderBy parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static OrderBy parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static OrderBy parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static OrderBy parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        
        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(OrderBy prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }
        
        @Override
        protected Builder newBuilderForType(
            BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements OrderByOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_OrderBy_descriptor;
          }
          
          protected FieldAccessorTable
              internalGetFieldAccessorTable() {
            return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_OrderBy_fieldAccessorTable;
          }
          
          // Construct using apsara.odps.lot.ExpressionProtos.WindowFunction.OrderBy.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }
          
          private Builder(BuilderParent parent) {
            super(parent);
            maybeForceBuilderInitialization();
          }
          private void maybeForceBuilderInitialization() {
            if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
              getExpressionFieldBuilder();
            }
          }
          private static Builder create() {
            return new Builder();
          }
          
          public Builder clear() {
            super.clear();
            if (expressionBuilder_ == null) {
              expression_ = ScalarExpression.getDefaultInstance();
            } else {
              expressionBuilder_.clear();
            }
            bitField0_ = (bitField0_ & ~0x00000001);
            isAsc_ = true;
            bitField0_ = (bitField0_ & ~0x00000002);
            return this;
          }
          
          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }
          
          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return OrderBy.getDescriptor();
          }
          
          public OrderBy getDefaultInstanceForType() {
            return OrderBy.getDefaultInstance();
          }
          
          public OrderBy build() {
            OrderBy result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }
          
          private OrderBy buildParsed()
              throws com.google.protobuf.InvalidProtocolBufferException {
            OrderBy result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(
                result).asInvalidProtocolBufferException();
            }
            return result;
          }
          
          public OrderBy buildPartial() {
            OrderBy result = new OrderBy(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            if (expressionBuilder_ == null) {
              result.expression_ = expression_;
            } else {
              result.expression_ = expressionBuilder_.build();
            }
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.isAsc_ = isAsc_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }
          
          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof OrderBy) {
              return mergeFrom((OrderBy)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }
          
          public Builder mergeFrom(OrderBy other) {
            if (other == OrderBy.getDefaultInstance()) return this;
            if (other.hasExpression()) {
              mergeExpression(other.getExpression());
            }
            if (other.hasIsAsc()) {
              setIsAsc(other.getIsAsc());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }
          
          public final boolean isInitialized() {
            if (!hasExpression()) {
              
              return false;
            }
            if (!getExpression().isInitialized()) {
              
              return false;
            }
            return true;
          }
          
          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder(
                this.getUnknownFields());
            while (true) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    this.setUnknownFields(unknownFields.build());
                    onChanged();
                    return this;
                  }
                  break;
                }
                case 10: {
                  ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                  if (hasExpression()) {
                    subBuilder.mergeFrom(getExpression());
                  }
                  input.readMessage(subBuilder, extensionRegistry);
                  setExpression(subBuilder.buildPartial());
                  break;
                }
                case 16: {
                  bitField0_ |= 0x00000002;
                  isAsc_ = input.readBool();
                  break;
                }
              }
            }
          }
          
          private int bitField0_;
          
          // required .apsara.odps.lot.ScalarExpression Expression = 1;
          private ScalarExpression expression_ = ScalarExpression.getDefaultInstance();
          private com.google.protobuf.SingleFieldBuilder<
              ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> expressionBuilder_;
          public boolean hasExpression() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          public ScalarExpression getExpression() {
            if (expressionBuilder_ == null) {
              return expression_;
            } else {
              return expressionBuilder_.getMessage();
            }
          }
          public Builder setExpression(ScalarExpression value) {
            if (expressionBuilder_ == null) {
              if (value == null) {
                throw new NullPointerException();
              }
              expression_ = value;
              onChanged();
            } else {
              expressionBuilder_.setMessage(value);
            }
            bitField0_ |= 0x00000001;
            return this;
          }
          public Builder setExpression(
              ScalarExpression.Builder builderForValue) {
            if (expressionBuilder_ == null) {
              expression_ = builderForValue.build();
              onChanged();
            } else {
              expressionBuilder_.setMessage(builderForValue.build());
            }
            bitField0_ |= 0x00000001;
            return this;
          }
          public Builder mergeExpression(ScalarExpression value) {
            if (expressionBuilder_ == null) {
              if (((bitField0_ & 0x00000001) == 0x00000001) &&
                  expression_ != ScalarExpression.getDefaultInstance()) {
                expression_ =
                  ScalarExpression.newBuilder(expression_).mergeFrom(value).buildPartial();
              } else {
                expression_ = value;
              }
              onChanged();
            } else {
              expressionBuilder_.mergeFrom(value);
            }
            bitField0_ |= 0x00000001;
            return this;
          }
          public Builder clearExpression() {
            if (expressionBuilder_ == null) {
              expression_ = ScalarExpression.getDefaultInstance();
              onChanged();
            } else {
              expressionBuilder_.clear();
            }
            bitField0_ = (bitField0_ & ~0x00000001);
            return this;
          }
          public ScalarExpression.Builder getExpressionBuilder() {
            bitField0_ |= 0x00000001;
            onChanged();
            return getExpressionFieldBuilder().getBuilder();
          }
          public ScalarExpressionOrBuilder getExpressionOrBuilder() {
            if (expressionBuilder_ != null) {
              return expressionBuilder_.getMessageOrBuilder();
            } else {
              return expression_;
            }
          }
          private com.google.protobuf.SingleFieldBuilder<
              ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
              getExpressionFieldBuilder() {
            if (expressionBuilder_ == null) {
              expressionBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                  ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                      expression_,
                      getParentForChildren(),
                      isClean());
              expression_ = null;
            }
            return expressionBuilder_;
          }
          
          // optional bool IsAsc = 2 [default = true];
          private boolean isAsc_ = true;
          public boolean hasIsAsc() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          public boolean getIsAsc() {
            return isAsc_;
          }
          public Builder setIsAsc(boolean value) {
            bitField0_ |= 0x00000002;
            isAsc_ = value;
            onChanged();
            return this;
          }
          public Builder clearIsAsc() {
            bitField0_ = (bitField0_ & ~0x00000002);
            isAsc_ = true;
            onChanged();
            return this;
          }
          
          // @@protoc_insertion_point(builder_scope:apsara.odps.lot.WindowFunction.OrderBy)
        }
        
        static {
          defaultInstance = new OrderBy(true);
          defaultInstance.initFields();
        }
        
        // @@protoc_insertion_point(class_scope:apsara.odps.lot.WindowFunction.OrderBy)
      }
      
      public interface WindowingClauseOrBuilder
          extends com.google.protobuf.MessageOrBuilder {
        
        // required int32 Begin = 1;
        boolean hasBegin();
        int getBegin();
        
        // required int32 End = 2;
        boolean hasEnd();
        int getEnd();
      }
      public static final class WindowingClause extends
          com.google.protobuf.GeneratedMessage
          implements WindowingClauseOrBuilder {
        // Use WindowingClause.newBuilder() to construct.
        private WindowingClause(Builder builder) {
          super(builder);
        }
        private WindowingClause(boolean noInit) {}
        
        private static final WindowingClause defaultInstance;
        public static WindowingClause getDefaultInstance() {
          return defaultInstance;
        }
        
        public WindowingClause getDefaultInstanceForType() {
          return defaultInstance;
        }
        
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_WindowingClause_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_WindowingClause_fieldAccessorTable;
        }
        
        private int bitField0_;
        // required int32 Begin = 1;
        public static final int BEGIN_FIELD_NUMBER = 1;
        private int begin_;
        public boolean hasBegin() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public int getBegin() {
          return begin_;
        }
        
        // required int32 End = 2;
        public static final int END_FIELD_NUMBER = 2;
        private int end_;
        public boolean hasEnd() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public int getEnd() {
          return end_;
        }
        
        private void initFields() {
          begin_ = 0;
          end_ = 0;
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;
          
          if (!hasBegin()) {
            memoizedIsInitialized = 0;
            return false;
          }
          if (!hasEnd()) {
            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.writeInt32(1, begin_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeInt32(2, end_);
          }
          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
              .computeInt32Size(1, begin_);
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeInt32Size(2, end_);
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }
        
        private static final long serialVersionUID = 0L;
        @Override
        protected Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }
        
        public static WindowingClause parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static WindowingClause parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static WindowingClause parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static WindowingClause parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static WindowingClause parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static WindowingClause parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        public static WindowingClause parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static WindowingClause parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static WindowingClause parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static WindowingClause parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        
        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(WindowingClause prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }
        
        @Override
        protected Builder newBuilderForType(
            BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements WindowingClauseOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_WindowingClause_descriptor;
          }
          
          protected FieldAccessorTable
              internalGetFieldAccessorTable() {
            return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_WindowingClause_fieldAccessorTable;
          }
          
          // Construct using apsara.odps.lot.ExpressionProtos.WindowFunction.WindowingClause.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }
          
          private Builder(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();
            begin_ = 0;
            bitField0_ = (bitField0_ & ~0x00000001);
            end_ = 0;
            bitField0_ = (bitField0_ & ~0x00000002);
            return this;
          }
          
          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }
          
          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return WindowingClause.getDescriptor();
          }
          
          public WindowingClause getDefaultInstanceForType() {
            return WindowingClause.getDefaultInstance();
          }
          
          public WindowingClause build() {
            WindowingClause result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }
          
          private WindowingClause buildParsed()
              throws com.google.protobuf.InvalidProtocolBufferException {
            WindowingClause result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(
                result).asInvalidProtocolBufferException();
            }
            return result;
          }
          
          public WindowingClause buildPartial() {
            WindowingClause result = new WindowingClause(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            result.begin_ = begin_;
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.end_ = end_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }
          
          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof WindowingClause) {
              return mergeFrom((WindowingClause)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }
          
          public Builder mergeFrom(WindowingClause other) {
            if (other == WindowingClause.getDefaultInstance()) return this;
            if (other.hasBegin()) {
              setBegin(other.getBegin());
            }
            if (other.hasEnd()) {
              setEnd(other.getEnd());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }
          
          public final boolean isInitialized() {
            if (!hasBegin()) {
              
              return false;
            }
            if (!hasEnd()) {
              
              return false;
            }
            return true;
          }
          
          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder(
                this.getUnknownFields());
            while (true) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    this.setUnknownFields(unknownFields.build());
                    onChanged();
                    return this;
                  }
                  break;
                }
                case 8: {
                  bitField0_ |= 0x00000001;
                  begin_ = input.readInt32();
                  break;
                }
                case 16: {
                  bitField0_ |= 0x00000002;
                  end_ = input.readInt32();
                  break;
                }
              }
            }
          }
          
          private int bitField0_;
          
          // required int32 Begin = 1;
          private int begin_ ;
          public boolean hasBegin() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          public int getBegin() {
            return begin_;
          }
          public Builder setBegin(int value) {
            bitField0_ |= 0x00000001;
            begin_ = value;
            onChanged();
            return this;
          }
          public Builder clearBegin() {
            bitField0_ = (bitField0_ & ~0x00000001);
            begin_ = 0;
            onChanged();
            return this;
          }
          
          // required int32 End = 2;
          private int end_ ;
          public boolean hasEnd() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          public int getEnd() {
            return end_;
          }
          public Builder setEnd(int value) {
            bitField0_ |= 0x00000002;
            end_ = value;
            onChanged();
            return this;
          }
          public Builder clearEnd() {
            bitField0_ = (bitField0_ & ~0x00000002);
            end_ = 0;
            onChanged();
            return this;
          }
          
          // @@protoc_insertion_point(builder_scope:apsara.odps.lot.WindowFunction.WindowingClause)
        }
        
        static {
          defaultInstance = new WindowingClause(true);
          defaultInstance.initFields();
        }
        
        // @@protoc_insertion_point(class_scope:apsara.odps.lot.WindowFunction.WindowingClause)
      }
      
      private int bitField0_;
      // required string Project = 1;
      public static final int PROJECT_FIELD_NUMBER = 1;
      private Object project_;
      public boolean hasProject() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public String getProject() {
        Object ref = project_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            project_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getProjectBytes() {
        Object ref = project_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          project_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required string Name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private Object name_;
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public String getName() {
        Object ref = name_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            name_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getNameBytes() {
        Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // optional bool IsDistinct = 3;
      public static final int ISDISTINCT_FIELD_NUMBER = 3;
      private boolean isDistinct_;
      public boolean hasIsDistinct() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public boolean getIsDistinct() {
        return isDistinct_;
      }
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
      public static final int PARAMETERS_FIELD_NUMBER = 4;
      private java.util.List<ScalarExpression> parameters_;
      public java.util.List<ScalarExpression> getParametersList() {
        return parameters_;
      }
      public java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList() {
        return parameters_;
      }
      public int getParametersCount() {
        return parameters_.size();
      }
      public ScalarExpression getParameters(int index) {
        return parameters_.get(index);
      }
      public ScalarExpressionOrBuilder getParametersOrBuilder(
          int index) {
        return parameters_.get(index);
      }
      
      // repeated .apsara.odps.lot.ScalarExpression PartitionBy = 5;
      public static final int PARTITIONBY_FIELD_NUMBER = 5;
      private java.util.List<ScalarExpression> partitionBy_;
      public java.util.List<ScalarExpression> getPartitionByList() {
        return partitionBy_;
      }
      public java.util.List<? extends ScalarExpressionOrBuilder>
          getPartitionByOrBuilderList() {
        return partitionBy_;
      }
      public int getPartitionByCount() {
        return partitionBy_.size();
      }
      public ScalarExpression getPartitionBy(int index) {
        return partitionBy_.get(index);
      }
      public ScalarExpressionOrBuilder getPartitionByOrBuilder(
          int index) {
        return partitionBy_.get(index);
      }
      
      // repeated group OrderBy = 6 {
      public static final int ORDERBY_FIELD_NUMBER = 6;
      private java.util.List<OrderBy> orderBy_;
      public java.util.List<OrderBy> getOrderByList() {
        return orderBy_;
      }
      public java.util.List<? extends OrderByOrBuilder>
          getOrderByOrBuilderList() {
        return orderBy_;
      }
      public int getOrderByCount() {
        return orderBy_.size();
      }
      public OrderBy getOrderBy(int index) {
        return orderBy_.get(index);
      }
      public OrderByOrBuilder getOrderByOrBuilder(
          int index) {
        return orderBy_.get(index);
      }
      
      // optional group WindowingClause = 7 {
      public static final int WINDOWINGCLAUSE_FIELD_NUMBER = 7;
      private WindowingClause windowingClause_;
      public boolean hasWindowingClause() {
        return ((bitField0_ & 0x00000008) == 0x00000008);
      }
      public WindowingClause getWindowingClause() {
        return windowingClause_;
      }
      public WindowingClauseOrBuilder getWindowingClauseOrBuilder() {
        return windowingClause_;
      }
      
      // optional bool requireBuiltin = 8 [default = false];
      public static final int REQUIREBUILTIN_FIELD_NUMBER = 8;
      private boolean requireBuiltin_;
      public boolean hasRequireBuiltin() {
        return ((bitField0_ & 0x00000010) == 0x00000010);
      }
      public boolean getRequireBuiltin() {
        return requireBuiltin_;
      }
      
      private void initFields() {
        project_ = "";
        name_ = "";
        isDistinct_ = false;
        parameters_ = java.util.Collections.emptyList();
        partitionBy_ = java.util.Collections.emptyList();
        orderBy_ = java.util.Collections.emptyList();
        windowingClause_ = WindowingClause.getDefaultInstance();
        requireBuiltin_ = false;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (!hasProject()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getParametersCount(); i++) {
          if (!getParameters(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        for (int i = 0; i < getPartitionByCount(); i++) {
          if (!getPartitionBy(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        for (int i = 0; i < getOrderByCount(); i++) {
          if (!getOrderBy(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        if (hasWindowingClause()) {
          if (!getWindowingClause().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.writeBytes(1, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBool(3, isDistinct_);
        }
        for (int i = 0; i < parameters_.size(); i++) {
          output.writeMessage(4, parameters_.get(i));
        }
        for (int i = 0; i < partitionBy_.size(); i++) {
          output.writeMessage(5, partitionBy_.get(i));
        }
        for (int i = 0; i < orderBy_.size(); i++) {
          output.writeGroup(6, orderBy_.get(i));
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          output.writeGroup(7, windowingClause_);
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          output.writeBool(8, requireBuiltin_);
        }
        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, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(3, isDistinct_);
        }
        for (int i = 0; i < parameters_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(4, parameters_.get(i));
        }
        for (int i = 0; i < partitionBy_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(5, partitionBy_.get(i));
        }
        for (int i = 0; i < orderBy_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeGroupSize(6, orderBy_.get(i));
        }
        if (((bitField0_ & 0x00000008) == 0x00000008)) {
          size += com.google.protobuf.CodedOutputStream
            .computeGroupSize(7, windowingClause_);
        }
        if (((bitField0_ & 0x00000010) == 0x00000010)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(8, requireBuiltin_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static WindowFunction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static WindowFunction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static WindowFunction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static WindowFunction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static WindowFunction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static WindowFunction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static WindowFunction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static WindowFunction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static WindowFunction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static WindowFunction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(WindowFunction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements WindowFunctionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_WindowFunction_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.WindowFunction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getParametersFieldBuilder();
            getPartitionByFieldBuilder();
            getOrderByFieldBuilder();
            getWindowingClauseFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          project_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          isDistinct_ = false;
          bitField0_ = (bitField0_ & ~0x00000004);
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
          } else {
            parametersBuilder_.clear();
          }
          if (partitionByBuilder_ == null) {
            partitionBy_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000010);
          } else {
            partitionByBuilder_.clear();
          }
          if (orderByBuilder_ == null) {
            orderBy_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000020);
          } else {
            orderByBuilder_.clear();
          }
          if (windowingClauseBuilder_ == null) {
            windowingClause_ = WindowingClause.getDefaultInstance();
          } else {
            windowingClauseBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000040);
          requireBuiltin_ = false;
          bitField0_ = (bitField0_ & ~0x00000080);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return WindowFunction.getDescriptor();
        }
        
        public WindowFunction getDefaultInstanceForType() {
          return WindowFunction.getDefaultInstance();
        }
        
        public WindowFunction build() {
          WindowFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private WindowFunction buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          WindowFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public WindowFunction buildPartial() {
          WindowFunction result = new WindowFunction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.project_ = project_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000004;
          }
          result.isDistinct_ = isDistinct_;
          if (parametersBuilder_ == null) {
            if (((bitField0_ & 0x00000008) == 0x00000008)) {
              parameters_ = java.util.Collections.unmodifiableList(parameters_);
              bitField0_ = (bitField0_ & ~0x00000008);
            }
            result.parameters_ = parameters_;
          } else {
            result.parameters_ = parametersBuilder_.build();
          }
          if (partitionByBuilder_ == null) {
            if (((bitField0_ & 0x00000010) == 0x00000010)) {
              partitionBy_ = java.util.Collections.unmodifiableList(partitionBy_);
              bitField0_ = (bitField0_ & ~0x00000010);
            }
            result.partitionBy_ = partitionBy_;
          } else {
            result.partitionBy_ = partitionByBuilder_.build();
          }
          if (orderByBuilder_ == null) {
            if (((bitField0_ & 0x00000020) == 0x00000020)) {
              orderBy_ = java.util.Collections.unmodifiableList(orderBy_);
              bitField0_ = (bitField0_ & ~0x00000020);
            }
            result.orderBy_ = orderBy_;
          } else {
            result.orderBy_ = orderByBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000040) == 0x00000040)) {
            to_bitField0_ |= 0x00000008;
          }
          if (windowingClauseBuilder_ == null) {
            result.windowingClause_ = windowingClause_;
          } else {
            result.windowingClause_ = windowingClauseBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000080) == 0x00000080)) {
            to_bitField0_ |= 0x00000010;
          }
          result.requireBuiltin_ = requireBuiltin_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof WindowFunction) {
            return mergeFrom((WindowFunction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(WindowFunction other) {
          if (other == WindowFunction.getDefaultInstance()) return this;
          if (other.hasProject()) {
            setProject(other.getProject());
          }
          if (other.hasName()) {
            setName(other.getName());
          }
          if (other.hasIsDistinct()) {
            setIsDistinct(other.getIsDistinct());
          }
          if (parametersBuilder_ == null) {
            if (!other.parameters_.isEmpty()) {
              if (parameters_.isEmpty()) {
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000008);
              } else {
                ensureParametersIsMutable();
                parameters_.addAll(other.parameters_);
              }
              onChanged();
            }
          } else {
            if (!other.parameters_.isEmpty()) {
              if (parametersBuilder_.isEmpty()) {
                parametersBuilder_.dispose();
                parametersBuilder_ = null;
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000008);
                parametersBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getParametersFieldBuilder() : null;
              } else {
                parametersBuilder_.addAllMessages(other.parameters_);
              }
            }
          }
          if (partitionByBuilder_ == null) {
            if (!other.partitionBy_.isEmpty()) {
              if (partitionBy_.isEmpty()) {
                partitionBy_ = other.partitionBy_;
                bitField0_ = (bitField0_ & ~0x00000010);
              } else {
                ensurePartitionByIsMutable();
                partitionBy_.addAll(other.partitionBy_);
              }
              onChanged();
            }
          } else {
            if (!other.partitionBy_.isEmpty()) {
              if (partitionByBuilder_.isEmpty()) {
                partitionByBuilder_.dispose();
                partitionByBuilder_ = null;
                partitionBy_ = other.partitionBy_;
                bitField0_ = (bitField0_ & ~0x00000010);
                partitionByBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getPartitionByFieldBuilder() : null;
              } else {
                partitionByBuilder_.addAllMessages(other.partitionBy_);
              }
            }
          }
          if (orderByBuilder_ == null) {
            if (!other.orderBy_.isEmpty()) {
              if (orderBy_.isEmpty()) {
                orderBy_ = other.orderBy_;
                bitField0_ = (bitField0_ & ~0x00000020);
              } else {
                ensureOrderByIsMutable();
                orderBy_.addAll(other.orderBy_);
              }
              onChanged();
            }
          } else {
            if (!other.orderBy_.isEmpty()) {
              if (orderByBuilder_.isEmpty()) {
                orderByBuilder_.dispose();
                orderByBuilder_ = null;
                orderBy_ = other.orderBy_;
                bitField0_ = (bitField0_ & ~0x00000020);
                orderByBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getOrderByFieldBuilder() : null;
              } else {
                orderByBuilder_.addAllMessages(other.orderBy_);
              }
            }
          }
          if (other.hasWindowingClause()) {
            mergeWindowingClause(other.getWindowingClause());
          }
          if (other.hasRequireBuiltin()) {
            setRequireBuiltin(other.getRequireBuiltin());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (!hasProject()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          for (int i = 0; i < getParametersCount(); i++) {
            if (!getParameters(i).isInitialized()) {
              
              return false;
            }
          }
          for (int i = 0; i < getPartitionByCount(); i++) {
            if (!getPartitionBy(i).isInitialized()) {
              
              return false;
            }
          }
          for (int i = 0; i < getOrderByCount(); i++) {
            if (!getOrderBy(i).isInitialized()) {
              
              return false;
            }
          }
          if (hasWindowingClause()) {
            if (!getWindowingClause().isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                project_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 24: {
                bitField0_ |= 0x00000004;
                isDistinct_ = input.readBool();
                break;
              }
              case 34: {
                ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                input.readMessage(subBuilder, extensionRegistry);
                addParameters(subBuilder.buildPartial());
                break;
              }
              case 42: {
                ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                input.readMessage(subBuilder, extensionRegistry);
                addPartitionBy(subBuilder.buildPartial());
                break;
              }
              case 51: {
                OrderBy.Builder subBuilder = OrderBy.newBuilder();
                input.readGroup(6, subBuilder, extensionRegistry);
                addOrderBy(subBuilder.buildPartial());
                break;
              }
              case 59: {
                WindowingClause.Builder subBuilder = WindowingClause.newBuilder();
                if (hasWindowingClause()) {
                  subBuilder.mergeFrom(getWindowingClause());
                }
                input.readGroup(7, subBuilder, extensionRegistry);
                setWindowingClause(subBuilder.buildPartial());
                break;
              }
              case 64: {
                bitField0_ |= 0x00000080;
                requireBuiltin_ = input.readBool();
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // required string Project = 1;
        private Object project_ = "";
        public boolean hasProject() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getProject() {
          Object ref = project_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            project_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setProject(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
          return this;
        }
        public Builder clearProject() {
          bitField0_ = (bitField0_ & ~0x00000001);
          project_ = getDefaultInstance().getProject();
          onChanged();
          return this;
        }
        void setProject(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
        }
        
        // required string Name = 2;
        private Object name_ = "";
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getName() {
          Object ref = name_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        void setName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
        }
        
        // optional bool IsDistinct = 3;
        private boolean isDistinct_ ;
        public boolean hasIsDistinct() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        public boolean getIsDistinct() {
          return isDistinct_;
        }
        public Builder setIsDistinct(boolean value) {
          bitField0_ |= 0x00000004;
          isDistinct_ = value;
          onChanged();
          return this;
        }
        public Builder clearIsDistinct() {
          bitField0_ = (bitField0_ & ~0x00000004);
          isDistinct_ = false;
          onChanged();
          return this;
        }
        
        // repeated .apsara.odps.lot.ScalarExpression Parameters = 4;
        private java.util.List<ScalarExpression> parameters_ =
          java.util.Collections.emptyList();
        private void ensureParametersIsMutable() {
          if (!((bitField0_ & 0x00000008) == 0x00000008)) {
            parameters_ = new java.util.ArrayList<ScalarExpression>(parameters_);
            bitField0_ |= 0x00000008;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> parametersBuilder_;
        
        public java.util.List<ScalarExpression> getParametersList() {
          if (parametersBuilder_ == null) {
            return java.util.Collections.unmodifiableList(parameters_);
          } else {
            return parametersBuilder_.getMessageList();
          }
        }
        public int getParametersCount() {
          if (parametersBuilder_ == null) {
            return parameters_.size();
          } else {
            return parametersBuilder_.getCount();
          }
        }
        public ScalarExpression getParameters(int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);
          } else {
            return parametersBuilder_.getMessage(index);
          }
        }
        public Builder setParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.set(index, value);
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.set(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(index, value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addParameters(
            ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllParameters(
            Iterable<? extends ScalarExpression> values) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            super.addAll(values, parameters_);
            onChanged();
          } else {
            parametersBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearParameters() {
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000008);
            onChanged();
          } else {
            parametersBuilder_.clear();
          }
          return this;
        }
        public Builder removeParameters(int index) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.remove(index);
            onChanged();
          } else {
            parametersBuilder_.remove(index);
          }
          return this;
        }
        public ScalarExpression.Builder getParametersBuilder(
            int index) {
          return getParametersFieldBuilder().getBuilder(index);
        }
        public ScalarExpressionOrBuilder getParametersOrBuilder(
            int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);  } else {
            return parametersBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ScalarExpressionOrBuilder>
             getParametersOrBuilderList() {
          if (parametersBuilder_ != null) {
            return parametersBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(parameters_);
          }
        }
        public ScalarExpression.Builder addParametersBuilder() {
          return getParametersFieldBuilder().addBuilder(
              ScalarExpression.getDefaultInstance());
        }
        public ScalarExpression.Builder addParametersBuilder(
            int index) {
          return getParametersFieldBuilder().addBuilder(
              index, ScalarExpression.getDefaultInstance());
        }
        public java.util.List<ScalarExpression.Builder>
             getParametersBuilderList() {
          return getParametersFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
            getParametersFieldBuilder() {
          if (parametersBuilder_ == null) {
            parametersBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                    parameters_,
                    ((bitField0_ & 0x00000008) == 0x00000008),
                    getParentForChildren(),
                    isClean());
            parameters_ = null;
          }
          return parametersBuilder_;
        }
        
        // repeated .apsara.odps.lot.ScalarExpression PartitionBy = 5;
        private java.util.List<ScalarExpression> partitionBy_ =
          java.util.Collections.emptyList();
        private void ensurePartitionByIsMutable() {
          if (!((bitField0_ & 0x00000010) == 0x00000010)) {
            partitionBy_ = new java.util.ArrayList<ScalarExpression>(partitionBy_);
            bitField0_ |= 0x00000010;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> partitionByBuilder_;
        
        public java.util.List<ScalarExpression> getPartitionByList() {
          if (partitionByBuilder_ == null) {
            return java.util.Collections.unmodifiableList(partitionBy_);
          } else {
            return partitionByBuilder_.getMessageList();
          }
        }
        public int getPartitionByCount() {
          if (partitionByBuilder_ == null) {
            return partitionBy_.size();
          } else {
            return partitionByBuilder_.getCount();
          }
        }
        public ScalarExpression getPartitionBy(int index) {
          if (partitionByBuilder_ == null) {
            return partitionBy_.get(index);
          } else {
            return partitionByBuilder_.getMessage(index);
          }
        }
        public Builder setPartitionBy(
            int index, ScalarExpression value) {
          if (partitionByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePartitionByIsMutable();
            partitionBy_.set(index, value);
            onChanged();
          } else {
            partitionByBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setPartitionBy(
            int index, ScalarExpression.Builder builderForValue) {
          if (partitionByBuilder_ == null) {
            ensurePartitionByIsMutable();
            partitionBy_.set(index, builderForValue.build());
            onChanged();
          } else {
            partitionByBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addPartitionBy(ScalarExpression value) {
          if (partitionByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePartitionByIsMutable();
            partitionBy_.add(value);
            onChanged();
          } else {
            partitionByBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addPartitionBy(
            int index, ScalarExpression value) {
          if (partitionByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePartitionByIsMutable();
            partitionBy_.add(index, value);
            onChanged();
          } else {
            partitionByBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addPartitionBy(
            ScalarExpression.Builder builderForValue) {
          if (partitionByBuilder_ == null) {
            ensurePartitionByIsMutable();
            partitionBy_.add(builderForValue.build());
            onChanged();
          } else {
            partitionByBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addPartitionBy(
            int index, ScalarExpression.Builder builderForValue) {
          if (partitionByBuilder_ == null) {
            ensurePartitionByIsMutable();
            partitionBy_.add(index, builderForValue.build());
            onChanged();
          } else {
            partitionByBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllPartitionBy(
            Iterable<? extends ScalarExpression> values) {
          if (partitionByBuilder_ == null) {
            ensurePartitionByIsMutable();
            super.addAll(values, partitionBy_);
            onChanged();
          } else {
            partitionByBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearPartitionBy() {
          if (partitionByBuilder_ == null) {
            partitionBy_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000010);
            onChanged();
          } else {
            partitionByBuilder_.clear();
          }
          return this;
        }
        public Builder removePartitionBy(int index) {
          if (partitionByBuilder_ == null) {
            ensurePartitionByIsMutable();
            partitionBy_.remove(index);
            onChanged();
          } else {
            partitionByBuilder_.remove(index);
          }
          return this;
        }
        public ScalarExpression.Builder getPartitionByBuilder(
            int index) {
          return getPartitionByFieldBuilder().getBuilder(index);
        }
        public ScalarExpressionOrBuilder getPartitionByOrBuilder(
            int index) {
          if (partitionByBuilder_ == null) {
            return partitionBy_.get(index);  } else {
            return partitionByBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ScalarExpressionOrBuilder>
             getPartitionByOrBuilderList() {
          if (partitionByBuilder_ != null) {
            return partitionByBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(partitionBy_);
          }
        }
        public ScalarExpression.Builder addPartitionByBuilder() {
          return getPartitionByFieldBuilder().addBuilder(
              ScalarExpression.getDefaultInstance());
        }
        public ScalarExpression.Builder addPartitionByBuilder(
            int index) {
          return getPartitionByFieldBuilder().addBuilder(
              index, ScalarExpression.getDefaultInstance());
        }
        public java.util.List<ScalarExpression.Builder>
             getPartitionByBuilderList() {
          return getPartitionByFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
            getPartitionByFieldBuilder() {
          if (partitionByBuilder_ == null) {
            partitionByBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                    partitionBy_,
                    ((bitField0_ & 0x00000010) == 0x00000010),
                    getParentForChildren(),
                    isClean());
            partitionBy_ = null;
          }
          return partitionByBuilder_;
        }
        
        // repeated group OrderBy = 6 {
        private java.util.List<OrderBy> orderBy_ =
          java.util.Collections.emptyList();
        private void ensureOrderByIsMutable() {
          if (!((bitField0_ & 0x00000020) == 0x00000020)) {
            orderBy_ = new java.util.ArrayList<OrderBy>(orderBy_);
            bitField0_ |= 0x00000020;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            OrderBy, OrderBy.Builder, OrderByOrBuilder> orderByBuilder_;
        
        public java.util.List<OrderBy> getOrderByList() {
          if (orderByBuilder_ == null) {
            return java.util.Collections.unmodifiableList(orderBy_);
          } else {
            return orderByBuilder_.getMessageList();
          }
        }
        public int getOrderByCount() {
          if (orderByBuilder_ == null) {
            return orderBy_.size();
          } else {
            return orderByBuilder_.getCount();
          }
        }
        public OrderBy getOrderBy(int index) {
          if (orderByBuilder_ == null) {
            return orderBy_.get(index);
          } else {
            return orderByBuilder_.getMessage(index);
          }
        }
        public Builder setOrderBy(
            int index, OrderBy value) {
          if (orderByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureOrderByIsMutable();
            orderBy_.set(index, value);
            onChanged();
          } else {
            orderByBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setOrderBy(
            int index, OrderBy.Builder builderForValue) {
          if (orderByBuilder_ == null) {
            ensureOrderByIsMutable();
            orderBy_.set(index, builderForValue.build());
            onChanged();
          } else {
            orderByBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addOrderBy(OrderBy value) {
          if (orderByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureOrderByIsMutable();
            orderBy_.add(value);
            onChanged();
          } else {
            orderByBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addOrderBy(
            int index, OrderBy value) {
          if (orderByBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureOrderByIsMutable();
            orderBy_.add(index, value);
            onChanged();
          } else {
            orderByBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addOrderBy(
            OrderBy.Builder builderForValue) {
          if (orderByBuilder_ == null) {
            ensureOrderByIsMutable();
            orderBy_.add(builderForValue.build());
            onChanged();
          } else {
            orderByBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addOrderBy(
            int index, OrderBy.Builder builderForValue) {
          if (orderByBuilder_ == null) {
            ensureOrderByIsMutable();
            orderBy_.add(index, builderForValue.build());
            onChanged();
          } else {
            orderByBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllOrderBy(
            Iterable<? extends OrderBy> values) {
          if (orderByBuilder_ == null) {
            ensureOrderByIsMutable();
            super.addAll(values, orderBy_);
            onChanged();
          } else {
            orderByBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearOrderBy() {
          if (orderByBuilder_ == null) {
            orderBy_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000020);
            onChanged();
          } else {
            orderByBuilder_.clear();
          }
          return this;
        }
        public Builder removeOrderBy(int index) {
          if (orderByBuilder_ == null) {
            ensureOrderByIsMutable();
            orderBy_.remove(index);
            onChanged();
          } else {
            orderByBuilder_.remove(index);
          }
          return this;
        }
        public OrderBy.Builder getOrderByBuilder(
            int index) {
          return getOrderByFieldBuilder().getBuilder(index);
        }
        public OrderByOrBuilder getOrderByOrBuilder(
            int index) {
          if (orderByBuilder_ == null) {
            return orderBy_.get(index);  } else {
            return orderByBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends OrderByOrBuilder>
             getOrderByOrBuilderList() {
          if (orderByBuilder_ != null) {
            return orderByBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(orderBy_);
          }
        }
        public OrderBy.Builder addOrderByBuilder() {
          return getOrderByFieldBuilder().addBuilder(
              OrderBy.getDefaultInstance());
        }
        public OrderBy.Builder addOrderByBuilder(
            int index) {
          return getOrderByFieldBuilder().addBuilder(
              index, OrderBy.getDefaultInstance());
        }
        public java.util.List<OrderBy.Builder>
             getOrderByBuilderList() {
          return getOrderByFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            OrderBy, OrderBy.Builder, OrderByOrBuilder>
            getOrderByFieldBuilder() {
          if (orderByBuilder_ == null) {
            orderByBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                OrderBy, OrderBy.Builder, OrderByOrBuilder>(
                    orderBy_,
                    ((bitField0_ & 0x00000020) == 0x00000020),
                    getParentForChildren(),
                    isClean());
            orderBy_ = null;
          }
          return orderByBuilder_;
        }
        
        // optional group WindowingClause = 7 {
        private WindowingClause windowingClause_ = WindowingClause.getDefaultInstance();
        private com.google.protobuf.SingleFieldBuilder<
            WindowingClause, WindowingClause.Builder, WindowingClauseOrBuilder> windowingClauseBuilder_;
        public boolean hasWindowingClause() {
          return ((bitField0_ & 0x00000040) == 0x00000040);
        }
        public WindowingClause getWindowingClause() {
          if (windowingClauseBuilder_ == null) {
            return windowingClause_;
          } else {
            return windowingClauseBuilder_.getMessage();
          }
        }
        public Builder setWindowingClause(WindowingClause value) {
          if (windowingClauseBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            windowingClause_ = value;
            onChanged();
          } else {
            windowingClauseBuilder_.setMessage(value);
          }
          bitField0_ |= 0x00000040;
          return this;
        }
        public Builder setWindowingClause(
            WindowingClause.Builder builderForValue) {
          if (windowingClauseBuilder_ == null) {
            windowingClause_ = builderForValue.build();
            onChanged();
          } else {
            windowingClauseBuilder_.setMessage(builderForValue.build());
          }
          bitField0_ |= 0x00000040;
          return this;
        }
        public Builder mergeWindowingClause(WindowingClause value) {
          if (windowingClauseBuilder_ == null) {
            if (((bitField0_ & 0x00000040) == 0x00000040) &&
                windowingClause_ != WindowingClause.getDefaultInstance()) {
              windowingClause_ =
                WindowingClause.newBuilder(windowingClause_).mergeFrom(value).buildPartial();
            } else {
              windowingClause_ = value;
            }
            onChanged();
          } else {
            windowingClauseBuilder_.mergeFrom(value);
          }
          bitField0_ |= 0x00000040;
          return this;
        }
        public Builder clearWindowingClause() {
          if (windowingClauseBuilder_ == null) {
            windowingClause_ = WindowingClause.getDefaultInstance();
            onChanged();
          } else {
            windowingClauseBuilder_.clear();
          }
          bitField0_ = (bitField0_ & ~0x00000040);
          return this;
        }
        public WindowingClause.Builder getWindowingClauseBuilder() {
          bitField0_ |= 0x00000040;
          onChanged();
          return getWindowingClauseFieldBuilder().getBuilder();
        }
        public WindowingClauseOrBuilder getWindowingClauseOrBuilder() {
          if (windowingClauseBuilder_ != null) {
            return windowingClauseBuilder_.getMessageOrBuilder();
          } else {
            return windowingClause_;
          }
        }
        private com.google.protobuf.SingleFieldBuilder<
            WindowingClause, WindowingClause.Builder, WindowingClauseOrBuilder>
            getWindowingClauseFieldBuilder() {
          if (windowingClauseBuilder_ == null) {
            windowingClauseBuilder_ = new com.google.protobuf.SingleFieldBuilder<
                WindowingClause, WindowingClause.Builder, WindowingClauseOrBuilder>(
                    windowingClause_,
                    getParentForChildren(),
                    isClean());
            windowingClause_ = null;
          }
          return windowingClauseBuilder_;
        }
        
        // optional bool requireBuiltin = 8 [default = false];
        private boolean requireBuiltin_ ;
        public boolean hasRequireBuiltin() {
          return ((bitField0_ & 0x00000080) == 0x00000080);
        }
        public boolean getRequireBuiltin() {
          return requireBuiltin_;
        }
        public Builder setRequireBuiltin(boolean value) {
          bitField0_ |= 0x00000080;
          requireBuiltin_ = value;
          onChanged();
          return this;
        }
        public Builder clearRequireBuiltin() {
          bitField0_ = (bitField0_ & ~0x00000080);
          requireBuiltin_ = false;
          onChanged();
          return this;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.WindowFunction)
      }
      
      static {
        defaultInstance = new WindowFunction(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.WindowFunction)
    }
    
    public interface TableValuedFunctionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // required string Project = 1;
      boolean hasProject();
      String getProject();
      
      // required string Name = 2;
      boolean hasName();
      String getName();
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
      java.util.List<ScalarExpression>
          getParametersList();
      ScalarExpression getParameters(int index);
      int getParametersCount();
      java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList();
      ScalarExpressionOrBuilder getParametersOrBuilder(
          int index);
      
      // repeated string OutputColumns = 4;
      java.util.List<String> getOutputColumnsList();
      int getOutputColumnsCount();
      String getOutputColumns(int index);
      
      // repeated group Properties = 5 {
      java.util.List<TableValuedFunction.Properties>
          getPropertiesList();
      TableValuedFunction.Properties getProperties(int index);
      int getPropertiesCount();
      java.util.List<? extends TableValuedFunction.PropertiesOrBuilder>
          getPropertiesOrBuilderList();
      TableValuedFunction.PropertiesOrBuilder getPropertiesOrBuilder(
          int index);
      
      // optional bool requireBuiltin = 6 [default = false];
      boolean hasRequireBuiltin();
      boolean getRequireBuiltin();
    }
    public static final class TableValuedFunction extends
        com.google.protobuf.GeneratedMessage
        implements TableValuedFunctionOrBuilder {
      // Use TableValuedFunction.newBuilder() to construct.
      private TableValuedFunction(Builder builder) {
        super(builder);
      }
      private TableValuedFunction(boolean noInit) {}
      
      private static final TableValuedFunction defaultInstance;
      public static TableValuedFunction getDefaultInstance() {
        return defaultInstance;
      }
      
      public TableValuedFunction getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_fieldAccessorTable;
      }
      
      public interface PropertiesOrBuilder
          extends com.google.protobuf.MessageOrBuilder {
        
        // required string Key = 1;
        boolean hasKey();
        String getKey();
        
        // required string Value = 2;
        boolean hasValue();
        String getValue();
      }
      public static final class Properties extends
          com.google.protobuf.GeneratedMessage
          implements PropertiesOrBuilder {
        // Use Properties.newBuilder() to construct.
        private Properties(Builder builder) {
          super(builder);
        }
        private Properties(boolean noInit) {}
        
        private static final Properties defaultInstance;
        public static Properties getDefaultInstance() {
          return defaultInstance;
        }
        
        public Properties getDefaultInstanceForType() {
          return defaultInstance;
        }
        
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_Properties_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_Properties_fieldAccessorTable;
        }
        
        private int bitField0_;
        // required string Key = 1;
        public static final int KEY_FIELD_NUMBER = 1;
        private Object key_;
        public boolean hasKey() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getKey() {
          Object ref = key_;
          if (ref instanceof String) {
            return (String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            String s = bs.toStringUtf8();
            if (com.google.protobuf.Internal.isValidUtf8(bs)) {
              key_ = s;
            }
            return s;
          }
        }
        private com.google.protobuf.ByteString getKeyBytes() {
          Object ref = key_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8((String) ref);
            key_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        
        // required string Value = 2;
        public static final int VALUE_FIELD_NUMBER = 2;
        private Object value_;
        public boolean hasValue() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getValue() {
          Object ref = value_;
          if (ref instanceof String) {
            return (String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            String s = bs.toStringUtf8();
            if (com.google.protobuf.Internal.isValidUtf8(bs)) {
              value_ = s;
            }
            return s;
          }
        }
        private com.google.protobuf.ByteString getValueBytes() {
          Object ref = value_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8((String) ref);
            value_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        
        private void initFields() {
          key_ = "";
          value_ = "";
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;
          
          if (!hasKey()) {
            memoizedIsInitialized = 0;
            return false;
          }
          if (!hasValue()) {
            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.writeBytes(1, getKeyBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeBytes(2, getValueBytes());
          }
          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, getKeyBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(2, getValueBytes());
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }
        
        private static final long serialVersionUID = 0L;
        @Override
        protected Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }
        
        public static Properties parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static Properties parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static Properties parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static Properties parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static Properties parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static Properties parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        public static Properties parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static Properties parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static Properties parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static Properties parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        
        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(Properties prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }
        
        @Override
        protected Builder newBuilderForType(
            BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements PropertiesOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_Properties_descriptor;
          }
          
          protected FieldAccessorTable
              internalGetFieldAccessorTable() {
            return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_Properties_fieldAccessorTable;
          }
          
          // Construct using apsara.odps.lot.ExpressionProtos.TableValuedFunction.Properties.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }
          
          private Builder(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();
            key_ = "";
            bitField0_ = (bitField0_ & ~0x00000001);
            value_ = "";
            bitField0_ = (bitField0_ & ~0x00000002);
            return this;
          }
          
          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }
          
          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return Properties.getDescriptor();
          }
          
          public Properties getDefaultInstanceForType() {
            return Properties.getDefaultInstance();
          }
          
          public Properties build() {
            Properties result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }
          
          private Properties buildParsed()
              throws com.google.protobuf.InvalidProtocolBufferException {
            Properties result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(
                result).asInvalidProtocolBufferException();
            }
            return result;
          }
          
          public Properties buildPartial() {
            Properties result = new Properties(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            result.key_ = key_;
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.value_ = value_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }
          
          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof Properties) {
              return mergeFrom((Properties)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }
          
          public Builder mergeFrom(Properties other) {
            if (other == Properties.getDefaultInstance()) return this;
            if (other.hasKey()) {
              setKey(other.getKey());
            }
            if (other.hasValue()) {
              setValue(other.getValue());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }
          
          public final boolean isInitialized() {
            if (!hasKey()) {
              
              return false;
            }
            if (!hasValue()) {
              
              return false;
            }
            return true;
          }
          
          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder(
                this.getUnknownFields());
            while (true) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    this.setUnknownFields(unknownFields.build());
                    onChanged();
                    return this;
                  }
                  break;
                }
                case 10: {
                  bitField0_ |= 0x00000001;
                  key_ = input.readBytes();
                  break;
                }
                case 18: {
                  bitField0_ |= 0x00000002;
                  value_ = input.readBytes();
                  break;
                }
              }
            }
          }
          
          private int bitField0_;
          
          // required string Key = 1;
          private Object key_ = "";
          public boolean hasKey() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          public String getKey() {
            Object ref = key_;
            if (!(ref instanceof String)) {
              String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
              key_ = s;
              return s;
            } else {
              return (String) ref;
            }
          }
          public Builder setKey(String value) {
            if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
            key_ = value;
            onChanged();
            return this;
          }
          public Builder clearKey() {
            bitField0_ = (bitField0_ & ~0x00000001);
            key_ = getDefaultInstance().getKey();
            onChanged();
            return this;
          }
          void setKey(com.google.protobuf.ByteString value) {
            bitField0_ |= 0x00000001;
            key_ = value;
            onChanged();
          }
          
          // required string Value = 2;
          private Object value_ = "";
          public boolean hasValue() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          public String getValue() {
            Object ref = value_;
            if (!(ref instanceof String)) {
              String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
              value_ = s;
              return s;
            } else {
              return (String) ref;
            }
          }
          public Builder setValue(String value) {
            if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
            value_ = value;
            onChanged();
            return this;
          }
          public Builder clearValue() {
            bitField0_ = (bitField0_ & ~0x00000002);
            value_ = getDefaultInstance().getValue();
            onChanged();
            return this;
          }
          void setValue(com.google.protobuf.ByteString value) {
            bitField0_ |= 0x00000002;
            value_ = value;
            onChanged();
          }
          
          // @@protoc_insertion_point(builder_scope:apsara.odps.lot.TableValuedFunction.Properties)
        }
        
        static {
          defaultInstance = new Properties(true);
          defaultInstance.initFields();
        }
        
        // @@protoc_insertion_point(class_scope:apsara.odps.lot.TableValuedFunction.Properties)
      }
      
      private int bitField0_;
      // required string Project = 1;
      public static final int PROJECT_FIELD_NUMBER = 1;
      private Object project_;
      public boolean hasProject() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public String getProject() {
        Object ref = project_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            project_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getProjectBytes() {
        Object ref = project_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          project_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required string Name = 2;
      public static final int NAME_FIELD_NUMBER = 2;
      private Object name_;
      public boolean hasName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public String getName() {
        Object ref = name_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            name_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getNameBytes() {
        Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
      public static final int PARAMETERS_FIELD_NUMBER = 3;
      private java.util.List<ScalarExpression> parameters_;
      public java.util.List<ScalarExpression> getParametersList() {
        return parameters_;
      }
      public java.util.List<? extends ScalarExpressionOrBuilder>
          getParametersOrBuilderList() {
        return parameters_;
      }
      public int getParametersCount() {
        return parameters_.size();
      }
      public ScalarExpression getParameters(int index) {
        return parameters_.get(index);
      }
      public ScalarExpressionOrBuilder getParametersOrBuilder(
          int index) {
        return parameters_.get(index);
      }
      
      // repeated string OutputColumns = 4;
      public static final int OUTPUTCOLUMNS_FIELD_NUMBER = 4;
      private com.google.protobuf.LazyStringList outputColumns_;
      public java.util.List<String>
          getOutputColumnsList() {
        return outputColumns_;
      }
      public int getOutputColumnsCount() {
        return outputColumns_.size();
      }
      public String getOutputColumns(int index) {
        return outputColumns_.get(index);
      }
      
      // repeated group Properties = 5 {
      public static final int PROPERTIES_FIELD_NUMBER = 5;
      private java.util.List<Properties> properties_;
      public java.util.List<Properties> getPropertiesList() {
        return properties_;
      }
      public java.util.List<? extends PropertiesOrBuilder>
          getPropertiesOrBuilderList() {
        return properties_;
      }
      public int getPropertiesCount() {
        return properties_.size();
      }
      public Properties getProperties(int index) {
        return properties_.get(index);
      }
      public PropertiesOrBuilder getPropertiesOrBuilder(
          int index) {
        return properties_.get(index);
      }
      
      // optional bool requireBuiltin = 6 [default = false];
      public static final int REQUIREBUILTIN_FIELD_NUMBER = 6;
      private boolean requireBuiltin_;
      public boolean hasRequireBuiltin() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public boolean getRequireBuiltin() {
        return requireBuiltin_;
      }
      
      private void initFields() {
        project_ = "";
        name_ = "";
        parameters_ = java.util.Collections.emptyList();
        outputColumns_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        properties_ = java.util.Collections.emptyList();
        requireBuiltin_ = false;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (!hasProject()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getParametersCount(); i++) {
          if (!getParameters(i).isInitialized()) {
            memoizedIsInitialized = 0;
            return false;
          }
        }
        for (int i = 0; i < getPropertiesCount(); i++) {
          if (!getProperties(i).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.writeBytes(1, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(2, getNameBytes());
        }
        for (int i = 0; i < parameters_.size(); i++) {
          output.writeMessage(3, parameters_.get(i));
        }
        for (int i = 0; i < outputColumns_.size(); i++) {
          output.writeBytes(4, outputColumns_.getByteString(i));
        }
        for (int i = 0; i < properties_.size(); i++) {
          output.writeGroup(5, properties_.get(i));
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeBool(6, requireBuiltin_);
        }
        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, getProjectBytes());
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(2, getNameBytes());
        }
        for (int i = 0; i < parameters_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeMessageSize(3, parameters_.get(i));
        }
        {
          int dataSize = 0;
          for (int i = 0; i < outputColumns_.size(); i++) {
            dataSize += com.google.protobuf.CodedOutputStream
              .computeBytesSizeNoTag(outputColumns_.getByteString(i));
          }
          size += dataSize;
          size += 1 * getOutputColumnsList().size();
        }
        for (int i = 0; i < properties_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeGroupSize(5, properties_.get(i));
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBoolSize(6, requireBuiltin_);
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static TableValuedFunction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static TableValuedFunction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static TableValuedFunction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static TableValuedFunction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static TableValuedFunction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static TableValuedFunction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static TableValuedFunction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static TableValuedFunction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static TableValuedFunction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static TableValuedFunction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(TableValuedFunction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements TableValuedFunctionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TableValuedFunction_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.TableValuedFunction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getParametersFieldBuilder();
            getPropertiesFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          project_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000002);
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000004);
          } else {
            parametersBuilder_.clear();
          }
          outputColumns_ = com.google.protobuf.LazyStringArrayList.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000008);
          if (propertiesBuilder_ == null) {
            properties_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000010);
          } else {
            propertiesBuilder_.clear();
          }
          requireBuiltin_ = false;
          bitField0_ = (bitField0_ & ~0x00000020);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return TableValuedFunction.getDescriptor();
        }
        
        public TableValuedFunction getDefaultInstanceForType() {
          return TableValuedFunction.getDefaultInstance();
        }
        
        public TableValuedFunction build() {
          TableValuedFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private TableValuedFunction buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          TableValuedFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public TableValuedFunction buildPartial() {
          TableValuedFunction result = new TableValuedFunction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.project_ = project_;
          if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
            to_bitField0_ |= 0x00000002;
          }
          result.name_ = name_;
          if (parametersBuilder_ == null) {
            if (((bitField0_ & 0x00000004) == 0x00000004)) {
              parameters_ = java.util.Collections.unmodifiableList(parameters_);
              bitField0_ = (bitField0_ & ~0x00000004);
            }
            result.parameters_ = parameters_;
          } else {
            result.parameters_ = parametersBuilder_.build();
          }
          if (((bitField0_ & 0x00000008) == 0x00000008)) {
            outputColumns_ = new com.google.protobuf.UnmodifiableLazyStringList(
                outputColumns_);
            bitField0_ = (bitField0_ & ~0x00000008);
          }
          result.outputColumns_ = outputColumns_;
          if (propertiesBuilder_ == null) {
            if (((bitField0_ & 0x00000010) == 0x00000010)) {
              properties_ = java.util.Collections.unmodifiableList(properties_);
              bitField0_ = (bitField0_ & ~0x00000010);
            }
            result.properties_ = properties_;
          } else {
            result.properties_ = propertiesBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000020) == 0x00000020)) {
            to_bitField0_ |= 0x00000004;
          }
          result.requireBuiltin_ = requireBuiltin_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof TableValuedFunction) {
            return mergeFrom((TableValuedFunction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(TableValuedFunction other) {
          if (other == TableValuedFunction.getDefaultInstance()) return this;
          if (other.hasProject()) {
            setProject(other.getProject());
          }
          if (other.hasName()) {
            setName(other.getName());
          }
          if (parametersBuilder_ == null) {
            if (!other.parameters_.isEmpty()) {
              if (parameters_.isEmpty()) {
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000004);
              } else {
                ensureParametersIsMutable();
                parameters_.addAll(other.parameters_);
              }
              onChanged();
            }
          } else {
            if (!other.parameters_.isEmpty()) {
              if (parametersBuilder_.isEmpty()) {
                parametersBuilder_.dispose();
                parametersBuilder_ = null;
                parameters_ = other.parameters_;
                bitField0_ = (bitField0_ & ~0x00000004);
                parametersBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getParametersFieldBuilder() : null;
              } else {
                parametersBuilder_.addAllMessages(other.parameters_);
              }
            }
          }
          if (!other.outputColumns_.isEmpty()) {
            if (outputColumns_.isEmpty()) {
              outputColumns_ = other.outputColumns_;
              bitField0_ = (bitField0_ & ~0x00000008);
            } else {
              ensureOutputColumnsIsMutable();
              outputColumns_.addAll(other.outputColumns_);
            }
            onChanged();
          }
          if (propertiesBuilder_ == null) {
            if (!other.properties_.isEmpty()) {
              if (properties_.isEmpty()) {
                properties_ = other.properties_;
                bitField0_ = (bitField0_ & ~0x00000010);
              } else {
                ensurePropertiesIsMutable();
                properties_.addAll(other.properties_);
              }
              onChanged();
            }
          } else {
            if (!other.properties_.isEmpty()) {
              if (propertiesBuilder_.isEmpty()) {
                propertiesBuilder_.dispose();
                propertiesBuilder_ = null;
                properties_ = other.properties_;
                bitField0_ = (bitField0_ & ~0x00000010);
                propertiesBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getPropertiesFieldBuilder() : null;
              } else {
                propertiesBuilder_.addAllMessages(other.properties_);
              }
            }
          }
          if (other.hasRequireBuiltin()) {
            setRequireBuiltin(other.getRequireBuiltin());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (!hasProject()) {
            
            return false;
          }
          if (!hasName()) {
            
            return false;
          }
          for (int i = 0; i < getParametersCount(); i++) {
            if (!getParameters(i).isInitialized()) {
              
              return false;
            }
          }
          for (int i = 0; i < getPropertiesCount(); i++) {
            if (!getProperties(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                project_ = input.readBytes();
                break;
              }
              case 18: {
                bitField0_ |= 0x00000002;
                name_ = input.readBytes();
                break;
              }
              case 26: {
                ScalarExpression.Builder subBuilder = ScalarExpression.newBuilder();
                input.readMessage(subBuilder, extensionRegistry);
                addParameters(subBuilder.buildPartial());
                break;
              }
              case 34: {
                ensureOutputColumnsIsMutable();
                outputColumns_.add(input.readBytes());
                break;
              }
              case 43: {
                Properties.Builder subBuilder = Properties.newBuilder();
                input.readGroup(5, subBuilder, extensionRegistry);
                addProperties(subBuilder.buildPartial());
                break;
              }
              case 48: {
                bitField0_ |= 0x00000020;
                requireBuiltin_ = input.readBool();
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // required string Project = 1;
        private Object project_ = "";
        public boolean hasProject() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getProject() {
          Object ref = project_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            project_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setProject(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
          return this;
        }
        public Builder clearProject() {
          bitField0_ = (bitField0_ & ~0x00000001);
          project_ = getDefaultInstance().getProject();
          onChanged();
          return this;
        }
        void setProject(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000001;
          project_ = value;
          onChanged();
        }
        
        // required string Name = 2;
        private Object name_ = "";
        public boolean hasName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getName() {
          Object ref = name_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
          return this;
        }
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000002);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        void setName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000002;
          name_ = value;
          onChanged();
        }
        
        // repeated .apsara.odps.lot.ScalarExpression Parameters = 3;
        private java.util.List<ScalarExpression> parameters_ =
          java.util.Collections.emptyList();
        private void ensureParametersIsMutable() {
          if (!((bitField0_ & 0x00000004) == 0x00000004)) {
            parameters_ = new java.util.ArrayList<ScalarExpression>(parameters_);
            bitField0_ |= 0x00000004;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder> parametersBuilder_;
        
        public java.util.List<ScalarExpression> getParametersList() {
          if (parametersBuilder_ == null) {
            return java.util.Collections.unmodifiableList(parameters_);
          } else {
            return parametersBuilder_.getMessageList();
          }
        }
        public int getParametersCount() {
          if (parametersBuilder_ == null) {
            return parameters_.size();
          } else {
            return parametersBuilder_.getCount();
          }
        }
        public ScalarExpression getParameters(int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);
          } else {
            return parametersBuilder_.getMessage(index);
          }
        }
        public Builder setParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.set(index, value);
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.set(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression value) {
          if (parametersBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureParametersIsMutable();
            parameters_.add(index, value);
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addParameters(
            ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addParameters(
            int index, ScalarExpression.Builder builderForValue) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.add(index, builderForValue.build());
            onChanged();
          } else {
            parametersBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllParameters(
            Iterable<? extends ScalarExpression> values) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            super.addAll(values, parameters_);
            onChanged();
          } else {
            parametersBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearParameters() {
          if (parametersBuilder_ == null) {
            parameters_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000004);
            onChanged();
          } else {
            parametersBuilder_.clear();
          }
          return this;
        }
        public Builder removeParameters(int index) {
          if (parametersBuilder_ == null) {
            ensureParametersIsMutable();
            parameters_.remove(index);
            onChanged();
          } else {
            parametersBuilder_.remove(index);
          }
          return this;
        }
        public ScalarExpression.Builder getParametersBuilder(
            int index) {
          return getParametersFieldBuilder().getBuilder(index);
        }
        public ScalarExpressionOrBuilder getParametersOrBuilder(
            int index) {
          if (parametersBuilder_ == null) {
            return parameters_.get(index);  } else {
            return parametersBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ScalarExpressionOrBuilder>
             getParametersOrBuilderList() {
          if (parametersBuilder_ != null) {
            return parametersBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(parameters_);
          }
        }
        public ScalarExpression.Builder addParametersBuilder() {
          return getParametersFieldBuilder().addBuilder(
              ScalarExpression.getDefaultInstance());
        }
        public ScalarExpression.Builder addParametersBuilder(
            int index) {
          return getParametersFieldBuilder().addBuilder(
              index, ScalarExpression.getDefaultInstance());
        }
        public java.util.List<ScalarExpression.Builder>
             getParametersBuilderList() {
          return getParametersFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>
            getParametersFieldBuilder() {
          if (parametersBuilder_ == null) {
            parametersBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                ScalarExpression, ScalarExpression.Builder, ScalarExpressionOrBuilder>(
                    parameters_,
                    ((bitField0_ & 0x00000004) == 0x00000004),
                    getParentForChildren(),
                    isClean());
            parameters_ = null;
          }
          return parametersBuilder_;
        }
        
        // repeated string OutputColumns = 4;
        private com.google.protobuf.LazyStringList outputColumns_ = com.google.protobuf.LazyStringArrayList.EMPTY;
        private void ensureOutputColumnsIsMutable() {
          if (!((bitField0_ & 0x00000008) == 0x00000008)) {
            outputColumns_ = new com.google.protobuf.LazyStringArrayList(outputColumns_);
            bitField0_ |= 0x00000008;
           }
        }
        public java.util.List<String>
            getOutputColumnsList() {
          return java.util.Collections.unmodifiableList(outputColumns_);
        }
        public int getOutputColumnsCount() {
          return outputColumns_.size();
        }
        public String getOutputColumns(int index) {
          return outputColumns_.get(index);
        }
        public Builder setOutputColumns(
            int index, String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    ensureOutputColumnsIsMutable();
          outputColumns_.set(index, value);
          onChanged();
          return this;
        }
        public Builder addOutputColumns(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    ensureOutputColumnsIsMutable();
          outputColumns_.add(value);
          onChanged();
          return this;
        }
        public Builder addAllOutputColumns(
            Iterable<String> values) {
          ensureOutputColumnsIsMutable();
          super.addAll(values, outputColumns_);
          onChanged();
          return this;
        }
        public Builder clearOutputColumns() {
          outputColumns_ = com.google.protobuf.LazyStringArrayList.EMPTY;
          bitField0_ = (bitField0_ & ~0x00000008);
          onChanged();
          return this;
        }
        void addOutputColumns(com.google.protobuf.ByteString value) {
          ensureOutputColumnsIsMutable();
          outputColumns_.add(value);
          onChanged();
        }
        
        // repeated group Properties = 5 {
        private java.util.List<Properties> properties_ =
          java.util.Collections.emptyList();
        private void ensurePropertiesIsMutable() {
          if (!((bitField0_ & 0x00000010) == 0x00000010)) {
            properties_ = new java.util.ArrayList<Properties>(properties_);
            bitField0_ |= 0x00000010;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            Properties, Properties.Builder, PropertiesOrBuilder> propertiesBuilder_;
        
        public java.util.List<Properties> getPropertiesList() {
          if (propertiesBuilder_ == null) {
            return java.util.Collections.unmodifiableList(properties_);
          } else {
            return propertiesBuilder_.getMessageList();
          }
        }
        public int getPropertiesCount() {
          if (propertiesBuilder_ == null) {
            return properties_.size();
          } else {
            return propertiesBuilder_.getCount();
          }
        }
        public Properties getProperties(int index) {
          if (propertiesBuilder_ == null) {
            return properties_.get(index);
          } else {
            return propertiesBuilder_.getMessage(index);
          }
        }
        public Builder setProperties(
            int index, Properties value) {
          if (propertiesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePropertiesIsMutable();
            properties_.set(index, value);
            onChanged();
          } else {
            propertiesBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setProperties(
            int index, Properties.Builder builderForValue) {
          if (propertiesBuilder_ == null) {
            ensurePropertiesIsMutable();
            properties_.set(index, builderForValue.build());
            onChanged();
          } else {
            propertiesBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addProperties(Properties value) {
          if (propertiesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePropertiesIsMutable();
            properties_.add(value);
            onChanged();
          } else {
            propertiesBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addProperties(
            int index, Properties value) {
          if (propertiesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensurePropertiesIsMutable();
            properties_.add(index, value);
            onChanged();
          } else {
            propertiesBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addProperties(
            Properties.Builder builderForValue) {
          if (propertiesBuilder_ == null) {
            ensurePropertiesIsMutable();
            properties_.add(builderForValue.build());
            onChanged();
          } else {
            propertiesBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addProperties(
            int index, Properties.Builder builderForValue) {
          if (propertiesBuilder_ == null) {
            ensurePropertiesIsMutable();
            properties_.add(index, builderForValue.build());
            onChanged();
          } else {
            propertiesBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllProperties(
            Iterable<? extends Properties> values) {
          if (propertiesBuilder_ == null) {
            ensurePropertiesIsMutable();
            super.addAll(values, properties_);
            onChanged();
          } else {
            propertiesBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearProperties() {
          if (propertiesBuilder_ == null) {
            properties_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000010);
            onChanged();
          } else {
            propertiesBuilder_.clear();
          }
          return this;
        }
        public Builder removeProperties(int index) {
          if (propertiesBuilder_ == null) {
            ensurePropertiesIsMutable();
            properties_.remove(index);
            onChanged();
          } else {
            propertiesBuilder_.remove(index);
          }
          return this;
        }
        public Properties.Builder getPropertiesBuilder(
            int index) {
          return getPropertiesFieldBuilder().getBuilder(index);
        }
        public PropertiesOrBuilder getPropertiesOrBuilder(
            int index) {
          if (propertiesBuilder_ == null) {
            return properties_.get(index);  } else {
            return propertiesBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends PropertiesOrBuilder>
             getPropertiesOrBuilderList() {
          if (propertiesBuilder_ != null) {
            return propertiesBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(properties_);
          }
        }
        public Properties.Builder addPropertiesBuilder() {
          return getPropertiesFieldBuilder().addBuilder(
              Properties.getDefaultInstance());
        }
        public Properties.Builder addPropertiesBuilder(
            int index) {
          return getPropertiesFieldBuilder().addBuilder(
              index, Properties.getDefaultInstance());
        }
        public java.util.List<Properties.Builder>
             getPropertiesBuilderList() {
          return getPropertiesFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            Properties, Properties.Builder, PropertiesOrBuilder>
            getPropertiesFieldBuilder() {
          if (propertiesBuilder_ == null) {
            propertiesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                Properties, Properties.Builder, PropertiesOrBuilder>(
                    properties_,
                    ((bitField0_ & 0x00000010) == 0x00000010),
                    getParentForChildren(),
                    isClean());
            properties_ = null;
          }
          return propertiesBuilder_;
        }
        
        // optional bool requireBuiltin = 6 [default = false];
        private boolean requireBuiltin_ ;
        public boolean hasRequireBuiltin() {
          return ((bitField0_ & 0x00000020) == 0x00000020);
        }
        public boolean getRequireBuiltin() {
          return requireBuiltin_;
        }
        public Builder setRequireBuiltin(boolean value) {
          bitField0_ |= 0x00000020;
          requireBuiltin_ = value;
          onChanged();
          return this;
        }
        public Builder clearRequireBuiltin() {
          bitField0_ = (bitField0_ & ~0x00000020);
          requireBuiltin_ = false;
          onChanged();
          return this;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.TableValuedFunction)
      }
      
      static {
        defaultInstance = new TableValuedFunction(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.TableValuedFunction)
    }
    
    public interface TemporaryFunctionOrBuilder
        extends com.google.protobuf.MessageOrBuilder {
      
      // required string Name = 1;
      boolean hasName();
      String getName();
      
      // repeated group Resources = 2 {
      java.util.List<TemporaryFunction.Resources>
          getResourcesList();
      TemporaryFunction.Resources getResources(int index);
      int getResourcesCount();
      java.util.List<? extends TemporaryFunction.ResourcesOrBuilder>
          getResourcesOrBuilderList();
      TemporaryFunction.ResourcesOrBuilder getResourcesOrBuilder(
          int index);
      
      // required string ClassName = 3;
      boolean hasClassName();
      String getClassName();
      
      // required .apsara.odps.Language Language = 4;
      boolean hasLanguage();
      LanguageProtos.Language getLanguage();
    }
    public static final class TemporaryFunction extends
        com.google.protobuf.GeneratedMessage
        implements TemporaryFunctionOrBuilder {
      // Use TemporaryFunction.newBuilder() to construct.
      private TemporaryFunction(Builder builder) {
        super(builder);
      }
      private TemporaryFunction(boolean noInit) {}
      
      private static final TemporaryFunction defaultInstance;
      public static TemporaryFunction getDefaultInstance() {
        return defaultInstance;
      }
      
      public TemporaryFunction getDefaultInstanceForType() {
        return defaultInstance;
      }
      
      public static final com.google.protobuf.Descriptors.Descriptor
          getDescriptor() {
        return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_descriptor;
      }
      
      protected FieldAccessorTable
          internalGetFieldAccessorTable() {
        return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_fieldAccessorTable;
      }
      
      public interface ResourcesOrBuilder
          extends com.google.protobuf.MessageOrBuilder {
        
        // required string Project = 1;
        boolean hasProject();
        String getProject();
        
        // required string ResourceName = 2;
        boolean hasResourceName();
        String getResourceName();
      }
      public static final class Resources extends
          com.google.protobuf.GeneratedMessage
          implements ResourcesOrBuilder {
        // Use Resources.newBuilder() to construct.
        private Resources(Builder builder) {
          super(builder);
        }
        private Resources(boolean noInit) {}
        
        private static final Resources defaultInstance;
        public static Resources getDefaultInstance() {
          return defaultInstance;
        }
        
        public Resources getDefaultInstanceForType() {
          return defaultInstance;
        }
        
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_Resources_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_Resources_fieldAccessorTable;
        }
        
        private int bitField0_;
        // required string Project = 1;
        public static final int PROJECT_FIELD_NUMBER = 1;
        private Object project_;
        public boolean hasProject() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getProject() {
          Object ref = project_;
          if (ref instanceof String) {
            return (String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            String s = bs.toStringUtf8();
            if (com.google.protobuf.Internal.isValidUtf8(bs)) {
              project_ = s;
            }
            return s;
          }
        }
        private com.google.protobuf.ByteString getProjectBytes() {
          Object ref = project_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8((String) ref);
            project_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        
        // required string ResourceName = 2;
        public static final int RESOURCENAME_FIELD_NUMBER = 2;
        private Object resourceName_;
        public boolean hasResourceName() {
          return ((bitField0_ & 0x00000002) == 0x00000002);
        }
        public String getResourceName() {
          Object ref = resourceName_;
          if (ref instanceof String) {
            return (String) ref;
          } else {
            com.google.protobuf.ByteString bs = 
                (com.google.protobuf.ByteString) ref;
            String s = bs.toStringUtf8();
            if (com.google.protobuf.Internal.isValidUtf8(bs)) {
              resourceName_ = s;
            }
            return s;
          }
        }
        private com.google.protobuf.ByteString getResourceNameBytes() {
          Object ref = resourceName_;
          if (ref instanceof String) {
            com.google.protobuf.ByteString b = 
                com.google.protobuf.ByteString.copyFromUtf8((String) ref);
            resourceName_ = b;
            return b;
          } else {
            return (com.google.protobuf.ByteString) ref;
          }
        }
        
        private void initFields() {
          project_ = "";
          resourceName_ = "";
        }
        private byte memoizedIsInitialized = -1;
        public final boolean isInitialized() {
          byte isInitialized = memoizedIsInitialized;
          if (isInitialized != -1) return isInitialized == 1;
          
          if (!hasProject()) {
            memoizedIsInitialized = 0;
            return false;
          }
          if (!hasResourceName()) {
            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.writeBytes(1, getProjectBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            output.writeBytes(2, getResourceNameBytes());
          }
          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, getProjectBytes());
          }
          if (((bitField0_ & 0x00000002) == 0x00000002)) {
            size += com.google.protobuf.CodedOutputStream
              .computeBytesSize(2, getResourceNameBytes());
          }
          size += getUnknownFields().getSerializedSize();
          memoizedSerializedSize = size;
          return size;
        }
        
        private static final long serialVersionUID = 0L;
        @Override
        protected Object writeReplace()
            throws java.io.ObjectStreamException {
          return super.writeReplace();
        }
        
        public static Resources parseFrom(
            com.google.protobuf.ByteString data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static Resources parseFrom(
            com.google.protobuf.ByteString data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static Resources parseFrom(byte[] data)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data).buildParsed();
        }
        public static Resources parseFrom(
            byte[] data,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws com.google.protobuf.InvalidProtocolBufferException {
          return newBuilder().mergeFrom(data, extensionRegistry)
                   .buildParsed();
        }
        public static Resources parseFrom(java.io.InputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static Resources parseFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        public static Resources parseDelimitedFrom(java.io.InputStream input)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static Resources parseDelimitedFrom(
            java.io.InputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          Builder builder = newBuilder();
          if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
            return builder.buildParsed();
          } else {
            return null;
          }
        }
        public static Resources parseFrom(
            com.google.protobuf.CodedInputStream input)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input).buildParsed();
        }
        public static Resources parseFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          return newBuilder().mergeFrom(input, extensionRegistry)
                   .buildParsed();
        }
        
        public static Builder newBuilder() { return Builder.create(); }
        public Builder newBuilderForType() { return newBuilder(); }
        public static Builder newBuilder(Resources prototype) {
          return newBuilder().mergeFrom(prototype);
        }
        public Builder toBuilder() { return newBuilder(this); }
        
        @Override
        protected Builder newBuilderForType(
            BuilderParent parent) {
          Builder builder = new Builder(parent);
          return builder;
        }
        public static final class Builder extends
            com.google.protobuf.GeneratedMessage.Builder<Builder>
           implements ResourcesOrBuilder {
          public static final com.google.protobuf.Descriptors.Descriptor
              getDescriptor() {
            return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_Resources_descriptor;
          }
          
          protected FieldAccessorTable
              internalGetFieldAccessorTable() {
            return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_Resources_fieldAccessorTable;
          }
          
          // Construct using apsara.odps.lot.ExpressionProtos.TemporaryFunction.Resources.newBuilder()
          private Builder() {
            maybeForceBuilderInitialization();
          }
          
          private Builder(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();
            project_ = "";
            bitField0_ = (bitField0_ & ~0x00000001);
            resourceName_ = "";
            bitField0_ = (bitField0_ & ~0x00000002);
            return this;
          }
          
          public Builder clone() {
            return create().mergeFrom(buildPartial());
          }
          
          public com.google.protobuf.Descriptors.Descriptor
              getDescriptorForType() {
            return Resources.getDescriptor();
          }
          
          public Resources getDefaultInstanceForType() {
            return Resources.getDefaultInstance();
          }
          
          public Resources build() {
            Resources result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(result);
            }
            return result;
          }
          
          private Resources buildParsed()
              throws com.google.protobuf.InvalidProtocolBufferException {
            Resources result = buildPartial();
            if (!result.isInitialized()) {
              throw newUninitializedMessageException(
                result).asInvalidProtocolBufferException();
            }
            return result;
          }
          
          public Resources buildPartial() {
            Resources result = new Resources(this);
            int from_bitField0_ = bitField0_;
            int to_bitField0_ = 0;
            if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
              to_bitField0_ |= 0x00000001;
            }
            result.project_ = project_;
            if (((from_bitField0_ & 0x00000002) == 0x00000002)) {
              to_bitField0_ |= 0x00000002;
            }
            result.resourceName_ = resourceName_;
            result.bitField0_ = to_bitField0_;
            onBuilt();
            return result;
          }
          
          public Builder mergeFrom(com.google.protobuf.Message other) {
            if (other instanceof Resources) {
              return mergeFrom((Resources)other);
            } else {
              super.mergeFrom(other);
              return this;
            }
          }
          
          public Builder mergeFrom(Resources other) {
            if (other == Resources.getDefaultInstance()) return this;
            if (other.hasProject()) {
              setProject(other.getProject());
            }
            if (other.hasResourceName()) {
              setResourceName(other.getResourceName());
            }
            this.mergeUnknownFields(other.getUnknownFields());
            return this;
          }
          
          public final boolean isInitialized() {
            if (!hasProject()) {
              
              return false;
            }
            if (!hasResourceName()) {
              
              return false;
            }
            return true;
          }
          
          public Builder mergeFrom(
              com.google.protobuf.CodedInputStream input,
              com.google.protobuf.ExtensionRegistryLite extensionRegistry)
              throws java.io.IOException {
            com.google.protobuf.UnknownFieldSet.Builder unknownFields =
              com.google.protobuf.UnknownFieldSet.newBuilder(
                this.getUnknownFields());
            while (true) {
              int tag = input.readTag();
              switch (tag) {
                case 0:
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                default: {
                  if (!parseUnknownField(input, unknownFields,
                                         extensionRegistry, tag)) {
                    this.setUnknownFields(unknownFields.build());
                    onChanged();
                    return this;
                  }
                  break;
                }
                case 10: {
                  bitField0_ |= 0x00000001;
                  project_ = input.readBytes();
                  break;
                }
                case 18: {
                  bitField0_ |= 0x00000002;
                  resourceName_ = input.readBytes();
                  break;
                }
              }
            }
          }
          
          private int bitField0_;
          
          // required string Project = 1;
          private Object project_ = "";
          public boolean hasProject() {
            return ((bitField0_ & 0x00000001) == 0x00000001);
          }
          public String getProject() {
            Object ref = project_;
            if (!(ref instanceof String)) {
              String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
              project_ = s;
              return s;
            } else {
              return (String) ref;
            }
          }
          public Builder setProject(String value) {
            if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
            project_ = value;
            onChanged();
            return this;
          }
          public Builder clearProject() {
            bitField0_ = (bitField0_ & ~0x00000001);
            project_ = getDefaultInstance().getProject();
            onChanged();
            return this;
          }
          void setProject(com.google.protobuf.ByteString value) {
            bitField0_ |= 0x00000001;
            project_ = value;
            onChanged();
          }
          
          // required string ResourceName = 2;
          private Object resourceName_ = "";
          public boolean hasResourceName() {
            return ((bitField0_ & 0x00000002) == 0x00000002);
          }
          public String getResourceName() {
            Object ref = resourceName_;
            if (!(ref instanceof String)) {
              String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
              resourceName_ = s;
              return s;
            } else {
              return (String) ref;
            }
          }
          public Builder setResourceName(String value) {
            if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000002;
            resourceName_ = value;
            onChanged();
            return this;
          }
          public Builder clearResourceName() {
            bitField0_ = (bitField0_ & ~0x00000002);
            resourceName_ = getDefaultInstance().getResourceName();
            onChanged();
            return this;
          }
          void setResourceName(com.google.protobuf.ByteString value) {
            bitField0_ |= 0x00000002;
            resourceName_ = value;
            onChanged();
          }
          
          // @@protoc_insertion_point(builder_scope:apsara.odps.lot.TemporaryFunction.Resources)
        }
        
        static {
          defaultInstance = new Resources(true);
          defaultInstance.initFields();
        }
        
        // @@protoc_insertion_point(class_scope:apsara.odps.lot.TemporaryFunction.Resources)
      }
      
      private int bitField0_;
      // required string Name = 1;
      public static final int NAME_FIELD_NUMBER = 1;
      private Object name_;
      public boolean hasName() {
        return ((bitField0_ & 0x00000001) == 0x00000001);
      }
      public String getName() {
        Object ref = name_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            name_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getNameBytes() {
        Object ref = name_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          name_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // repeated group Resources = 2 {
      public static final int RESOURCES_FIELD_NUMBER = 2;
      private java.util.List<Resources> resources_;
      public java.util.List<Resources> getResourcesList() {
        return resources_;
      }
      public java.util.List<? extends ResourcesOrBuilder>
          getResourcesOrBuilderList() {
        return resources_;
      }
      public int getResourcesCount() {
        return resources_.size();
      }
      public Resources getResources(int index) {
        return resources_.get(index);
      }
      public ResourcesOrBuilder getResourcesOrBuilder(
          int index) {
        return resources_.get(index);
      }
      
      // required string ClassName = 3;
      public static final int CLASSNAME_FIELD_NUMBER = 3;
      private Object className_;
      public boolean hasClassName() {
        return ((bitField0_ & 0x00000002) == 0x00000002);
      }
      public String getClassName() {
        Object ref = className_;
        if (ref instanceof String) {
          return (String) ref;
        } else {
          com.google.protobuf.ByteString bs = 
              (com.google.protobuf.ByteString) ref;
          String s = bs.toStringUtf8();
          if (com.google.protobuf.Internal.isValidUtf8(bs)) {
            className_ = s;
          }
          return s;
        }
      }
      private com.google.protobuf.ByteString getClassNameBytes() {
        Object ref = className_;
        if (ref instanceof String) {
          com.google.protobuf.ByteString b = 
              com.google.protobuf.ByteString.copyFromUtf8((String) ref);
          className_ = b;
          return b;
        } else {
          return (com.google.protobuf.ByteString) ref;
        }
      }
      
      // required .apsara.odps.Language Language = 4;
      public static final int LANGUAGE_FIELD_NUMBER = 4;
      private LanguageProtos.Language language_;
      public boolean hasLanguage() {
        return ((bitField0_ & 0x00000004) == 0x00000004);
      }
      public LanguageProtos.Language getLanguage() {
        return language_;
      }
      
      private void initFields() {
        name_ = "";
        resources_ = java.util.Collections.emptyList();
        className_ = "";
        language_ = LanguageProtos.Language.Java;
      }
      private byte memoizedIsInitialized = -1;
      public final boolean isInitialized() {
        byte isInitialized = memoizedIsInitialized;
        if (isInitialized != -1) return isInitialized == 1;
        
        if (!hasName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasClassName()) {
          memoizedIsInitialized = 0;
          return false;
        }
        if (!hasLanguage()) {
          memoizedIsInitialized = 0;
          return false;
        }
        for (int i = 0; i < getResourcesCount(); i++) {
          if (!getResources(i).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.writeBytes(1, getNameBytes());
        }
        for (int i = 0; i < resources_.size(); i++) {
          output.writeGroup(2, resources_.get(i));
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          output.writeBytes(3, getClassNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          output.writeEnum(4, language_.getNumber());
        }
        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, getNameBytes());
        }
        for (int i = 0; i < resources_.size(); i++) {
          size += com.google.protobuf.CodedOutputStream
            .computeGroupSize(2, resources_.get(i));
        }
        if (((bitField0_ & 0x00000002) == 0x00000002)) {
          size += com.google.protobuf.CodedOutputStream
            .computeBytesSize(3, getClassNameBytes());
        }
        if (((bitField0_ & 0x00000004) == 0x00000004)) {
          size += com.google.protobuf.CodedOutputStream
            .computeEnumSize(4, language_.getNumber());
        }
        size += getUnknownFields().getSerializedSize();
        memoizedSerializedSize = size;
        return size;
      }
      
      private static final long serialVersionUID = 0L;
      @Override
      protected Object writeReplace()
          throws java.io.ObjectStreamException {
        return super.writeReplace();
      }
      
      public static TemporaryFunction parseFrom(
          com.google.protobuf.ByteString data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static TemporaryFunction parseFrom(
          com.google.protobuf.ByteString data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static TemporaryFunction parseFrom(byte[] data)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data).buildParsed();
      }
      public static TemporaryFunction parseFrom(
          byte[] data,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws com.google.protobuf.InvalidProtocolBufferException {
        return newBuilder().mergeFrom(data, extensionRegistry)
                 .buildParsed();
      }
      public static TemporaryFunction parseFrom(java.io.InputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static TemporaryFunction parseFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      public static TemporaryFunction parseDelimitedFrom(java.io.InputStream input)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static TemporaryFunction parseDelimitedFrom(
          java.io.InputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        Builder builder = newBuilder();
        if (builder.mergeDelimitedFrom(input, extensionRegistry)) {
          return builder.buildParsed();
        } else {
          return null;
        }
      }
      public static TemporaryFunction parseFrom(
          com.google.protobuf.CodedInputStream input)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input).buildParsed();
      }
      public static TemporaryFunction parseFrom(
          com.google.protobuf.CodedInputStream input,
          com.google.protobuf.ExtensionRegistryLite extensionRegistry)
          throws java.io.IOException {
        return newBuilder().mergeFrom(input, extensionRegistry)
                 .buildParsed();
      }
      
      public static Builder newBuilder() { return Builder.create(); }
      public Builder newBuilderForType() { return newBuilder(); }
      public static Builder newBuilder(TemporaryFunction prototype) {
        return newBuilder().mergeFrom(prototype);
      }
      public Builder toBuilder() { return newBuilder(this); }
      
      @Override
      protected Builder newBuilderForType(
          BuilderParent parent) {
        Builder builder = new Builder(parent);
        return builder;
      }
      public static final class Builder extends
          com.google.protobuf.GeneratedMessage.Builder<Builder>
         implements TemporaryFunctionOrBuilder {
        public static final com.google.protobuf.Descriptors.Descriptor
            getDescriptor() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_descriptor;
        }
        
        protected FieldAccessorTable
            internalGetFieldAccessorTable() {
          return ExpressionProtos.internal_static_apsara_odps_lot_TemporaryFunction_fieldAccessorTable;
        }
        
        // Construct using apsara.odps.lot.ExpressionProtos.TemporaryFunction.newBuilder()
        private Builder() {
          maybeForceBuilderInitialization();
        }
        
        private Builder(BuilderParent parent) {
          super(parent);
          maybeForceBuilderInitialization();
        }
        private void maybeForceBuilderInitialization() {
          if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
            getResourcesFieldBuilder();
          }
        }
        private static Builder create() {
          return new Builder();
        }
        
        public Builder clear() {
          super.clear();
          name_ = "";
          bitField0_ = (bitField0_ & ~0x00000001);
          if (resourcesBuilder_ == null) {
            resources_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000002);
          } else {
            resourcesBuilder_.clear();
          }
          className_ = "";
          bitField0_ = (bitField0_ & ~0x00000004);
          language_ = LanguageProtos.Language.Java;
          bitField0_ = (bitField0_ & ~0x00000008);
          return this;
        }
        
        public Builder clone() {
          return create().mergeFrom(buildPartial());
        }
        
        public com.google.protobuf.Descriptors.Descriptor
            getDescriptorForType() {
          return TemporaryFunction.getDescriptor();
        }
        
        public TemporaryFunction getDefaultInstanceForType() {
          return TemporaryFunction.getDefaultInstance();
        }
        
        public TemporaryFunction build() {
          TemporaryFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(result);
          }
          return result;
        }
        
        private TemporaryFunction buildParsed()
            throws com.google.protobuf.InvalidProtocolBufferException {
          TemporaryFunction result = buildPartial();
          if (!result.isInitialized()) {
            throw newUninitializedMessageException(
              result).asInvalidProtocolBufferException();
          }
          return result;
        }
        
        public TemporaryFunction buildPartial() {
          TemporaryFunction result = new TemporaryFunction(this);
          int from_bitField0_ = bitField0_;
          int to_bitField0_ = 0;
          if (((from_bitField0_ & 0x00000001) == 0x00000001)) {
            to_bitField0_ |= 0x00000001;
          }
          result.name_ = name_;
          if (resourcesBuilder_ == null) {
            if (((bitField0_ & 0x00000002) == 0x00000002)) {
              resources_ = java.util.Collections.unmodifiableList(resources_);
              bitField0_ = (bitField0_ & ~0x00000002);
            }
            result.resources_ = resources_;
          } else {
            result.resources_ = resourcesBuilder_.build();
          }
          if (((from_bitField0_ & 0x00000004) == 0x00000004)) {
            to_bitField0_ |= 0x00000002;
          }
          result.className_ = className_;
          if (((from_bitField0_ & 0x00000008) == 0x00000008)) {
            to_bitField0_ |= 0x00000004;
          }
          result.language_ = language_;
          result.bitField0_ = to_bitField0_;
          onBuilt();
          return result;
        }
        
        public Builder mergeFrom(com.google.protobuf.Message other) {
          if (other instanceof TemporaryFunction) {
            return mergeFrom((TemporaryFunction)other);
          } else {
            super.mergeFrom(other);
            return this;
          }
        }
        
        public Builder mergeFrom(TemporaryFunction other) {
          if (other == TemporaryFunction.getDefaultInstance()) return this;
          if (other.hasName()) {
            setName(other.getName());
          }
          if (resourcesBuilder_ == null) {
            if (!other.resources_.isEmpty()) {
              if (resources_.isEmpty()) {
                resources_ = other.resources_;
                bitField0_ = (bitField0_ & ~0x00000002);
              } else {
                ensureResourcesIsMutable();
                resources_.addAll(other.resources_);
              }
              onChanged();
            }
          } else {
            if (!other.resources_.isEmpty()) {
              if (resourcesBuilder_.isEmpty()) {
                resourcesBuilder_.dispose();
                resourcesBuilder_ = null;
                resources_ = other.resources_;
                bitField0_ = (bitField0_ & ~0x00000002);
                resourcesBuilder_ = 
                  com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ?
                     getResourcesFieldBuilder() : null;
              } else {
                resourcesBuilder_.addAllMessages(other.resources_);
              }
            }
          }
          if (other.hasClassName()) {
            setClassName(other.getClassName());
          }
          if (other.hasLanguage()) {
            setLanguage(other.getLanguage());
          }
          this.mergeUnknownFields(other.getUnknownFields());
          return this;
        }
        
        public final boolean isInitialized() {
          if (!hasName()) {
            
            return false;
          }
          if (!hasClassName()) {
            
            return false;
          }
          if (!hasLanguage()) {
            
            return false;
          }
          for (int i = 0; i < getResourcesCount(); i++) {
            if (!getResources(i).isInitialized()) {
              
              return false;
            }
          }
          return true;
        }
        
        public Builder mergeFrom(
            com.google.protobuf.CodedInputStream input,
            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
            throws java.io.IOException {
          com.google.protobuf.UnknownFieldSet.Builder unknownFields =
            com.google.protobuf.UnknownFieldSet.newBuilder(
              this.getUnknownFields());
          while (true) {
            int tag = input.readTag();
            switch (tag) {
              case 0:
                this.setUnknownFields(unknownFields.build());
                onChanged();
                return this;
              default: {
                if (!parseUnknownField(input, unknownFields,
                                       extensionRegistry, tag)) {
                  this.setUnknownFields(unknownFields.build());
                  onChanged();
                  return this;
                }
                break;
              }
              case 10: {
                bitField0_ |= 0x00000001;
                name_ = input.readBytes();
                break;
              }
              case 19: {
                Resources.Builder subBuilder = Resources.newBuilder();
                input.readGroup(2, subBuilder, extensionRegistry);
                addResources(subBuilder.buildPartial());
                break;
              }
              case 26: {
                bitField0_ |= 0x00000004;
                className_ = input.readBytes();
                break;
              }
              case 32: {
                int rawValue = input.readEnum();
                LanguageProtos.Language value = LanguageProtos.Language.valueOf(rawValue);
                if (value == null) {
                  unknownFields.mergeVarintField(4, rawValue);
                } else {
                  bitField0_ |= 0x00000008;
                  language_ = value;
                }
                break;
              }
            }
          }
        }
        
        private int bitField0_;
        
        // required string Name = 1;
        private Object name_ = "";
        public boolean hasName() {
          return ((bitField0_ & 0x00000001) == 0x00000001);
        }
        public String getName() {
          Object ref = name_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            name_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000001;
          name_ = value;
          onChanged();
          return this;
        }
        public Builder clearName() {
          bitField0_ = (bitField0_ & ~0x00000001);
          name_ = getDefaultInstance().getName();
          onChanged();
          return this;
        }
        void setName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000001;
          name_ = value;
          onChanged();
        }
        
        // repeated group Resources = 2 {
        private java.util.List<Resources> resources_ =
          java.util.Collections.emptyList();
        private void ensureResourcesIsMutable() {
          if (!((bitField0_ & 0x00000002) == 0x00000002)) {
            resources_ = new java.util.ArrayList<Resources>(resources_);
            bitField0_ |= 0x00000002;
           }
        }
        
        private com.google.protobuf.RepeatedFieldBuilder<
            Resources, Resources.Builder, ResourcesOrBuilder> resourcesBuilder_;
        
        public java.util.List<Resources> getResourcesList() {
          if (resourcesBuilder_ == null) {
            return java.util.Collections.unmodifiableList(resources_);
          } else {
            return resourcesBuilder_.getMessageList();
          }
        }
        public int getResourcesCount() {
          if (resourcesBuilder_ == null) {
            return resources_.size();
          } else {
            return resourcesBuilder_.getCount();
          }
        }
        public Resources getResources(int index) {
          if (resourcesBuilder_ == null) {
            return resources_.get(index);
          } else {
            return resourcesBuilder_.getMessage(index);
          }
        }
        public Builder setResources(
            int index, Resources value) {
          if (resourcesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureResourcesIsMutable();
            resources_.set(index, value);
            onChanged();
          } else {
            resourcesBuilder_.setMessage(index, value);
          }
          return this;
        }
        public Builder setResources(
            int index, Resources.Builder builderForValue) {
          if (resourcesBuilder_ == null) {
            ensureResourcesIsMutable();
            resources_.set(index, builderForValue.build());
            onChanged();
          } else {
            resourcesBuilder_.setMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addResources(Resources value) {
          if (resourcesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureResourcesIsMutable();
            resources_.add(value);
            onChanged();
          } else {
            resourcesBuilder_.addMessage(value);
          }
          return this;
        }
        public Builder addResources(
            int index, Resources value) {
          if (resourcesBuilder_ == null) {
            if (value == null) {
              throw new NullPointerException();
            }
            ensureResourcesIsMutable();
            resources_.add(index, value);
            onChanged();
          } else {
            resourcesBuilder_.addMessage(index, value);
          }
          return this;
        }
        public Builder addResources(
            Resources.Builder builderForValue) {
          if (resourcesBuilder_ == null) {
            ensureResourcesIsMutable();
            resources_.add(builderForValue.build());
            onChanged();
          } else {
            resourcesBuilder_.addMessage(builderForValue.build());
          }
          return this;
        }
        public Builder addResources(
            int index, Resources.Builder builderForValue) {
          if (resourcesBuilder_ == null) {
            ensureResourcesIsMutable();
            resources_.add(index, builderForValue.build());
            onChanged();
          } else {
            resourcesBuilder_.addMessage(index, builderForValue.build());
          }
          return this;
        }
        public Builder addAllResources(
            Iterable<? extends Resources> values) {
          if (resourcesBuilder_ == null) {
            ensureResourcesIsMutable();
            super.addAll(values, resources_);
            onChanged();
          } else {
            resourcesBuilder_.addAllMessages(values);
          }
          return this;
        }
        public Builder clearResources() {
          if (resourcesBuilder_ == null) {
            resources_ = java.util.Collections.emptyList();
            bitField0_ = (bitField0_ & ~0x00000002);
            onChanged();
          } else {
            resourcesBuilder_.clear();
          }
          return this;
        }
        public Builder removeResources(int index) {
          if (resourcesBuilder_ == null) {
            ensureResourcesIsMutable();
            resources_.remove(index);
            onChanged();
          } else {
            resourcesBuilder_.remove(index);
          }
          return this;
        }
        public Resources.Builder getResourcesBuilder(
            int index) {
          return getResourcesFieldBuilder().getBuilder(index);
        }
        public ResourcesOrBuilder getResourcesOrBuilder(
            int index) {
          if (resourcesBuilder_ == null) {
            return resources_.get(index);  } else {
            return resourcesBuilder_.getMessageOrBuilder(index);
          }
        }
        public java.util.List<? extends ResourcesOrBuilder>
             getResourcesOrBuilderList() {
          if (resourcesBuilder_ != null) {
            return resourcesBuilder_.getMessageOrBuilderList();
          } else {
            return java.util.Collections.unmodifiableList(resources_);
          }
        }
        public Resources.Builder addResourcesBuilder() {
          return getResourcesFieldBuilder().addBuilder(
              Resources.getDefaultInstance());
        }
        public Resources.Builder addResourcesBuilder(
            int index) {
          return getResourcesFieldBuilder().addBuilder(
              index, Resources.getDefaultInstance());
        }
        public java.util.List<Resources.Builder>
             getResourcesBuilderList() {
          return getResourcesFieldBuilder().getBuilderList();
        }
        private com.google.protobuf.RepeatedFieldBuilder<
            Resources, Resources.Builder, ResourcesOrBuilder>
            getResourcesFieldBuilder() {
          if (resourcesBuilder_ == null) {
            resourcesBuilder_ = new com.google.protobuf.RepeatedFieldBuilder<
                Resources, Resources.Builder, ResourcesOrBuilder>(
                    resources_,
                    ((bitField0_ & 0x00000002) == 0x00000002),
                    getParentForChildren(),
                    isClean());
            resources_ = null;
          }
          return resourcesBuilder_;
        }
        
        // required string ClassName = 3;
        private Object className_ = "";
        public boolean hasClassName() {
          return ((bitField0_ & 0x00000004) == 0x00000004);
        }
        public String getClassName() {
          Object ref = className_;
          if (!(ref instanceof String)) {
            String s = ((com.google.protobuf.ByteString) ref).toStringUtf8();
            className_ = s;
            return s;
          } else {
            return (String) ref;
          }
        }
        public Builder setClassName(String value) {
          if (value == null) {
      throw new NullPointerException();
    }
    bitField0_ |= 0x00000004;
          className_ = value;
          onChanged();
          return this;
        }
        public Builder clearClassName() {
          bitField0_ = (bitField0_ & ~0x00000004);
          className_ = getDefaultInstance().getClassName();
          onChanged();
          return this;
        }
        void setClassName(com.google.protobuf.ByteString value) {
          bitField0_ |= 0x00000004;
          className_ = value;
          onChanged();
        }
        
        // required .apsara.odps.Language Language = 4;
        private LanguageProtos.Language language_ = LanguageProtos.Language.Java;
        public boolean hasLanguage() {
          return ((bitField0_ & 0x00000008) == 0x00000008);
        }
        public LanguageProtos.Language getLanguage() {
          return language_;
        }
        public Builder setLanguage(LanguageProtos.Language value) {
          if (value == null) {
            throw new NullPointerException();
          }
          bitField0_ |= 0x00000008;
          language_ = value;
          onChanged();
          return this;
        }
        public Builder clearLanguage() {
          bitField0_ = (bitField0_ & ~0x00000008);
          language_ = LanguageProtos.Language.Java;
          onChanged();
          return this;
        }
        
        // @@protoc_insertion_point(builder_scope:apsara.odps.lot.TemporaryFunction)
      }
      
      static {
        defaultInstance = new TemporaryFunction(true);
        defaultInstance.initFields();
      }
      
      // @@protoc_insertion_point(class_scope:apsara.odps.lot.TemporaryFunction)
    }
    
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_ScalarExpression_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_ScalarExpression_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_ScalarFunction_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_ScalarFunction_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_AggregationFunction_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_AggregationFunction_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_WindowFunction_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_WindowFunction_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_WindowFunction_OrderBy_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_WindowFunction_OrderBy_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_WindowFunction_WindowingClause_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_WindowFunction_WindowingClause_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_TableValuedFunction_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_TableValuedFunction_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_TableValuedFunction_Properties_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_TableValuedFunction_Properties_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_TemporaryFunction_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_TemporaryFunction_fieldAccessorTable;
    private static com.google.protobuf.Descriptors.Descriptor
      internal_static_apsara_odps_lot_TemporaryFunction_Resources_descriptor;
    private static
      com.google.protobuf.GeneratedMessage.FieldAccessorTable
        internal_static_apsara_odps_lot_TemporaryFunction_Resources_fieldAccessorTable;
    
    public static com.google.protobuf.Descriptors.FileDescriptor
        getDescriptor() {
      return descriptor;
    }
    private static com.google.protobuf.Descriptors.FileDescriptor
        descriptor;
    static {
      String[] descriptorData = {
        "\n\024lot/expression.proto\022\017apsara.odps.lot\032" +
        "\022common/types.proto\032\027common/expression.p" +
        "roto\032\025common/language.proto\"\274\001\n\020ScalarEx" +
        "pression\022)\n\tReference\030\001 \001(\0132\026.apsara.odp" +
        "s.Reference\022\'\n\010Constant\030\002 \001(\0132\025.apsara.o" +
        "dps.Constant\022\037\n\004Null\030\003 \001(\0132\021.apsara.odps" +
        ".Null\0223\n\nExpression\030\004 \001(\0132\037.apsara.odps." +
        "lot.ScalarFunction\"\205\001\n\016ScalarFunction\022\017\n" +
        "\007Project\030\001 \002(\t\022\014\n\004Name\030\002 \002(\t\0225\n\nParamete" +
        "rs\030\003 \003(\0132!.apsara.odps.lot.ScalarExpress",
        "ion\022\035\n\016requireBuiltin\030\004 \001(\010:\005false\"\236\001\n\023A" +
        "ggregationFunction\022\017\n\007Project\030\001 \002(\t\022\014\n\004N" +
        "ame\030\002 \002(\t\022\022\n\nIsDistinct\030\003 \002(\010\0225\n\nParamet" +
        "ers\030\004 \003(\0132!.apsara.odps.lot.ScalarExpres" +
        "sion\022\035\n\016requireBuiltin\030\005 \001(\010:\005false\"\333\003\n\016" +
        "WindowFunction\022\017\n\007Project\030\001 \002(\t\022\014\n\004Name\030" +
        "\002 \002(\t\022\022\n\nIsDistinct\030\003 \001(\010\0225\n\nParameters\030" +
        "\004 \003(\0132!.apsara.odps.lot.ScalarExpression" +
        "\0226\n\013PartitionBy\030\005 \003(\0132!.apsara.odps.lot." +
        "ScalarExpression\0228\n\007orderby\030\006 \003(\n2\'.apsa",
        "ra.odps.lot.WindowFunction.OrderBy\022H\n\017wi" +
        "ndowingclause\030\007 \001(\n2/.apsara.odps.lot.Wi" +
        "ndowFunction.WindowingClause\022\035\n\016requireB" +
        "uiltin\030\010 \001(\010:\005false\032U\n\007OrderBy\0225\n\nExpres" +
        "sion\030\001 \002(\0132!.apsara.odps.lot.ScalarExpre" +
        "ssion\022\023\n\005IsAsc\030\002 \001(\010:\004true\032-\n\017WindowingC" +
        "lause\022\r\n\005Begin\030\001 \002(\005\022\013\n\003End\030\002 \002(\005\"\220\002\n\023Ta" +
        "bleValuedFunction\022\017\n\007Project\030\001 \002(\t\022\014\n\004Na" +
        "me\030\002 \002(\t\0225\n\nParameters\030\003 \003(\0132!.apsara.od" +
        "ps.lot.ScalarExpression\022\025\n\rOutputColumns",
        "\030\004 \003(\t\022C\n\nproperties\030\005 \003(\n2/.apsara.odps" +
        ".lot.TableValuedFunction.Properties\022\035\n\016r" +
        "equireBuiltin\030\006 \001(\010:\005false\032(\n\nProperties" +
        "\022\013\n\003Key\030\001 \002(\t\022\r\n\005Value\030\002 \002(\t\"\322\001\n\021Tempora" +
        "ryFunction\022\014\n\004Name\030\001 \002(\t\022?\n\tresources\030\002 " +
        "\003(\n2,.apsara.odps.lot.TemporaryFunction." +
        "Resources\022\021\n\tClassName\030\003 \002(\t\022\'\n\010Language" +
        "\030\004 \002(\0162\025.apsara.odps.Language\0322\n\tResourc" +
        "es\022\017\n\007Project\030\001 \002(\t\022\024\n\014ResourceName\030\002 \002(" +
        "\tB\022B\020ExpressionProtos"
      };
      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_apsara_odps_lot_ScalarExpression_descriptor =
              getDescriptor().getMessageTypes().get(0);
            internal_static_apsara_odps_lot_ScalarExpression_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_ScalarExpression_descriptor,
                new String[] { "Reference", "Constant", "Null", "Expression", },
                ScalarExpression.class,
                ScalarExpression.Builder.class);
            internal_static_apsara_odps_lot_ScalarFunction_descriptor =
              getDescriptor().getMessageTypes().get(1);
            internal_static_apsara_odps_lot_ScalarFunction_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_ScalarFunction_descriptor,
                new String[] { "Project", "Name", "Parameters", "RequireBuiltin", },
                ScalarFunction.class,
                ScalarFunction.Builder.class);
            internal_static_apsara_odps_lot_AggregationFunction_descriptor =
              getDescriptor().getMessageTypes().get(2);
            internal_static_apsara_odps_lot_AggregationFunction_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_AggregationFunction_descriptor,
                new String[] { "Project", "Name", "IsDistinct", "Parameters", "RequireBuiltin", },
                AggregationFunction.class,
                AggregationFunction.Builder.class);
            internal_static_apsara_odps_lot_WindowFunction_descriptor =
              getDescriptor().getMessageTypes().get(3);
            internal_static_apsara_odps_lot_WindowFunction_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_WindowFunction_descriptor,
                new String[] { "Project", "Name", "IsDistinct", "Parameters", "PartitionBy", "OrderBy", "WindowingClause", "RequireBuiltin", },
                WindowFunction.class,
                WindowFunction.Builder.class);
            internal_static_apsara_odps_lot_WindowFunction_OrderBy_descriptor =
              internal_static_apsara_odps_lot_WindowFunction_descriptor.getNestedTypes().get(0);
            internal_static_apsara_odps_lot_WindowFunction_OrderBy_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_WindowFunction_OrderBy_descriptor,
                new String[] { "Expression", "IsAsc", },
                WindowFunction.OrderBy.class,
                WindowFunction.OrderBy.Builder.class);
            internal_static_apsara_odps_lot_WindowFunction_WindowingClause_descriptor =
              internal_static_apsara_odps_lot_WindowFunction_descriptor.getNestedTypes().get(1);
            internal_static_apsara_odps_lot_WindowFunction_WindowingClause_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_WindowFunction_WindowingClause_descriptor,
                new String[] { "Begin", "End", },
                WindowFunction.WindowingClause.class,
                WindowFunction.WindowingClause.Builder.class);
            internal_static_apsara_odps_lot_TableValuedFunction_descriptor =
              getDescriptor().getMessageTypes().get(4);
            internal_static_apsara_odps_lot_TableValuedFunction_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_TableValuedFunction_descriptor,
                new String[] { "Project", "Name", "Parameters", "OutputColumns", "Properties", "RequireBuiltin", },
                TableValuedFunction.class,
                TableValuedFunction.Builder.class);
            internal_static_apsara_odps_lot_TableValuedFunction_Properties_descriptor =
              internal_static_apsara_odps_lot_TableValuedFunction_descriptor.getNestedTypes().get(0);
            internal_static_apsara_odps_lot_TableValuedFunction_Properties_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_TableValuedFunction_Properties_descriptor,
                new String[] { "Key", "Value", },
                TableValuedFunction.Properties.class,
                TableValuedFunction.Properties.Builder.class);
            internal_static_apsara_odps_lot_TemporaryFunction_descriptor =
              getDescriptor().getMessageTypes().get(5);
            internal_static_apsara_odps_lot_TemporaryFunction_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_TemporaryFunction_descriptor,
                new String[] { "Name", "Resources", "ClassName", "Language", },
                TemporaryFunction.class,
                TemporaryFunction.Builder.class);
            internal_static_apsara_odps_lot_TemporaryFunction_Resources_descriptor =
              internal_static_apsara_odps_lot_TemporaryFunction_descriptor.getNestedTypes().get(0);
            internal_static_apsara_odps_lot_TemporaryFunction_Resources_fieldAccessorTable = new
              com.google.protobuf.GeneratedMessage.FieldAccessorTable(
                internal_static_apsara_odps_lot_TemporaryFunction_Resources_descriptor,
                new String[] { "Project", "ResourceName", },
                TemporaryFunction.Resources.class,
                TemporaryFunction.Resources.Builder.class);
            return null;
          }
        };
      com.google.protobuf.Descriptors.FileDescriptor
        .internalBuildGeneratedFileFrom(descriptorData,
          new com.google.protobuf.Descriptors.FileDescriptor[] {
            TypesProtos.getDescriptor(),
            apsara.odps.ExpressionProtos.getDescriptor(),
            LanguageProtos.getDescriptor(),
          }, assigner);
    }
    
    // @@protoc_insertion_point(outer_class_scope)
  }
  