utils

package
v2.1.1 Latest Latest
Warning

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

Go to latest
Published: Feb 18, 2023 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

View Source
const FirestoreCollectionAccounts = "accounts"

FirestoreCollectionAccounts is the Firestore collection name for documents of type utils.Account.

View Source
const FirestoreCollectionActions = "actions"

FirestoreCollectionActions is the Firestore collection name for documents of type utils.Action.

View Source
const FirestoreCollectionManifests = "manifests"

FirestoreCollectionManifests is the Firestore collection name for documents of type utils.Manifest.

View Source
const FirestoreCollectionSessions = "sessions"

FirestoreCollectionSessions is the Firestore collection name for documents of type utils.Session.

View Source
const FirestoreCollectionUsers = "users"

FirestoreCollectionUsers is the Firestore collection name for documents of type utils.User.

Variables

View Source
var File_utils_account_proto protoreflect.FileDescriptor
View Source
var File_utils_session_proto protoreflect.FileDescriptor
View Source
var File_utils_user_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Account

type Account struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*Account) Descriptor deprecated

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

Deprecated: Use Account.ProtoReflect.Descriptor instead.

func (*Account) GetName

func (x *Account) GetName() string

func (*Account) ProtoMessage

func (*Account) ProtoMessage()

func (*Account) ProtoReflect

func (x *Account) ProtoReflect() protoreflect.Message

func (*Account) Reset

func (x *Account) Reset()

func (*Account) String

func (x *Account) String() string

func (*Account) ToFirestore

func (x *Account) ToFirestore() (*FirestoreAccount, error)

ToFirestore returns the Firestore Custom Object for Account.

type Action

