service

package module
v0.0.0-...-61added Latest Latest
Warning

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

Go to latest
Published: Nov 30, 2019 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package service is a gRPC service. It implements all of the service methods defined in the proto file. Authentication will happen on the per method level, still deciding on a pattern but using interceptors and by decorating the methods I should be able to have a decent permissions framework.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	DB      string
	Cache   string
	Storage string
}

Service is a type representing a configured server.

func NewService

func NewService(db string, cache string, storage string) *Service

NewService returns a new service configured with all the resources.

func (*Service) ArchiveLandingPage

func (s *Service) ArchiveLandingPage(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ArchiveLandingPage will check the current LandingPage state.

func (*Service) ArchiveUser

func (s *Service) ArchiveUser(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ArchiveUser will archive the current User state.

func (*Service) CreateConfiguration

func (s *Service) CreateConfiguration(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

CreateConfiguration will create the current configuration state.

func (*Service) CreateLandingPage

func (s *Service) CreateLandingPage(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

CreateLandingPage will check the current LandingPage state.

func (*Service) CreateMovement

CreateMovement will create the current Movement state.

func (*Service) CreateUser

func (s *Service) CreateUser(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

CreateUser will create the current User state.

func (*Service) DeleteMovement

DeleteMovement will check the current Movement state.

func (*Service) DestroyConfiguration

func (s *Service) DestroyConfiguration(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

DestroyConfiguration will check the current configuration state.

func (*Service) GetVolunteerLocationStream

func (s *Service) GetVolunteerLocationStream(in *pb.StubRequest, stream pb.Shrike_GetVolunteerLocationStreamServer) error

GetVolunteerLocationStream will return a stream of Volunteer GPS coordinates.

func (*Service) ListLandingPages

func (s *Service) ListLandingPages(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ListLandingPages will check the current LandingPage state.

func (*Service) ListMovements

ListMovements will check the current Movement state.

func (*Service) ListUsers

func (s *Service) ListUsers(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ListUsers will check the current User state.

func (*Service) ReadConfiguration

func (s *Service) ReadConfiguration(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ReadConfiguration will check the current configuration state.

func (*Service) ReadLandingPage

func (s *Service) ReadLandingPage(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ReadLandingPage will check the current LandingPage state.

func (*Service) ReadMovement

func (s *Service) ReadMovement(ctx context.Context, in *pb.ReadMovementRequest) (*pb.ReadMovementResponse, error)

ReadMovement will read the current Movement state.

func (*Service) ReadUser

func (s *Service) ReadUser(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

ReadUser will read the current User state.

func (*Service) UpdateConfiguration

func (s *Service) UpdateConfiguration(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

UpdateConfiguration will check the current configuration state.

func (*Service) UpdateLandingPage

func (s *Service) UpdateLandingPage(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

UpdateLandingPage will check the current LandingPage state.

func (*Service) UpdateMovement

UpdateMovement will check the current Movement state.

func (*Service) UpdateUser

func (s *Service) UpdateUser(ctx context.Context, in *pb.StubRequest) (*pb.StubResponse, error)

UpdateUser will update the current User state.

Jump to

Keyboard shortcuts

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