utils

package
v1.3.0 Latest Latest
Warning

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

Go to latest
Published: Feb 9, 2023 License: Apache-2.0 Imports: 11 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 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 FS_utils

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

func Firestore

func Firestore(client *firestore.Client) *FS_utils

func (*FS_utils) Accounts

func (x *FS_utils) Accounts() *FS_utils_Accounts

func (*FS_utils) Users added in v1.2.0

func (x *FS_utils) Users() *FS_utils_Users

type FS_utils_Accounts

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

func (*FS_utils_Accounts) Doc

func (*FS_utils_Accounts) Limit

func (*FS_utils_Accounts) OrderBy

func (*FS_utils_Accounts) Where

func (x *FS_utils_Accounts) Where(path, op string, value interface{}) *FS_utils_Accounts_Query

type FS_utils_Accounts_Doc

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

func (*FS_utils_Accounts_Doc) Delete added in v1.2.0

func (*FS_utils_Accounts_Doc) Get added in v1.2.0

func (*FS_utils_Accounts_Doc) Ref added in v1.2.0

func (*FS_utils_Accounts_Doc) Set added in v1.2.0

type FS_utils_Accounts_Iter

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

func (*FS_utils_Accounts_Iter) GetAll added in v1.2.0

func (x *FS_utils_Accounts_Iter) GetAll() ([]*Account, error)

func (*FS_utils_Accounts_Iter) GetAllAsSnapshots added in v1.2.0

func (x *FS_utils_Accounts_Iter) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FS_utils_Accounts_Iter) Next added in v1.2.0

func (x *FS_utils_Accounts_Iter) Next() (*Account, error)

func (*FS_utils_Accounts_Iter) NextAsSnapshot added in v1.2.0

func (x *FS_utils_Accounts_Iter) NextAsSnapshot() (*firestore.DocumentSnapshot, error)

func (*FS_utils_Accounts_Iter) Stop

func (x *FS_utils_Accounts_Iter) Stop()

type FS_utils_Accounts_Query

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

func (*FS_utils_Accounts_Query) Documents

func (*FS_utils_Accounts_Query) First added in v1.2.0

func (*FS_utils_Accounts_Query) Limit

func (*FS_utils_Accounts_Query) OrderBy

func (*FS_utils_Accounts_Query) Value

func (*FS_utils_Accounts_Query) Where

func (x *FS_utils_Accounts_Query) Where(path, op string, value interface{}) *FS_utils_Accounts_Query

type FS_utils_Users added in v1.2.0

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

func (*FS_utils_Users) Create added in v1.2.0

func (x *FS_utils_Users) Create(ctx context.Context, p *User) (*firestore.WriteResult, error)

func (*FS_utils_Users) Doc added in v1.2.0

func (*FS_utils_Users) Limit added in v1.2.0

func (*FS_utils_Users) OrderBy added in v1.2.0

func (*FS_utils_Users) Where added in v1.2.0

func (x *FS_utils_Users) Where(path, op string, value interface{}) *FS_utils_Users_Query

type FS_utils_Users_Doc added in v1.2.0

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

func (*FS_utils_Users_Doc) Delete added in v1.2.0

func (*FS_utils_Users_Doc) Get added in v1.2.0

func (x *FS_utils_Users_Doc) Get(ctx context.Context) (*User, error)

func (*FS_utils_Users_Doc) Ref added in v1.2.0

func (*FS_utils_Users_Doc) Sessions added in v1.2.0

func (*FS_utils_Users_Doc) Set added in v1.2.0

func (x *FS_utils_Users_Doc) Set(ctx context.Context, m *User) error

type FS_utils_Users_Iter added in v1.2.0

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

func (*FS_utils_Users_Iter) GetAll added in v1.2.0

func (x *FS_utils_Users_Iter) GetAll() ([]*User, error)

func (*FS_utils_Users_Iter) GetAllAsSnapshots added in v1.2.0

func (x *FS_utils_Users_Iter) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FS_utils_Users_Iter) Next added in v1.2.0

func (x *FS_utils_Users_Iter) Next() (*User, error)

func (*FS_utils_Users_Iter) NextAsSnapshot added in v1.2.0

func (x *FS_utils_Users_Iter) NextAsSnapshot() (*firestore.DocumentSnapshot, error)

func (*FS_utils_Users_Iter) Stop added in v1.2.0

func (x *FS_utils_Users_Iter) Stop()

type FS_utils_Users_Query added in v1.2.0

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

func (*FS_utils_Users_Query) Documents added in v1.2.0

func (*FS_utils_Users_Query) First added in v1.2.0

func (x *FS_utils_Users_Query) First(ctx context.Context) (*User, error)

func (*FS_utils_Users_Query) Limit added in v1.2.0

func (*FS_utils_Users_Query) OrderBy added in v1.2.0

func (*FS_utils_Users_Query) Value added in v1.2.0

func (*FS_utils_Users_Query) Where added in v1.2.0

func (x *FS_utils_Users_Query) Where(path, op string, value interface{}) *FS_utils_Users_Query

type FS_utils_Users_Sessions added in v1.2.0

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

func (*FS_utils_Users_Sessions) Doc added in v1.2.0

func (*FS_utils_Users_Sessions) Limit added in v1.2.0

func (*FS_utils_Users_Sessions) OrderBy added in v1.2.0

func (*FS_utils_Users_Sessions) Where added in v1.2.0

func (x *FS_utils_Users_Sessions) Where(path, op string, value interface{}) *FS_utils_Users_Sessions_Query

type FS_utils_Users_Sessions_Doc added in v1.2.0

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

func (*FS_utils_Users_Sessions_Doc) Delete added in v1.2.0

func (*FS_utils_Users_Sessions_Doc) Get added in v1.2.0

func (*FS_utils_Users_Sessions_Doc) Ref added in v1.2.0

func (*FS_utils_Users_Sessions_Doc) Set added in v1.2.0

type FS_utils_Users_Sessions_Iter added in v1.2.0

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

func (*FS_utils_Users_Sessions_Iter) GetAll added in v1.2.0

func (x *FS_utils_Users_Sessions_Iter) GetAll() ([]*Session, error)

func (*FS_utils_Users_Sessions_Iter) GetAllAsSnapshots added in v1.2.0

func (x *FS_utils_Users_Sessions_Iter) GetAllAsSnapshots() ([]*firestore.DocumentSnapshot, error)

func (*FS_utils_Users_Sessions_Iter) Next added in v1.2.0

func (*FS_utils_Users_Sessions_Iter) NextAsSnapshot added in v1.2.0

func (*FS_utils_Users_Sessions_Iter) Stop added in v1.2.0

func (x *FS_utils_Users_Sessions_Iter) Stop()

type FS_utils_Users_Sessions_Query added in v1.2.0

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

func (*FS_utils_Users_Sessions_Query) Documents added in v1.2.0

func (*FS_utils_Users_Sessions_Query) First added in v1.2.0

func (*FS_utils_Users_Sessions_Query) Limit added in v1.2.0

func (*FS_utils_Users_Sessions_Query) OrderBy added in v1.2.0

func (*FS_utils_Users_Sessions_Query) Value added in v1.2.0

func (*FS_utils_Users_Sessions_Query) Where added in v1.2.0

func (x *FS_utils_Users_Sessions_Query) Where(path, op string, value interface{}) *FS_utils_Users_Sessions_Query

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 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 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 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