datastore

package
v0.0.0-...-52d6a69 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 19, 2019 License: Apache-2.0, Apache-2.0 Imports: 10 Imported by: 0

Documentation

Overview

Package datastore is a generated protocol buffer package.

It is generated from these files:

google/datastore/v1/datastore.proto
google/datastore/v1/entity.proto
google/datastore/v1/query.proto

It has these top-level messages:

LookupRequest
LookupResponse
RunQueryRequest
RunQueryResponse
BeginTransactionRequest
BeginTransactionResponse
RollbackRequest
RollbackResponse
CommitRequest
CommitResponse
AllocateIdsRequest
AllocateIdsResponse
Mutation
MutationResult
ReadOptions
TransactionOptions
PartitionId
Key
ArrayValue
Value
Entity
EntityResult
Query
KindExpression
PropertyReference
Projection
PropertyOrder
Filter
CompositeFilter
PropertyFilter
GqlQuery
GqlQueryParameter
QueryResultBatch

Index

Constants

This section is empty.

Variables

View Source
var CommitRequest_Mode_name = map[int32]string{
	0: "MODE_UNSPECIFIED",
	1: "TRANSACTIONAL",
	2: "NON_TRANSACTIONAL",
}
View Source
var CommitRequest_Mode_value = map[string]int32{
	"MODE_UNSPECIFIED":  0,
	"TRANSACTIONAL":     1,
	"NON_TRANSACTIONAL": 2,
}
View Source
var CompositeFilter_Operator_name = map[int32]string{
	0: "OPERATOR_UNSPECIFIED",
	1: "AND",
}
View Source
var CompositeFilter_Operator_value = map[string]int32{
	"OPERATOR_UNSPECIFIED": 0,
	"AND":                  1,
}
View Source
var EntityResult_ResultType_name = map[int32]string{
	0: "RESULT_TYPE_UNSPECIFIED",
	1: "FULL",
	2: "PROJECTION",
	3: "KEY_ONLY",
}
View Source
var EntityResult_ResultType_value = map[string]int32{
	"RESULT_TYPE_UNSPECIFIED": 0,
	"FULL":                    1,
	"PROJECTION":              2,
	"KEY_ONLY":                3,
}
View Source
var PropertyFilter_Operator_name = map[int32]string{
	0:  "OPERATOR_UNSPECIFIED",
	1:  "LESS_THAN",
	2:  "LESS_THAN_OR_EQUAL",
	3:  "GREATER_THAN",
	4:  "GREATER_THAN_OR_EQUAL",
	5:  "EQUAL",
	11: "HAS_ANCESTOR",
}
View Source
var PropertyFilter_Operator_value = map[string]int32{
	"OPERATOR_UNSPECIFIED":  0,
	"LESS_THAN":             1,
	"LESS_THAN_OR_EQUAL":    2,
	"GREATER_THAN":          3,
	"GREATER_THAN_OR_EQUAL": 4,
	"EQUAL":                 5,
	"HAS_ANCESTOR":          11,
}
View Source
var PropertyOrder_Direction_name = map[int32]string{
	0: "DIRECTION_UNSPECIFIED",
	1: "ASCENDING",
	2: "DESCENDING",
}
View Source
var PropertyOrder_Direction_value = map[string]int32{
	"DIRECTION_UNSPECIFIED": 0,
	"ASCENDING":             1,
	"DESCENDING":            2,
}
View Source
var QueryResultBatch_MoreResultsType_name = map[int32]string{
	0: "MORE_RESULTS_TYPE_UNSPECIFIED",
	1: "NOT_FINISHED",
	2: "MORE_RESULTS_AFTER_LIMIT",
	4: "MORE_RESULTS_AFTER_CURSOR",
	3: "NO_MORE_RESULTS",
}
View Source
var QueryResultBatch_MoreResultsType_value = map[string]int32{
	"MORE_RESULTS_TYPE_UNSPECIFIED": 0,
	"NOT_FINISHED":                  1,
	"MORE_RESULTS_AFTER_LIMIT":      2,
	"MORE_RESULTS_AFTER_CURSOR":     4,
	"NO_MORE_RESULTS":               3,
}
View Source
var ReadOptions_ReadConsistency_name = map[int32]string{
	0: "READ_CONSISTENCY_UNSPECIFIED",
	1: "STRONG",
	2: "EVENTUAL",
}
View Source
var ReadOptions_ReadConsistency_value = map[string]int32{
	"READ_CONSISTENCY_UNSPECIFIED": 0,
	"STRONG":                       1,
	"EVENTUAL":                     2,
}

Functions

func RegisterDatastoreServer

func RegisterDatastoreServer(s *grpc.Server, srv DatastoreServer)

Types

type AllocateIdsRequest

type AllocateIdsRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// A list of keys with incomplete key paths for which to allocate IDs.
	// No key may be reserved/read-only.
	Keys []*Key `protobuf:"bytes,1,rep,name=keys" json:"keys,omitempty"`
}

The request for [Datastore.AllocateIds][google.datastore.v1.Datastore.AllocateIds].

func (*AllocateIdsRequest) Descriptor

func (*AllocateIdsRequest) Descriptor() ([]byte, []int)

func (*AllocateIdsRequest) GetKeys

func (m *AllocateIdsRequest) GetKeys() []*Key

func (*AllocateIdsRequest) GetProjectId

func (m *AllocateIdsRequest) GetProjectId() string

func (*AllocateIdsRequest) ProtoMessage

func (*AllocateIdsRequest) ProtoMessage()

func (*AllocateIdsRequest) Reset

func (m *AllocateIdsRequest) Reset()

func (*AllocateIdsRequest) String

func (m *AllocateIdsRequest) String() string

type AllocateIdsResponse

type AllocateIdsResponse struct {
	// The keys specified in the request (in the same order), each with
	// its key path completed with a newly allocated ID.
	Keys []*Key `protobuf:"bytes,1,rep,name=keys" json:"keys,omitempty"`
}

The response for [Datastore.AllocateIds][google.datastore.v1.Datastore.AllocateIds].

func (*AllocateIdsResponse) Descriptor

func (*AllocateIdsResponse) Descriptor() ([]byte, []int)

func (*AllocateIdsResponse) GetKeys

func (m *AllocateIdsResponse) GetKeys() []*Key

func (*AllocateIdsResponse) ProtoMessage

func (*AllocateIdsResponse) ProtoMessage()

func (*AllocateIdsResponse) Reset

func (m *AllocateIdsResponse) Reset()

func (*AllocateIdsResponse) String

func (m *AllocateIdsResponse) String() string

type ArrayValue

type ArrayValue struct {
	// Values in the array.
	// The order of this array may not be preserved if it contains a mix of
	// indexed and unindexed values.
	Values []*Value `protobuf:"bytes,1,rep,name=values" json:"values,omitempty"`
}

An array value.

func (*ArrayValue) Descriptor

func (*ArrayValue) Descriptor() ([]byte, []int)

func (*ArrayValue) GetValues

func (m *ArrayValue) GetValues() []*Value

func (*ArrayValue) ProtoMessage

func (*ArrayValue) ProtoMessage()

func (*ArrayValue) Reset

func (m *ArrayValue) Reset()

func (*ArrayValue) String

func (m *ArrayValue) String() string

type BeginTransactionRequest

type BeginTransactionRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// Options for a new transaction.
	TransactionOptions *TransactionOptions `protobuf:"bytes,10,opt,name=transaction_options,json=transactionOptions" json:"transaction_options,omitempty"`
}

The request for [Datastore.BeginTransaction][google.datastore.v1.Datastore.BeginTransaction].

func (*BeginTransactionRequest) Descriptor

func (*BeginTransactionRequest) Descriptor() ([]byte, []int)

func (*BeginTransactionRequest) GetProjectId

func (m *BeginTransactionRequest) GetProjectId() string

func (*BeginTransactionRequest) GetTransactionOptions

func (m *BeginTransactionRequest) GetTransactionOptions() *TransactionOptions

func (*BeginTransactionRequest) ProtoMessage

func (*BeginTransactionRequest) ProtoMessage()

func (*BeginTransactionRequest) Reset

func (m *BeginTransactionRequest) Reset()

func (*BeginTransactionRequest) String

func (m *BeginTransactionRequest) String() string

type BeginTransactionResponse

