Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public DateTime getDateTime(String name) {
@Override
public Blob getBlob(String name) {
Value<?> value = getValue(name);
if (value.meaning() == 18 && value instanceof StringValue) {
if (value.getMeaning() == 18 && value instanceof StringValue) {
return new Blob(ByteString.copyFromUtf8(getString(name)));
}
return ((Value<Blob>) value).get();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@

import static com.google.common.base.Preconditions.checkNotNull;

import com.google.cloud.GcpLaunchStage;
import com.google.common.base.MoreObjects;
import com.google.datastore.v1.Value.ValueTypeCase;

Expand Down Expand Up @@ -56,7 +57,7 @@ abstract static class BaseMarshaller<V, P extends Value<V>, B extends ValueBuild
public final B fromProto(com.google.datastore.v1.Value proto) {
B builder = newBuilder(getValue(proto));
builder.setExcludeFromIndexes(proto.getExcludeFromIndexes());
builder.meaning(proto.getMeaning());
builder.setMeaning(proto.getMeaning());
return builder;
}

Expand All @@ -65,7 +66,7 @@ public final B fromProto(com.google.datastore.v1.Value proto) {
public final com.google.datastore.v1.Value toProto(P value) {
com.google.datastore.v1.Value.Builder builder = com.google.datastore.v1.Value.newBuilder();
builder.setExcludeFromIndexes(value.excludeFromIndexes());
builder.setMeaning(value.meaning());
builder.setMeaning(value.getMeaning());
setValue(value, builder);
return builder.build();
}
Expand Down Expand Up @@ -111,19 +112,13 @@ public B setExcludeFromIndexes(boolean excludeFromIndexes) {
return self();
}

@Deprecated
@GcpLaunchStage.Deprecated
@Override
public int getMeaning() {
return meaning;
}

@Deprecated
@Override
public B meaning(int meaning) {
return setMeaning(meaning);
}

@Deprecated
@GcpLaunchStage.Deprecated
@Override
public B setMeaning(int meaning) {
this.meaning = meaning;
Expand Down Expand Up @@ -158,14 +153,6 @@ <P extends Value<V>, B extends BaseBuilder<V, P, B>> Value(ValueBuilder<V, P, B>
value = builder.get();
}

/**
* Returns the type of this value.
*/
@Deprecated
public final ValueType type() {
return getType();
}

/**
* Returns the type of this value.
*/
Expand All @@ -180,12 +167,7 @@ public final boolean excludeFromIndexes() {
return excludeFromIndexes;
}

@Deprecated
final int meaning() {
return getMeaning();
}

@Deprecated
@GcpLaunchStage.Deprecated
final int getMeaning() {
return meaning;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@

package com.google.cloud.datastore;

import com.google.cloud.GcpLaunchStage;

/**
* A common interface for Value builders.
*
Expand All @@ -36,19 +38,13 @@ public interface ValueBuilder<V, P extends Value<V>, B extends ValueBuilder<V, P
/**
* Deprecated. This library preserves the field for backwards compatibility.
*/
@Deprecated
@GcpLaunchStage.Deprecated
int getMeaning();

/**
* Deprecated. This library preserves the field for backwards compatibility.
*/
@Deprecated
B meaning(int meaning);

/**
* Deprecated. This library preserves the field for backwards compatibility.
*/
@Deprecated
@GcpLaunchStage.Deprecated
B setMeaning(int meaning);

V get();
Expand Down