business

package
Version: v3.22.2+incompatible Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2021 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrGLNNotFound         error
	ErrGLNDoesNotMatch     error
	ErrGLNCantParse        error
	ErrGLNNoLookupProvider error
)

Error constants

Functions

This section is empty.

Types

type GlnLookupProvider

type GlnLookupProvider interface {
	Lookup(gln string) GlnSearchResult
}

GlnLookupProvider interface

func NewMedRegOmLookup

func NewMedRegOmLookup(baseURL string, httpTimeout time.Duration, logger keycloakb.Logger) (GlnLookupProvider, error)

NewMedRegOmLookup creates a GLN lookup tool using medregom.admin.ch

func NewNaRegLookup

func NewNaRegLookup(baseURL string, httpTimeout time.Duration, logger keycloakb.Logger) (GlnLookupProvider, error)

NewNaRegLookup creates a GLN lookup provider using nareg website

func NewPsyRegLookup

func NewPsyRegLookup(baseURL string, httpTimeout time.Duration, logger keycloakb.Logger) (GlnLookupProvider, error)

NewPsyRegLookup creates a GLN lookup tool using psyreg.admin.ch

func NewRefDataLookup

func NewRefDataLookup(baseURL string, httpTimeout time.Duration, logger keycloakb.Logger) (GlnLookupProvider, error)

NewRefDataLookup creates a GLN lookup tool using refdata.ch

type GlnPerson

type GlnPerson struct {
	Active     *bool
	Number     *string
	FirstName  *string
	LastName   *string
	Canton     *string
	ZipCode    *string
	City       *string
	Country    *string
	Profession *string
}

GlnPerson describes a person found by his/her GLN number

type GlnSearchResult

type GlnSearchResult struct {
	Persons []GlnPerson
	Error   error
}

GlnSearchResult is the result of a GLN lookup. It includes effective result field and an error field in order to be passed through a channel in a single operation

type GlnVerifier

type GlnVerifier interface {
	ValidateGLN(firstName, lastName, gln string) error
}

GlnVerifier interface

func NewGlnVerifier

func NewGlnVerifier(providers ...GlnLookupProvider) GlnVerifier

NewGlnVerifier creates a GLN verifier using given GLN lookup providers

type MedRegPerson

type MedRegPerson struct {
	ID         *int     `json:"Id"`
	FirstName  *string  `json:"FirstName"`
	LastName   *string  `json:"LastName"`
	Profession *string  `json:"Beruf"`
	Street     []string `json:"Strasse"`
	ZipCode    []string `json:"Plz"`
	Location   []string `json:"Ort"`
	Score      *int     `json:"Score"`
	Education  *string  `json:"Weiterbildungen"`
}

MedRegPerson struct

type MedRegResponse

type MedRegResponse struct {
	EmptyRowData   interface{}    `json:"emptyrowdata"`
	Rows           []MedRegPerson `json:"rows"`
	Settings       interface{}    `json:"settings"`
	AdditionalInfo interface{}    `json:"additionalInfo"`
}

MedRegResponse struct

Jump to

Keyboard shortcuts

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