type BeginTransactionResponse struct {
	// The transaction identifier (always present).
	Transaction []byte `protobuf:"bytes,1,opt,name=transaction,proto3" json:"transaction,omitempty"`
}

The response for [Datastore.BeginTransaction][google.datastore.v1.Datastore.BeginTransaction].

func (*BeginTransactionResponse) Descriptor

func (*BeginTransactionResponse) Descriptor() ([]byte, []int)

func (*BeginTransactionResponse) GetTransaction

func (m *BeginTransactionResponse) GetTransaction() []byte

func (*BeginTransactionResponse) ProtoMessage

func (*BeginTransactionResponse) ProtoMessage()

func (*BeginTransactionResponse) Reset

func (m *BeginTransactionResponse) Reset()

func (*BeginTransactionResponse) String

func (m *BeginTransactionResponse) String() string

type CommitRequest

type CommitRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// The type of commit to perform. Defaults to `TRANSACTIONAL`.
	Mode CommitRequest_Mode `protobuf:"varint,5,opt,name=mode,enum=google.datastore.v1.CommitRequest_Mode" json:"mode,omitempty"`
	// Must be set when mode is `TRANSACTIONAL`.
	//
	// Types that are valid to be assigned to TransactionSelector:
	//	*CommitRequest_Transaction
	TransactionSelector isCommitRequest_TransactionSelector `protobuf_oneof:"transaction_selector"`
	// The mutations to perform.
	//
	// When mode is `TRANSACTIONAL`, mutations affecting a single entity are
	// applied in order. The following sequences of mutations affecting a single
	// entity are not permitted in a single `Commit` request:
	//
	// - `insert` followed by `insert`
	// - `update` followed by `insert`
	// - `upsert` followed by `insert`
	// - `delete` followed by `update`
	//
	// When mode is `NON_TRANSACTIONAL`, no two mutations may affect a single
	// entity.
	Mutations []*Mutation `protobuf:"bytes,6,rep,name=mutations" json:"mutations,omitempty"`
}

The request for [Datastore.Commit][google.datastore.v1.Datastore.Commit].

func (*CommitRequest) Descriptor

func (*CommitRequest) Descriptor() ([]byte, []int)

func (*CommitRequest) GetMode

func (m *CommitRequest) GetMode() CommitRequest_Mode

func (*CommitRequest) GetMutations

func (m *CommitRequest) GetMutations() []*Mutation

func (*CommitRequest) GetProjectId

func (m *CommitRequest) GetProjectId() string

func (*CommitRequest) GetTransaction

func (m *CommitRequest) GetTransaction() []byte

func (*CommitRequest) GetTransactionSelector

func (m *CommitRequest) GetTransactionSelector() isCommitRequest_TransactionSelector

func (*CommitRequest) ProtoMessage

func (*CommitRequest) ProtoMessage()

func (*CommitRequest) Reset

func (m *CommitRequest) Reset()

func (*CommitRequest) String

func (m *CommitRequest) String() string

func (*CommitRequest) XXX_OneofFuncs

func (*CommitRequest) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type CommitRequest_Mode

type CommitRequest_Mode int32

The modes available for commits.

const (
	// Unspecified. This value must not be used.
	CommitRequest_MODE_UNSPECIFIED CommitRequest_Mode = 0
	// Transactional: The mutations are either all applied, or none are applied.
	// Learn about transactions [here](https://cloud.google.com/datastore/docs/concepts/transactions).
	CommitRequest_TRANSACTIONAL CommitRequest_Mode = 1
	// Non-transactional: The mutations may not apply as all or none.
	CommitRequest_NON_TRANSACTIONAL CommitRequest_Mode = 2
)

func (CommitRequest_Mode) EnumDescriptor

func (CommitRequest_Mode) EnumDescriptor() ([]byte, []int)

func (CommitRequest_Mode) String

func (x CommitRequest_Mode) String() string

type CommitRequest_Transaction

type CommitRequest_Transaction struct {
	Transaction []byte `protobuf:"bytes,1,opt,name=transaction,proto3,oneof"`
}

type CommitResponse

type CommitResponse struct {
	// The result of performing the mutations.
	// The i-th mutation result corresponds to the i-th mutation in the request.
	MutationResults []*MutationResult `protobuf:"bytes,3,rep,name=mutation_results,json=mutationResults" json:"mutation_results,omitempty"`
	// The number of index entries updated during the commit, or zero if none were
	// updated.
	IndexUpdates int32 `protobuf:"varint,4,opt,name=index_updates,json=indexUpdates" json:"index_updates,omitempty"`
}

The response for [Datastore.Commit][google.datastore.v1.Datastore.Commit].

func (*CommitResponse) Descriptor

func (*CommitResponse) Descriptor() ([]byte, []int)

func (*CommitResponse) GetIndexUpdates

func (m *CommitResponse) GetIndexUpdates() int32

func (*CommitResponse) GetMutationResults

func (m *CommitResponse) GetMutationResults() []*MutationResult

func (*CommitResponse) ProtoMessage

func (*CommitResponse) ProtoMessage()

func (*CommitResponse) Reset

func (m *CommitResponse) Reset()

func (*CommitResponse) String

func (m *CommitResponse) String() string

type CompositeFilter

type CompositeFilter struct {
	// The operator for combining multiple filters.
	Op CompositeFilter_Operator `protobuf:"varint,1,opt,name=op,enum=google.datastore.v1.CompositeFilter_Operator" json:"op,omitempty"`
	// The list of filters to combine.
	// Must contain at least one filter.
	Filters []*Filter `protobuf:"bytes,2,rep,name=filters" json:"filters,omitempty"`
}

A filter that merges multiple other filters using the given operator.

func (*CompositeFilter) Descriptor

func (*CompositeFilter) Descriptor() ([]byte, []int)

func (*CompositeFilter) GetFilters

func (m *CompositeFilter) GetFilters() []*Filter

func (*CompositeFilter) GetOp

func (*CompositeFilter) ProtoMessage

func (*CompositeFilter) ProtoMessage()

func (*CompositeFilter) Reset

func (m *CompositeFilter) Reset()

func (*CompositeFilter) String

func (m *CompositeFilter) String() string

type CompositeFilter_Operator

type CompositeFilter_Operator int32

A composite filter operator.

const (
	// Unspecified. This value must not be used.
	CompositeFilter_OPERATOR_UNSPECIFIED CompositeFilter_Operator = 0
	// The results are required to satisfy each of the combined filters.
	CompositeFilter_AND CompositeFilter_Operator = 1
)

func (CompositeFilter_Operator) EnumDescriptor

func (CompositeFilter_Operator) EnumDescriptor() ([]byte, []int)

func (CompositeFilter_Operator) String

func (x CompositeFilter_Operator) String() string

type DatastoreClient

type DatastoreClient interface {
	// Looks up entities by key.
	Lookup(ctx context.Context, in *LookupRequest, opts ...grpc.CallOption) (*LookupResponse, error)
	// Queries for entities.
	RunQuery(ctx context.Context, in *RunQueryRequest, opts ...grpc.CallOption) (*RunQueryResponse, error)
	// Begins a new transaction.
	BeginTransaction(ctx context.Context, in *BeginTransactionRequest, opts ...grpc.CallOption) (*BeginTransactionResponse, error)
	// Commits a transaction, optionally creating, deleting or modifying some
	// entities.
	Commit(ctx context.Context, in *CommitRequest, opts ...grpc.CallOption) (*CommitResponse, error)
	// Rolls back a transaction.
	Rollback(ctx context.Context, in *RollbackRequest, opts ...grpc.CallOption) (*RollbackResponse, error)
	// Allocates IDs for the given keys, which is useful for referencing an entity
	// before it is inserted.
	AllocateIds(ctx context.Context, in *AllocateIdsRequest, opts ...grpc.CallOption) (*AllocateIdsResponse, error)
}

func NewDatastoreClient

func NewDatastoreClient(cc *grpc.ClientConn) DatastoreClient

type DatastoreServer

