attributes

package
v1.0.0-dev Latest Latest
Warning

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

Go to latest
Published: Jun 3, 2025 License: GPL-3.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseAttribute

func ParseAttribute(dp utils.DataProvider, attrType, path string, value utils.RSRParsers, roundingDec int, timeZone, layout string) (
	out any, err error)

Types

type AttrSProcessEventReply

type AttrSProcessEventReply struct {
	AlteredFields []*FieldsAltered
	CGREvent      *utils.CGREvent
	// contains filtered or unexported fields
}

AttrSProcessEventReply reply used for proccess event

func (*AttrSProcessEventReply) Digest

func (attrReply *AttrSProcessEventReply) Digest() (rplyDigest string)

Digest returns serialized version of alteredFields in AttrSProcessEventReply format fldName1:fldVal1,fldName2:fldVal2

func (*AttrSProcessEventReply) UniqueAlteredFields

func (flds *AttrSProcessEventReply) UniqueAlteredFields() (unFlds utils.StringSet)

UniqueAlteredFields will return all altered fields without duplicates

type AttributeS

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

AttributeS the service for the API

func NewAttributeService

func NewAttributeService(dm *engine.DataManager, filterS *engine.FilterS,
	cgrcfg *config.CGRConfig) *AttributeS

NewAttributeService returns a new AttributeService

func (*AttributeS) V1GetAttributeForEvent

func (alS *AttributeS) V1GetAttributeForEvent(ctx *context.Context, args *utils.CGREvent,
	attrPrfl *utils.APIAttributeProfile) (err error)

V1GetAttributeForEvent returns the AttributeProfile that matches the event

func (*AttributeS) V1ProcessEvent

func (alS *AttributeS) V1ProcessEvent(ctx *context.Context, args *utils.CGREvent,
	reply *AttrSProcessEventReply) (err error)

V1ProcessEvent proccess the event and returns the result

type FieldsAltered

type FieldsAltered struct {
	MatchedProfileID string
	Fields           []string
}

Jump to

Keyboard shortcuts

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