Documentation
¶
Overview ¶
Default generated models package docs (at least one file is necessary in a models package)
generated boilerplate code edit the file for adding other stages
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
generated code - do not edit
Index ¶
- Constants
- func AfterCreateFromFront[Type Gongstruct](stage *Stage, instance *Type)
- func AfterDeleteFromFront[Type Gongstruct](stage *Stage, staged, front *Type)
- func AfterReadFromFront[Type Gongstruct](stage *Stage, instance *Type)
- func AfterUpdateFromFront[Type Gongstruct](stage *Stage, old, new *Type)
- func CompareGongstructByName[T PointerToGongstruct](a, b T) int
- func CopyBranch[Type Gongstruct](from *Type) (to *Type)
- func GetAssociationName[Type Gongstruct]() *Type
- func GetFields[Type Gongstruct]() (res []string)
- func GetFieldsFromPointer[Type PointerToGongstruct]() (res []string)
- func GetGongstrucsSorted[T PointerToGongstruct](stage *Stage) (sortedSlice []T)
- func GetGongstructInstancesMap[Type Gongstruct](stage *Stage) *map[string]*Type
- func GetGongstructInstancesSet[Type Gongstruct](stage *Stage) *map[*Type]any
- func GetGongstructInstancesSetFromPointerType[Type PointerToGongstruct](stage *Stage) *map[Type]any
- func GetGongstructName[Type Gongstruct]() (res string)
- func GetNamedStructInstances[T PointerToGongstruct](set map[T]any, order map[T]uint) (res []string)
- func GetOrder[Type Gongstruct](stage *Stage, instance *Type) uint
- func GetPointerReverseMap[Start, End Gongstruct](fieldname string, stage *Stage) map[*End][]*Start
- func GetPointerToGongstructName[Type PointerToGongstruct]() (res string)
- func GetReverseFieldOwner[T Gongstruct](stage *Stage, instance *T, reverseField *ReverseField) (res any)
- func GetReverseFieldOwnerName(stage *Stage, instance any, reverseField *ReverseField) (res string)
- func GetSliceOfPointersReverseMap[Start, End Gongstruct](fieldname string, stage *Stage) map[*End]*Start
- func GongGetMap[Type GongstructMapString](stage *Stage) *Type
- func GongGetSet[Type GongstructSet](stage *Stage) *Type
- func GongNoteNameToIdentifier(gongNoteName string) (identifier string)
- func GongStructNameToIdentifier(structName string) (identifier string)
- func GongstructAndFieldnameToFieldIdentifier(structName string, fieldName string) (fieldIdentifier string)
- func IdentifierToFieldName(fieldIdentifier string) (fieldName string)
- func IdentifierToGongObjectName(structIdentifier string) (structName string)
- func IdentifierToReceiverAndFieldName(fieldIdentifier string) (receiver, fieldName string)
- func IntToLetters(number int32) (letters string)
- func IsNodeExpanded(binaryEncoding, nodeRank int) bool
- func IsStaged[Type Gongstruct](stage *Stage, instance *Type) (ok bool)
- func ParseAstEmbeddedFile(stage *Stage, directory embed.FS, pathToFile string) error
- func ParseAstFile(stage *Stage, pathToFile string) error
- func ParseAstFileFromAst(stage *Stage, inFile *ast.File, fset *token.FileSet) error
- func ReplaceOldDeclarationsInFile(pathToFile string) error
- func Serialize[Type Gongstruct](stage *Stage, tab Tabulator)
- func SerializeExcelize[Type Gongstruct](stage *Stage, f *excelize.File)
- func SerializeExcelizePointerToGongstruct[Type PointerToGongstruct](stage *Stage, f *excelize.File)
- func SerializeStage(stage *Stage, filename string)
- func SetCallbackAfterCreateFromFront[Type Gongstruct](stage *Stage, callback OnAfterCreateInterface[Type])
- func SetCallbackAfterDeleteFromFront[Type Gongstruct](stage *Stage, callback OnAfterDeleteInterface[Type])
- func SetCallbackAfterReadFromFront[Type Gongstruct](stage *Stage, callback OnAfterReadInterface[Type])
- func SetCallbackAfterUpdateFromFront[Type Gongstruct](stage *Stage, callback OnAfterUpdateInterface[Type])
- func SetOrchestratorOnAfterUpdate[Type Gongstruct](stage *Stage)
- func SetupMapDocLinkRenaming(gongStage *gong_models.Stage, gongdocStage *Stage)
- func SortGongstructSetByName[T PointerToGongstruct](set map[T]any) (sortedSlice []T)
- func StageBranch[Type Gongstruct](stage *Stage, instance *Type)
- func ToggleNodeExpanded(binaryEncoding *int, nodeRank int)
- func UnmarshallGongstructStaging(stage *Stage, cmap *ast.CommentMap, assignStmt *ast.AssignStmt, ...) (instance any, identifier string, gongstructName string, fieldName string)
- func UnstageBranch[Type Gongstruct](stage *Stage, instance *Type)
- type AllModelsStructCreateInterface
- type AllModelsStructDeleteInterface
- type AnchoredTextImplLinkFieldName
- type AnchoredTextImplLinkSourceMultiplicity
- type AnchoredTextImplLinkTargetMultiplicity
- type AttributeFieldNodeProxy
- type AttributeShape
- func (attributeshape *AttributeShape) Checkout(stage *Stage) *AttributeShape
- func (attributeshape *AttributeShape) Commit(stage *Stage) *AttributeShape
- func (attributeshape *AttributeShape) CommitVoid(stage *Stage)
- func (from *AttributeShape) CopyBasicFields(to *AttributeShape)
- func (attributeshape *AttributeShape) GetName() (res string)
- func (attributeshape *AttributeShape) Stage(stage *Stage) *AttributeShape
- func (attributeshape *AttributeShape) Unstage(stage *Stage) *AttributeShape
- func (attributeshape *AttributeShape) UnstageVoid(stage *Stage)
- type AttributeShape_WOP
- type BackRepoInterface
- type ButtonNewClassdiagramProxy
- type ButtonType
- func (buttontype ButtonType) CodeValues() (res []int)
- func (buttontype ButtonType) Codes() (res []string)
- func (buttontype *ButtonType) FromCodeString(input string) (err error)
- func (buttontype *ButtonType) FromInt(input int) (err error)
- func (buttontype *ButtonType) ToCodeString() (res string)
- func (buttontype ButtonType) ToInt() (res int)
- type ClassDiagramButtonProxy
- type ClassDiagramGongEnumsNodeProxy
- type ClassDiagramGongNotesNodeProxy
- type ClassDiagramGongStructsNodeProxy
- type ClassDiagramNodeProxy
- type Classdiagram
- func (classdiagram *Classdiagram) AddAttributeFieldShape(stage *Stage, gongStage *gong.Stage, gongStruct *gong.GongStruct, ...)
- func (classdiagram *Classdiagram) AddGongEnumShape(stage *Stage, diagramPackage *DiagramPackage, enumshapeName string)
- func (classdiagram *Classdiagram) AddGongEnumValueShapeToDiagram(stage *Stage, gongEnumShape *GongEnumShape, gongEnum *gong.GongEnum, ...)
- func (classdiagram *Classdiagram) AddGongNoteShape(stage *Stage, gongNote *gong.GongNote, diagramPackage *DiagramPackage, ...)
- func (classdiagram *Classdiagram) AddGongStructShape(stage *Stage, diagramPackage *DiagramPackage, gongstructshapeName string)
- func (classdiagram *Classdiagram) AddLinkFieldShape(stage *Stage, gongStage *gong.Stage, gongStruct *gong.GongStruct, ...)
- func (classdiagram *Classdiagram) Checkout(stage *Stage) *Classdiagram
- func (classdiagram *Classdiagram) Commit(stage *Stage) *Classdiagram
- func (classdiagram *Classdiagram) CommitVoid(stage *Stage)
- func (from *Classdiagram) CopyBasicFields(to *Classdiagram)
- func (classdiagram *Classdiagram) DuplicateDiagram() (newClassdiagram *Classdiagram)
- func (classdiagram *Classdiagram) GetName() (res string)
- func (classdiagram *Classdiagram) HasGongNoteShape(gongstructName string) (foundGongNoteShape bool, gongNoteShape *GongNoteShape)
- func (classdiagram *Classdiagram) HasGongStructShape(gongstructName string) (foundGongStructShape bool, gongstructshape *GongStructShape)
- func (classdiagram *Classdiagram) RemoveAttributeFieldShape(stage *Stage, attributeShape *AttributeShape, gongStructShape *GongStructShape)
- func (classdiagram *Classdiagram) RemoveGongEnumShape(stage *Stage, gongenumshapeName string)
- func (classdiagram *Classdiagram) RemoveGongEnumValueShapeFromDiagram(stage *Stage, gongEnumShape *GongEnumShape, gongEnumValue *gong.GongEnumValue)
- func (classdiagram *Classdiagram) RemoveGongNoteShape(stage *Stage, gongNoteName string)
- func (classdiagram *Classdiagram) RemoveGongStructShape(stage *Stage, gongstructName string)
- func (classdiagram *Classdiagram) RemoveLinkFieldShape(stage *Stage, linkShape *LinkShape, gongStructShape *GongStructShape)
- func (classdiagram *Classdiagram) Stage(stage *Stage) *Classdiagram
- func (classdiagram *Classdiagram) Unstage(stage *Stage) *Classdiagram
- func (classdiagram *Classdiagram) UnstageVoid(stage *Stage)
- type Classdiagram_WOP
- type DiagramPackage
- func (diagrampackage *DiagramPackage) Checkout(stage *Stage) *DiagramPackage
- func (diagrampackage *DiagramPackage) Commit(stage *Stage) *DiagramPackage
- func (diagrampackage *DiagramPackage) CommitVoid(stage *Stage)
- func (from *DiagramPackage) CopyBasicFields(to *DiagramPackage)
- func (diagrampackage *DiagramPackage) GetName() (res string)
- func (diagrampackage *DiagramPackage) Stage(stage *Stage) *DiagramPackage
- func (diagrampackage *DiagramPackage) Unstage(stage *Stage) *DiagramPackage
- func (diagrampackage *DiagramPackage) UnstageVoid(stage *Stage)
- type DiagramPackage_WOP
- type DocSVGMapper
- type ExcelizeTabulator
- type GONG__ExpressionType
- type GONG__Identifier
- type GongEnumNodeProxy
- type GongEnumNodeValueProxy
- type GongEnumShape
- func (gongenumshape *GongEnumShape) Checkout(stage *Stage) *GongEnumShape
- func (gongenumshape *GongEnumShape) Commit(stage *Stage) *GongEnumShape
- func (gongenumshape *GongEnumShape) CommitVoid(stage *Stage)
- func (from *GongEnumShape) CopyBasicFields(to *GongEnumShape)
- func (gongenumshape *GongEnumShape) GetName() (res string)
- func (gongenumshape *GongEnumShape) Stage(stage *Stage) *GongEnumShape
- func (gongenumshape *GongEnumShape) Unstage(stage *Stage) *GongEnumShape
- func (gongenumshape *GongEnumShape) UnstageVoid(stage *Stage)
- type GongEnumShapeType
- func (gongenumshapetype GongEnumShapeType) CodeValues() (res []int)
- func (gongenumshapetype GongEnumShapeType) Codes() (res []string)
- func (gongenumshapetype *GongEnumShapeType) FromCodeString(input string) (err error)
- func (gongenumshapetype *GongEnumShapeType) FromInt(input int) (err error)
- func (gongenumshapetype *GongEnumShapeType) ToCodeString() (res string)
- func (gongenumshapetype GongEnumShapeType) ToInt() (res int)
- type GongEnumShape_WOP
- type GongEnumValueShape
- func (gongenumvalueshape *GongEnumValueShape) Checkout(stage *Stage) *GongEnumValueShape
- func (gongenumvalueshape *GongEnumValueShape) Commit(stage *Stage) *GongEnumValueShape
- func (gongenumvalueshape *GongEnumValueShape) CommitVoid(stage *Stage)
- func (from *GongEnumValueShape) CopyBasicFields(to *GongEnumValueShape)
- func (gongenumvalueshape *GongEnumValueShape) GetName() (res string)
- func (gongenumvalueshape *GongEnumValueShape) Stage(stage *Stage) *GongEnumValueShape
- func (gongenumvalueshape *GongEnumValueShape) Unstage(stage *Stage) *GongEnumValueShape
- func (gongenumvalueshape *GongEnumValueShape) UnstageVoid(stage *Stage)
- type GongEnumValueShape_WOP
- type GongFieldValue
- type GongFieldValueType
- type GongNoteLinkShape
- func (gongnotelinkshape *GongNoteLinkShape) Checkout(stage *Stage) *GongNoteLinkShape
- func (gongnotelinkshape *GongNoteLinkShape) Commit(stage *Stage) *GongNoteLinkShape
- func (gongnotelinkshape *GongNoteLinkShape) CommitVoid(stage *Stage)
- func (from *GongNoteLinkShape) CopyBasicFields(to *GongNoteLinkShape)
- func (gongnotelinkshape *GongNoteLinkShape) GetName() (res string)
- func (gongnotelinkshape *GongNoteLinkShape) Stage(stage *Stage) *GongNoteLinkShape
- func (gongnotelinkshape *GongNoteLinkShape) Unstage(stage *Stage) *GongNoteLinkShape
- func (gongnotelinkshape *GongNoteLinkShape) UnstageVoid(stage *Stage)
- type GongNoteLinkShape_WOP
- type GongNoteNodeProxy
- type GongNoteShape
- func (gongnoteshape *GongNoteShape) Checkout(stage *Stage) *GongNoteShape
- func (gongnoteshape *GongNoteShape) Commit(stage *Stage) *GongNoteShape
- func (gongnoteshape *GongNoteShape) CommitVoid(stage *Stage)
- func (from *GongNoteShape) CopyBasicFields(to *GongNoteShape)
- func (gongnoteshape *GongNoteShape) GetName() (res string)
- func (gongnoteshape *GongNoteShape) Stage(stage *Stage) *GongNoteShape
- func (gongnoteshape *GongNoteShape) Unstage(stage *Stage) *GongNoteShape
- func (gongnoteshape *GongNoteShape) UnstageVoid(stage *Stage)
- type GongNoteShape_WOP
- type GongStructInterface
- type GongStructNodeProxy
- type GongStructShape
- func (gongstructshape *GongStructShape) Checkout(stage *Stage) *GongStructShape
- func (gongstructshape *GongStructShape) Commit(stage *Stage) *GongStructShape
- func (gongstructshape *GongStructShape) CommitVoid(stage *Stage)
- func (from *GongStructShape) CopyBasicFields(to *GongStructShape)
- func (gongstructshape *GongStructShape) GetName() (res string)
- func (gongstructshape *GongStructShape) Stage(stage *Stage) *GongStructShape
- func (gongstructshape *GongStructShape) Unstage(stage *Stage) *GongStructShape
- func (gongstructshape *GongStructShape) UnstageVoid(stage *Stage)
- type GongStructShape_WOP
- type Gongstruct
- type GongstructEnumIntField
- type GongstructEnumStringField
- type GongstructMapString
- type GongstructSet
- type GongtructBasicField
- type LinkFieldNodeProxy
- type LinkImplLink
- type LinkShape
- func (linkshape *LinkShape) Checkout(stage *Stage) *LinkShape
- func (linkshape *LinkShape) Commit(stage *Stage) *LinkShape
- func (linkshape *LinkShape) CommitVoid(stage *Stage)
- func (from *LinkShape) CopyBasicFields(to *LinkShape)
- func (linkshape *LinkShape) GetName() (res string)
- func (linkshape *LinkShape) Stage(stage *Stage) *LinkShape
- func (linkshape *LinkShape) Unstage(stage *Stage) *LinkShape
- func (linkshape *LinkShape) UnstageVoid(stage *Stage)
- type LinkShape_WOP
- type ModelElement
- type MultiplicityType
- func (multiplicitytype MultiplicityType) CodeValues() (res []string)
- func (multiplicitytype MultiplicityType) Codes() (res []string)
- func (multiplicitytype *MultiplicityType) FromCodeString(input string) (err error)
- func (multiplicitytype *MultiplicityType) FromString(input string) (err error)
- func (multiplicitytype *MultiplicityType) ToCodeString() (res string)
- func (multiplicitytype MultiplicityType) ToString() (res string)
- type NamedStruct
- type NoteShapeLinkType
- func (noteshapelinktype NoteShapeLinkType) CodeValues() (res []string)
- func (noteshapelinktype NoteShapeLinkType) Codes() (res []string)
- func (noteshapelinktype *NoteShapeLinkType) FromCodeString(input string) (err error)
- func (noteshapelinktype *NoteShapeLinkType) FromString(input string) (err error)
- func (noteshapelinktype *NoteShapeLinkType) ToCodeString() (res string)
- func (noteshapelinktype NoteShapeLinkType) ToString() (res string)
- type OnAfterCreateInterface
- type OnAfterDeleteInterface
- type OnAfterReadInterface
- type OnAfterUpdateInterface
- type OnInitCommitInterface
- type OrientationType
- func (orientationtype OrientationType) CodeValues() (res []string)
- func (orientationtype OrientationType) Codes() (res []string)
- func (orientationtype *OrientationType) FromCodeString(input string) (err error)
- func (orientationtype *OrientationType) FromString(input string) (err error)
- func (orientationtype *OrientationType) ToCodeString() (res string)
- func (orientationtype OrientationType) ToString() (res string)
- type PointerToGongstruct
- type PointerToGongstructEnumIntField
- type PointerToGongstructEnumStringField
- type RectImplGongenumShape
- type RectImplGongstructShape
- type RectImplNoteShape
- type ReverseField
- type Shape
- type Stage
- func (stage *Stage) Backup(dirPath string)
- func (stage *Stage) BackupXL(dirPath string)
- func (stage *Stage) Checkout()
- func (stage *Stage) Commit()
- func (stage *Stage) CommitWithSuspendedCallbacks()
- func (stage *Stage) ComputeReverseMaps()
- func (stage *Stage) GetDigramsEmbededDir() embed.FS
- func (stage *Stage) GetMap_GongStructName_InstancesNb() map[string]int
- func (stage *Stage) GetModelsEmbededDir() embed.FS
- func (stage *Stage) GetName() string
- func (stage *Stage) GetNamedStructNamesByOrder(namedStructName string) (res []string)
- func (stage *Stage) GetNamedStructsNames() (res []string)
- func (stage *Stage) GetProbeFormStageName() string
- func (stage *Stage) GetProbeSplitStageName() string
- func (stage *Stage) GetProbeTableStageName() string
- func (stage *Stage) GetProbeTreeSidebarStageName() string
- func (stage *Stage) GetType() string
- func (stage *Stage) IsStagedAttributeShape(attributeshape *AttributeShape) (ok bool)
- func (stage *Stage) IsStagedClassdiagram(classdiagram *Classdiagram) (ok bool)
- func (stage *Stage) IsStagedDiagramPackage(diagrampackage *DiagramPackage) (ok bool)
- func (stage *Stage) IsStagedGongEnumShape(gongenumshape *GongEnumShape) (ok bool)
- func (stage *Stage) IsStagedGongEnumValueShape(gongenumvalueshape *GongEnumValueShape) (ok bool)
- func (stage *Stage) IsStagedGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape) (ok bool)
- func (stage *Stage) IsStagedGongNoteShape(gongnoteshape *GongNoteShape) (ok bool)
- func (stage *Stage) IsStagedGongStructShape(gongstructshape *GongStructShape) (ok bool)
- func (stage *Stage) IsStagedLinkShape(linkshape *LinkShape) (ok bool)
- func (stage *Stage) Marshall(file *os.File, modelsPackageName, packageName string)
- func (stage *Stage) Nil()
- func (stage *Stage) Reset()
- func (stage *Stage) Restore(dirPath string)
- func (stage *Stage) RestoreXL(dirPath string)
- func (stage *Stage) StageBranchAttributeShape(attributeshape *AttributeShape)
- func (stage *Stage) StageBranchClassdiagram(classdiagram *Classdiagram)
- func (stage *Stage) StageBranchDiagramPackage(diagrampackage *DiagramPackage)
- func (stage *Stage) StageBranchGongEnumShape(gongenumshape *GongEnumShape)
- func (stage *Stage) StageBranchGongEnumValueShape(gongenumvalueshape *GongEnumValueShape)
- func (stage *Stage) StageBranchGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape)
- func (stage *Stage) StageBranchGongNoteShape(gongnoteshape *GongNoteShape)
- func (stage *Stage) StageBranchGongStructShape(gongstructshape *GongStructShape)
- func (stage *Stage) StageBranchLinkShape(linkshape *LinkShape)
- func (stage *Stage) Unstage()
- func (stage *Stage) UnstageBranchAttributeShape(attributeshape *AttributeShape)
- func (stage *Stage) UnstageBranchClassdiagram(classdiagram *Classdiagram)
- func (stage *Stage) UnstageBranchDiagramPackage(diagrampackage *DiagramPackage)
- func (stage *Stage) UnstageBranchGongEnumShape(gongenumshape *GongEnumShape)
- func (stage *Stage) UnstageBranchGongEnumValueShape(gongenumvalueshape *GongEnumValueShape)
- func (stage *Stage) UnstageBranchGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape)
- func (stage *Stage) UnstageBranchGongNoteShape(gongnoteshape *GongNoteShape)
- func (stage *Stage) UnstageBranchGongStructShape(gongstructshape *GongStructShape)
- func (stage *Stage) UnstageBranchLinkShape(linkshape *LinkShape)
- type Stager
- type Tabulator
- type TreeNames
- func (treenames TreeNames) CodeValues() (res []string)
- func (treenames TreeNames) Codes() (res []string)
- func (treenames *TreeNames) FromCodeString(input string) (err error)
- func (treenames *TreeNames) FromString(input string) (err error)
- func (treenames *TreeNames) ToCodeString() (res string)
- func (treenames TreeNames) ToString() (res string)
Constants ¶
const ClassBoxStrokeWidth = 3
const GongEnumShapeDefaultHeight = 48.0
const GongEnumShapeDefaultWidth = 240.0
const GongStructShapeDefaultHeight = 48.0
const GongStructShapeDefaultWidth = 240.0
const HeightBetween2AttributeShapes = 20
const IdentifiersDecls = `
{{Identifier}} := (&models.{{GeneratedStructName}}{}).Stage(stage)`
const LegacyDiagramUmarshalling = false
const NoteOnGongdoc = ""
GONGNOTE(NoteOnGongdoc): Note Example
This note can refers to models.GongNoteShape or to models.Classdiagram.GongNoteShapes or to models.OrientationType
const NumberInitStatement = `
{{Identifier}}.{{GeneratedFieldName}} = {{GeneratedFieldNameValue}}`
const PointerFieldInitStatement = `
{{Identifier}}.{{GeneratedFieldName}} = {{GeneratedFieldNameValue}}`
const ProbeFormSuffix = "-form"
const ProbeSplitSuffix = "-probe"
const ProbeTableSuffix = "-table"
const ProbeTreeSidebarSuffix = "-sidebar"
const RefPackagePlusPeriod = "models."
const RefPrefixReferencedPackage = "ref_"
const SVGName string = `SVG`
const SliceOfPointersFieldInitStatement = `
{{Identifier}}.{{GeneratedFieldName}} = append({{Identifier}}.{{GeneratedFieldName}}, {{GeneratedFieldNameValue}})`
const StringEnumInitStatement = `
{{Identifier}}.{{GeneratedFieldName}} = {{GeneratedFieldNameValue}}`
const StringInitStatement = `
{{Identifier}}.{{GeneratedFieldName}} = ` + "`" + `{{GeneratedFieldNameValue}}` + "`"
const TimeInitStatement = `` /* 129-byte string literal not displayed */
Variables ¶
This section is empty.
Functions ¶
func AfterCreateFromFront ¶
func AfterCreateFromFront[Type Gongstruct](stage *Stage, instance *Type)
AfterCreateFromFront is called after a create from front
func AfterDeleteFromFront ¶
func AfterDeleteFromFront[Type Gongstruct](stage *Stage, staged, front *Type)
AfterDeleteFromFront is called after a delete from front
func AfterReadFromFront ¶
func AfterReadFromFront[Type Gongstruct](stage *Stage, instance *Type)
AfterReadFromFront is called after a Read from front
func AfterUpdateFromFront ¶
func AfterUpdateFromFront[Type Gongstruct](stage *Stage, old, new *Type)
AfterUpdateFromFront is called after a update from front
func CompareGongstructByName ¶
func CompareGongstructByName[T PointerToGongstruct](a, b T) int
func CopyBranch ¶
func CopyBranch[Type Gongstruct](from *Type) (to *Type)
CopyBranch stages instance and apply CopyBranch on all gongstruct instances that are referenced by pointers or slices of pointers of the instance
the algorithm stops along the course of graph if a vertex is already staged
func GetAssociationName ¶
func GetAssociationName[Type Gongstruct]() *Type
GetAssociationName is a generic function that returns an instance of Type where each association is filled with an instance whose name is the name of the association
This function can be handy for generating navigation function that are refactorable
func GetFields ¶
func GetFields[Type Gongstruct]() (res []string)
GetFields return the array of the fields
func GetFieldsFromPointer ¶
func GetFieldsFromPointer[Type PointerToGongstruct]() (res []string)
GetFieldsFromPointer return the array of the fields
func GetGongstrucsSorted ¶
func GetGongstrucsSorted[T PointerToGongstruct](stage *Stage) (sortedSlice []T)
func GetGongstructInstancesMap ¶
func GetGongstructInstancesMap[Type Gongstruct](stage *Stage) *map[string]*Type
GetGongstructInstancesMap returns the map of staged GongstructType instances it is usefull because it allows refactoring of gong struct identifier
func GetGongstructInstancesSet ¶
func GetGongstructInstancesSet[Type Gongstruct](stage *Stage) *map[*Type]any
GetGongstructInstancesSet returns the set staged GongstructType instances it is usefull because it allows refactoring of gongstruct identifier
func GetGongstructInstancesSetFromPointerType ¶
func GetGongstructInstancesSetFromPointerType[Type PointerToGongstruct](stage *Stage) *map[Type]any
GetGongstructInstancesSetFromPointerType returns the set staged GongstructType instances it is usefull because it allows refactoring of gongstruct identifier
func GetGongstructName ¶
func GetGongstructName[Type Gongstruct]() (res string)
GetGongstructName returns the name of the Gongstruct this can be usefull if one want program robust to refactoring
func GetNamedStructInstances ¶
func GetNamedStructInstances[T PointerToGongstruct](set map[T]any, order map[T]uint) (res []string)
func GetOrder ¶
func GetOrder[Type Gongstruct](stage *Stage, instance *Type) uint
func GetPointerReverseMap ¶
func GetPointerReverseMap[Start, End Gongstruct](fieldname string, stage *Stage) map[*End][]*Start
GetPointerReverseMap allows backtrack navigation of any Start.Fieldname associations (0..1) that is a pointer from one staged Gongstruct (type Start) instances to another (type End)
The function provides a map with keys as instances of End and values to arrays of *Start the map is construed by iterating over all Start instances and populationg keys with End instances and values with slice of Start instances
func GetPointerToGongstructName ¶
func GetPointerToGongstructName[Type PointerToGongstruct]() (res string)
GetPointerToGongstructName returns the name of the Gongstruct this can be usefull if one want program robust to refactoring
func GetReverseFieldOwner ¶
func GetReverseFieldOwner[T Gongstruct]( stage *Stage, instance *T, reverseField *ReverseField) (res any)
func GetReverseFieldOwnerName ¶
func GetReverseFieldOwnerName( stage *Stage, instance any, reverseField *ReverseField) (res string)
func GetSliceOfPointersReverseMap ¶
func GetSliceOfPointersReverseMap[Start, End Gongstruct](fieldname string, stage *Stage) map[*End]*Start
GetSliceOfPointersReverseMap allows backtrack navigation of any Start.Fieldname associations (0..N) between one staged Gongstruct instances and many others
The function provides a map with keys as instances of End and values to *Start instances the map is construed by iterating over all Start instances and populating keys with End instances and values with the Start instances
func GongGetMap ¶
func GongGetMap[Type GongstructMapString](stage *Stage) *Type
GongGetMap returns the map of staged GongstructType instances it is usefull because it allows refactoring of gong struct identifier
func GongGetSet ¶
func GongGetSet[Type GongstructSet](stage *Stage) *Type
GongGetSet returns the set staged GongstructType instances it is usefull because it allows refactoring of gong struct identifier
func GongstructAndFieldnameToFieldIdentifier ¶
func GongstructAndFieldnameToFieldIdentifier(structName string, fieldName string) (fieldIdentifier string)
GongstructAndFieldnameToFieldIdentifier takes "Foo" "Name" and returns "ref_models.Foo.Name"
func IdentifierToFieldName ¶
IdentifierToFieldName take an ident in the forms "ref_models.Foo.Name" and returns "Name"
func IdentifierToGongObjectName ¶
IdentifierToGongObjectName take an ident in the forms "ref_models.Foo" and returns "Foo"
func IntToLetters ¶
func IsNodeExpanded ¶
func IsStaged ¶
func IsStaged[Type Gongstruct](stage *Stage, instance *Type) (ok bool)
func ParseAstEmbeddedFile ¶
ParseAstEmbeddedFile parses the Go source code from an embedded file specified by pathToFile within the provided embed.FS directory and stages instances declared in the file using the provided Stage.
Parameters:
stage: The staging area to populate. directory: The embedded filesystem containing the file. pathToFile: The path to the Go source file within the embedded filesystem.
Returns:
An error if reading or parsing the file fails, or if ParseAstFileFromAst fails.
func ParseAstFile ¶
ParseAstFile Parse pathToFile and stages all instances declared in the file
func ParseAstFileFromAst ¶
ParseAstFile Parse pathToFile and stages all instances declared in the file
func ReplaceOldDeclarationsInFile ¶
ReplaceOldDeclarationsInFile replaces specific text in a file at the given path.
func Serialize ¶
func Serialize[Type Gongstruct](stage *Stage, tab Tabulator)
func SerializeExcelize ¶
func SerializeExcelize[Type Gongstruct](stage *Stage, f *excelize.File)
func SerializeExcelizePointerToGongstruct ¶
func SerializeExcelizePointerToGongstruct[Type PointerToGongstruct](stage *Stage, f *excelize.File)
func SerializeStage ¶
func SetCallbackAfterCreateFromFront ¶
func SetCallbackAfterCreateFromFront[Type Gongstruct](stage *Stage, callback OnAfterCreateInterface[Type])
func SetCallbackAfterDeleteFromFront ¶
func SetCallbackAfterDeleteFromFront[Type Gongstruct](stage *Stage, callback OnAfterDeleteInterface[Type])
func SetCallbackAfterReadFromFront ¶
func SetCallbackAfterReadFromFront[Type Gongstruct](stage *Stage, callback OnAfterReadInterface[Type])
func SetCallbackAfterUpdateFromFront ¶
func SetCallbackAfterUpdateFromFront[Type Gongstruct](stage *Stage, callback OnAfterUpdateInterface[Type])
SetCallbackAfterUpdateFromFront is a function to set up callback that is robust to refactoring
func SetOrchestratorOnAfterUpdate ¶
func SetOrchestratorOnAfterUpdate[Type Gongstruct](stage *Stage)
func SetupMapDocLinkRenaming ¶
func SetupMapDocLinkRenaming(gongStage *gong_models.Stage, gongdocStage *Stage)
to be removed after fix of [issue](https://github.com/golang/go/issues/57559)
func SortGongstructSetByName ¶
func SortGongstructSetByName[T PointerToGongstruct](set map[T]any) (sortedSlice []T)
func StageBranch ¶
func StageBranch[Type Gongstruct](stage *Stage, instance *Type)
StageBranch stages instance and apply StageBranch on all gongstruct instances that are referenced by pointers or slices of pointers of the instance
the algorithm stops along the course of graph if a vertex is already staged
func ToggleNodeExpanded ¶
func UnmarshallGongstructStaging ¶
func UnmarshallGongstructStaging(stage *Stage, cmap *ast.CommentMap, assignStmt *ast.AssignStmt, astCoordinate_ string) ( instance any, identifier string, gongstructName string, fieldName string)
UnmarshallGoStaging unmarshall a go assign statement
func UnstageBranch ¶
func UnstageBranch[Type Gongstruct](stage *Stage, instance *Type)
UnstageBranch stages instance and apply UnstageBranch on all gongstruct instances that are referenced by pointers or slices of pointers of the insance
the algorithm stops along the course of graph if a vertex is already staged
Types ¶
type AllModelsStructCreateInterface ¶
type AllModelsStructCreateInterface interface { CreateORMAttributeShape(AttributeShape *AttributeShape) CreateORMClassdiagram(Classdiagram *Classdiagram) CreateORMDiagramPackage(DiagramPackage *DiagramPackage) CreateORMGongEnumShape(GongEnumShape *GongEnumShape) CreateORMGongEnumValueShape(GongEnumValueShape *GongEnumValueShape) CreateORMGongNoteLinkShape(GongNoteLinkShape *GongNoteLinkShape) CreateORMGongNoteShape(GongNoteShape *GongNoteShape) CreateORMGongStructShape(GongStructShape *GongStructShape) CreateORMLinkShape(LinkShape *LinkShape) }
swagger:ignore
type AllModelsStructDeleteInterface ¶
type AllModelsStructDeleteInterface interface { DeleteORMAttributeShape(AttributeShape *AttributeShape) DeleteORMClassdiagram(Classdiagram *Classdiagram) DeleteORMDiagramPackage(DiagramPackage *DiagramPackage) DeleteORMGongEnumShape(GongEnumShape *GongEnumShape) DeleteORMGongEnumValueShape(GongEnumValueShape *GongEnumValueShape) DeleteORMGongNoteLinkShape(GongNoteLinkShape *GongNoteLinkShape) DeleteORMGongNoteShape(GongNoteShape *GongNoteShape) DeleteORMGongStructShape(GongStructShape *GongStructShape) DeleteORMLinkShape(LinkShape *LinkShape) }
type AnchoredTextImplLinkFieldName ¶
type AnchoredTextImplLinkFieldName struct {
// contains filtered or unexported fields
}
AnchoredTextImplLinkFieldName it meets the interface of AnchoredTextImplInterface and updates the link field name position
func NewAnchoredTextImplLinkFieldName ¶
func NewAnchoredTextImplLinkFieldName( anchoredtext *LinkShape, gongdocStage *Stage) (anchoredtextImplAnchoredText *AnchoredTextImplLinkFieldName)
func (*AnchoredTextImplLinkFieldName) AnchoredTextUpdated ¶
func (anchoredtextImplAnchoredText *AnchoredTextImplLinkFieldName) AnchoredTextUpdated( updatedAnchoredText *svg.LinkAnchoredText)
type AnchoredTextImplLinkSourceMultiplicity ¶
type AnchoredTextImplLinkSourceMultiplicity struct {
// contains filtered or unexported fields
}
AnchoredTextImplLinkSourceMultiplicity it meets the interface of AnchoredTextImplInterface and updates the link field name position
func NewAnchoredTextImplLinkSourceMultiplicity ¶
func NewAnchoredTextImplLinkSourceMultiplicity( anchoredtext *LinkShape, gongdocStage *Stage) (anchoredtextImplAnchoredText *AnchoredTextImplLinkSourceMultiplicity)
func (*AnchoredTextImplLinkSourceMultiplicity) AnchoredTextUpdated ¶
func (anchoredtextImplAnchoredText *AnchoredTextImplLinkSourceMultiplicity) AnchoredTextUpdated( updatedAnchoredText *gongsvg_models.LinkAnchoredText)
type AnchoredTextImplLinkTargetMultiplicity ¶
type AnchoredTextImplLinkTargetMultiplicity struct {
// contains filtered or unexported fields
}
AnchoredTextImplLinkTargetMultiplicity it meets the interface of AnchoredTextImplInterface and updates the link field name position
func NewAnchoredTextImplLinkTargetMultiplicity ¶
func NewAnchoredTextImplLinkTargetMultiplicity( anchoredtext *LinkShape, gongdocStage *Stage) (anchoredtextImplAnchoredText *AnchoredTextImplLinkTargetMultiplicity)
func (*AnchoredTextImplLinkTargetMultiplicity) AnchoredTextUpdated ¶
func (anchoredtextImplAnchoredText *AnchoredTextImplLinkTargetMultiplicity) AnchoredTextUpdated( updatedAnchoredText *gongsvg_models.LinkAnchoredText)
type AttributeFieldNodeProxy ¶
type AttributeFieldNodeProxy struct {
// contains filtered or unexported fields
}
func (*AttributeFieldNodeProxy) OnAfterUpdate ¶
func (proxy *AttributeFieldNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type AttributeShape ¶
type AttributeShape struct { Name string //gong:ident Identifier string FieldTypeAsString string Structname string Fieldtypename string }
AttributeShape
func CopyBranchAttributeShape ¶
func CopyBranchAttributeShape(mapOrigCopy map[any]any, attributeshapeFrom *AttributeShape) (attributeshapeTo *AttributeShape)
insertion point for stage branch per struct
func (*AttributeShape) Checkout ¶
func (attributeshape *AttributeShape) Checkout(stage *Stage) *AttributeShape
Checkout attributeshape to the back repo (if it is already staged)
func (*AttributeShape) Commit ¶
func (attributeshape *AttributeShape) Commit(stage *Stage) *AttributeShape
commit attributeshape to the back repo (if it is already staged)
func (*AttributeShape) CommitVoid ¶
func (attributeshape *AttributeShape) CommitVoid(stage *Stage)
func (*AttributeShape) CopyBasicFields ¶
func (from *AttributeShape) CopyBasicFields(to *AttributeShape)
func (*AttributeShape) GetName ¶
func (attributeshape *AttributeShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*AttributeShape) Stage ¶
func (attributeshape *AttributeShape) Stage(stage *Stage) *AttributeShape
insertion point for cumulative sub template with model space calls Stage puts attributeshape to the model stage
func (*AttributeShape) Unstage ¶
func (attributeshape *AttributeShape) Unstage(stage *Stage) *AttributeShape
Unstage removes attributeshape off the model stage
func (*AttributeShape) UnstageVoid ¶
func (attributeshape *AttributeShape) UnstageVoid(stage *Stage)
UnstageVoid removes attributeshape off the model stage
type AttributeShape_WOP ¶
type AttributeShape_WOP struct { // insertion point Name string Identifier string FieldTypeAsString string Structname string Fieldtypename string }
insertion point
type BackRepoInterface ¶
type BackRepoInterface interface { Commit(stage *Stage) Checkout(stage *Stage) Backup(stage *Stage, dirPath string) Restore(stage *Stage, dirPath string) BackupXL(stage *Stage, dirPath string) RestoreXL(stage *Stage, dirPath string) // insertion point for Commit and Checkout signatures CommitAttributeShape(attributeshape *AttributeShape) CheckoutAttributeShape(attributeshape *AttributeShape) CommitClassdiagram(classdiagram *Classdiagram) CheckoutClassdiagram(classdiagram *Classdiagram) CommitDiagramPackage(diagrampackage *DiagramPackage) CheckoutDiagramPackage(diagrampackage *DiagramPackage) CommitGongEnumShape(gongenumshape *GongEnumShape) CheckoutGongEnumShape(gongenumshape *GongEnumShape) CommitGongEnumValueShape(gongenumvalueshape *GongEnumValueShape) CheckoutGongEnumValueShape(gongenumvalueshape *GongEnumValueShape) CommitGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape) CheckoutGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape) CommitGongNoteShape(gongnoteshape *GongNoteShape) CheckoutGongNoteShape(gongnoteshape *GongNoteShape) CommitGongStructShape(gongstructshape *GongStructShape) CheckoutGongStructShape(gongstructshape *GongStructShape) CommitLinkShape(linkshape *LinkShape) CheckoutLinkShape(linkshape *LinkShape) GetLastCommitFromBackNb() uint GetLastPushFromFrontNb() uint }
type ButtonNewClassdiagramProxy ¶
type ButtonNewClassdiagramProxy struct {
// contains filtered or unexported fields
}
func (*ButtonNewClassdiagramProxy) ButtonUpdated ¶
func (proxy *ButtonNewClassdiagramProxy) ButtonUpdated( treeStage *tree.Stage, staged, front *tree.Button)
type ButtonType ¶
type ButtonType int
const ( DUPLICATE ButtonType = iota EDIT_CANCEL EDIT REMOVE RENAME_CANCEL RENAME SAVE )
func (ButtonType) CodeValues ¶
func (buttontype ButtonType) CodeValues() (res []int)
func (ButtonType) Codes ¶
func (buttontype ButtonType) Codes() (res []string)
func (*ButtonType) FromCodeString ¶
func (buttontype *ButtonType) FromCodeString(input string) (err error)
func (*ButtonType) FromInt ¶
func (buttontype *ButtonType) FromInt(input int) (err error)
func (*ButtonType) ToCodeString ¶
func (buttontype *ButtonType) ToCodeString() (res string)
func (ButtonType) ToInt ¶
func (buttontype ButtonType) ToInt() (res int)
insertion point of enum utility functions Utility function for ButtonType if enum values are string, it is stored with the value if enum values are int, they are stored with the code of the value
type ClassDiagramButtonProxy ¶
type ClassDiagramButtonProxy struct { ButtonType // contains filtered or unexported fields }
func NewClassDiagramButtonProxy ¶
func NewClassDiagramButtonProxy( stager *Stager, classdiagram *Classdiagram, node *tree.Node, buttonType ButtonType, ) (proxy *ClassDiagramButtonProxy)
func (*ClassDiagramButtonProxy) ButtonUpdated ¶
func (proxy *ClassDiagramButtonProxy) ButtonUpdated( treeStage *tree.Stage, stageButton, front *tree.Button)
type ClassDiagramGongEnumsNodeProxy ¶
type ClassDiagramGongEnumsNodeProxy struct {
// contains filtered or unexported fields
}
func (*ClassDiagramGongEnumsNodeProxy) OnAfterUpdate ¶
func (proxy *ClassDiagramGongEnumsNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type ClassDiagramGongNotesNodeProxy ¶
type ClassDiagramGongNotesNodeProxy struct {
// contains filtered or unexported fields
}
func (*ClassDiagramGongNotesNodeProxy) OnAfterUpdate ¶
func (proxy *ClassDiagramGongNotesNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type ClassDiagramGongStructsNodeProxy ¶
type ClassDiagramGongStructsNodeProxy struct {
// contains filtered or unexported fields
}
func (*ClassDiagramGongStructsNodeProxy) OnAfterUpdate ¶
func (proxy *ClassDiagramGongStructsNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type ClassDiagramNodeProxy ¶
type ClassDiagramNodeProxy struct {
// contains filtered or unexported fields
}
func (*ClassDiagramNodeProxy) OnAfterUpdate ¶
func (proxy *ClassDiagramNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
OnAfterUpdate is called when a node is checked/unchecked by the user
type Classdiagram ¶
type Classdiagram struct { Name string // list of gongstructshapes in the diagram GongStructShapes []*GongStructShape GongEnumShapes []*GongEnumShape // list of notes in the diagram GongNoteShapes []*GongNoteShape // IsInRenameMode means the user can edit the node IsInRenameMode bool // IsExpanded is true if the corresponding node is expanded IsExpanded bool NodeGongStructsIsExpanded bool // encoding of the the expanded status per named struct node // the bit position is the NodeNamedStruct position // beyond 63, there is no storage of expanded status // // bit 0 at 0 means first gong struct is not encoded // bit 1 at 0 means second gong struct is not encoded // etc... NodeGongStructNodeExpansionBinaryEncoding int NodeGongEnumsIsExpanded bool NodeGongEnumNodeExpansionBinaryEncoding int NodeGongNotesIsExpanded bool NodeGongNoteNodeExpansionBinaryEncoding int }
Classdiagram diagram struct store a class diagram temporary here swagger:model Classdiagram
func CopyBranchClassdiagram ¶
func CopyBranchClassdiagram(mapOrigCopy map[any]any, classdiagramFrom *Classdiagram) (classdiagramTo *Classdiagram)
func (*Classdiagram) AddAttributeFieldShape ¶
func (classdiagram *Classdiagram) AddAttributeFieldShape( stage *Stage, gongStage *gong.Stage, gongStruct *gong.GongStruct, field gong.FieldInterface, gongStructShape *GongStructShape)
AddToDiagram implements diagrammer.ElementNode.
func (*Classdiagram) AddGongEnumShape ¶
func (classdiagram *Classdiagram) AddGongEnumShape(stage *Stage, diagramPackage *DiagramPackage, enumshapeName string)
func (*Classdiagram) AddGongEnumValueShapeToDiagram ¶
func (classdiagram *Classdiagram) AddGongEnumValueShapeToDiagram( stage *Stage, gongEnumShape *GongEnumShape, gongEnum *gong.GongEnum, gongEnumValue *gong.GongEnumValue, )
AddToDiagram implements diagrammer.ElementNode.
func (*Classdiagram) AddGongNoteShape ¶
func (classdiagram *Classdiagram) AddGongNoteShape(stage *Stage, gongNote *gong.GongNote, diagramPackage *DiagramPackage, gongNoteShapeName string)
func (*Classdiagram) AddGongStructShape ¶
func (classdiagram *Classdiagram) AddGongStructShape(stage *Stage, diagramPackage *DiagramPackage, gongstructshapeName string)
func (*Classdiagram) AddLinkFieldShape ¶
func (classdiagram *Classdiagram) AddLinkFieldShape( stage *Stage, gongStage *gong.Stage, gongStruct *gong.GongStruct, field gong.FieldInterface, gongStructShape *GongStructShape)
AddToDiagram implements diagrammer.ElementNode.
func (*Classdiagram) Checkout ¶
func (classdiagram *Classdiagram) Checkout(stage *Stage) *Classdiagram
Checkout classdiagram to the back repo (if it is already staged)
func (*Classdiagram) Commit ¶
func (classdiagram *Classdiagram) Commit(stage *Stage) *Classdiagram
commit classdiagram to the back repo (if it is already staged)
func (*Classdiagram) CommitVoid ¶
func (classdiagram *Classdiagram) CommitVoid(stage *Stage)
func (*Classdiagram) CopyBasicFields ¶
func (from *Classdiagram) CopyBasicFields(to *Classdiagram)
func (*Classdiagram) DuplicateDiagram ¶
func (classdiagram *Classdiagram) DuplicateDiagram() (newClassdiagram *Classdiagram)
DuplicateDiagram generates a new diagram with duplicated shapes
func (*Classdiagram) GetName ¶
func (classdiagram *Classdiagram) GetName() (res string)
for satisfaction of GongStruct interface
func (*Classdiagram) HasGongNoteShape ¶
func (classdiagram *Classdiagram) HasGongNoteShape(gongstructName string) (foundGongNoteShape bool, gongNoteShape *GongNoteShape)
func (*Classdiagram) HasGongStructShape ¶
func (classdiagram *Classdiagram) HasGongStructShape(gongstructName string) (foundGongStructShape bool, gongstructshape *GongStructShape)
func (*Classdiagram) RemoveAttributeFieldShape ¶
func (classdiagram *Classdiagram) RemoveAttributeFieldShape( stage *Stage, attributeShape *AttributeShape, gongStructShape *GongStructShape)
RemoveAttributeFieldShape implements diagrammer.ModelElementNode.
func (*Classdiagram) RemoveGongEnumShape ¶
func (classdiagram *Classdiagram) RemoveGongEnumShape(stage *Stage, gongenumshapeName string)
func (*Classdiagram) RemoveGongEnumValueShapeFromDiagram ¶
func (classdiagram *Classdiagram) RemoveGongEnumValueShapeFromDiagram( stage *Stage, gongEnumShape *GongEnumShape, gongEnumValue *gong.GongEnumValue, )
RemoveFromDiagram implements diagrammer.ModelElementNode.
func (*Classdiagram) RemoveGongNoteShape ¶
func (classdiagram *Classdiagram) RemoveGongNoteShape(stage *Stage, gongNoteName string)
func (*Classdiagram) RemoveGongStructShape ¶
func (classdiagram *Classdiagram) RemoveGongStructShape(stage *Stage, gongstructName string)
func (*Classdiagram) RemoveLinkFieldShape ¶
func (classdiagram *Classdiagram) RemoveLinkFieldShape( stage *Stage, linkShape *LinkShape, gongStructShape *GongStructShape)
RemoveLinkFieldShape implements diagrammer.ModelElementNode.
func (*Classdiagram) Stage ¶
func (classdiagram *Classdiagram) Stage(stage *Stage) *Classdiagram
Stage puts classdiagram to the model stage
func (*Classdiagram) Unstage ¶
func (classdiagram *Classdiagram) Unstage(stage *Stage) *Classdiagram
Unstage removes classdiagram off the model stage
func (*Classdiagram) UnstageVoid ¶
func (classdiagram *Classdiagram) UnstageVoid(stage *Stage)
UnstageVoid removes classdiagram off the model stage
type Classdiagram_WOP ¶
type Classdiagram_WOP struct { // insertion point Name string IsInRenameMode bool IsExpanded bool NodeGongStructsIsExpanded bool NodeGongStructNodeExpansionBinaryEncoding int NodeGongEnumsIsExpanded bool NodeGongEnumNodeExpansionBinaryEncoding int NodeGongNotesIsExpanded bool NodeGongNoteNodeExpansionBinaryEncoding int }
type DiagramPackage ¶
type DiagramPackage struct { Name string // Path to the "diagrams" directory Path string // GongModelPath is the package path, e.g. "fullstack-lang/gongxlsx/go/models" GongModelPath string // Classdiagrams store UML Classdiagrams Classdiagrams []*Classdiagram // SelectedClassdiagram is the diagram of interest SelectedClassdiagram *Classdiagram // pointer to the model package ModelPkg *gong_models.ModelPkg AbsolutePathToDiagramPackage string // swagger:ignore Map_Identifier_NbInstances map[string]int }
DiagramPackage stores all diagrams related to a gong package swagger:model DiagramPackage
func CopyBranchDiagramPackage ¶
func CopyBranchDiagramPackage(mapOrigCopy map[any]any, diagrampackageFrom *DiagramPackage) (diagrampackageTo *DiagramPackage)
func (*DiagramPackage) Checkout ¶
func (diagrampackage *DiagramPackage) Checkout(stage *Stage) *DiagramPackage
Checkout diagrampackage to the back repo (if it is already staged)
func (*DiagramPackage) Commit ¶
func (diagrampackage *DiagramPackage) Commit(stage *Stage) *DiagramPackage
commit diagrampackage to the back repo (if it is already staged)
func (*DiagramPackage) CommitVoid ¶
func (diagrampackage *DiagramPackage) CommitVoid(stage *Stage)
func (*DiagramPackage) CopyBasicFields ¶
func (from *DiagramPackage) CopyBasicFields(to *DiagramPackage)
func (*DiagramPackage) GetName ¶
func (diagrampackage *DiagramPackage) GetName() (res string)
for satisfaction of GongStruct interface
func (*DiagramPackage) Stage ¶
func (diagrampackage *DiagramPackage) Stage(stage *Stage) *DiagramPackage
Stage puts diagrampackage to the model stage
func (*DiagramPackage) Unstage ¶
func (diagrampackage *DiagramPackage) Unstage(stage *Stage) *DiagramPackage
Unstage removes diagrampackage off the model stage
func (*DiagramPackage) UnstageVoid ¶
func (diagrampackage *DiagramPackage) UnstageVoid(stage *Stage)
UnstageVoid removes diagrampackage off the model stage
type DiagramPackage_WOP ¶
type DocSVGMapper ¶
type DocSVGMapper struct {
// contains filtered or unexported fields
}
func NewDocSVGMapper ¶
func NewDocSVGMapper( gongsvgStage *svg_models.Stage) (docSVGMapper *DocSVGMapper)
func (*DocSVGMapper) GenerateSvg ¶
func (docSVGMapper *DocSVGMapper) GenerateSvg( gongdocStage *Stage, embeddedDiagram bool, )
type ExcelizeTabulator ¶
type ExcelizeTabulator struct {
// contains filtered or unexported fields
}
func (*ExcelizeTabulator) AddCell ¶
func (tab *ExcelizeTabulator) AddCell(sheetName string, rowId, columnIndex int, value string)
func (*ExcelizeTabulator) AddRow ¶
func (tab *ExcelizeTabulator) AddRow(sheetName string) (rowId int)
func (*ExcelizeTabulator) AddSheet ¶
func (tab *ExcelizeTabulator) AddSheet(sheetName string)
func (*ExcelizeTabulator) SetExcelizeFile ¶
func (tab *ExcelizeTabulator) SetExcelizeFile(f *excelize.File)
type GONG__ExpressionType ¶
type GONG__ExpressionType string
swagger:ignore
const ( GONG__STRUCT_INSTANCE GONG__ExpressionType = "STRUCT_INSTANCE" GONG__FIELD_OR_CONST_VALUE GONG__ExpressionType = "FIELD_OR_CONST_VALUE" GONG__FIELD_VALUE GONG__ExpressionType = "FIELD_VALUE" GONG__ENUM_CAST_INT GONG__ExpressionType = "ENUM_CAST_INT" GONG__ENUM_CAST_STRING GONG__ExpressionType = "ENUM_CAST_STRING" GONG__IDENTIFIER_CONST GONG__ExpressionType = "IDENTIFIER_CONST" )
type GONG__Identifier ¶
type GONG__Identifier struct { Ident string Type GONG__ExpressionType }
type GongEnumNodeProxy ¶
type GongEnumNodeProxy struct {
// contains filtered or unexported fields
}
func (*GongEnumNodeProxy) OnAfterUpdate ¶
func (proxy *GongEnumNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type GongEnumNodeValueProxy ¶
type GongEnumNodeValueProxy struct {
// contains filtered or unexported fields
}
func (*GongEnumNodeValueProxy) OnAfterUpdate ¶
func (proxy *GongEnumNodeValueProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type GongEnumShape ¶
type GongEnumShape struct { Name string X, Y float64 // Identifier is the identifier of the struct referenced by the shape in the modeled package //gong:ident Identifier string GongEnumValueShapes []*GongEnumValueShape // with and height of the shape when they are rendered on SVG or with jointjs // They are optional fields. they can be computed when empty Width, Height float64 IsExpanded bool }
GongEnumShape mirrors joint.shapes.uml.Class swagger:model GongEnumShape
func CopyBranchGongEnumShape ¶
func CopyBranchGongEnumShape(mapOrigCopy map[any]any, gongenumshapeFrom *GongEnumShape) (gongenumshapeTo *GongEnumShape)
func (*GongEnumShape) Checkout ¶
func (gongenumshape *GongEnumShape) Checkout(stage *Stage) *GongEnumShape
Checkout gongenumshape to the back repo (if it is already staged)
func (*GongEnumShape) Commit ¶
func (gongenumshape *GongEnumShape) Commit(stage *Stage) *GongEnumShape
commit gongenumshape to the back repo (if it is already staged)
func (*GongEnumShape) CommitVoid ¶
func (gongenumshape *GongEnumShape) CommitVoid(stage *Stage)
func (*GongEnumShape) CopyBasicFields ¶
func (from *GongEnumShape) CopyBasicFields(to *GongEnumShape)
func (*GongEnumShape) GetName ¶
func (gongenumshape *GongEnumShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*GongEnumShape) Stage ¶
func (gongenumshape *GongEnumShape) Stage(stage *Stage) *GongEnumShape
Stage puts gongenumshape to the model stage
func (*GongEnumShape) Unstage ¶
func (gongenumshape *GongEnumShape) Unstage(stage *Stage) *GongEnumShape
Unstage removes gongenumshape off the model stage
func (*GongEnumShape) UnstageVoid ¶
func (gongenumshape *GongEnumShape) UnstageVoid(stage *Stage)
UnstageVoid removes gongenumshape off the model stage
type GongEnumShapeType ¶
type GongEnumShapeType int
const ( Int GongEnumShapeType = iota String )
func (GongEnumShapeType) CodeValues ¶
func (gongenumshapetype GongEnumShapeType) CodeValues() (res []int)
func (GongEnumShapeType) Codes ¶
func (gongenumshapetype GongEnumShapeType) Codes() (res []string)
func (*GongEnumShapeType) FromCodeString ¶
func (gongenumshapetype *GongEnumShapeType) FromCodeString(input string) (err error)
func (*GongEnumShapeType) FromInt ¶
func (gongenumshapetype *GongEnumShapeType) FromInt(input int) (err error)
func (*GongEnumShapeType) ToCodeString ¶
func (gongenumshapetype *GongEnumShapeType) ToCodeString() (res string)
func (GongEnumShapeType) ToInt ¶
func (gongenumshapetype GongEnumShapeType) ToInt() (res int)
Utility function for GongEnumShapeType if enum values are string, it is stored with the value if enum values are int, they are stored with the code of the value
type GongEnumShape_WOP ¶
type GongEnumValueShape ¶
type GongEnumValueShape struct { // Name of the enum value Name string // Identifier is the identifier of the enum value referenced by the shape in the modeled package //gong:ident Identifier string }
func CopyBranchGongEnumValueShape ¶
func CopyBranchGongEnumValueShape(mapOrigCopy map[any]any, gongenumvalueshapeFrom *GongEnumValueShape) (gongenumvalueshapeTo *GongEnumValueShape)
func (*GongEnumValueShape) Checkout ¶
func (gongenumvalueshape *GongEnumValueShape) Checkout(stage *Stage) *GongEnumValueShape
Checkout gongenumvalueshape to the back repo (if it is already staged)
func (*GongEnumValueShape) Commit ¶
func (gongenumvalueshape *GongEnumValueShape) Commit(stage *Stage) *GongEnumValueShape
commit gongenumvalueshape to the back repo (if it is already staged)
func (*GongEnumValueShape) CommitVoid ¶
func (gongenumvalueshape *GongEnumValueShape) CommitVoid(stage *Stage)
func (*GongEnumValueShape) CopyBasicFields ¶
func (from *GongEnumValueShape) CopyBasicFields(to *GongEnumValueShape)
func (*GongEnumValueShape) GetName ¶
func (gongenumvalueshape *GongEnumValueShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*GongEnumValueShape) Stage ¶
func (gongenumvalueshape *GongEnumValueShape) Stage(stage *Stage) *GongEnumValueShape
Stage puts gongenumvalueshape to the model stage
func (*GongEnumValueShape) Unstage ¶
func (gongenumvalueshape *GongEnumValueShape) Unstage(stage *Stage) *GongEnumValueShape
Unstage removes gongenumvalueshape off the model stage
func (*GongEnumValueShape) UnstageVoid ¶
func (gongenumvalueshape *GongEnumValueShape) UnstageVoid(stage *Stage)
UnstageVoid removes gongenumvalueshape off the model stage
type GongEnumValueShape_WOP ¶
type GongFieldValue ¶
type GongFieldValue struct { GongFieldValueType // contains filtered or unexported fields }
func GetFieldStringValue ¶
func GetFieldStringValue(instance any, fieldName string) (res GongFieldValue)
func GetFieldStringValueFromPointer ¶
func GetFieldStringValueFromPointer(instance any, fieldName string) (res GongFieldValue)
func (*GongFieldValue) GetValueBool ¶
func (gongValueField *GongFieldValue) GetValueBool() bool
func (*GongFieldValue) GetValueFloat ¶
func (gongValueField *GongFieldValue) GetValueFloat() float64
func (*GongFieldValue) GetValueInt ¶
func (gongValueField *GongFieldValue) GetValueInt() int
func (*GongFieldValue) GetValueString ¶
func (gongValueField *GongFieldValue) GetValueString() string
type GongFieldValueType ¶
type GongFieldValueType string
const ( GongFieldValueTypeInt GongFieldValueType = "GongFieldValueTypeInt" GongFieldValueTypeFloat GongFieldValueType = "GongFieldValueTypeFloat" GongFieldValueTypeBool GongFieldValueType = "GongFieldValueTypeBool" GongFieldValueTypeOthers GongFieldValueType = "GongFieldValueTypeOthers" )
type GongNoteLinkShape ¶
type GongNoteLinkShape struct { Name string // Identifier of the target shape / link of the note link //gong:ident Identifier string // Type of the target shape / link of the note link Type NoteShapeLinkType }
A GongNoteLinkShape is a visual link from a shape to a Link or to a Classshape
The end point of the link is computed from the Type ¶
Because of[issue](https://github.com/golang/go/issues/57559) the referenced identifiers in the note comments are not renamed. Unlinke for identifiers used for referencing stuff, there is workaround this limitation
func CopyBranchGongNoteLinkShape ¶
func CopyBranchGongNoteLinkShape(mapOrigCopy map[any]any, gongnotelinkshapeFrom *GongNoteLinkShape) (gongnotelinkshapeTo *GongNoteLinkShape)
func (*GongNoteLinkShape) Checkout ¶
func (gongnotelinkshape *GongNoteLinkShape) Checkout(stage *Stage) *GongNoteLinkShape
Checkout gongnotelinkshape to the back repo (if it is already staged)
func (*GongNoteLinkShape) Commit ¶
func (gongnotelinkshape *GongNoteLinkShape) Commit(stage *Stage) *GongNoteLinkShape
commit gongnotelinkshape to the back repo (if it is already staged)
func (*GongNoteLinkShape) CommitVoid ¶
func (gongnotelinkshape *GongNoteLinkShape) CommitVoid(stage *Stage)
func (*GongNoteLinkShape) CopyBasicFields ¶
func (from *GongNoteLinkShape) CopyBasicFields(to *GongNoteLinkShape)
func (*GongNoteLinkShape) GetName ¶
func (gongnotelinkshape *GongNoteLinkShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*GongNoteLinkShape) Stage ¶
func (gongnotelinkshape *GongNoteLinkShape) Stage(stage *Stage) *GongNoteLinkShape
Stage puts gongnotelinkshape to the model stage
func (*GongNoteLinkShape) Unstage ¶
func (gongnotelinkshape *GongNoteLinkShape) Unstage(stage *Stage) *GongNoteLinkShape
Unstage removes gongnotelinkshape off the model stage
func (*GongNoteLinkShape) UnstageVoid ¶
func (gongnotelinkshape *GongNoteLinkShape) UnstageVoid(stage *Stage)
UnstageVoid removes gongnotelinkshape off the model stage
type GongNoteLinkShape_WOP ¶
type GongNoteLinkShape_WOP struct { // insertion point Name string Identifier string Type NoteShapeLinkType }
type GongNoteNodeProxy ¶
type GongNoteNodeProxy struct {
// contains filtered or unexported fields
}
func (*GongNoteNodeProxy) OnAfterUpdate ¶
func (proxy *GongNoteNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type GongNoteShape ¶
type GongNoteShape struct { Name string // Identifier of the note object in the model package // a note is a special coment syntax https://pkg.go.dev/go/doc#Note // see vendor/github.com/fullstack-lang/gong/go/models/gong_note.go // since a note name is not an identifier, it cannot be renamed by gopls // unless it is understood to be the name of the identifier immediatly // following the comment // // Gongdoc makes this option a wrtting condition for note: // a comment text in gong containing a // 'gongnote' have to be followed by a constant identifier. // // // GONGNOTE(ShortNodeOnModels): this is an example of a short note // // It uses the DocLink convention for referencing Identifiers // // In this case [Line], [Point] and [Line.Start] // const ShortNodeOnModels = "" // // the following directive directs gong to manage this field as an identifier field // //gong:ident Identifier string Body string BodyHTML string X, Y float64 Width, Height float64 Matched bool // if a note with the same name has been found GongNoteLinkShapes []*GongNoteLinkShape IsExpanded bool }
GongNoteShape is a UML note in a class diagram
func CopyBranchGongNoteShape ¶
func CopyBranchGongNoteShape(mapOrigCopy map[any]any, gongnoteshapeFrom *GongNoteShape) (gongnoteshapeTo *GongNoteShape)
func (*GongNoteShape) Checkout ¶
func (gongnoteshape *GongNoteShape) Checkout(stage *Stage) *GongNoteShape
Checkout gongnoteshape to the back repo (if it is already staged)
func (*GongNoteShape) Commit ¶
func (gongnoteshape *GongNoteShape) Commit(stage *Stage) *GongNoteShape
commit gongnoteshape to the back repo (if it is already staged)
func (*GongNoteShape) CommitVoid ¶
func (gongnoteshape *GongNoteShape) CommitVoid(stage *Stage)
func (*GongNoteShape) CopyBasicFields ¶
func (from *GongNoteShape) CopyBasicFields(to *GongNoteShape)
func (*GongNoteShape) GetName ¶
func (gongnoteshape *GongNoteShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*GongNoteShape) Stage ¶
func (gongnoteshape *GongNoteShape) Stage(stage *Stage) *GongNoteShape
Stage puts gongnoteshape to the model stage
func (*GongNoteShape) Unstage ¶
func (gongnoteshape *GongNoteShape) Unstage(stage *Stage) *GongNoteShape
Unstage removes gongnoteshape off the model stage
func (*GongNoteShape) UnstageVoid ¶
func (gongnoteshape *GongNoteShape) UnstageVoid(stage *Stage)
UnstageVoid removes gongnoteshape off the model stage
type GongNoteShape_WOP ¶
type GongStructInterface ¶
type GongStructInterface interface {
GetName() (res string)
}
GongStructInterface is the interface met by GongStructs It allows runtime reflexion of instances (without the hassle of the "reflect" package)
type GongStructNodeProxy ¶
type GongStructNodeProxy struct {
// contains filtered or unexported fields
}
func (*GongStructNodeProxy) OnAfterUpdate ¶
func (proxy *GongStructNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type GongStructShape ¶
type GongStructShape struct { Name string X float64 Y float64 // Identifier is the identifier of the struct referenced by the shape in the modeled package //gong:ident Identifier string // gongdoc can be integrated in a runtime application // the application can then set up the number of instances of Struct ShowNbInstances bool NbInstances int // models of the composition of Field AttributeShapes []*AttributeShape // models of the composition of Link LinkShapes []*LinkShape // with and height of the shape when they are rendered on SVG or with jointjs // They are optional fields. they can be computed when empty Width, Height float64 // this is always false in the backend, but it can be set to true by the front end // this means it is selected by the user IsSelected bool }
GongStructShape mirrors joint.shapes.uml.Class swagger:model GongStructShape
func CopyBranchGongStructShape ¶
func CopyBranchGongStructShape(mapOrigCopy map[any]any, gongstructshapeFrom *GongStructShape) (gongstructshapeTo *GongStructShape)
func (*GongStructShape) Checkout ¶
func (gongstructshape *GongStructShape) Checkout(stage *Stage) *GongStructShape
Checkout gongstructshape to the back repo (if it is already staged)
func (*GongStructShape) Commit ¶
func (gongstructshape *GongStructShape) Commit(stage *Stage) *GongStructShape
commit gongstructshape to the back repo (if it is already staged)
func (*GongStructShape) CommitVoid ¶
func (gongstructshape *GongStructShape) CommitVoid(stage *Stage)
func (*GongStructShape) CopyBasicFields ¶
func (from *GongStructShape) CopyBasicFields(to *GongStructShape)
func (*GongStructShape) GetName ¶
func (gongstructshape *GongStructShape) GetName() (res string)
for satisfaction of GongStruct interface
func (*GongStructShape) Stage ¶
func (gongstructshape *GongStructShape) Stage(stage *Stage) *GongStructShape
Stage puts gongstructshape to the model stage
func (*GongStructShape) Unstage ¶
func (gongstructshape *GongStructShape) Unstage(stage *Stage) *GongStructShape
Unstage removes gongstructshape off the model stage
func (*GongStructShape) UnstageVoid ¶
func (gongstructshape *GongStructShape) UnstageVoid(stage *Stage)
UnstageVoid removes gongstructshape off the model stage
type GongStructShape_WOP ¶
type Gongstruct ¶
type Gongstruct interface { }
Gongstruct is the type parameter for generated generic function that allows - access to staged instances - navigation between staged instances by going backward association links between gongstruct - full refactoring of Gongstruct identifiers / fields
type GongstructEnumIntField ¶
type GongstructEnumIntField interface { int | ButtonType | GongEnumShapeType Codes() []string CodeValues() []int }
type GongstructMapString ¶
type GongstructSet ¶
type GongtructBasicField ¶
type LinkFieldNodeProxy ¶
type LinkFieldNodeProxy struct {
// contains filtered or unexported fields
}
func (*LinkFieldNodeProxy) OnAfterUpdate ¶
func (proxy *LinkFieldNodeProxy) OnAfterUpdate( stage *tree.Stage, staged, front *tree.Node)
type LinkImplLink ¶
type LinkImplLink struct {
// contains filtered or unexported fields
}
LinkImplLink it meets the interface of LinkImplInterface
func NewLinkImplLink ¶
func NewLinkImplLink( link *LinkShape, gongdocStage *Stage) (linkImplLink *LinkImplLink)
func (*LinkImplLink) LinkUpdated ¶
func (linkImplLink *LinkImplLink) LinkUpdated(updatedLink *gongsvg_models.Link)
type LinkShape ¶
type LinkShape struct { Name string // Identifier is the identifier of the struct field referenced by the // UML field of the classshape in the modeled package //gong:ident Identifier string //gong:ident Fieldtypename string // position of the field text relative to the // arrow end FieldOffsetX float64 FieldOffsetY float64 TargetMultiplicity MultiplicityType // position of the TargetMultiplicity text relative to the // arrow end TargetMultiplicityOffsetX float64 TargetMultiplicityOffsetY float64 SourceMultiplicity MultiplicityType // position of the SourceMultiplicity text relative to the // arrow end SourceMultiplicityOffsetX float64 SourceMultiplicityOffsetY float64 // for links with floating anchors // if link type is floating orthogonal ratio, from 0 to 1, // where the anchor starts on the edge (horizontal / vertical) // Vertice in the middle X float64 Y float64 StartOrientation OrientationType StartRatio float64 EndOrientation OrientationType EndRatio float64 // in case StartOrientation is the same as EndOrientation, // there is a perpendicular line that reach the corner at // CornerOffsetRatio CornerOffsetRatio float64 }
LinkShape represent the UML LinkShape in any diagram uni-directional https://en.wikipedia.org/wiki/Association_(object-oriented_programming) More specificaly It is a 0..1 ---> 0..1 swagger:model LinkShape
func CopyBranchLinkShape ¶
func (*LinkShape) CommitVoid ¶
func (*LinkShape) CopyBasicFields ¶
func (*LinkShape) UnstageVoid ¶
UnstageVoid removes linkshape off the model stage
type LinkShape_WOP ¶
type LinkShape_WOP struct { // insertion point Name string Identifier string Fieldtypename string FieldOffsetX float64 FieldOffsetY float64 TargetMultiplicity MultiplicityType TargetMultiplicityOffsetX float64 TargetMultiplicityOffsetY float64 SourceMultiplicity MultiplicityType SourceMultiplicityOffsetX float64 SourceMultiplicityOffsetY float64 X float64 Y float64 StartOrientation OrientationType StartRatio float64 EndOrientation OrientationType EndRatio float64 CornerOffsetRatio float64 }
type ModelElement ¶
type ModelElement interface { }
type MultiplicityType ¶
type MultiplicityType string
const ( ZERO_ONE MultiplicityType = "0..1" ONE MultiplicityType = "1" MANY MultiplicityType = "*" )
values for EnumType
func (MultiplicityType) CodeValues ¶
func (multiplicitytype MultiplicityType) CodeValues() (res []string)
func (MultiplicityType) Codes ¶
func (multiplicitytype MultiplicityType) Codes() (res []string)
func (*MultiplicityType) FromCodeString ¶
func (multiplicitytype *MultiplicityType) FromCodeString(input string) (err error)
func (*MultiplicityType) FromString ¶
func (multiplicitytype *MultiplicityType) FromString(input string) (err error)
func (*MultiplicityType) ToCodeString ¶
func (multiplicitytype *MultiplicityType) ToCodeString() (res string)
func (MultiplicityType) ToString ¶
func (multiplicitytype MultiplicityType) ToString() (res string)
Utility function for MultiplicityType if enum values are string, it is stored with the value if enum values are int, they are stored with the code of the value
type NamedStruct ¶
type NamedStruct struct {
// contains filtered or unexported fields
}
func (*NamedStruct) GetName ¶
func (namedStruct *NamedStruct) GetName() string
type NoteShapeLinkType ¶
type NoteShapeLinkType string
const ( NOTE_SHAPE_LINK_TO_GONG_STRUCT_OR_ENUM_SHAPE NoteShapeLinkType = "NOTE_SHAPE_LINK_TO_GONG_STRUCT_OR_ENUM_SHAPE" NOTE_SHAPE_LINK_TO_GONG_FIELD NoteShapeLinkType = "NOTE_SHAPE_LINK_TO_GONG_FIELD" )
func (NoteShapeLinkType) CodeValues ¶
func (noteshapelinktype NoteShapeLinkType) CodeValues() (res []string)
func (NoteShapeLinkType) Codes ¶
func (noteshapelinktype NoteShapeLinkType) Codes() (res []string)
func (*NoteShapeLinkType) FromCodeString ¶
func (noteshapelinktype *NoteShapeLinkType) FromCodeString(input string) (err error)
func (*NoteShapeLinkType) FromString ¶
func (noteshapelinktype *NoteShapeLinkType) FromString(input string) (err error)
func (*NoteShapeLinkType) ToCodeString ¶
func (noteshapelinktype *NoteShapeLinkType) ToCodeString() (res string)
func (NoteShapeLinkType) ToString ¶
func (noteshapelinktype NoteShapeLinkType) ToString() (res string)
Utility function for NoteShapeLinkType if enum values are string, it is stored with the value if enum values are int, they are stored with the code of the value
type OnAfterCreateInterface ¶
type OnAfterCreateInterface[Type Gongstruct] interface { OnAfterCreate(stage *Stage, instance *Type) }
OnAfterCreateInterface callback when an instance is updated from the front
type OnAfterDeleteInterface ¶
type OnAfterDeleteInterface[Type Gongstruct] interface { OnAfterDelete(stage *Stage, staged, front *Type) }
OnAfterDeleteInterface callback when an instance is updated from the front
type OnAfterReadInterface ¶
type OnAfterReadInterface[Type Gongstruct] interface { OnAfterRead(stage *Stage, instance *Type) }
OnAfterReadInterface callback when an instance is updated from the front
type OnAfterUpdateInterface ¶
type OnAfterUpdateInterface[Type Gongstruct] interface { OnAfterUpdate(stage *Stage, old, new *Type) }
OnAfterUpdateInterface callback when an instance is updated from the front
type OnInitCommitInterface ¶
type OnInitCommitInterface interface {
BeforeCommit(stage *Stage)
}
type OrientationType ¶
type OrientationType string
const ( ORIENTATION_HORIZONTAL OrientationType = "ORIENTATION_HORIZONTAL" ORIENTATION_VERTICAL OrientationType = "ORIENTATION_VERTICAL" )
values for EnumType
func (OrientationType) CodeValues ¶
func (orientationtype OrientationType) CodeValues() (res []string)
func (OrientationType) Codes ¶
func (orientationtype OrientationType) Codes() (res []string)
func (*OrientationType) FromCodeString ¶
func (orientationtype *OrientationType) FromCodeString(input string) (err error)
func (*OrientationType) FromString ¶
func (orientationtype *OrientationType) FromString(input string) (err error)
func (*OrientationType) ToCodeString ¶
func (orientationtype *OrientationType) ToCodeString() (res string)
func (OrientationType) ToString ¶
func (orientationtype OrientationType) ToString() (res string)
Utility function for OrientationType if enum values are string, it is stored with the value if enum values are int, they are stored with the code of the value
type PointerToGongstruct ¶
type PointerToGongstruct interface { GetName() string CommitVoid(*Stage) UnstageVoid(stage *Stage) comparable }
Gongstruct is the type parameter for generated generic function that allows - access to staged instances - navigation between staged instances by going backward association links between gongstruct - full refactoring of Gongstruct identifiers / fields
type PointerToGongstructEnumIntField ¶
type PointerToGongstructEnumIntField interface { *ButtonType | *GongEnumShapeType FromCodeString(input string) (err error) }
type RectImplGongenumShape ¶
type RectImplGongenumShape struct {
// contains filtered or unexported fields
}
RectImplGongenumShape it meets the interface of RectImplInterface
func NewRectImplGongenumShape ¶
func NewRectImplGongenumShape( gongEnumShape *GongEnumShape, gongdocStage *Stage) (rectImplGongenumShape *RectImplGongenumShape)
func (*RectImplGongenumShape) RectUpdated ¶
func (rectImplGongenumShape *RectImplGongenumShape) RectUpdated(updatedRect *gongsvg_models.Rect)
type RectImplGongstructShape ¶
type RectImplGongstructShape struct {
// contains filtered or unexported fields
}
RectImplGongstructShape it meets the interface of RectImplInterface
func NewRectImplGongstructShape ¶
func NewRectImplGongstructShape( gongstructShape *GongStructShape, gongdocStage *Stage) (rectImplGongstructShape *RectImplGongstructShape)
func (*RectImplGongstructShape) RectUpdated ¶
func (rectImplGongstructShape *RectImplGongstructShape) RectUpdated(updatedRect *gongsvg_models.Rect)
type RectImplNoteShape ¶
type RectImplNoteShape struct {
// contains filtered or unexported fields
}
RectImplNoteShape it meets the interface of RectImplInterface
func NewRectImplNoteShape ¶
func NewRectImplNoteShape( noteShape *GongNoteShape, gongdocStage *Stage) (rectImplNoteShape *RectImplNoteShape)
func (*RectImplNoteShape) RectUpdated ¶
func (rectImplNoteShape *RectImplNoteShape) RectUpdated(updatedRect *gongsvg_models.Rect)
type ReverseField ¶
func GetReverseFields ¶
func GetReverseFields[Type Gongstruct]() (res []ReverseField)
type Stage ¶
type Stage struct { // insertion point for definition of arrays registering instances AttributeShapes map[*AttributeShape]any AttributeShapes_mapString map[string]*AttributeShape // insertion point for slice of pointers maps OnAfterAttributeShapeCreateCallback OnAfterCreateInterface[AttributeShape] OnAfterAttributeShapeUpdateCallback OnAfterUpdateInterface[AttributeShape] OnAfterAttributeShapeDeleteCallback OnAfterDeleteInterface[AttributeShape] OnAfterAttributeShapeReadCallback OnAfterReadInterface[AttributeShape] Classdiagrams map[*Classdiagram]any Classdiagrams_mapString map[string]*Classdiagram // insertion point for slice of pointers maps Classdiagram_GongStructShapes_reverseMap map[*GongStructShape]*Classdiagram Classdiagram_GongEnumShapes_reverseMap map[*GongEnumShape]*Classdiagram Classdiagram_GongNoteShapes_reverseMap map[*GongNoteShape]*Classdiagram OnAfterClassdiagramCreateCallback OnAfterCreateInterface[Classdiagram] OnAfterClassdiagramUpdateCallback OnAfterUpdateInterface[Classdiagram] OnAfterClassdiagramDeleteCallback OnAfterDeleteInterface[Classdiagram] OnAfterClassdiagramReadCallback OnAfterReadInterface[Classdiagram] DiagramPackages map[*DiagramPackage]any DiagramPackages_mapString map[string]*DiagramPackage // insertion point for slice of pointers maps DiagramPackage_Classdiagrams_reverseMap map[*Classdiagram]*DiagramPackage OnAfterDiagramPackageCreateCallback OnAfterCreateInterface[DiagramPackage] OnAfterDiagramPackageUpdateCallback OnAfterUpdateInterface[DiagramPackage] OnAfterDiagramPackageDeleteCallback OnAfterDeleteInterface[DiagramPackage] OnAfterDiagramPackageReadCallback OnAfterReadInterface[DiagramPackage] GongEnumShapes map[*GongEnumShape]any GongEnumShapes_mapString map[string]*GongEnumShape // insertion point for slice of pointers maps GongEnumShape_GongEnumValueShapes_reverseMap map[*GongEnumValueShape]*GongEnumShape OnAfterGongEnumShapeCreateCallback OnAfterCreateInterface[GongEnumShape] OnAfterGongEnumShapeUpdateCallback OnAfterUpdateInterface[GongEnumShape] OnAfterGongEnumShapeDeleteCallback OnAfterDeleteInterface[GongEnumShape] OnAfterGongEnumShapeReadCallback OnAfterReadInterface[GongEnumShape] GongEnumValueShapes map[*GongEnumValueShape]any GongEnumValueShapes_mapString map[string]*GongEnumValueShape // insertion point for slice of pointers maps OnAfterGongEnumValueShapeCreateCallback OnAfterCreateInterface[GongEnumValueShape] OnAfterGongEnumValueShapeUpdateCallback OnAfterUpdateInterface[GongEnumValueShape] OnAfterGongEnumValueShapeDeleteCallback OnAfterDeleteInterface[GongEnumValueShape] OnAfterGongEnumValueShapeReadCallback OnAfterReadInterface[GongEnumValueShape] GongNoteLinkShapes map[*GongNoteLinkShape]any GongNoteLinkShapes_mapString map[string]*GongNoteLinkShape // insertion point for slice of pointers maps OnAfterGongNoteLinkShapeCreateCallback OnAfterCreateInterface[GongNoteLinkShape] OnAfterGongNoteLinkShapeUpdateCallback OnAfterUpdateInterface[GongNoteLinkShape] OnAfterGongNoteLinkShapeDeleteCallback OnAfterDeleteInterface[GongNoteLinkShape] OnAfterGongNoteLinkShapeReadCallback OnAfterReadInterface[GongNoteLinkShape] GongNoteShapes map[*GongNoteShape]any GongNoteShapes_mapString map[string]*GongNoteShape // insertion point for slice of pointers maps GongNoteShape_GongNoteLinkShapes_reverseMap map[*GongNoteLinkShape]*GongNoteShape OnAfterGongNoteShapeCreateCallback OnAfterCreateInterface[GongNoteShape] OnAfterGongNoteShapeUpdateCallback OnAfterUpdateInterface[GongNoteShape] OnAfterGongNoteShapeDeleteCallback OnAfterDeleteInterface[GongNoteShape] OnAfterGongNoteShapeReadCallback OnAfterReadInterface[GongNoteShape] GongStructShapes map[*GongStructShape]any GongStructShapes_mapString map[string]*GongStructShape // insertion point for slice of pointers maps GongStructShape_AttributeShapes_reverseMap map[*AttributeShape]*GongStructShape GongStructShape_LinkShapes_reverseMap map[*LinkShape]*GongStructShape OnAfterGongStructShapeCreateCallback OnAfterCreateInterface[GongStructShape] OnAfterGongStructShapeUpdateCallback OnAfterUpdateInterface[GongStructShape] OnAfterGongStructShapeDeleteCallback OnAfterDeleteInterface[GongStructShape] OnAfterGongStructShapeReadCallback OnAfterReadInterface[GongStructShape] LinkShapes map[*LinkShape]any LinkShapes_mapString map[string]*LinkShape // insertion point for slice of pointers maps OnAfterLinkShapeCreateCallback OnAfterCreateInterface[LinkShape] OnAfterLinkShapeUpdateCallback OnAfterUpdateInterface[LinkShape] OnAfterLinkShapeDeleteCallback OnAfterDeleteInterface[LinkShape] OnAfterLinkShapeReadCallback OnAfterReadInterface[LinkShape] AllModelsStructCreateCallback AllModelsStructCreateInterface AllModelsStructDeleteCallback AllModelsStructDeleteInterface BackRepo BackRepoInterface // if set will be called before each commit to the back repo OnInitCommitCallback OnInitCommitInterface OnInitCommitFromFrontCallback OnInitCommitInterface OnInitCommitFromBackCallback OnInitCommitInterface // store the number of instance per gongstruct Map_GongStructName_InstancesNb map[string]int // store meta package import MetaPackageImportPath string MetaPackageImportAlias string // to be removed after fix of [issue](https://github.com/golang/go/issues/57559) // map to enable docLink renaming when an identifier is renamed Map_DocLink_Renaming map[string]GONG__Identifier // store the stage order of each instance in order to // preserve this order when serializing them // insertion point for order fields declaration AttributeShapeOrder uint AttributeShapeMap_Staged_Order map[*AttributeShape]uint ClassdiagramOrder uint ClassdiagramMap_Staged_Order map[*Classdiagram]uint DiagramPackageOrder uint DiagramPackageMap_Staged_Order map[*DiagramPackage]uint GongEnumShapeOrder uint GongEnumShapeMap_Staged_Order map[*GongEnumShape]uint GongEnumValueShapeOrder uint GongEnumValueShapeMap_Staged_Order map[*GongEnumValueShape]uint GongNoteLinkShapeOrder uint GongNoteLinkShapeMap_Staged_Order map[*GongNoteLinkShape]uint GongNoteShapeOrder uint GongNoteShapeMap_Staged_Order map[*GongNoteShape]uint GongStructShapeOrder uint GongStructShapeMap_Staged_Order map[*GongStructShape]uint LinkShapeOrder uint LinkShapeMap_Staged_Order map[*LinkShape]uint NamedStructs []*NamedStruct // contains filtered or unexported fields }
Stage enables storage of staged instances swagger:ignore
func (*Stage) CommitWithSuspendedCallbacks ¶
func (stage *Stage) CommitWithSuspendedCallbacks()
func (*Stage) ComputeReverseMaps ¶
func (stage *Stage) ComputeReverseMaps()
ComputeReverseMaps computes the reverse map, for all intances, for all slice to pointers field Its complexity is in O(n)O(p) where p is the number of pointers
func (*Stage) GetDigramsEmbededDir ¶
func (*Stage) GetMap_GongStructName_InstancesNb ¶
func (*Stage) GetModelsEmbededDir ¶
func (*Stage) GetNamedStructNamesByOrder ¶
func (*Stage) GetNamedStructsNames ¶
GetNamedStructs implements models.ProbebStage.
func (*Stage) GetProbeFormStageName ¶
func (*Stage) GetProbeSplitStageName ¶
func (*Stage) GetProbeTableStageName ¶
func (*Stage) GetProbeTreeSidebarStageName ¶
func (*Stage) IsStagedAttributeShape ¶
func (stage *Stage) IsStagedAttributeShape(attributeshape *AttributeShape) (ok bool)
insertion point for stage per struct
func (*Stage) IsStagedClassdiagram ¶
func (stage *Stage) IsStagedClassdiagram(classdiagram *Classdiagram) (ok bool)
func (*Stage) IsStagedDiagramPackage ¶
func (stage *Stage) IsStagedDiagramPackage(diagrampackage *DiagramPackage) (ok bool)
func (*Stage) IsStagedGongEnumShape ¶
func (stage *Stage) IsStagedGongEnumShape(gongenumshape *GongEnumShape) (ok bool)
func (*Stage) IsStagedGongEnumValueShape ¶
func (stage *Stage) IsStagedGongEnumValueShape(gongenumvalueshape *GongEnumValueShape) (ok bool)
func (*Stage) IsStagedGongNoteLinkShape ¶
func (stage *Stage) IsStagedGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape) (ok bool)
func (*Stage) IsStagedGongNoteShape ¶
func (stage *Stage) IsStagedGongNoteShape(gongnoteshape *GongNoteShape) (ok bool)
func (*Stage) IsStagedGongStructShape ¶
func (stage *Stage) IsStagedGongStructShape(gongstructshape *GongStructShape) (ok bool)
func (*Stage) IsStagedLinkShape ¶
func (*Stage) Marshall ¶
Marshall marshall the stage content into the file as an instanciation into a stage
func (*Stage) Restore ¶
Restore resets Stage & BackRepo and restores their content from the restore files in dirPath
func (*Stage) RestoreXL ¶
Restore resets Stage & BackRepo and restores their content from the restore files in dirPath
func (*Stage) StageBranchAttributeShape ¶
func (stage *Stage) StageBranchAttributeShape(attributeshape *AttributeShape)
insertion point for stage branch per struct
func (*Stage) StageBranchClassdiagram ¶
func (stage *Stage) StageBranchClassdiagram(classdiagram *Classdiagram)
func (*Stage) StageBranchDiagramPackage ¶
func (stage *Stage) StageBranchDiagramPackage(diagrampackage *DiagramPackage)
func (*Stage) StageBranchGongEnumShape ¶
func (stage *Stage) StageBranchGongEnumShape(gongenumshape *GongEnumShape)
func (*Stage) StageBranchGongEnumValueShape ¶
func (stage *Stage) StageBranchGongEnumValueShape(gongenumvalueshape *GongEnumValueShape)
func (*Stage) StageBranchGongNoteLinkShape ¶
func (stage *Stage) StageBranchGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape)
func (*Stage) StageBranchGongNoteShape ¶
func (stage *Stage) StageBranchGongNoteShape(gongnoteshape *GongNoteShape)
func (*Stage) StageBranchGongStructShape ¶
func (stage *Stage) StageBranchGongStructShape(gongstructshape *GongStructShape)
func (*Stage) StageBranchLinkShape ¶
func (*Stage) UnstageBranchAttributeShape ¶
func (stage *Stage) UnstageBranchAttributeShape(attributeshape *AttributeShape)
insertion point for unstage branch per struct
func (*Stage) UnstageBranchClassdiagram ¶
func (stage *Stage) UnstageBranchClassdiagram(classdiagram *Classdiagram)
func (*Stage) UnstageBranchDiagramPackage ¶
func (stage *Stage) UnstageBranchDiagramPackage(diagrampackage *DiagramPackage)
func (*Stage) UnstageBranchGongEnumShape ¶
func (stage *Stage) UnstageBranchGongEnumShape(gongenumshape *GongEnumShape)
func (*Stage) UnstageBranchGongEnumValueShape ¶
func (stage *Stage) UnstageBranchGongEnumValueShape(gongenumvalueshape *GongEnumValueShape)
func (*Stage) UnstageBranchGongNoteLinkShape ¶
func (stage *Stage) UnstageBranchGongNoteLinkShape(gongnotelinkshape *GongNoteLinkShape)
func (*Stage) UnstageBranchGongNoteShape ¶
func (stage *Stage) UnstageBranchGongNoteShape(gongnoteshape *GongNoteShape)
func (*Stage) UnstageBranchGongStructShape ¶
func (stage *Stage) UnstageBranchGongStructShape(gongstructshape *GongStructShape)
func (*Stage) UnstageBranchLinkShape ¶
type Stager ¶
type Stager struct {
// contains filtered or unexported fields
}
func (*Stager) UpdateAndCommitSVGStage ¶
func (stager *Stager) UpdateAndCommitSVGStage()
func (*Stager) UpdateAndCommitTreeStage ¶
func (stager *Stager) UpdateAndCommitTreeStage()
func (*Stager) UpdateSVGStage ¶
func (stager *Stager) UpdateSVGStage()
type Tabulator ¶
type Tabulator interface { AddSheet(sheetName string) AddRow(sheetName string) int AddCell(sheetName string, rowId, columnIndex int, value string) }
Tabulator is an interface for writing to a table strings
type TreeNames ¶
type TreeNames string
TreeNames are the names of the tree used in the front using an enum allows the compile-time consistency of the tree names between the front and the back
func (TreeNames) CodeValues ¶
func (*TreeNames) FromCodeString ¶
func (*TreeNames) FromString ¶
func (*TreeNames) ToCodeString ¶
Source Files
¶
- anchored_text_impl_link_field_name.go
- anchored_text_impl_link_source_mulitplicity.go
- anchored_text_impl_link_target_mulitplicity.go
- attribute_field_proxy.go
- attribute_shape.go
- button_new_classdiagram_proxy.go
- classdiagram.go
- classdiagram_button_proxy.go
- classdiagram_get_set_of_model_element.go
- classdiagram_gong_enums_node_proxy.go
- classdiagram_gong_notes_node_proxy.go
- classdiagram_gong_structs_node_proxy.go
- classdiagram_node_proxy.go
- contains.go
- diagram_package.go
- doc_svg_mapper.go
- docs.go
- gong_enum_node_proxy.go
- gong_enum_shape.go
- gong_enum_value_node_proxy.go
- gong_enum_value_shape.go
- gong_note_link_shape.go
- gong_note_node_proxy.go
- gong_note_shape.go
- gong_struct_node_proxy.go
- gong_struct_shape.go
- identifiers_functions.go
- link_field_node_proxy.go
- link_shape.go
- multiplicity_type.go
- note_on_gongdoc.go
- note_shape_link_type.go
- orientation_type_enum.go
- rect_impl_gongenum_shape.go
- rect_impl_gongstruct_shape.go
- rect_impl_link.go
- rect_impl_note_shape.go
- remove.go
- setup_map_doclink_renaming.go
- stager.go
- stager_update_and_commit_svg.go
- stager_update_and_commit_tree_stage.go
- tree_names_enum.go
- zzz_gong.go
- zzz_gong_ast.go
- zzz_gong_callbacks.go
- zzz_gong_enum.go
- zzz_gong_graph.go
- zzz_gong_marshall.go
- zzz_gong_orchestrator.go
- zzz_gong_reverse.go
- zzz_gong_serialize.go
- zzz_gong_slices.go
- zzz_gong_wop.go