type DatastoreServer interface {
	// Looks up entities by key.
	Lookup(context.Context, *LookupRequest) (*LookupResponse, error)
	// Queries for entities.
	RunQuery(context.Context, *RunQueryRequest) (*RunQueryResponse, error)
	// Begins a new transaction.
	BeginTransaction(context.Context, *BeginTransactionRequest) (*BeginTransactionResponse, error)
	// Commits a transaction, optionally creating, deleting or modifying some
	// entities.
	Commit(context.Context, *CommitRequest) (*CommitResponse, error)
	// Rolls back a transaction.
	Rollback(context.Context, *RollbackRequest) (*RollbackResponse, error)
	// Allocates IDs for the given keys, which is useful for referencing an entity
	// before it is inserted.
	AllocateIds(context.Context, *AllocateIdsRequest) (*AllocateIdsResponse, error)
}

type Entity

type Entity struct {
	// The entity's key.
	//
	// An entity must have a key, unless otherwise documented (for example,
	// an entity in `Value.entity_value` may have no key).
	// An entity's kind is its key path's last element's kind,
	// or null if it has no key.
	Key *Key `protobuf:"bytes,1,opt,name=key" json:"key,omitempty"`
	// The entity's properties.
	// The map's keys are property names.
	// A property name matching regex `__.*__` is reserved.
	// A reserved property name is forbidden in certain documented contexts.
	// The name must not contain more than 500 characters.
	// The name cannot be `""`.
	Properties map[string]*Value `` /* 140-byte string literal not displayed */
}

A Datastore data object.

An entity is limited to 1 megabyte when stored. That _roughly_ corresponds to a limit of 1 megabyte for the serialized form of this message.

func (*Entity) Descriptor

func (*Entity) Descriptor() ([]byte, []int)

func (*Entity) GetKey

func (m *Entity) GetKey() *Key

func (*Entity) GetProperties

func (m *Entity) GetProperties() map[string]*Value

func (*Entity) ProtoMessage

func (*Entity) ProtoMessage()

func (*Entity) Reset

func (m *Entity) Reset()

func (*Entity) String

func (m *Entity) String() string

type EntityResult

type EntityResult struct {
	// The resulting entity.
	Entity *Entity `protobuf:"bytes,1,opt,name=entity" json:"entity,omitempty"`
	// The version of the entity, a strictly positive number that monotonically
	// increases with changes to the entity.
	//
	// This field is set for [`FULL`][google.datastore.v1.EntityResult.ResultType.FULL] entity
	// results.
	//
	// For [missing][google.datastore.v1.LookupResponse.missing] entities in `LookupResponse`, this
	// is the version of the snapshot that was used to look up the entity, and it
	// is always set except for eventually consistent reads.
	Version int64 `protobuf:"varint,4,opt,name=version" json:"version,omitempty"`
	// A cursor that points to the position after the result entity.
	// Set only when the `EntityResult` is part of a `QueryResultBatch` message.
	Cursor []byte `protobuf:"bytes,3,opt,name=cursor,proto3" json:"cursor,omitempty"`
}

The result of fetching an entity from Datastore.

func (*EntityResult) Descriptor

func (*EntityResult) Descriptor() ([]byte, []int)

func (*EntityResult) GetCursor

func (m *EntityResult) GetCursor() []byte

func (*EntityResult) GetEntity

func (m *EntityResult) GetEntity() *Entity

func (*EntityResult) GetVersion

func (m *EntityResult) GetVersion() int64

func (*EntityResult) ProtoMessage

func (*EntityResult) ProtoMessage()

func (*EntityResult) Reset

func (m *EntityResult) Reset()

func (*EntityResult) String

func (m *EntityResult) String() string

type EntityResult_ResultType

type EntityResult_ResultType int32

Specifies what data the 'entity' field contains. A `ResultType` is either implied (for example, in `LookupResponse.missing` from `datastore.proto`, it is always `KEY_ONLY`) or specified by context (for example, in message `QueryResultBatch`, field `entity_result_type` specifies a `ResultType` for all the values in field `entity_results`).

const (
	// Unspecified. This value is never used.
	EntityResult_RESULT_TYPE_UNSPECIFIED EntityResult_ResultType = 0
	// The key and properties.
	EntityResult_FULL EntityResult_ResultType = 1
	// A projected subset of properties. The entity may have no key.
	EntityResult_PROJECTION EntityResult_ResultType = 2
	// Only the key.
	EntityResult_KEY_ONLY EntityResult_ResultType = 3
)

func (EntityResult_ResultType) EnumDescriptor

func (EntityResult_ResultType) EnumDescriptor() ([]byte, []int)

func (EntityResult_ResultType) String

func (x EntityResult_ResultType) String() string

type Filter

type Filter struct {
	// The type of filter.
	//
	// Types that are valid to be assigned to FilterType:
	//	*Filter_CompositeFilter
	//	*Filter_PropertyFilter
	FilterType isFilter_FilterType `protobuf_oneof:"filter_type"`
}

A holder for any type of filter.

func (*Filter) Descriptor

func (*Filter) Descriptor() ([]byte, []int)

func (*Filter) GetCompositeFilter

func (m *Filter) GetCompositeFilter() *CompositeFilter

func (*Filter) GetFilterType

func (m *Filter) GetFilterType() isFilter_FilterType

func (*Filter) GetPropertyFilter

func (m *Filter) GetPropertyFilter() *PropertyFilter

func (*Filter) ProtoMessage

func (*Filter) ProtoMessage()

func (*Filter) Reset

func (m *Filter) Reset()

func (*Filter) String

func (m *Filter) String() string

func (*Filter) XXX_OneofFuncs

func (*Filter) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type Filter_CompositeFilter

type Filter_CompositeFilter struct {
	CompositeFilter *CompositeFilter `protobuf:"bytes,1,opt,name=composite_filter,json=compositeFilter,oneof"`
}

type Filter_PropertyFilter

type Filter_PropertyFilter struct {
	PropertyFilter *PropertyFilter `protobuf:"bytes,2,opt,name=property_filter,json=propertyFilter,oneof"`
}

type GqlQuery

type GqlQuery struct {
	// A string of the format described
	// [here](https://cloud.google.com/datastore/docs/apis/gql/gql_reference).
	QueryString string `protobuf:"bytes,1,opt,name=query_string,json=queryString" json:"query_string,omitempty"`
	// When false, the query string must not contain any literals and instead must
	// bind all values. For example,
	// `SELECT * FROM Kind WHERE a = 'string literal'` is not allowed, while
	// `SELECT * FROM Kind WHERE a = @value` is.
	AllowLiterals bool `protobuf:"varint,2,opt,name=allow_literals,json=allowLiterals" json:"allow_literals,omitempty"`
	// For each non-reserved named binding site in the query string, there must be
	// a named parameter with that name, but not necessarily the inverse.
	//
	// Key must match regex `[A-Za-z_$][A-Za-z_$0-9]*`, must not match regex
	// `__.*__`, and must not be `""`.
	NamedBindings map[string]*GqlQueryParameter `` /* 167-byte string literal not displayed */
	// Numbered binding site @1 references the first numbered parameter,
	// effectively using 1-based indexing, rather than the usual 0.
	//
	// For each binding site numbered i in `query_string`, there must be an i-th
	// numbered parameter. The inverse must also be true.
	PositionalBindings []*GqlQueryParameter `protobuf:"bytes,4,rep,name=positional_bindings,json=positionalBindings" json:"positional_bindings,omitempty"`
}

