Documentation
¶
Index ¶
- func CheckIfTruffleStructure(directory string) bool
- func FindTruffleDirectories() []string
- func NewContract(truffleContract Contract) (*stacktrace.Contract, error)
- func NewContractSource(path string, networkId string, client client.Client) (stacktrace.ContractSource, error)
- func Parse(contracts map[string]*Contract) (map[string]stacktrace.SourceMap, map[string][]byte, error)
- func ParseContract(contract *Contract) (stacktrace.SourceMap, error)
- type ApiContract
- type ApiDeploymentInformation
- type Config
- type Contract
- type ContractAst
- type ContractCompiler
- type ContractNetwork
- type ContractSource
- type NetworkConfig
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckIfTruffleStructure ¶ added in v0.1.6
func FindTruffleDirectories ¶ added in v0.1.6
func FindTruffleDirectories() []string
func NewContract ¶
func NewContract(truffleContract Contract) (*stacktrace.Contract, error)
func NewContractSource ¶
func NewContractSource(path string, networkId string, client client.Client) (stacktrace.ContractSource, error)
NewContractSource builds the Contract Source from the provided config, and scoped to the provided network.
func ParseContract ¶
func ParseContract(contract *Contract) (stacktrace.SourceMap, error)
Types ¶
type ApiContract ¶ added in v0.2.5
type ApiContract struct { ID string `json:"id"` AccountID string `json:"account_id"` ProjectID string `json:"project_id"` NetworkID string `json:"network_id"` Public bool `json:"public"` Address string `json:"address"` Name string `json:"contract_name"` Abi string `json:"abi"` Bytecode string `json:"bytecode"` Source string `json:"source"` SourceMap string `json:"source_map"` DeploymentInformation *ApiDeploymentInformation `json:"deployment_information"` CreatedAt time.Time `json:"created_at"` }
type ApiDeploymentInformation ¶ added in v0.2.5
type Config ¶
type Config struct { ProjectDirectory string `json:"project_directory"` BuildDirectory string `json:"contracts_build_directory"` Networks map[string]NetworkConfig `json:"networks"` }
func (*Config) AbsoluteBuildDirectoryPath ¶
type Contract ¶
type Contract struct { Name string `json:"contractName"` Abi interface{} `json:"abi"` Bytecode string `json:"bytecode"` DeployedBytecode string `json:"deployedBytecode"` SourceMap string `json:"sourceMap"` DeployedSourceMap string `json:"deployedSourceMap"` Source string `json:"source"` SourcePath string `json:"sourcePath"` Ast ContractAst `json:"legacyAST"` Compiler ContractCompiler `json:"compiler"` Networks map[string]ContractNetwork `json:"networks"` SchemaVersion string `json:"schemaVersion"` UpdatedAt time.Time `json:"updatedAt"` }
type ContractAst ¶
type ContractCompiler ¶
type ContractNetwork ¶
type ContractSource ¶
type ContractSource struct {
// contains filtered or unexported fields
}
func (*ContractSource) Get ¶
func (cs *ContractSource) Get(id string) (*stacktrace.ContractDetails, error)
type NetworkConfig ¶
Click to show internal directories.
Click to hide internal directories.