Documentation
¶
Index ¶
- func FormatSize(size int64) string
- type AnalysisResult
- type Format
- type PropertyValidationResult
- type RelationPropertyValidationResult
- type SchemaEntityDef
- type SchemaMetamodel
- type SchemaRelationDef
- type Writer
- func (w *Writer) WriteAnalysisResult(result AnalysisResult) error
- func (w *Writer) WriteBar(value, maxValue int) string
- func (w *Writer) WriteEntities(entities []*entity.Entity) error
- func (w *Writer) WriteEntitiesWithSummary(entities []*entity.Entity) error
- func (w *Writer) WriteEntity(entity *entity.Entity, incoming, outgoing []*entity.Relation) error
- func (w *Writer) WriteError(format string, args ...interface{})
- func (w *Writer) WriteFooterSummary(text string)
- func (w *Writer) WriteInfo(format string, args ...interface{})
- func (w *Writer) WriteMessage(format string, args ...interface{})
- func (w *Writer) WritePath(path []tracer.PathStep) error
- func (w *Writer) WriteRelations(relations []*entity.Relation) error
- func (w *Writer) WriteSchemaEntities(m SchemaMetamodel) error
- func (w *Writer) WriteSchemaEntityDetail(name string, def SchemaEntityDef, _ SchemaMetamodel) error
- func (w *Writer) WriteSchemaOverview(m SchemaMetamodel) error
- func (w *Writer) WriteSchemaRelationDetail(name string, def SchemaRelationDef) error
- func (w *Writer) WriteSchemaRelations(m SchemaMetamodel) error
- func (w *Writer) WriteSchemaTypes(m SchemaMetamodel) error
- func (w *Writer) WriteSectionHeader(title string)
- func (w *Writer) WriteSeparator()
- func (w *Writer) WriteSuccess(format string, args ...interface{})
- func (w *Writer) WriteSummaryBox(items []string)
- func (w *Writer) WriteTrace(result *tracer.TraceResult) error
- func (w *Writer) WriteWarning(format string, args ...interface{})
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func FormatSize ¶
FormatSize formats a byte size as a human-readable string.
Types ¶
type AnalysisResult ¶
type AnalysisResult struct {
Status string `json:"status"` // "success", "warning", "error"
Message string `json:"message"`
Count int `json:"count,omitempty"`
Details interface{} `json:"details,omitempty"`
}
AnalysisResult represents the result of an analysis command for JSON output
type PropertyValidationResult ¶
type PropertyValidationResult struct {
EntityID string `json:"entity_id"`
EntityType string `json:"entity_type"`
Errors []string `json:"errors"`
}
PropertyValidationResult represents validation errors for JSON output
type RelationPropertyValidationResult ¶
type RelationPropertyValidationResult struct {
RelationKey string `json:"relation_key"` // from--type--to
RelationType string `json:"relation_type"`
Errors []string `json:"errors"`
}
RelationPropertyValidationResult represents validation errors for a relation
type SchemaEntityDef ¶
type SchemaEntityDef interface {
GetLabel() string
GetAliases() []string
GetIDPatterns() []string
GetProperties() interface{}
GetRDFType() string
GetColor() string
GetBorderColor() string
}
SchemaEntityDef interface for entity definition output
type SchemaMetamodel ¶
type SchemaMetamodel interface {
GetVersion() string
GetNamespace() string
GetEntities() interface{}
GetRelations() interface{}
GetTypes() interface{}
}
SchemaMetamodel interface for metamodel schema output
type SchemaRelationDef ¶
type SchemaRelationDef interface {
GetLabel() string
GetFrom() []string
GetTo() []string
GetDescription() string
GetInverse() interface{}
IsSymmetric() bool
GetMinOutgoing() *int
GetMaxOutgoing() *int
GetMinIncoming() *int
GetMaxIncoming() *int
}
SchemaRelationDef interface for relation definition output
type Writer ¶
Writer handles formatted output
func NewWithWriter ¶
NewWithWriter creates a new output writer with a custom writer
func (*Writer) WriteAnalysisResult ¶
func (w *Writer) WriteAnalysisResult(result AnalysisResult) error
WriteAnalysisResult outputs an analysis result in the appropriate format
func (*Writer) WriteEntities ¶
WriteEntities outputs a list of entities
func (*Writer) WriteEntitiesWithSummary ¶
WriteEntitiesWithSummary outputs a list of entities with a footer summary
func (*Writer) WriteEntity ¶
WriteEntity outputs a single entity with details
func (*Writer) WriteError ¶
WriteError outputs an error message
func (*Writer) WriteFooterSummary ¶
WriteFooterSummary writes a subtle footer summary line
func (*Writer) WriteMessage ¶
WriteMessage outputs a simple message
func (*Writer) WriteRelations ¶
WriteRelations outputs a list of relations
func (*Writer) WriteSchemaEntities ¶
func (w *Writer) WriteSchemaEntities(m SchemaMetamodel) error
WriteSchemaEntities outputs entity types as JSON
func (*Writer) WriteSchemaEntityDetail ¶
func (w *Writer) WriteSchemaEntityDetail(name string, def SchemaEntityDef, _ SchemaMetamodel) error
WriteSchemaEntityDetail outputs a single entity type as JSON
func (*Writer) WriteSchemaOverview ¶
func (w *Writer) WriteSchemaOverview(m SchemaMetamodel) error
WriteSchemaOverview outputs the metamodel overview as JSON
func (*Writer) WriteSchemaRelationDetail ¶
func (w *Writer) WriteSchemaRelationDetail(name string, def SchemaRelationDef) error
WriteSchemaRelationDetail outputs a single relation type as JSON
func (*Writer) WriteSchemaRelations ¶
func (w *Writer) WriteSchemaRelations(m SchemaMetamodel) error
WriteSchemaRelations outputs relation types as JSON
func (*Writer) WriteSchemaTypes ¶
func (w *Writer) WriteSchemaTypes(m SchemaMetamodel) error
WriteSchemaTypes outputs custom types as JSON
func (*Writer) WriteSectionHeader ¶
WriteSectionHeader writes a styled section header with box drawing
func (*Writer) WriteSeparator ¶
func (w *Writer) WriteSeparator()
WriteSeparator writes a subtle horizontal separator
func (*Writer) WriteSuccess ¶
WriteSuccess outputs a success message
func (*Writer) WriteSummaryBox ¶
WriteSummaryBox writes a boxed summary line
func (*Writer) WriteTrace ¶
func (w *Writer) WriteTrace(result *tracer.TraceResult) error
WriteTrace outputs a trace result as a tree
func (*Writer) WriteWarning ¶
WriteWarning outputs a warning message