Documentation ¶
Index ¶
- type FirestoreBackend
- func (backend *FirestoreBackend) Close() error
- func (backend *FirestoreBackend) Del(ctx context.Context, key string) error
- func (backend *FirestoreBackend) Get(ctx context.Context, name string) (*internal.Route, error)
- func (backend *FirestoreBackend) GetAll(ctx context.Context) (map[string]internal.Route, error)
- func (backend *FirestoreBackend) List(ctx context.Context, start string) (internal.RouteIterator, error)
- func (backend *FirestoreBackend) NextID(ctx context.Context) (uint64, error)
- func (backend *FirestoreBackend) Put(ctx context.Context, key string, rt *internal.Route) error
- type FirestoreRouteIterator
- func (i *FirestoreRouteIterator) Error() error
- func (i *FirestoreRouteIterator) Name() string
- func (i *FirestoreRouteIterator) Next() bool
- func (i *FirestoreRouteIterator) Release()
- func (i *FirestoreRouteIterator) Route() *internal.Route
- func (i *FirestoreRouteIterator) Seek(cur string) bool
- func (i *FirestoreRouteIterator) Valid() bool
- type NextID
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FirestoreBackend ¶
type FirestoreBackend struct {
// contains filtered or unexported fields
}
FirestoreBackend provides access to Google Firestore.
func (*FirestoreBackend) Close ¶
func (backend *FirestoreBackend) Close() error
Close the resources associated with this backend.
func (*FirestoreBackend) Del ¶
func (backend *FirestoreBackend) Del(ctx context.Context, key string) error
Del removes an existing shortcut from the data store.
func (*FirestoreBackend) GetAll ¶
GetAll gets everything in the db to dump it out for backup purposes
func (*FirestoreBackend) List ¶
func (backend *FirestoreBackend) List(ctx context.Context, start string) (internal.RouteIterator, error)
List all routes in an iterator, starting with the key prefix of start (which can also be nil).
type FirestoreRouteIterator ¶
type FirestoreRouteIterator struct {
// contains filtered or unexported fields
}
FirestoreRouteIterator allows iteration of the named routes in firestore.
func (*FirestoreRouteIterator) Error ¶
func (i *FirestoreRouteIterator) Error() error
Error returns any active error that has stopped the iterator.
func (*FirestoreRouteIterator) Name ¶
func (i *FirestoreRouteIterator) Name() string
Name is the name of the current route.
func (*FirestoreRouteIterator) Next ¶
func (i *FirestoreRouteIterator) Next() bool
Next advances the iterator to the next value.
func (*FirestoreRouteIterator) Release ¶
func (i *FirestoreRouteIterator) Release()
Release disposes of the resources in the iterator.
func (*FirestoreRouteIterator) Route ¶
func (i *FirestoreRouteIterator) Route() *internal.Route
Route is the current route.
func (*FirestoreRouteIterator) Seek ¶
func (i *FirestoreRouteIterator) Seek(cur string) bool
Seek ...
func (*FirestoreRouteIterator) Valid ¶
func (i *FirestoreRouteIterator) Valid() bool
Valid indicates whether the current values of the iterator are valid.