type Action struct {
	Id         string                 `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Proto      []byte                 `protobuf:"bytes,2,opt,name=proto,proto3" json:"proto,omitempty"`
	CreateTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
	// contains filtered or unexported fields
}

func (*Action) Descriptor deprecated

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

Deprecated: Use Action.ProtoReflect.Descriptor instead.

func (*Action) GetCreateTime

func (x *Action) GetCreateTime() *timestamppb.Timestamp

func (*Action) GetId

func (x *Action) GetId() string

func (*Action) GetProto

func (x *Action) GetProto() []byte

func (*Action) ProtoMessage

func (*Action) ProtoMessage()

func (*Action) ProtoReflect

func (x *Action) ProtoReflect() protoreflect.Message

func (*Action) Reset

func (x *Action) Reset()

func (*Action) String

func (x *Action) String() string

func (*Action) ToFirestore

func (x *Action) ToFirestore() (*FirestoreAction, error)

ToFirestore returns the Firestore Custom Object for Action.

type Firestore

type Firestore struct {
	// contains filtered or unexported fields
}

func WithFirestore

func WithFirestore(client *firestore.Client) *Firestore

func (*Firestore) Accounts

func (fs *Firestore) Accounts() *FirestoreAccountsCollectionRef

func (*Firestore) Installations

func (fs *Firestore) Installations() *FirestoreInstallationsCollectionRef

type FirestoreAccount

type FirestoreAccount struct {
	Name string `firestore:"name,omitempty"`
}

FirestoreAccount is the Firestore Custom Object for utils.Account.

func (*FirestoreAccount) ToProto

func (m *FirestoreAccount) ToProto() (*Account, error)

ToProto converts this FirestoreAccount to its protobuf representation.

type FirestoreAccountsCollectionRef

type FirestoreAccountsCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreAccountsCollectionRef holds a reference to the Firestore collection `accounts`.

func (*FirestoreAccountsCollectionRef) Doc

func (*FirestoreAccountsCollectionRef) Limit

func (*FirestoreAccountsCollectionRef) OrderBy

func (*FirestoreAccountsCollectionRef) Where

func (ref *FirestoreAccountsCollectionRef) Where(path, op string, value interface{}) *FirestoreAccountsQuery

type FirestoreAccountsDocumentRef

type FirestoreAccountsDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreAccountsDocumentRef holds a reference to a Firestore document in collection `accounts`.

func (*FirestoreAccountsDocumentRef) Delete

func (*FirestoreAccountsDocumentRef) Get

func (*FirestoreAccountsDocumentRef) Ref

func (*FirestoreAccountsDocumentRef) Set

func (*FirestoreAccountsDocumentRef) Users added in v2.0.2

type FirestoreAccountsIterator

type FirestoreAccountsIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreAccountsIterator) GetAll

func (i *FirestoreAccountsIterator) GetAll() ([]*Account, error)

func (*FirestoreAccountsIterator) GetAllAsSnapshots

func (i *FirestoreAccountsIterator) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FirestoreAccountsIterator) Next

func (i *FirestoreAccountsIterator) Next() (*Account, error)

func (*FirestoreAccountsIterator) NextAsSnapshot

func (*FirestoreAccountsIterator) Stop

func (i *FirestoreAccountsIterator) Stop()

type FirestoreAccountsQuery

type FirestoreAccountsQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreAccountsQuery) Documents

func (*FirestoreAccountsQuery) First

func (*FirestoreAccountsQuery) Limit

func (*FirestoreAccountsQuery) OrderBy

func (*FirestoreAccountsQuery) Value

func (*FirestoreAccountsQuery) Where

func (q *FirestoreAccountsQuery) Where(path, op string, value interface{}) *FirestoreAccountsQuery

type FirestoreAction

type FirestoreAction struct {
	Id         string    `firestore:"id,omitempty"`
	Proto      []byte    `firestore:"proto,omitempty"`
	CreateTime time.Time `firestore:"createTime,serverTimestamp"`
}

FirestoreAction is the Firestore Custom Object for utils.Action.

func (*FirestoreAction) ToProto

func (m *FirestoreAction) ToProto() (*Action, error)

ToProto converts this FirestoreAction to its protobuf representation.

type FirestoreActionsCollectionRef

type FirestoreActionsCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreActionsCollectionRef holds a reference to the Firestore collection `actions`.

func (*FirestoreActionsCollectionRef) Create

func (*FirestoreActionsCollectionRef) Doc

func (*FirestoreActionsCollectionRef) Limit

func (*FirestoreActionsCollectionRef) OrderBy

func (*FirestoreActionsCollectionRef) Where

func (ref *FirestoreActionsCollectionRef) Where(path, op string, value interface{}) *FirestoreActionsQuery

type FirestoreActionsDocumentRef

type FirestoreActionsDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreActionsDocumentRef holds a reference to a Firestore document in collection `actions`.

func (*FirestoreActionsDocumentRef) Delete

func (*FirestoreActionsDocumentRef) Get

func (*FirestoreActionsDocumentRef) Ref

func (*FirestoreActionsDocumentRef) Set

type FirestoreActionsIterator

type FirestoreActionsIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreActionsIterator) GetAll

func (i *FirestoreActionsIterator) GetAll() ([]*Action, error)

func (*FirestoreActionsIterator) GetAllAsSnapshots

func (i *FirestoreActionsIterator) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FirestoreActionsIterator) Next

func (i *FirestoreActionsIterator) Next() (*Action, error)

func (*FirestoreActionsIterator) NextAsSnapshot

func (i *FirestoreActionsIterator) NextAsSnapshot() (*firestore.DocumentSnapshot, error)

func (*FirestoreActionsIterator) Stop

func (i *FirestoreActionsIterator) Stop()

type FirestoreActionsQuery

type FirestoreActionsQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreActionsQuery) Documents

func (*FirestoreActionsQuery) First

func (q *FirestoreActionsQuery) First(ctx context.Context) (*Action, error)

func (*FirestoreActionsQuery) Limit

func (*FirestoreActionsQuery) OrderBy

func (*FirestoreActionsQuery) Value

func (*FirestoreActionsQuery) Where

func (q *FirestoreActionsQuery) Where(path, op string, value interface{}) *FirestoreActionsQuery

type FirestoreInstallationsCollectionRef

type FirestoreInstallationsCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreInstallationsCollectionRef holds a reference to the Firestore collection `installations`.

func (*FirestoreInstallationsCollectionRef) Doc

func (*FirestoreInstallationsCollectionRef) Limit

func (*FirestoreInstallationsCollectionRef) OrderBy

func (*FirestoreInstallationsCollectionRef) Where

func (ref *FirestoreInstallationsCollectionRef) Where(path, op string, value interface{}) *FirestoreInstallationsQuery

type FirestoreInstallationsDocumentRef

type FirestoreInstallationsDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreInstallationsDocumentRef holds a reference to a Firestore document in collection `installations`.

func (*FirestoreInstallationsDocumentRef) Repositories added in v2.0.2

type FirestoreInstallationsIterator

type FirestoreInstallationsIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreInstallationsIterator) Stop

type FirestoreInstallationsQuery

type FirestoreInstallationsQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreInstallationsQuery) Documents

func (*FirestoreInstallationsQuery) Limit

func (*FirestoreInstallationsQuery) OrderBy

func (*FirestoreInstallationsQuery) Value

func (*FirestoreInstallationsQuery) Where

func (q *FirestoreInstallationsQuery) Where(path, op string, value interface{}) *FirestoreInstallationsQuery

type FirestoreManifest

type FirestoreManifest struct {
	Id         string    `firestore:"id,omitempty"`
	Owner      string    `firestore:"owner,omitempty"`
	Repository string    `firestore:"repository,omitempty"`
	CreateTime time.Time `firestore:"createTime,serverTimestamp"`
}

FirestoreManifest is the Firestore Custom Object for utils.Manifest.

func (*FirestoreManifest) ToProto

func (m *FirestoreManifest) ToProto() (*Manifest, error)

ToProto converts this FirestoreManifest to its protobuf representation.

type FirestoreManifestsCollectionRef

type FirestoreManifestsCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreManifestsCollectionRef holds a reference to the Firestore collection `manifests`.

func (*FirestoreManifestsCollectionRef) Create

func (*FirestoreManifestsCollectionRef) Doc

func (*FirestoreManifestsCollectionRef) Limit

func (*FirestoreManifestsCollectionRef) OrderBy

func (*FirestoreManifestsCollectionRef) Where

func (ref *FirestoreManifestsCollectionRef) Where(path, op string, value interface{}) *FirestoreManifestsQuery

type FirestoreManifestsDocumentRef

type FirestoreManifestsDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreManifestsDocumentRef holds a reference to a Firestore document in collection `manifests`.

func (*FirestoreManifestsDocumentRef) Actions added in v2.0.2

func (*FirestoreManifestsDocumentRef) Delete

func (*FirestoreManifestsDocumentRef) Get

func (*FirestoreManifestsDocumentRef) Ref

func (*FirestoreManifestsDocumentRef) Set

type FirestoreManifestsIterator

type FirestoreManifestsIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreManifestsIterator) GetAll

func (i *FirestoreManifestsIterator) GetAll() ([]*Manifest, error)

func (*FirestoreManifestsIterator) GetAllAsSnapshots

func (i *FirestoreManifestsIterator) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FirestoreManifestsIterator) Next

func (*FirestoreManifestsIterator) NextAsSnapshot

func (*FirestoreManifestsIterator) Stop

func (i *FirestoreManifestsIterator) Stop()

type FirestoreManifestsQuery

type FirestoreManifestsQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreManifestsQuery) Documents

func (*FirestoreManifestsQuery) First

func (*FirestoreManifestsQuery) Limit

func (*FirestoreManifestsQuery) OrderBy

func (*FirestoreManifestsQuery) Value

func (*FirestoreManifestsQuery) Where

func (q *FirestoreManifestsQuery) Where(path, op string, value interface{}) *FirestoreManifestsQuery

type FirestoreRepositoriesCollectionRef

type FirestoreRepositoriesCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreRepositoriesCollectionRef holds a reference to the Firestore collection `repositories`.

func (*FirestoreRepositoriesCollectionRef) Doc

func (*FirestoreRepositoriesCollectionRef) Limit

func (*FirestoreRepositoriesCollectionRef) OrderBy

func (*FirestoreRepositoriesCollectionRef) Where

func (ref *FirestoreRepositoriesCollectionRef) Where(path, op string, value interface{}) *FirestoreRepositoriesQuery

type FirestoreRepositoriesDocumentRef

type FirestoreRepositoriesDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreRepositoriesDocumentRef holds a reference to a Firestore document in collection `repositories`.

func (*FirestoreRepositoriesDocumentRef) Manifests added in v2.0.2

type FirestoreRepositoriesIterator

type FirestoreRepositoriesIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreRepositoriesIterator) Stop

type FirestoreRepositoriesQuery

type FirestoreRepositoriesQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreRepositoriesQuery) Documents

func (*FirestoreRepositoriesQuery) Limit

func (*FirestoreRepositoriesQuery) OrderBy

func (*FirestoreRepositoriesQuery) Value

func (*FirestoreRepositoriesQuery) Where

func (q *FirestoreRepositoriesQuery) Where(path, op string, value interface{}) *FirestoreRepositoriesQuery

type FirestoreSession

type FirestoreSession struct {
	Uuid string `firestore:"uuid,omitempty"`
}

FirestoreSession is the Firestore Custom Object for utils.Session.

func (*FirestoreSession) ToProto

func (m *FirestoreSession) ToProto() (*Session, error)

ToProto converts this FirestoreSession to its protobuf representation.

type FirestoreSessionsCollectionRef

type FirestoreSessionsCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreSessionsCollectionRef holds a reference to the Firestore collection `sessions`.

func (*FirestoreSessionsCollectionRef) Doc

func (*FirestoreSessionsCollectionRef) Limit

func (*FirestoreSessionsCollectionRef) OrderBy

func (*FirestoreSessionsCollectionRef) Where

func (ref *FirestoreSessionsCollectionRef) Where(path, op string, value interface{}) *FirestoreSessionsQuery

type FirestoreSessionsDocumentRef

type FirestoreSessionsDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreSessionsDocumentRef holds a reference to a Firestore document in collection `sessions`.

func (*FirestoreSessionsDocumentRef) Delete

func (*FirestoreSessionsDocumentRef) Get

func (*FirestoreSessionsDocumentRef) Ref

func (*FirestoreSessionsDocumentRef) Set

type FirestoreSessionsIterator

type FirestoreSessionsIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreSessionsIterator) GetAll

func (i *FirestoreSessionsIterator) GetAll() ([]*Session, error)

func (*FirestoreSessionsIterator) GetAllAsSnapshots

func (i *FirestoreSessionsIterator) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FirestoreSessionsIterator) Next

func (i *FirestoreSessionsIterator) Next() (*Session, error)

func (*FirestoreSessionsIterator) NextAsSnapshot

func (*FirestoreSessionsIterator) Stop

func (i *FirestoreSessionsIterator) Stop()

type FirestoreSessionsQuery

type FirestoreSessionsQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreSessionsQuery) Documents

func (*FirestoreSessionsQuery) First

func (*FirestoreSessionsQuery) Limit

func (*FirestoreSessionsQuery) OrderBy

func (*FirestoreSessionsQuery) Value

func (*FirestoreSessionsQuery) Where

func (q *FirestoreSessionsQuery) Where(path, op string, value interface{}) *FirestoreSessionsQuery

type FirestoreUser

type FirestoreUser struct {
	Name string `firestore:"name,omitempty"`
}

FirestoreUser is the Firestore Custom Object for utils.User.

func (*FirestoreUser) ToProto

func (m *FirestoreUser) ToProto() (*User, error)

ToProto converts this FirestoreUser to its protobuf representation.

type FirestoreUsersCollectionRef

type FirestoreUsersCollectionRef struct {
	// contains filtered or unexported fields
}

FirestoreUsersCollectionRef holds a reference to the Firestore collection `users`.

func (*FirestoreUsersCollectionRef) Create

func (*FirestoreUsersCollectionRef) Doc

func (*FirestoreUsersCollectionRef) Limit

func (*FirestoreUsersCollectionRef) OrderBy

func (*FirestoreUsersCollectionRef) Where

func (ref *FirestoreUsersCollectionRef) Where(path, op string, value interface{}) *FirestoreUsersQuery

type FirestoreUsersDocumentRef

type FirestoreUsersDocumentRef struct {
	// contains filtered or unexported fields
}

FirestoreUsersDocumentRef holds a reference to a Firestore document in collection `users`.

func (*FirestoreUsersDocumentRef) Delete

func (*FirestoreUsersDocumentRef) Get

func (*FirestoreUsersDocumentRef) Ref

func (*FirestoreUsersDocumentRef) Sessions added in v2.0.2

func (*FirestoreUsersDocumentRef) Set

func (ref *FirestoreUsersDocumentRef) Set(ctx context.Context, msg *User, opts ...firestore.SetOption) error

type FirestoreUsersIterator

type FirestoreUsersIterator struct {
	// contains filtered or unexported fields
}

func (*FirestoreUsersIterator) GetAll

func (i *FirestoreUsersIterator) GetAll() ([]*User, error)

func (*FirestoreUsersIterator) GetAllAsSnapshots

func (i *FirestoreUsersIterator) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FirestoreUsersIterator) Next

func (i *FirestoreUsersIterator) Next() (*User, error)

func (*FirestoreUsersIterator) NextAsSnapshot

func (i *FirestoreUsersIterator) NextAsSnapshot() (*firestore.DocumentSnapshot, error)

func (*FirestoreUsersIterator) Stop

func (i *FirestoreUsersIterator) Stop()

type FirestoreUsersQuery

type FirestoreUsersQuery struct {
	// contains filtered or unexported fields
}

func (*FirestoreUsersQuery) Documents

func (*FirestoreUsersQuery) First

func (q *FirestoreUsersQuery) First(ctx context.Context) (*User, error)

func (*FirestoreUsersQuery) Limit

func (*FirestoreUsersQuery) OrderBy

func (*FirestoreUsersQuery) Value

func (q *FirestoreUsersQuery) Value() firestore.Query

func (*FirestoreUsersQuery) Where

func (q *FirestoreUsersQuery) Where(path, op string, value interface{}) *FirestoreUsersQuery

type Manifest

type Manifest struct {
	Id         string                 `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Owner      string                 `protobuf:"bytes,2,opt,name=owner,proto3" json:"owner,omitempty"`
	Repository string                 `protobuf:"bytes,3,opt,name=repository,proto3" json:"repository,omitempty"`
	CreateTime *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=create_time,json=createTime,proto3" json:"create_time,omitempty"`
	// contains filtered or unexported fields
}

