Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ConfigFilePath ¶
Types ¶
type Generator ¶
type Generator struct {
// contains filtered or unexported fields
}
type SmartContract ¶
type TemplateContext ¶
type TemplateContext struct { // description: Ethereum smart contract addresses created by Vega. These can represent bridges or ERC20 tokens. Addresses map[string]SmartContract // description: Ethereum network ID. NetworkID string // description: Ethereum chain ID. ChainID string }
description: |
Template context also includes functions: - `.GetEthContractAddr "contract_name"` - returns contract address based on name. - `.GetVegaContractID "contract_name"` - returns contract vega ID based on name.
func NewTemplateContext ¶
func NewTemplateContext(chainID, networkID string, addressesJSON []byte) (*TemplateContext, error)
func (TemplateContext) GetEthContractAddr ¶
func (gc TemplateContext) GetEthContractAddr(contract string) string
func (TemplateContext) GetVegaContractID ¶
func (gc TemplateContext) GetVegaContractID(contract string) string
Click to show internal directories.
Click to hide internal directories.