A [GQL query](https://cloud.google.com/datastore/docs/apis/gql/gql_reference).

func (*GqlQuery) Descriptor

func (*GqlQuery) Descriptor() ([]byte, []int)

func (*GqlQuery) GetAllowLiterals

func (m *GqlQuery) GetAllowLiterals() bool

func (*GqlQuery) GetNamedBindings

func (m *GqlQuery) GetNamedBindings() map[string]*GqlQueryParameter

func (*GqlQuery) GetPositionalBindings

func (m *GqlQuery) GetPositionalBindings() []*GqlQueryParameter

func (*GqlQuery) GetQueryString

func (m *GqlQuery) GetQueryString() string

func (*GqlQuery) ProtoMessage

func (*GqlQuery) ProtoMessage()

func (*GqlQuery) Reset

func (m *GqlQuery) Reset()

func (*GqlQuery) String

func (m *GqlQuery) String() string

type GqlQueryParameter

type GqlQueryParameter struct {
	// The type of parameter.
	//
	// Types that are valid to be assigned to ParameterType:
	//	*GqlQueryParameter_Value
	//	*GqlQueryParameter_Cursor
	ParameterType isGqlQueryParameter_ParameterType `protobuf_oneof:"parameter_type"`
}

A binding parameter for a GQL query.

func (*GqlQueryParameter) Descriptor

func (*GqlQueryParameter) Descriptor() ([]byte, []int)

func (*GqlQueryParameter) GetCursor

func (m *GqlQueryParameter) GetCursor() []byte

func (*GqlQueryParameter) GetParameterType

func (m *GqlQueryParameter) GetParameterType() isGqlQueryParameter_ParameterType

func (*GqlQueryParameter) GetValue

func (m *GqlQueryParameter) GetValue() *Value

func (*GqlQueryParameter) ProtoMessage

func (*GqlQueryParameter) ProtoMessage()

func (*GqlQueryParameter) Reset

func (m *GqlQueryParameter) Reset()

func (*GqlQueryParameter) String

func (m *GqlQueryParameter) String() string

func (*GqlQueryParameter) XXX_OneofFuncs

func (*GqlQueryParameter) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type GqlQueryParameter_Cursor

type GqlQueryParameter_Cursor struct {
	Cursor []byte `protobuf:"bytes,3,opt,name=cursor,proto3,oneof"`
}

type GqlQueryParameter_Value

type GqlQueryParameter_Value struct {
	Value *Value `protobuf:"bytes,2,opt,name=value,oneof"`
}

type Key

type Key struct {
	// Entities are partitioned into subsets, currently identified by a project
	// ID and namespace ID.
	// Queries are scoped to a single partition.
	PartitionId *PartitionId `protobuf:"bytes,1,opt,name=partition_id,json=partitionId" json:"partition_id,omitempty"`
	// The entity path.
	// An entity path consists of one or more elements composed of a kind and a
	// string or numerical identifier, which identify entities. The first
	// element identifies a _root entity_, the second element identifies
	// a _child_ of the root entity, the third element identifies a child of the
	// second entity, and so forth. The entities identified by all prefixes of
	// the path are called the element's _ancestors_.
	//
	// An entity path is always fully complete: *all* of the entity's ancestors
	// are required to be in the path along with the entity identifier itself.
	// The only exception is that in some documented cases, the identifier in the
	// last path element (for the entity) itself may be omitted. For example,
	// the last path element of the key of `Mutation.insert` may have no
	// identifier.
	//
	// A path can never be empty, and a path can have at most 100 elements.
	Path []*Key_PathElement `protobuf:"bytes,2,rep,name=path" json:"path,omitempty"`
}

A unique identifier for an entity. If a key's partition ID or any of its path kinds or names are reserved/read-only, the key is reserved/read-only. A reserved/read-only key is forbidden in certain documented contexts.

func (*Key) Descriptor

func (*Key) Descriptor() ([]byte, []int)

func (*Key) GetPartitionId

func (m *Key) GetPartitionId() *PartitionId

func (*Key) GetPath

func (m *Key) GetPath() []*Key_PathElement

func (*Key) ProtoMessage

func (*Key) ProtoMessage()

func (*Key) Reset

func (m *Key) Reset()

func (*Key) String

func (m *Key) String() string

type Key_PathElement

type Key_PathElement struct {
	// The kind of the entity.
	// A kind matching regex `__.*__` is reserved/read-only.
	// A kind must not contain more than 1500 bytes when UTF-8 encoded.
	// Cannot be `""`.
	Kind string `protobuf:"bytes,1,opt,name=kind" json:"kind,omitempty"`
	// The type of ID.
	//
	// Types that are valid to be assigned to IdType:
	//	*Key_PathElement_Id
	//	*Key_PathElement_Name
	IdType isKey_PathElement_IdType `protobuf_oneof:"id_type"`
}

A (kind, ID/name) pair used to construct a key path.

If either name or ID is set, the element is complete. If neither is set, the element is incomplete.

func (*Key_PathElement) Descriptor

func (*Key_PathElement) Descriptor() ([]byte, []int)

func (*Key_PathElement) GetId

func (m *Key_PathElement) GetId() int64

func (*Key_PathElement) GetIdType

func (m *Key_PathElement) GetIdType() isKey_PathElement_IdType

func (*Key_PathElement) GetKind

func (m *Key_PathElement) GetKind() string

func (*Key_PathElement) GetName

func (m *Key_PathElement) GetName() string

func (*Key_PathElement) ProtoMessage

func (*Key_PathElement) ProtoMessage()

func (*Key_PathElement) Reset

func (m *Key_PathElement) Reset()

func (*Key_PathElement) String

func (m *Key_PathElement) String() string

func (*Key_PathElement) XXX_OneofFuncs

func (*Key_PathElement) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type Key_PathElement_Id

type Key_PathElement_Id struct {
	Id int64 `protobuf:"varint,2,opt,name=id,oneof"`
}

type Key_PathElement_Name

type Key_PathElement_Name struct {
	Name string `protobuf:"bytes,3,opt,name=name,oneof"`
}

type KindExpression

type KindExpression struct {
	// The name of the kind.
	Name string `protobuf:"bytes,1,opt,name=name" json:"name,omitempty"`
}

A representation of a kind.

func (*KindExpression) Descriptor

func (*KindExpression) Descriptor() ([]byte, []int)

func (*KindExpression) GetName

func (m *KindExpression) GetName() string

func (*KindExpression) ProtoMessage

func (*KindExpression) ProtoMessage()

func (*KindExpression) Reset

func (m *KindExpression) Reset()

func (*KindExpression) String

func (m *KindExpression) String() string

type LookupRequest

type LookupRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// The options for this lookup request.
	ReadOptions *ReadOptions `protobuf:"bytes,1,opt,name=read_options,json=readOptions" json:"read_options,omitempty"`
	// Keys of entities to look up.
	Keys []*Key `protobuf:"bytes,3,rep,name=keys" json:"keys,omitempty"`
}

The request for [Datastore.Lookup][google.datastore.v1.Datastore.Lookup].

func (*LookupRequest) Descriptor

func (*LookupRequest) Descriptor() ([]byte, []int)

func (*LookupRequest) GetKeys

func (m *LookupRequest) GetKeys() []*Key

func (*LookupRequest) GetProjectId

func (m *LookupRequest) GetProjectId() string

func (*LookupRequest) GetReadOptions

func (m *LookupRequest) GetReadOptions() *ReadOptions

func (*LookupRequest) ProtoMessage

func (*LookupRequest) ProtoMessage()

func (*LookupRequest) Reset

func (m *LookupRequest) Reset()

func (*LookupRequest) String

func (m *LookupRequest) String() string

type LookupResponse

type LookupResponse struct {
	// Entities found as `ResultType.FULL` entities. The order of results in this
	// field is undefined and has no relation to the order of the keys in the
	// input.
	Found []*EntityResult `protobuf:"bytes,1,rep,name=found" json:"found,omitempty"`
	// Entities not found as `ResultType.KEY_ONLY` entities. The order of results
	// in this field is undefined and has no relation to the order of the keys
	// in the input.
	Missing []*EntityResult `protobuf:"bytes,2,rep,name=missing" json:"missing,omitempty"`
	// A list of keys that were not looked up due to resource constraints. The
	// order of results in this field is undefined and has no relation to the
	// order of the keys in the input.
	Deferred []*Key `protobuf:"bytes,3,rep,name=deferred" json:"deferred,omitempty"`
}

The response for [Datastore.Lookup][google.datastore.v1.Datastore.Lookup].

func (*LookupResponse) Descriptor

func (*LookupResponse) Descriptor() ([]byte, []int)

func (*LookupResponse) GetDeferred

func (m *LookupResponse) GetDeferred() []*Key

func (*LookupResponse) GetFound

func (m *LookupResponse) GetFound() []*EntityResult

func (*LookupResponse) GetMissing

func (m *LookupResponse) GetMissing() []*EntityResult

func (*LookupResponse) ProtoMessage

func (*LookupResponse) ProtoMessage()

func (*LookupResponse) Reset

func (m *LookupResponse) Reset()

func (*LookupResponse) String

func (m *LookupResponse) String() string

type Mutation

