Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Checker ¶
type Checker struct {
// contains filtered or unexported fields
}
Checker aggregates risk rules and evaluates them sequentially. The first rule that returns an error causes the check to fail.
type CheckerBuilder ¶
type CheckerBuilder struct {
// contains filtered or unexported fields
}
CheckerBuilder constructs a Checker by accumulating rules.
func NewCheckerBuilder ¶
func NewCheckerBuilder() *CheckerBuilder
NewCheckerBuilder creates a new CheckerBuilder.
func (*CheckerBuilder) AddRule ¶
func (b *CheckerBuilder) AddRule(r rule.Rule) *CheckerBuilder
AddRule appends a rule to the builder.
func (*CheckerBuilder) Build ¶
func (b *CheckerBuilder) Build() *Checker
Build creates the Checker from the accumulated rules.
type CheckerEntry ¶
CheckerEntry describes a single rule to add to the Checker.
type Config ¶
type Config struct {
Actor []actor.Entry `yaml:"actor"`
Checker []CheckerEntry `yaml:"checker"`
}
Config contains risk engine configuration.
type Engine ¶
type Engine struct {
engine.EngineBase
// contains filtered or unexported fields
}
Engine manages risk calculations and limits. It constructs actors from config via the factory registry and builds a Checker from configured rules to gate order flow.
Click to show internal directories.
Click to hide internal directories.