entgo

package
v0.0.9 Latest Latest
Warning

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

Go to latest
Published: May 16, 2021 License: AGPL-3.0 Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type EntgoRepository

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

func NewEntgoRepository

func NewEntgoRepository(
	client *ent.Client,
	logger *logger.Logger,
) *EntgoRepository

func (*EntgoRepository) CorrelationCount added in v0.0.5

func (r *EntgoRepository) CorrelationCount() (int, error)

func (*EntgoRepository) CreateDataset

func (r *EntgoRepository) CreateDataset(d *domain.Dataset) (*domain.Dataset, error)

func (*EntgoRepository) CreateDictionaty added in v0.0.8

func (r *EntgoRepository) CreateDictionaty(d *domain.Dictionary) error

func (*EntgoRepository) CreateDictionatyEntry added in v0.0.8

func (r *EntgoRepository) CreateDictionatyEntry(d *domain.DictionaryEntry) error

func (*EntgoRepository) CreateIndicator

func (r *EntgoRepository) CreateIndicator(i *domain.Indicator) (*domain.Indicator, error)

func (*EntgoRepository) CreateObservation

func (r *EntgoRepository) CreateObservation(o *domain.Observation) (*domain.Observation, error)

func (*EntgoRepository) CreateOrUpdateCorrelation

func (r *EntgoRepository) CreateOrUpdateCorrelation(c *domain.Correlation) (*domain.Correlation, error)

func (*EntgoRepository) CreateOrUpdateObservation

func (r *EntgoRepository) CreateOrUpdateObservation(o *domain.Observation) (*domain.Observation, error)

func (*EntgoRepository) CreateScale

func (r *EntgoRepository) CreateScale(s domain.Scale) (*domain.Scale, error)

func (*EntgoRepository) CreateUser

func (r *EntgoRepository) CreateUser(u *domain.User) (*domain.User, error)

func (*EntgoRepository) DatasetCount added in v0.0.5

func (r *EntgoRepository) DatasetCount() (int, error)

func (*EntgoRepository) GetCorrelation

func (r *EntgoRepository) GetCorrelation(args domain.GetCorrelationArgs) (*domain.Correlation, error)

func (*EntgoRepository) GetDatasetByID

func (r *EntgoRepository) GetDatasetByID(id int, observationsLimit int, granularity string) (*domain.Dataset, error)

func (*EntgoRepository) GetDatasets

func (r *EntgoRepository) GetDatasets(args domain.GetDatasetsArgs) ([]*domain.Dataset, error)

func (*EntgoRepository) GetDictionaryByCode added in v0.0.8

func (r *EntgoRepository) GetDictionaryByCode(code string) (*domain.Dictionary, error)

func (*EntgoRepository) GetDictionaryByID added in v0.0.8

func (r *EntgoRepository) GetDictionaryByID(id int) (*domain.Dictionary, error)

func (*EntgoRepository) GetDictionaryEntryByID added in v0.0.8

func (r *EntgoRepository) GetDictionaryEntryByID(id int) (*domain.DictionaryEntry, error)

func (*EntgoRepository) GetIndicatorByCode added in v0.0.7

func (r *EntgoRepository) GetIndicatorByCode(code string) (*domain.Indicator, error)

func (*EntgoRepository) GetIndicatorByID

func (r *EntgoRepository) GetIndicatorByID(id int) (*domain.Indicator, error)

func (*EntgoRepository) GetIndicators

func (r *EntgoRepository) GetIndicators(args domain.GetIndicatorsArgs) ([]*domain.Indicator, error)

func (*EntgoRepository) GetOrCreateUserIndicatorDataset

func (r *EntgoRepository) GetOrCreateUserIndicatorDataset(u *domain.User, ind *domain.Indicator) (*domain.Dataset, error)

func (*EntgoRepository) GetScaleByType

func (r *EntgoRepository) GetScaleByType(scaleType string) (*domain.Scale, error)

func (*EntgoRepository) GetScales

func (r *EntgoRepository) GetScales() ([]*domain.Scale, error)

func (*EntgoRepository) GetUserByID

func (r *EntgoRepository) GetUserByID(id int) (*domain.User, error)

func (*EntgoRepository) GetUserByUsername

func (r *EntgoRepository) GetUserByUsername(username string) (*domain.User, error)

func (*EntgoRepository) GetUserCorrelations

func (r *EntgoRepository) GetUserCorrelations(userID int, granularity string) ([]*domain.Correlation, error)

func (*EntgoRepository) GetUserCount

func (r *EntgoRepository) GetUserCount() (int, error)

func (*EntgoRepository) GetUserDatasets

func (r *EntgoRepository) GetUserDatasets(userID int, withShared bool, observationsLimit int, granularity string) ([]*domain.Dataset, error)

GetUserDatasets fetches all datasets created or avaliable to user, including shared datasets.

func (*EntgoRepository) GetUserIndicatorDataset

func (r *EntgoRepository) GetUserIndicatorDataset(u *domain.User, ind *domain.Indicator) (*domain.Dataset, error)

func (*EntgoRepository) IndicatorCount added in v0.0.5

func (r *EntgoRepository) IndicatorCount() (int, error)

func (*EntgoRepository) ObservationCount added in v0.0.5

func (r *EntgoRepository) ObservationCount() (int, error)

func (*EntgoRepository) ScaleCount added in v0.0.5

func (r *EntgoRepository) ScaleCount() (int, error)

func (*EntgoRepository) UpdateIndicator added in v0.0.8

func (r *EntgoRepository) UpdateIndicator(i *domain.Indicator) (*domain.Indicator, error)

func (*EntgoRepository) UserCount added in v0.0.5

func (r *EntgoRepository) UserCount() (int, error)

Jump to

Keyboard shortcuts

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