service

package
v0.0.0-...-e608192 Latest Latest
Warning

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

Go to latest
Published: Oct 15, 2018 License: BSD-3-Clause Imports: 18 Imported by: 0

Documentation

Overview

Package service contains helpers for creating services.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

type Application struct {
	AuthResource string
	Host         []string
	Login        []LoginBundle
}

type Configration

type Configration interface {
	HTTPServer() (api.HTTPServer, bool)
	AuthServer() (api.AuthServer, bool)
	BundleUpdate(*api.ServiceBundle)
}

Configuration

type ConnRes

type ConnRes struct {
	Conn     *grpc.ClientConn
	Resource *api.Resource
}

type LoginBundle

type LoginBundle struct {
	ConsumeRedirect bool
	Resource        string
	Prefix          string
	LoginState      string // api.LoginState_value
}

type RemoteService

type RemoteService struct {
	Conn    *grpc.ClientConn
	Address string
}

type Resource

type Resource struct {
	Name    string
	Type    string // api.ResourceType
	Consume string // api.ResourceType
	Parent  string
	Include []string
	C       map[string]interface{}
}

type ResourceFile

type ResourceFile struct {
	Name    string
	File    string
	Content string
}

ResourceFile represents a donwloadable ll

type SCReader

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

func NewSCReader

func NewSCReader(p string) (*SCReader, error)

func (*SCReader) Close

func (r *SCReader) Close()

type Service

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

func New

func New() *Service

func (*Service) ResConn

func (s *Service) ResConn(version string) (map[string]ConnRes, bool)

func (*Service) SPA

func (s *Service) SPA(name string) (*ResourceFile, bool)

func (*Service) Setup

func (s *Service) Setup(ctx context.Context, sc Configration)

type ServiceConfiguration

type ServiceConfiguration struct {
	Name        string
	Application []Application
	Resource    []Resource
	Files       []*ResourceFile
}

Jump to

Keyboard shortcuts

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