services

package
v0.1.3 Latest Latest
Warning

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

Go to latest
Published: Jan 8, 2019 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func New

func New(settings *platform.Settings) presidio.ServicesAPI

New services with settings

Types

type Services

type Services struct {
	AnalyzerService       types.AnalyzeServiceClient
	AnonymizeService      types.AnonymizeServiceClient
	AnonymizeImageService types.AnonymizeImageServiceClient
	OcrService            types.OcrServiceClient
	DatasinkService       types.DatasinkServiceClient
	SchedulerService      types.SchedulerServiceClient
	Settings              *platform.Settings
}

Services exposes GRPC services

func (*Services) AnalyzeItem

func (services *Services) AnalyzeItem(ctx context.Context, text string, template *types.AnalyzeTemplate) ([]*types.AnalyzeResult, error)

AnalyzeItem - search for PII

func (*Services) AnonymizeImageItem added in v0.1.3

func (services *Services) AnonymizeImageItem(ctx context.Context, image *types.Image, analyzeResults []*types.AnalyzeResult,
	detectionType types.DetectionTypeEnum,
	anonymizeImageTemplate *types.AnonymizeImageTemplate) (*types.AnonymizeImageResponse, error)

AnonymizeImageItem - anonymize image

func (*Services) AnonymizeItem

func (services *Services) AnonymizeItem(ctx context.Context, analyzeResults []*types.AnalyzeResult,
	text string, anonymizeTemplate *types.AnonymizeTemplate) (*types.AnonymizeResponse, error)

AnonymizeItem - anonymize text

func (*Services) ApplyScan

func (services *Services) ApplyScan(ctx context.Context, scanJobRequest *types.ScannerCronJobRequest) (*types.ScannerCronJobResponse, error)

ApplyScan create scan cron job

func (*Services) ApplyStream

func (services *Services) ApplyStream(ctx context.Context, streamsJobRequest *types.StreamsJobRequest) (*types.StreamsJobResponse, error)

ApplyStream create stream job

func (*Services) CloseDatasink

func (services *Services) CloseDatasink(ctx context.Context, datasinkTemplate *types.CompletionMessage) (*types.DatasinkResponse, error)

CloseDatasink notify datasink the collector is finished

func (*Services) InitDatasink

func (services *Services) InitDatasink(ctx context.Context, datasinkTemplate *types.DatasinkTemplate) (*types.DatasinkResponse, error)

InitDatasink initialize datasink app

func (*Services) OcrItem added in v0.1.3

func (services *Services) OcrItem(ctx context.Context, image *types.Image) (*types.OcrResponse, error)

OcrItem - ocr image

func (*Services) SendResultToDatasink

func (services *Services) SendResultToDatasink(ctx context.Context, analyzeResults []*types.AnalyzeResult,
	anonymizeResults *types.AnonymizeResponse, path string) error

SendResultToDatasink - export results

func (*Services) SetupAnalyzerService

func (services *Services) SetupAnalyzerService()

SetupAnalyzerService GRPC connection

func (*Services) SetupAnonymizerImageService added in v0.1.3

func (services *Services) SetupAnonymizerImageService()

SetupAnonymizerImageService GRPC connection

func (*Services) SetupAnonymizerService

func (services *Services) SetupAnonymizerService()

SetupAnonymizerService GRPC connection

func (*Services) SetupCache

func (services *Services) SetupCache() cache.Cache

SetupCache Redis cache

func (*Services) SetupDatasinkService

func (services *Services) SetupDatasinkService()

SetupDatasinkService GRPC connection

func (*Services) SetupOCRService added in v0.1.3

func (services *Services) SetupOCRService()

SetupOCRService GRPC connection

func (*Services) SetupSchedulerService

func (services *Services) SetupSchedulerService()

SetupSchedulerService GRPC connection

Jump to

Keyboard shortcuts

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