Documentation ¶
Index ¶
- func NewHandler(origin string, wp query.WorkerPool, clients ethereum.ClientRegistry, ...) (origins.Handler, error)
- type AgentDependencies
- type AsyncDependencies
- type Config
- func (c *Config) AsyncPriceProvider(d AsyncDependencies) (provider.Provider, error)
- func (c *Config) PriceHook(d HookDependencies) (provider.PriceHook, error)
- func (c *Config) PriceProvider(d Dependencies, noRPC bool) (provider.Provider, error)
- func (c *Config) RPCAgent(d AgentDependencies) (*rpc.Agent, error)
- type Dependencies
- type HookDependencies
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewHandler ¶
func NewHandler( origin string, wp query.WorkerPool, clients ethereum.ClientRegistry, params map[string]any, ) (origins.Handler, error)
Types ¶
type AgentDependencies ¶
type AsyncDependencies ¶
type AsyncDependencies struct { Clients ethereumConfig.ClientRegistry Logger log.Logger }
type Config ¶
type Config struct { // RPCListenAddr is the address on which the RPC server will listen. RPCListenAddr string `hcl:"rpc_listen_addr,optional"` // RPCAgentAddr is the address of the RPC agent. RPCAgentAddr string `hcl:"rpc_agent_addr,optional"` // Origins is a configuration of price origins. Origins []configOrigin `hcl:"origin,block"` // PriceModels is a configuration of price models. PriceModels []configSource `hcl:"price_model,block"` // Hooks is a configuration of hooks. Hooks []configHook `hcl:"hook,block"` // HCL fields: Range hcl.Range `hcl:",range"` Content hcl.BodyContent `hcl:",content"` // contains filtered or unexported fields }
func (*Config) AsyncPriceProvider ¶
func (c *Config) AsyncPriceProvider(d AsyncDependencies) (provider.Provider, error)
AsyncPriceProvider returns a new async gofer instance.
func (*Config) PriceHook ¶
func (c *Config) PriceHook(d HookDependencies) (provider.PriceHook, error)
func (*Config) PriceProvider ¶
PriceProvider returns a new async gofer instance.
type Dependencies ¶
type Dependencies struct { Clients ethereumConfig.ClientRegistry Logger log.Logger }
type HookDependencies ¶
type HookDependencies struct { Context context.Context Clients ethereumConfig.ClientRegistry }
Click to show internal directories.
Click to hide internal directories.