Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnalysisResult ¶
type AnalysisResult struct {
FileName string `json:"fileName"`
Type string `json:"type"`
Parameters []Parameter `json:"parameters"`
ReturnType string `json:"returnType,omitempty"`
Imports []Import `json:"imports"`
Base64 string `json:"base64,omitempty"`
Tag string `json:"tag,omitempty"`
}
AnalysisResult represents the analysis result of a single Cadence file
type Analyzer ¶
type Analyzer struct {
Transactions map[string]AnalysisResult
Scripts map[string]AnalysisResult
Structs map[string]Struct
IncludeBase64 bool
}
Analyzer is responsible for analyzing Cadence files
func (*Analyzer) AnalyzeDirectory ¶
AnalyzeDirectory analyzes all Cadence files in a directory and its subdirectories
func (*Analyzer) AnalyzeFile ¶
func (a *Analyzer) AnalyzeFile(filePath string) (*AnalysisResult, error)
AnalyzeFile analyzes a single Cadence file and returns its analysis result
func (*Analyzer) SetIncludeBase64 ¶
SetIncludeBase64 sets whether to include base64-encoded content in the analysis results
type Field ¶
type Field struct {
Name string `json:"name"`
TypeStr string `json:"typeStr"`
Optional bool `json:"optional"`
Access string `json:"access"`
}
Field represents a field in a struct
type Parameter ¶
type Parameter struct {
Name string `json:"name"`
TypeStr string `json:"typeStr"`
Optional bool `json:"optional"`
}
Parameter represents a single parameter in a Cadence transaction or script
type Report ¶
type Report struct {
Transactions map[string]AnalysisResult `json:"transactions"`
Scripts map[string]AnalysisResult `json:"scripts"`
Structs map[string]Struct `json:"structs"`
IncludeBase64 bool `json:"-"`
}
Report represents the complete analysis report
type SimpleMemoryGauge ¶
type SimpleMemoryGauge struct{}
SimpleMemoryGauge implements common.MemoryGauge
func (*SimpleMemoryGauge) MeterMemory ¶
func (g *SimpleMemoryGauge) MeterMemory(size common.MemoryUsage) error
Click to show internal directories.
Click to hide internal directories.