if (!other.getSql().isEmpty()) { sql_ = other.sql_; onChanged();
if (!other.getSql().isEmpty()) { sql_ = other.sql_; onChanged();
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (getColumnsCount() > 0) { hash = (37 * hash) + COLUMNS_FIELD_NUMBER; hash = (53 * hash) + getColumnsList().hashCode(); } hash = (37 * hash) + SQL_FIELD_NUMBER; hash = (53 * hash) + getSql().hashCode(); if (getParametersCount() > 0) { hash = (37 * hash) + PARAMETERS_FIELD_NUMBER; hash = (53 * hash) + getParametersList().hashCode(); } if (hasCursorFactory()) { hash = (37 * hash) + CURSOR_FACTORY_FIELD_NUMBER; hash = (53 * hash) + getCursorFactory().hashCode(); } hash = (37 * hash) + STATEMENTTYPE_FIELD_NUMBER; hash = (53 * hash) + statementType_; hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
if (!other.getSql().isEmpty()) { sql_ = other.sql_; onChanged();
@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); if (getColumnsCount() > 0) { hash = (37 * hash) + COLUMNS_FIELD_NUMBER; hash = (53 * hash) + getColumnsList().hashCode(); } hash = (37 * hash) + SQL_FIELD_NUMBER; hash = (53 * hash) + getSql().hashCode(); if (getParametersCount() > 0) { hash = (37 * hash) + PARAMETERS_FIELD_NUMBER; hash = (53 * hash) + getParametersList().hashCode(); } if (hasCursorFactory()) { hash = (37 * hash) + CURSOR_FACTORY_FIELD_NUMBER; hash = (53 * hash) + getCursorFactory().hashCode(); } hash = (37 * hash) + STATEMENTTYPE_FIELD_NUMBER; hash = (53 * hash) + statementType_; hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.apache.calcite.avatica.proto.Common.Signature)) { return super.equals(obj); } org.apache.calcite.avatica.proto.Common.Signature other = (org.apache.calcite.avatica.proto.Common.Signature) obj; boolean result = true; result = result && getColumnsList() .equals(other.getColumnsList()); result = result && getSql() .equals(other.getSql()); result = result && getParametersList() .equals(other.getParametersList()); result = result && (hasCursorFactory() == other.hasCursorFactory()); if (hasCursorFactory()) { result = result && getCursorFactory() .equals(other.getCursorFactory()); } result = result && statementType_ == other.statementType_; result = result && unknownFields.equals(other.unknownFields); return result; }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.apache.calcite.avatica.proto.Common.Signature)) { return super.equals(obj); } org.apache.calcite.avatica.proto.Common.Signature other = (org.apache.calcite.avatica.proto.Common.Signature) obj; boolean result = true; result = result && getColumnsList() .equals(other.getColumnsList()); result = result && getSql() .equals(other.getSql()); result = result && getParametersList() .equals(other.getParametersList()); result = result && (hasCursorFactory() == other.hasCursorFactory()); if (hasCursorFactory()) { result = result && getCursorFactory() .equals(other.getCursorFactory()); } result = result && statementType_ == other.statementType_; result = result && unknownFields.equals(other.unknownFields); return result; }
public static Signature fromProto(Common.Signature protoSignature) { List<ColumnMetaData> metadata = new ArrayList<>(protoSignature.getColumnsCount()); for (Common.ColumnMetaData protoMetadata : protoSignature.getColumnsList()) { metadata.add(ColumnMetaData.fromProto(protoMetadata)); } List<AvaticaParameter> parameters = new ArrayList<>(protoSignature.getParametersCount()); for (Common.AvaticaParameter protoParam : protoSignature.getParametersList()) { parameters.add(AvaticaParameter.fromProto(protoParam)); } final Descriptor desc = protoSignature.getDescriptorForType(); String sql = null; if (ProtobufService.hasField(protoSignature, desc, Common.Signature.SQL_FIELD_NUMBER)) { sql = protoSignature.getSql(); } CursorFactory cursorFactory = null; if (ProtobufService.hasField(protoSignature, desc, Common.Signature.CURSOR_FACTORY_FIELD_NUMBER)) { cursorFactory = CursorFactory.fromProto(protoSignature.getCursorFactory()); } final Meta.StatementType statementType = Meta.StatementType.fromProto(protoSignature.getStatementType()); return Signature.create(metadata, sql, parameters, cursorFactory, statementType); }
public static Signature fromProto(Common.Signature protoSignature) { List<ColumnMetaData> metadata = new ArrayList<>(protoSignature.getColumnsCount()); for (Common.ColumnMetaData protoMetadata : protoSignature.getColumnsList()) { metadata.add(ColumnMetaData.fromProto(protoMetadata)); } List<AvaticaParameter> parameters = new ArrayList<>(protoSignature.getParametersCount()); for (Common.AvaticaParameter protoParam : protoSignature.getParametersList()) { parameters.add(AvaticaParameter.fromProto(protoParam)); } String sql = null; if (protoSignature.hasField(SQL_DESCRIPTOR)) { sql = protoSignature.getSql(); } CursorFactory cursorFactory = null; if (protoSignature.hasField(CURSOR_FACTORY_DESCRIPTOR)) { cursorFactory = CursorFactory.fromProto(protoSignature.getCursorFactory()); } final Meta.StatementType statementType = Meta.StatementType.fromProto(protoSignature.getStatementType()); return Signature.create(metadata, sql, parameters, cursorFactory, statementType); }
public static Signature fromProto(Common.Signature protoSignature) { List<ColumnMetaData> metadata = new ArrayList<>(protoSignature.getColumnsCount()); for (Common.ColumnMetaData protoMetadata : protoSignature.getColumnsList()) { metadata.add(ColumnMetaData.fromProto(protoMetadata)); } List<AvaticaParameter> parameters = new ArrayList<>(protoSignature.getParametersCount()); for (Common.AvaticaParameter protoParam : protoSignature.getParametersList()) { parameters.add(AvaticaParameter.fromProto(protoParam)); } String sql = null; if (protoSignature.hasField(SQL_DESCRIPTOR)) { sql = protoSignature.getSql(); } CursorFactory cursorFactory = null; if (protoSignature.hasField(CURSOR_FACTORY_DESCRIPTOR)) { cursorFactory = CursorFactory.fromProto(protoSignature.getCursorFactory()); } final Meta.StatementType statementType = Meta.StatementType.fromProto(protoSignature.getStatementType()); return Signature.create(metadata, sql, parameters, cursorFactory, statementType); }
/** * <code>string sql = 2;</code> */ public Builder clearSql() { sql_ = getDefaultInstance().getSql(); onChanged(); return this; } /**
/** * <code>string sql = 2;</code> */ public Builder clearSql() { sql_ = getDefaultInstance().getSql(); onChanged(); return this; } /**
/** * <code>optional string sql = 2;</code> */ public Builder clearSql() { sql_ = getDefaultInstance().getSql(); onChanged(); return this; } /**