Documentation ¶
Overview ¶
Package graph implements the GraphQL schema and resolvers.
Index ¶
- func GenerateAmountStatisticBridgeSQL(typeArg model.StatisticType, address *string, chainID *int, ...) (*string, error)
- func GenerateAmountStatisticMessageBusSQL(typeArg model.StatisticType, compositeFilters string) (*string, error)
- func GenerateAmountStatisticSwapSQL(typeArg model.StatisticType, compositeFilters string, tokenAddress *string) (*string, error)
- func GenerateDailyStatisticByChainAllSQL(typeArg *model.DailyStatisticType, compositeFilters string, firstFilter *bool) (*string, error)
- func GenerateDailyStatisticByChainAllSQLMv(typeArg *model.DailyStatisticType, compositeFilters string, ...) (*string, error)
- func GenerateDailyStatisticByChainBridgeSQL(typeArg *model.DailyStatisticType, compositeFilters string, firstFilter *bool) (*string, error)
- func GenerateDailyStatisticByChainBridgeSQLMv(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
- func GenerateDailyStatisticByChainMessageBusSQL(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
- func GenerateDailyStatisticByChainSwapSQL(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
- func GenerateRankedChainsByVolumeSQL(compositeFilters string, firstFilter *bool) string
- func GetDurationFilter(duration *model.Duration, firstFilter *bool, prefix string) string
- func GetPartialInfoFromBridgeEventHybrid(bridgeEvent sql.HybridBridgeEvent, includePending *bool) (*model.BridgeTransaction, error)
- func GetPartialInfoFromMessageBusEventHybrid(ctx context.Context, messageBusEvent sql.HybridMessageBusEvent, pending bool) (*model.MessageBusTransaction, error)
- func GetTargetTime(hours *int) uint64
- type Resolver
- type SortBridgeTxType
- type SortMessageBusTxType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateAmountStatisticBridgeSQL ¶ added in v0.0.81
func GenerateAmountStatisticBridgeSQL(typeArg model.StatisticType, address *string, chainID *int, tokenAddress *string) (*string, error)
GenerateAmountStatisticBridgeSQL generate sql for the bridge platform.
func GenerateAmountStatisticMessageBusSQL ¶ added in v0.0.81
func GenerateAmountStatisticMessageBusSQL(typeArg model.StatisticType, compositeFilters string) (*string, error)
GenerateAmountStatisticMessageBusSQL generates sql for getting stats on the message bus platform.
func GenerateAmountStatisticSwapSQL ¶ added in v0.0.81
func GenerateAmountStatisticSwapSQL(typeArg model.StatisticType, compositeFilters string, tokenAddress *string) (*string, error)
GenerateAmountStatisticSwapSQL generates sql to get statistics on the swap platform.
nolint:cyclop
func GenerateDailyStatisticByChainAllSQL ¶ added in v0.0.81
func GenerateDailyStatisticByChainAllSQL(typeArg *model.DailyStatisticType, compositeFilters string, firstFilter *bool) (*string, error)
GenerateDailyStatisticByChainAllSQL generates sql for getting daily stats across all chains.
func GenerateDailyStatisticByChainAllSQLMv ¶ added in v0.0.81
func GenerateDailyStatisticByChainAllSQLMv(typeArg *model.DailyStatisticType, compositeFilters string, compositeFiltersMv string) (*string, error)
GenerateDailyStatisticByChainAllSQLMv generates sql for getting daily stats across all chains.
func GenerateDailyStatisticByChainBridgeSQL ¶ added in v0.0.81
func GenerateDailyStatisticByChainBridgeSQL(typeArg *model.DailyStatisticType, compositeFilters string, firstFilter *bool) (*string, error)
GenerateDailyStatisticByChainBridgeSQL generates sql for getting data for daily stats across the bridge platform.
func GenerateDailyStatisticByChainBridgeSQLMv ¶ added in v0.0.81
func GenerateDailyStatisticByChainBridgeSQLMv(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
GenerateDailyStatisticByChainBridgeSQLMv generates sql for getting data for daily stats across the bridge platform.
func GenerateDailyStatisticByChainMessageBusSQL ¶ added in v0.0.81
func GenerateDailyStatisticByChainMessageBusSQL(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
GenerateDailyStatisticByChainMessageBusSQL generates sql for getting daily stats across the message bus platform.
func GenerateDailyStatisticByChainSwapSQL ¶ added in v0.0.81
func GenerateDailyStatisticByChainSwapSQL(typeArg *model.DailyStatisticType, compositeFilters string) (*string, error)
GenerateDailyStatisticByChainSwapSQL generates sql for getting daily stats across the swap platform.
func GenerateRankedChainsByVolumeSQL ¶ added in v0.0.81
GenerateRankedChainsByVolumeSQL generates sql for getting all chains ranked in order of volume.
func GetDurationFilter ¶ added in v0.0.81
GetDurationFilter creates a filter for the various time ranges for analysis.
func GetPartialInfoFromBridgeEventHybrid ¶ added in v0.0.43
func GetPartialInfoFromBridgeEventHybrid(bridgeEvent sql.HybridBridgeEvent, includePending *bool) (*model.BridgeTransaction, error)
GetPartialInfoFromBridgeEventHybrid returns the partial info from bridge event.
nolint:cyclop
func GetPartialInfoFromMessageBusEventHybrid ¶ added in v0.0.81
func GetPartialInfoFromMessageBusEventHybrid(ctx context.Context, messageBusEvent sql.HybridMessageBusEvent, pending bool) (*model.MessageBusTransaction, error)
GetPartialInfoFromMessageBusEventHybrid returns the partial info from message bus event.
nolint:cyclop
func GetTargetTime ¶ added in v0.0.81
GetTargetTime converts the number of hours into a timestamp.
Types ¶
type Resolver ¶
type Resolver struct { DB db.ConsumerDB Fetcher fetcher.ScribeFetcher Cache cache.Service Clients map[uint32]etherClient.EVM Parsers *types.ServerParsers Refs *types.ServerRefs SwapFilters map[string]*swap.SwapFlashLoanFilterer Config serverConfig.Config }
Resolver is the root resolver.
func (*Resolver) Query ¶
func (r *Resolver) Query() resolvers.QueryResolver
Query returns resolvers.QueryResolver implementation.
type SortBridgeTxType ¶ added in v0.0.81
type SortBridgeTxType []*model.BridgeTransaction
SortBridgeTxType sorts bridge transactions by time.
func (SortBridgeTxType) Len ¶ added in v0.0.81
func (s SortBridgeTxType) Len() int
func (SortBridgeTxType) Less ¶ added in v0.0.81
func (s SortBridgeTxType) Less(i, j int) bool
func (SortBridgeTxType) Swap ¶ added in v0.0.81
func (s SortBridgeTxType) Swap(i, j int)
type SortMessageBusTxType ¶ added in v0.0.81
type SortMessageBusTxType []*model.MessageBusTransaction
SortMessageBusTxType sorts message bus transactions by time.
func (SortMessageBusTxType) Len ¶ added in v0.0.81
func (s SortMessageBusTxType) Len() int
func (SortMessageBusTxType) Less ¶ added in v0.0.81
func (s SortMessageBusTxType) Less(i, j int) bool
func (SortMessageBusTxType) Swap ¶ added in v0.0.81
func (s SortMessageBusTxType) Swap(i, j int)
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Package model provides the GraphQL model for the explorer service.
|
Package model provides the GraphQL model for the explorer service. |
Package resolvers provides the GraphQL resolver for the explorer service.
|
Package resolvers provides the GraphQL resolver for the explorer service. |