GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - modernizing/modeling: Modeling 是一个基于代码的领域模型生成工具,支持 Java、Cpp、TypeScript、Golang 等语言。Modeling is a tools to analysis different languages by Ctags

BranchesTags
Open more actions menu

Latest commit

 

History

159 Commits
159 Commits

Folders and files

NameName
Last commit message
Last commit date
.github
.github
 
 
_fixtures
_fixtures
 
 
src
src
 
 
static
static
 
 
.gitignore
.gitignore
 
 
CHANGELOG.md
CHANGELOG.md
 
 
Cargo.toml
Cargo.toml
 
 
Doxyfile
Doxyfile
 
 
LICENSE
LICENSE
 
 
README.md
README.md
 
 
_config.yml
_config.yml
 
 
cliff.toml
cliff.toml
 
 
justfile
justfile
 
 

Repository files navigation

Modeling

crates.io docs.rs license

Modeling is a tools to analysis different languages by Ctags

process:

  1. analysis ctags
    • generate to opt
    • call ctags with opt
    • analysis ctags logs by regex
  2. generate results
  3. visual result with visualing (optional)

language support:

  • Java
  • C#
  • Cpp
  • TypeScript
  • Golang
  • Rust
  • ... others by ctags

Usage

  • modeling, generate model from source code.
  • concepting, generate concepts from source code.
  • visualing, visualization the uml.
Modeling 0.6.2

USAGE:
    modeling [FLAGS] [OPTIONS]

FLAGS:
    -b, --by-modules             multiple modules
    -d, --debug                  output debug information
    -f, --field-only             only load field in methods
    -h, --help                   Prints help information
        --inline-id-suffix       if class's prop end with Id and class in list, will replace `int` type to `xxClass`
    -m, --merge                  merge for same method name
    -V, --version                Prints version information
        --without-impl-suffix    if class's prop start with `IRepository` will become `Repository`
        --without-parent         without class inheritance

OPTIONS:
    -g, --grep <grep>                  by grep regex rules: for example: `.*Service` [default: ]
    -i, --input <input>                input dir [default: .]
    -o, --output-type <output-type>    support: puml, mermaid, graphviz with json [default: puml]
    -p, --packages <packages>...       filter by packages, like: `com.phodal.modeling`
    -s, --suffixes <suffixes>...       filter by suffixes, like: `java` for .java file
    --without-suffix <without-suffix>  remove specify suffix by text, for example `DemoDto` with be `Demo` [default: ]

sample: Grep with MVC

modeling --input=/youpath/ --field-only --without-parent --grep ".*Service|.*Controller|.*Repository"

sample: with Graphviz and Visualization

with --output-type=graphviz

modeling --input=/youpath  --field-only -o graphviz --without-impl-suffix

sample: puml to Image

convert to image: plantuml modeling.puml modeling.svg -tsvg

with Visualization

PS: need to set --output-type graphviz, in order to generate output.json file

modeling -i youpath -o graphviz
visualing

Library

cargo install modeling
modeling .

Library

use modeling::{by_dir};
use modeling::render::PlantUmlRender;

let classes = by_dir("src/");
let puml = PlantUmlRender::render(&classes);

output sample:

@startuml

class Animal {
  + string name
  + string constructor()
  +move()
}

class Horse extends Animal {
  +move()
}

class Snake extends Animal {
  +move()
}

@enduml

License

ctags analysis based on https://github.com/dalance/ptags with MIT, see in src

ctags parser rewrite from Golang's https://github.com/ruben2020/tags2uml with Apache License.

@ 2020~2021 This code is distributed under the MIT license. See LICENSE in this directory.

About

Modeling 是一个基于代码的领域模型生成工具,支持 Java、Cpp、TypeScript、Golang 等语言。Modeling is a tools to analysis different languages by Ctags

inherd.org/modeling/

Topics

ctagsmodel-driven-developmentmodeling

Resources

Readme
License

Contributing

Contributing
Activity
Custom properties

Stars

21 stars

Watchers

5 watching

Forks

4 forks
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.