Skip to content

Instantly share code, notes, and snippets.

@projetnumero9
projetnumero9 / Attribute - replace string.ajs
Last active February 18, 2024 16:35
Search and replace a string for one or many concepts attribute (litteral string or REGEX) #jarchi
//
// Attribute - replace string
//
// (c) 2019 David GERARD
//
// Search and replace a string for one or many concepts attributes (name, documentation)
//
// Roadmap:
// - when using Regex, implement global replacement if multiple occurences
// - when the replacementString is a Regex, some corrections and improvment still needed
@projetnumero9
projetnumero9 / LinkConceptToView.ajs
Created December 9, 2020 20:21
#jArchi Create createViewReference between concept and view, back and forth, to ease navigation
//
// Link concept to View
//
// 2020 David GERARD
//
// For selected concept in view, search the model for a view with the same name.
// If found,
// - create a .createViewReference() positioned in the upperleft corner of the concept, pointing to the view with the same name
// - create a .createViewReference() positioned in the upperleft corner of the view with the same name, point to the view holding the selected concept
// Quite useful to describe process and subprocesses, and especially with the HTML export
@projetnumero9
projetnumero9 / Generate diagram legend.ajs
Created December 9, 2020 18:32
#jArchi Generate a legend for the selected view, based on the concept types currently used
//
// Generate diagram legend
//
// 2020 David GERARD
//
// For a selected view, create a group named 'Legend', in which will be nested for each concepts type found in view
// - a concept, specifically sized to show the pictogram
// - a note, to be used to name or explain the concept specifically in the view, hence preventing to rename the concept
// That way,
// - a model will be a bit polluted but with a specific set of concepts, for legend purpose, prefixed so easily identifiable