type Mutation struct {
	// The mutation operation.
	//
	// For `insert`, `update`, and `upsert`:
	// - The entity's key must not be reserved/read-only.
	// - No property in the entity may have a reserved name,
	//   not even a property in an entity in a value.
	// - No value in the entity may have meaning 18,
	//   not even a value in an entity in another value.
	//
	// Types that are valid to be assigned to Operation:
	//	*Mutation_Insert
	//	*Mutation_Update
	//	*Mutation_Upsert
	//	*Mutation_Delete
	Operation isMutation_Operation `protobuf_oneof:"operation"`
	// When set, the server will detect whether or not this mutation conflicts
	// with the current version of the entity on the server. Conflicting mutations
	// are not applied, and are marked as such in MutationResult.
	//
	// Types that are valid to be assigned to ConflictDetectionStrategy:
	//	*Mutation_BaseVersion
	ConflictDetectionStrategy isMutation_ConflictDetectionStrategy `protobuf_oneof:"conflict_detection_strategy"`
}

A mutation to apply to an entity.

func (*Mutation) Descriptor

func (*Mutation) Descriptor() ([]byte, []int)

func (*Mutation) GetBaseVersion

func (m *Mutation) GetBaseVersion() int64

func (*Mutation) GetConflictDetectionStrategy

func (m *Mutation) GetConflictDetectionStrategy() isMutation_ConflictDetectionStrategy

func (*Mutation) GetDelete

func (m *Mutation) GetDelete() *Key

func (*Mutation) GetInsert

func (m *Mutation) GetInsert() *Entity

func (*Mutation) GetOperation

func (m *Mutation) GetOperation() isMutation_Operation

func (*Mutation) GetUpdate

func (m *Mutation) GetUpdate() *Entity

func (*Mutation) GetUpsert

func (m *Mutation) GetUpsert() *Entity

func (*Mutation) ProtoMessage

func (*Mutation) ProtoMessage()

func (*Mutation) Reset

func (m *Mutation) Reset()

func (*Mutation) String

func (m *Mutation) String() string

func (*Mutation) XXX_OneofFuncs

func (*Mutation) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type MutationResult

type MutationResult struct {
	// The automatically allocated key.
	// Set only when the mutation allocated a key.
	Key *Key `protobuf:"bytes,3,opt,name=key" json:"key,omitempty"`
	// The version of the entity on the server after processing the mutation. If
	// the mutation doesn't change anything on the server, then the version will
	// be the version of the current entity or, if no entity is present, a version
	// that is strictly greater than the version of any previous entity and less
	// than the version of any possible future entity.
	Version int64 `protobuf:"varint,4,opt,name=version" json:"version,omitempty"`
	// Whether a conflict was detected for this mutation. Always false when a
	// conflict detection strategy field is not set in the mutation.
	ConflictDetected bool `protobuf:"varint,5,opt,name=conflict_detected,json=conflictDetected" json:"conflict_detected,omitempty"`
}

The result of applying a mutation.

func (*MutationResult) Descriptor

func (*MutationResult) Descriptor() ([]byte, []int)

func (*MutationResult) GetConflictDetected

func (m *MutationResult) GetConflictDetected() bool

func (*MutationResult) GetKey

func (m *MutationResult) GetKey() *Key

func (*MutationResult) GetVersion

func (m *MutationResult) GetVersion() int64

func (*MutationResult) ProtoMessage

func (*MutationResult) ProtoMessage()

func (*MutationResult) Reset

func (m *MutationResult) Reset()

func (*MutationResult) String

func (m *MutationResult) String() string

type Mutation_BaseVersion

type Mutation_BaseVersion struct {
	BaseVersion int64 `protobuf:"varint,8,opt,name=base_version,json=baseVersion,oneof"`
}

type Mutation_Delete

type Mutation_Delete struct {
	Delete *Key `protobuf:"bytes,7,opt,name=delete,oneof"`
}

type Mutation_Insert

type Mutation_Insert struct {
	Insert *Entity `protobuf:"bytes,4,opt,name=insert,oneof"`
}

type Mutation_Update

type Mutation_Update struct {
	Update *Entity `protobuf:"bytes,5,opt,name=update,oneof"`
}

type Mutation_Upsert

type Mutation_Upsert struct {
	Upsert *Entity `protobuf:"bytes,6,opt,name=upsert,oneof"`
}

type PartitionId