func (*Manifest) Descriptor deprecated

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

Deprecated: Use Manifest.ProtoReflect.Descriptor instead.

func (*Manifest) GetCreateTime

func (x *Manifest) GetCreateTime() *timestamppb.Timestamp

func (*Manifest) GetId

func (x *Manifest) GetId() string

func (*Manifest) GetOwner

func (x *Manifest) GetOwner() string

func (*Manifest) GetRepository

func (x *Manifest) GetRepository() string

func (*Manifest) ProtoMessage

func (*Manifest) ProtoMessage()

func (*Manifest) ProtoReflect

func (x *Manifest) ProtoReflect() protoreflect.Message

func (*Manifest) Reset

func (x *Manifest) Reset()

func (*Manifest) String

func (x *Manifest) String() string

func (*Manifest) ToFirestore

func (x *Manifest) ToFirestore() (*FirestoreManifest, error)

ToFirestore returns the Firestore Custom Object for Manifest.

type Session

type Session struct {
	Uuid string `protobuf:"bytes,1,opt,name=uuid,proto3" json:"uuid,omitempty"`
	// contains filtered or unexported fields
}

func (*Session) Descriptor deprecated

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

Deprecated: Use Session.ProtoReflect.Descriptor instead.

func (*Session) GetUuid

func (x *Session) GetUuid() string

func (*Session) ProtoMessage

func (*Session) ProtoMessage()

func (*Session) ProtoReflect

func (x *Session) ProtoReflect() protoreflect.Message

func (*Session) Reset

func (x *Session) Reset()

func (*Session) String

func (x *Session) String() string

func (*Session) ToFirestore

func (x *Session) ToFirestore() (*FirestoreSession, error)

ToFirestore returns the Firestore Custom Object for Session.

type User

type User struct {
	Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	// contains filtered or unexported fields
}

func (*User) Descriptor deprecated

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

Deprecated: Use User.ProtoReflect.Descriptor instead.

func (*User) GetName

func (x *User) GetName() string

func (*User) ProtoMessage

func (*User) ProtoMessage()

func (*User) ProtoReflect

func (x *User) ProtoReflect() protoreflect.Message

func (*User) Reset

func (x *User) Reset()

func (*User) String

func (x *User) String() string

func (*User) ToFirestore

func (x *User) ToFirestore() (*FirestoreUser, error)

ToFirestore returns the Firestore Custom Object for User.

Jump to

Keyboard shortcuts

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