type PartitionId struct {
	// The ID of the project to which the entities belong.
	ProjectId string `protobuf:"bytes,2,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// If not empty, the ID of the namespace to which the entities belong.
	NamespaceId string `protobuf:"bytes,4,opt,name=namespace_id,json=namespaceId" json:"namespace_id,omitempty"`
}

A partition ID identifies a grouping of entities. The grouping is always by project and namespace, however the namespace ID may be empty.

A partition ID contains several dimensions: project ID and namespace ID.

Partition dimensions:

- May be `""`. - Must be valid UTF-8 bytes. - Must have values that match regex `[A-Za-z\d\.\-_]{1,100}` If the value of any dimension matches regex `__.*__`, the partition is reserved/read-only. A reserved/read-only partition ID is forbidden in certain documented contexts.

Foreign partition IDs (in which the project ID does not match the context project ID ) are discouraged. Reads and writes of foreign partition IDs may fail if the project is not in an active state.

func (*PartitionId) Descriptor

func (*PartitionId) Descriptor() ([]byte, []int)

func (*PartitionId) GetNamespaceId

func (m *PartitionId) GetNamespaceId() string

func (*PartitionId) GetProjectId

func (m *PartitionId) GetProjectId() string

func (*PartitionId) ProtoMessage

func (*PartitionId) ProtoMessage()

func (*PartitionId) Reset

func (m *PartitionId) Reset()

func (*PartitionId) String

func (m *PartitionId) String() string

type Projection

type Projection struct {
	// The property to project.
	Property *PropertyReference `protobuf:"bytes,1,opt,name=property" json:"property,omitempty"`
}

A representation of a property in a projection.

func (*Projection) Descriptor

func (*Projection) Descriptor() ([]byte, []int)

func (*Projection) GetProperty

func (m *Projection) GetProperty() *PropertyReference

func (*Projection) ProtoMessage

func (*Projection) ProtoMessage()

func (*Projection) Reset

func (m *Projection) Reset()

func (*Projection) String

func (m *Projection) String() string

type PropertyFilter

type PropertyFilter struct {
	// The property to filter by.
	Property *PropertyReference `protobuf:"bytes,1,opt,name=property" json:"property,omitempty"`
	// The operator to filter by.
	Op PropertyFilter_Operator `protobuf:"varint,2,opt,name=op,enum=google.datastore.v1.PropertyFilter_Operator" json:"op,omitempty"`
	// The value to compare the property to.
	Value *Value `protobuf:"bytes,3,opt,name=value" json:"value,omitempty"`
}

A filter on a specific property.

func (*PropertyFilter) Descriptor

func (*PropertyFilter) Descriptor() ([]byte, []int)

func (*PropertyFilter) GetOp

func (*PropertyFilter) GetProperty

func (m *PropertyFilter) GetProperty() *PropertyReference

func (*PropertyFilter) GetValue

func (m *PropertyFilter) GetValue() *Value

func (*PropertyFilter) ProtoMessage

func (*PropertyFilter) ProtoMessage()

func (*PropertyFilter) Reset

func (m *PropertyFilter) Reset()

func (*PropertyFilter) String

func (m *PropertyFilter) String() string

type PropertyFilter_Operator

type PropertyFilter_Operator int32

A property filter operator.

const (
	// Unspecified. This value must not be used.
	PropertyFilter_OPERATOR_UNSPECIFIED PropertyFilter_Operator = 0
	// Less than.
	PropertyFilter_LESS_THAN PropertyFilter_Operator = 1
	// Less than or equal.
	PropertyFilter_LESS_THAN_OR_EQUAL PropertyFilter_Operator = 2
	// Greater than.
	PropertyFilter_GREATER_THAN PropertyFilter_Operator = 3
	// Greater than or equal.
	PropertyFilter_GREATER_THAN_OR_EQUAL PropertyFilter_Operator = 4
	// Equal.
	PropertyFilter_EQUAL PropertyFilter_Operator = 5
	// Has ancestor.
	PropertyFilter_HAS_ANCESTOR PropertyFilter_Operator = 11
)

func (PropertyFilter_Operator) EnumDescriptor

func (PropertyFilter_Operator) EnumDescriptor() ([]byte, []int)

func (PropertyFilter_Operator) String

func (x PropertyFilter_Operator) String() string

type PropertyOrder

type PropertyOrder struct {
	// The property to order by.
	Property *PropertyReference `protobuf:"bytes,1,opt,name=property" json:"property,omitempty"`
	// The direction to order by. Defaults to `ASCENDING`.
	Direction PropertyOrder_Direction `protobuf:"varint,2,opt,name=direction,enum=google.datastore.v1.PropertyOrder_Direction" json:"direction,omitempty"`
}

The desired order for a specific property.

func (*PropertyOrder) Descriptor

func (*PropertyOrder) Descriptor() ([]byte, []int)

func (*PropertyOrder) GetDirection

func (m *PropertyOrder) GetDirection() PropertyOrder_Direction

func (*PropertyOrder) GetProperty

func (m *PropertyOrder) GetProperty() *PropertyReference

func (*PropertyOrder) ProtoMessage

func (*PropertyOrder) ProtoMessage()

func (*PropertyOrder) Reset

func (m *PropertyOrder) Reset()

func (*PropertyOrder) String

func (m *PropertyOrder) String() string

type PropertyOrder_Direction

type PropertyOrder_Direction int32

The sort direction.

const (
	// Unspecified. This value must not be used.
	PropertyOrder_DIRECTION_UNSPECIFIED PropertyOrder_Direction = 0
	// Ascending.
	PropertyOrder_ASCENDING PropertyOrder_Direction = 1
	// Descending.
	PropertyOrder_DESCENDING PropertyOrder_Direction = 2
)

func (PropertyOrder_Direction) EnumDescriptor

func (PropertyOrder_Direction) EnumDescriptor() ([]byte, []int)

func (PropertyOrder_Direction) String

func (x PropertyOrder_Direction) String() string

type PropertyReference

type PropertyReference struct {
	// The name of the property.
	// If name includes "."s, it may be interpreted as a property name path.
	Name string `protobuf:"bytes,2,opt,name=name" json:"name,omitempty"`
}

A reference to a property relative to the kind expressions.

func (*PropertyReference) Descriptor

func (*PropertyReference) Descriptor() ([]byte, []int)

func (*PropertyReference) GetName

func (m *PropertyReference) GetName() string

func (*PropertyReference) ProtoMessage

func (*PropertyReference) ProtoMessage()

func (*PropertyReference) Reset

func (m *PropertyReference) Reset()

func (*PropertyReference) String

func (m *PropertyReference) String() string

type Query

type Query struct {
	// The projection to return. Defaults to returning all properties.
	Projection []*Projection `protobuf:"bytes,2,rep,name=projection" json:"projection,omitempty"`
	// The kinds to query (if empty, returns entities of all kinds).
	// Currently at most 1 kind may be specified.
	Kind []*KindExpression `protobuf:"bytes,3,rep,name=kind" json:"kind,omitempty"`
	// The filter to apply.
	Filter *Filter `protobuf:"bytes,4,opt,name=filter" json:"filter,omitempty"`
	// The order to apply to the query results (if empty, order is unspecified).
	Order []*PropertyOrder `protobuf:"bytes,5,rep,name=order" json:"order,omitempty"`
	// The properties to make distinct. The query results will contain the first
	// result for each distinct combination of values for the given properties
	// (if empty, all results are returned).
	DistinctOn []*PropertyReference `protobuf:"bytes,6,rep,name=distinct_on,json=distinctOn" json:"distinct_on,omitempty"`
	// A starting point for the query results. Query cursors are
	// returned in query result batches and
	// [can only be used to continue the same query](https://cloud.google.com/datastore/docs/concepts/queries#cursors_limits_and_offsets).
	StartCursor []byte `protobuf:"bytes,7,opt,name=start_cursor,json=startCursor,proto3" json:"start_cursor,omitempty"`
	// An ending point for the query results. Query cursors are
	// returned in query result batches and
	// [can only be used to limit the same query](https://cloud.google.com/datastore/docs/concepts/queries#cursors_limits_and_offsets).
	EndCursor []byte `protobuf:"bytes,8,opt,name=end_cursor,json=endCursor,proto3" json:"end_cursor,omitempty"`
	// The number of results to skip. Applies before limit, but after all other
	// constraints. Optional. Must be >= 0 if specified.
	Offset int32 `protobuf:"varint,10,opt,name=offset" json:"offset,omitempty"`
	// The maximum number of results to return. Applies after all other
	// constraints. Optional.
	// Unspecified is interpreted as no limit.
	// Must be >= 0 if specified.
	Limit *google_protobuf3.Int32Value `protobuf:"bytes,12,opt,name=limit" json:"limit,omitempty"`
}

A query for entities.

func (*Query) Descriptor

func (*Query) Descriptor() ([]byte, []int)

func (*Query) GetDistinctOn

func (m *Query) GetDistinctOn() []*PropertyReference

func (*Query) GetEndCursor

func (m *Query) GetEndCursor() []byte

func (*Query) GetFilter

func (m *Query) GetFilter() *Filter

func (*Query) GetKind

func (m *Query) GetKind() []*KindExpression

func (*Query) GetLimit

func (m *Query) GetLimit() *google_protobuf3.Int32Value

func (*Query) GetOffset

func (m *Query) GetOffset() int32

func (*Query) GetOrder

func (m *Query) GetOrder() []*PropertyOrder

func (*Query) GetProjection

func (m *Query) GetProjection() []*Projection

func (*Query) GetStartCursor

func (m *Query) GetStartCursor() []byte

func (*Query) ProtoMessage

func (*Query) ProtoMessage()

func (*Query) Reset

func (m *Query) Reset()

func (*Query) String

func (m *Query) String() string

type QueryResultBatch

type QueryResultBatch struct {
	// The number of results skipped, typically because of an offset.
	SkippedResults int32 `protobuf:"varint,6,opt,name=skipped_results,json=skippedResults" json:"skipped_results,omitempty"`
	// A cursor that points to the position after the last skipped result.
	// Will be set when `skipped_results` != 0.
	SkippedCursor []byte `protobuf:"bytes,3,opt,name=skipped_cursor,json=skippedCursor,proto3" json:"skipped_cursor,omitempty"`
	// The result type for every entity in `entity_results`.
	EntityResultType EntityResult_ResultType `` /* 154-byte string literal not displayed */
	// The results for this batch.
	EntityResults []*EntityResult `protobuf:"bytes,2,rep,name=entity_results,json=entityResults" json:"entity_results,omitempty"`
	// A cursor that points to the position after the last result in the batch.
	EndCursor []byte `protobuf:"bytes,4,opt,name=end_cursor,json=endCursor,proto3" json:"end_cursor,omitempty"`
	// The state of the query after the current batch.
	MoreResults QueryResultBatch_MoreResultsType `` /* 146-byte string literal not displayed */
	// The version number of the snapshot this batch was returned from.
	// This applies to the range of results from the query's `start_cursor` (or
	// the beginning of the query if no cursor was given) to this batch's
	// `end_cursor` (not the query's `end_cursor`).
	//
	// In a single transaction, subsequent query result batches for the same query
	// can have a greater snapshot version number. Each batch's snapshot version
	// is valid for all preceding batches.
	// The value will be zero for eventually consistent queries.
	SnapshotVersion int64 `protobuf:"varint,7,opt,name=snapshot_version,json=snapshotVersion" json:"snapshot_version,omitempty"`
}

A batch of results produced by a query.

func (*QueryResultBatch) Descriptor

func (*QueryResultBatch) Descriptor() ([]byte, []int)

func (*QueryResultBatch) GetEndCursor

func (m *QueryResultBatch) GetEndCursor() []byte

func (*QueryResultBatch) GetEntityResultType

func (m *QueryResultBatch) GetEntityResultType() EntityResult_ResultType

func (*QueryResultBatch) GetEntityResults

func (m *QueryResultBatch) GetEntityResults() []*EntityResult

func (*QueryResultBatch) GetMoreResults

func (*QueryResultBatch) GetSkippedCursor

func (m *QueryResultBatch) GetSkippedCursor() []byte

func (*QueryResultBatch) GetSkippedResults

func (m *QueryResultBatch) GetSkippedResults() int32

func (*QueryResultBatch) GetSnapshotVersion

func (m *QueryResultBatch) GetSnapshotVersion() int64

func (*QueryResultBatch) ProtoMessage

func (*QueryResultBatch) ProtoMessage()

func (*QueryResultBatch) Reset

func (m *QueryResultBatch) Reset()

func (*QueryResultBatch) String

func (m *QueryResultBatch) String() string

type QueryResultBatch_MoreResultsType

type QueryResultBatch_MoreResultsType int32

The possible values for the `more_results` field.

const (
	// Unspecified. This value is never used.
	QueryResultBatch_MORE_RESULTS_TYPE_UNSPECIFIED QueryResultBatch_MoreResultsType = 0
	// There may be additional batches to fetch from this query.
	QueryResultBatch_NOT_FINISHED QueryResultBatch_MoreResultsType = 1
	// The query is finished, but there may be more results after the limit.
	QueryResultBatch_MORE_RESULTS_AFTER_LIMIT QueryResultBatch_MoreResultsType = 2
	// The query is finished, but there may be more results after the end
	// cursor.
	QueryResultBatch_MORE_RESULTS_AFTER_CURSOR QueryResultBatch_MoreResultsType = 4
	// The query is finished, and there are no more results.
	QueryResultBatch_NO_MORE_RESULTS QueryResultBatch_MoreResultsType = 3
)

func (QueryResultBatch_MoreResultsType) EnumDescriptor

func (QueryResultBatch_MoreResultsType) EnumDescriptor() ([]byte, []int)

func (QueryResultBatch_MoreResultsType) String

type ReadOptions

type ReadOptions struct {
	// If not specified, lookups and ancestor queries default to
	// `read_consistency`=`STRONG`, global queries default to
	// `read_consistency`=`EVENTUAL`.
	//
	// Types that are valid to be assigned to ConsistencyType:
	//	*ReadOptions_ReadConsistency_
	//	*ReadOptions_Transaction
	ConsistencyType isReadOptions_ConsistencyType `protobuf_oneof:"consistency_type"`
}

The options shared by read requests.

func (*ReadOptions) Descriptor

func (*ReadOptions) Descriptor() ([]byte, []int)

func (*ReadOptions) GetConsistencyType

func (m *ReadOptions) GetConsistencyType() isReadOptions_ConsistencyType

func (*ReadOptions) GetReadConsistency

func (m *ReadOptions) GetReadConsistency() ReadOptions_ReadConsistency

func (*ReadOptions) GetTransaction

func (m *ReadOptions) GetTransaction() []byte

func (*ReadOptions) ProtoMessage

func (*ReadOptions) ProtoMessage()

func (*ReadOptions) Reset

func (m *ReadOptions) Reset()

func (*ReadOptions) String

func (m *ReadOptions) String() string

func (*ReadOptions) XXX_OneofFuncs

func (*ReadOptions) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type ReadOptions_ReadConsistency

type ReadOptions_ReadConsistency int32

The possible values for read consistencies.

const (
	// Unspecified. This value must not be used.
	ReadOptions_READ_CONSISTENCY_UNSPECIFIED ReadOptions_ReadConsistency = 0
	// Strong consistency.
	ReadOptions_STRONG ReadOptions_ReadConsistency = 1
	// Eventual consistency.
	ReadOptions_EVENTUAL ReadOptions_ReadConsistency = 2
)

func (ReadOptions_ReadConsistency) EnumDescriptor

func (ReadOptions_ReadConsistency) EnumDescriptor() ([]byte, []int)

func (ReadOptions_ReadConsistency) String

type ReadOptions_ReadConsistency_

type ReadOptions_ReadConsistency_ struct {
	ReadConsistency ReadOptions_ReadConsistency `protobuf:"varint,1,opt,name=read_consistency,json=readConsistency,enum=google.datastore.v1.ReadOptions_ReadConsistency,oneof"`
}

type ReadOptions_Transaction

type ReadOptions_Transaction struct {
	Transaction []byte `protobuf:"bytes,2,opt,name=transaction,proto3,oneof"`
}

type RollbackRequest

type RollbackRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// The transaction identifier, returned by a call to
	// [Datastore.BeginTransaction][google.datastore.v1.Datastore.BeginTransaction].
	Transaction []byte `protobuf:"bytes,1,opt,name=transaction,proto3" json:"transaction,omitempty"`
}

The request for [Datastore.Rollback][google.datastore.v1.Datastore.Rollback].

func (*RollbackRequest) Descriptor

func (*RollbackRequest) Descriptor() ([]byte, []int)

func (*RollbackRequest) GetProjectId

func (m *RollbackRequest) GetProjectId() string

func (*RollbackRequest) GetTransaction

func (m *RollbackRequest) GetTransaction() []byte

func (*RollbackRequest) ProtoMessage

func (*RollbackRequest) ProtoMessage()

func (*RollbackRequest) Reset

func (m *RollbackRequest) Reset()

func (*RollbackRequest) String

func (m *RollbackRequest) String() string

type RollbackResponse

type RollbackResponse struct {
}

The response for [Datastore.Rollback][google.datastore.v1.Datastore.Rollback]. (an empty message).

func (*RollbackResponse) Descriptor

func (*RollbackResponse) Descriptor() ([]byte, []int)

func (*RollbackResponse) ProtoMessage

func (*RollbackResponse) ProtoMessage()

func (*RollbackResponse) Reset

func (m *RollbackResponse) Reset()

func (*RollbackResponse) String

func (m *RollbackResponse) String() string

type RunQueryRequest

type RunQueryRequest struct {
	// The ID of the project against which to make the request.
	ProjectId string `protobuf:"bytes,8,opt,name=project_id,json=projectId" json:"project_id,omitempty"`
	// Entities are partitioned into subsets, identified by a partition ID.
	// Queries are scoped to a single partition.
	// This partition ID is normalized with the standard default context
	// partition ID.
	PartitionId *PartitionId `protobuf:"bytes,2,opt,name=partition_id,json=partitionId" json:"partition_id,omitempty"`
	// The options for this query.
	ReadOptions *ReadOptions `protobuf:"bytes,1,opt,name=read_options,json=readOptions" json:"read_options,omitempty"`
	// The type of query.
	//
	// Types that are valid to be assigned to QueryType:
	//	*RunQueryRequest_Query
	//	*RunQueryRequest_GqlQuery
	QueryType isRunQueryRequest_QueryType `protobuf_oneof:"query_type"`
}

The request for [Datastore.RunQuery][google.datastore.v1.Datastore.RunQuery].

func (*RunQueryRequest) Descriptor

func (*RunQueryRequest) Descriptor() ([]byte, []int)

func (*RunQueryRequest) GetGqlQuery

func (m *RunQueryRequest) GetGqlQuery() *GqlQuery

func (*RunQueryRequest) GetPartitionId

func (m *RunQueryRequest) GetPartitionId() *PartitionId

func (*RunQueryRequest) GetProjectId

func (m *RunQueryRequest) GetProjectId() string

func (*RunQueryRequest) GetQuery

func (m *RunQueryRequest) GetQuery() *Query

func (*RunQueryRequest) GetQueryType

func (m *RunQueryRequest) GetQueryType() isRunQueryRequest_QueryType

func (*RunQueryRequest) GetReadOptions

func (m *RunQueryRequest) GetReadOptions() *ReadOptions

func (*RunQueryRequest) ProtoMessage

func (*RunQueryRequest) ProtoMessage()

func (*RunQueryRequest) Reset

func (m *RunQueryRequest) Reset()

func (*RunQueryRequest) String

func (m *RunQueryRequest) String() string

func (*RunQueryRequest) XXX_OneofFuncs

func (*RunQueryRequest) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type RunQueryRequest_GqlQuery

type RunQueryRequest_GqlQuery struct {
	GqlQuery *GqlQuery `protobuf:"bytes,7,opt,name=gql_query,json=gqlQuery,oneof"`
}

type RunQueryRequest_Query

type RunQueryRequest_Query struct {
	Query *Query `protobuf:"bytes,3,opt,name=query,oneof"`
}

type RunQueryResponse

type RunQueryResponse struct {
	// A batch of query results (always present).
	Batch *QueryResultBatch `protobuf:"bytes,1,opt,name=batch" json:"batch,omitempty"`
	// The parsed form of the `GqlQuery` from the request, if it was set.
	Query *Query `protobuf:"bytes,2,opt,name=query" json:"query,omitempty"`
}

The response for [Datastore.RunQuery][google.datastore.v1.Datastore.RunQuery].

func (*RunQueryResponse) Descriptor

func (*RunQueryResponse) Descriptor() ([]byte, []int)

func (*RunQueryResponse) GetBatch

func (m *RunQueryResponse) GetBatch() *QueryResultBatch

func (*RunQueryResponse) GetQuery

func (m *RunQueryResponse) GetQuery() *Query

func (*RunQueryResponse) ProtoMessage

func (*RunQueryResponse) ProtoMessage()

func (*RunQueryResponse) Reset

func (m *RunQueryResponse) Reset()

func (*RunQueryResponse) String

func (m *RunQueryResponse) String() string

type TransactionOptions

type TransactionOptions struct {
	// The `mode` of the transaction, indicating whether write operations are
	// supported.
	//
	// Types that are valid to be assigned to Mode:
	//	*TransactionOptions_ReadWrite_
	//	*TransactionOptions_ReadOnly_
	Mode isTransactionOptions_Mode `protobuf_oneof:"mode"`
}

Options for beginning a new transaction.

func (*TransactionOptions) Descriptor

func (*TransactionOptions) Descriptor() ([]byte, []int)

func (*TransactionOptions) GetMode

func (m *TransactionOptions) GetMode() isTransactionOptions_Mode

func (*TransactionOptions) GetReadOnly

func (*TransactionOptions) GetReadWrite

func (*TransactionOptions) ProtoMessage

func (*TransactionOptions) ProtoMessage()

func (*TransactionOptions) Reset

func (m *TransactionOptions) Reset()

func (*TransactionOptions) String

func (m *TransactionOptions) String() string

func (*TransactionOptions) XXX_OneofFuncs

func (*TransactionOptions) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type TransactionOptions_ReadOnly

type TransactionOptions_ReadOnly struct {
}

Options specific to read-only transactions.

func (*TransactionOptions_ReadOnly) Descriptor

func (*TransactionOptions_ReadOnly) Descriptor() ([]byte, []int)

func (*TransactionOptions_ReadOnly) ProtoMessage

func (*TransactionOptions_ReadOnly) ProtoMessage()

func (*TransactionOptions_ReadOnly) Reset

func (m *TransactionOptions_ReadOnly) Reset()

func (*TransactionOptions_ReadOnly) String

func (m *TransactionOptions_ReadOnly) String() string

type TransactionOptions_ReadOnly_

type TransactionOptions_ReadOnly_ struct {
	ReadOnly *TransactionOptions_ReadOnly `protobuf:"bytes,2,opt,name=read_only,json=readOnly,oneof"`
}

type TransactionOptions_ReadWrite

type TransactionOptions_ReadWrite struct {
	// The transaction identifier of the transaction being retried.
	PreviousTransaction []byte `protobuf:"bytes,1,opt,name=previous_transaction,json=previousTransaction,proto3" json:"previous_transaction,omitempty"`
}

Options specific to read / write transactions.

func (*TransactionOptions_ReadWrite) Descriptor

func (*TransactionOptions_ReadWrite) Descriptor() ([]byte, []int)

func (*TransactionOptions_ReadWrite) GetPreviousTransaction

func (m *TransactionOptions_ReadWrite) GetPreviousTransaction() []byte

func (*TransactionOptions_ReadWrite) ProtoMessage

func (*TransactionOptions_ReadWrite) ProtoMessage()

func (*TransactionOptions_ReadWrite) Reset

func (m *TransactionOptions_ReadWrite) Reset()

func (*TransactionOptions_ReadWrite) String

type TransactionOptions_ReadWrite_

type TransactionOptions_ReadWrite_ struct {
	ReadWrite *TransactionOptions_ReadWrite `protobuf:"bytes,1,opt,name=read_write,json=readWrite,oneof"`
}

type Value

type Value struct {
	// Must have a value set.
	//
	// Types that are valid to be assigned to ValueType:
	//	*Value_NullValue
	//	*Value_BooleanValue
	//	*Value_IntegerValue
	//	*Value_DoubleValue
	//	*Value_TimestampValue
	//	*Value_KeyValue
	//	*Value_StringValue
	//	*Value_BlobValue
	//	*Value_GeoPointValue
	//	*Value_EntityValue
	//	*Value_ArrayValue
	ValueType isValue_ValueType `protobuf_oneof:"value_type"`
	// The `meaning` field should only be populated for backwards compatibility.
	Meaning int32 `protobuf:"varint,14,opt,name=meaning" json:"meaning,omitempty"`
	// If the value should be excluded from all indexes including those defined
	// explicitly.
	ExcludeFromIndexes bool `protobuf:"varint,19,opt,name=exclude_from_indexes,json=excludeFromIndexes" json:"exclude_from_indexes,omitempty"`
}

A message that can hold any of the supported value types and associated metadata.

func (*Value) Descriptor

func (*Value) Descriptor() ([]byte, []int)

func (*Value) GetArrayValue

func (m *Value) GetArrayValue() *ArrayValue

func (*Value) GetBlobValue

func (m *Value) GetBlobValue() []byte

func (*Value) GetBooleanValue

func (m *Value) GetBooleanValue() bool

func (*Value) GetDoubleValue

func (m *Value) GetDoubleValue() float64

func (*Value) GetEntityValue

func (m *Value) GetEntityValue() *Entity

func (*Value) GetExcludeFromIndexes

func (m *Value) GetExcludeFromIndexes() bool

func (*Value) GetGeoPointValue

func (m *Value) GetGeoPointValue() *google_type.LatLng

func (*Value) GetIntegerValue

func (m *Value) GetIntegerValue() int64

func (*Value) GetKeyValue

func (m *Value) GetKeyValue() *Key

func (*Value) GetMeaning

func (m *Value) GetMeaning() int32

func (*Value) GetNullValue

func (m *Value) GetNullValue() google_protobuf1.NullValue

func (*Value) GetStringValue

func (m *Value) GetStringValue() string

func (*Value) GetTimestampValue

func (m *Value) GetTimestampValue() *google_protobuf2.Timestamp

func (*Value) GetValueType

func (m *Value) GetValueType() isValue_ValueType

func (*Value) ProtoMessage

func (*Value) ProtoMessage()

func (*Value) Reset

func (m *Value) Reset()

func (*Value) String

func (m *Value) String() string

func (*Value) XXX_OneofFuncs

func (*Value) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{})

XXX_OneofFuncs is for the internal use of the proto package.

type Value_ArrayValue

type Value_ArrayValue struct {
	ArrayValue *ArrayValue `protobuf:"bytes,9,opt,name=array_value,json=arrayValue,oneof"`
}

type Value_BlobValue

type Value_BlobValue struct {
	BlobValue []byte `protobuf:"bytes,18,opt,name=blob_value,json=blobValue,proto3,oneof"`
}

type Value_BooleanValue

type Value_BooleanValue struct {
	BooleanValue bool `protobuf:"varint,1,opt,name=boolean_value,json=booleanValue,oneof"`
}

type Value_DoubleValue

type Value_DoubleValue struct {
	DoubleValue float64 `protobuf:"fixed64,3,opt,name=double_value,json=doubleValue,oneof"`
}

type Value_EntityValue

type Value_EntityValue struct {
	EntityValue *Entity `protobuf:"bytes,6,opt,name=entity_value,json=entityValue,oneof"`
}

type Value_GeoPointValue

type Value_GeoPointValue struct {
	GeoPointValue *google_type.LatLng `protobuf:"bytes,8,opt,name=geo_point_value,json=geoPointValue,oneof"`
}

type Value_IntegerValue

type Value_IntegerValue struct {
	IntegerValue int64 `protobuf:"varint,2,opt,name=integer_value,json=integerValue,oneof"`
}

type Value_KeyValue

type Value_KeyValue struct {
	KeyValue *Key `protobuf:"bytes,5,opt,name=key_value,json=keyValue,oneof"`
}

type Value_NullValue

type Value_NullValue struct {
	NullValue google_protobuf1.NullValue `protobuf:"varint,11,opt,name=null_value,json=nullValue,enum=google.protobuf.NullValue,oneof"`
}

type Value_StringValue

type Value_StringValue struct {
	StringValue string `protobuf:"bytes,17,opt,name=string_value,json=stringValue,oneof"`
}

type Value_TimestampValue

type Value_TimestampValue struct {
	TimestampValue *google_protobuf2.Timestamp `protobuf:"bytes,10,opt,name=timestamp_value,json=timestampValue,oneof"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL