Skip to content

hakandilek/vagabond-uml

 
 

Repository files navigation

npm Build Status Dependencies status devDependency Status

Welcome to Vagabond-UML!

This project is a spin-off from JHipster's UML model which has a main goal to bring support of UML (more precisely, XMI) files (from various editors) to JHipster. Vagabond-UML uses a similar but enhanced model. Scroll down for further information.

We support: Modelio, UML Designer, GenMyModel and Visual Paradigm... and our DSL!

TODO

Here is a brief roadmap

  • Entity model
  • Service model
  • Relation model
  • Annotation model
    • Entity level annotations
    • Use entity level annotations instead of
      • dto
      • pagination definitions
    • Field level annotations
  • XMI support
  • UML Designer

Model Elements

Entities

Entities are used to form the data model

entity Job {
  Long jobId
  String jobTitle
  Long minSalary 
  Long maxSalary
}

In this example a Job entity is defined with 4 attributes:

  • jobId with type Long,
  • jobTitle with type String,
  • minSalary with type Long, and a
  • maxSalary with type Long

Services

Services represent an operational endpoint as in REST endpoints and hold several operations (functions) together.

service Manager {
  void assign(Department department, Employee employee)
  Long countEmployees()
} 

This example defines a Manager service with two functions:

  • void assign(Department department, Employee employee)

    assign method with a return type of void (nothing returned) and two parameters one Department and an Employee

  • Long countEmployees()

countEmployees method returning a Long value with no parameters.

Relations

Relations bind Entities together.

Annotations

Annotations are used to represent special characteristics of Entites or Entity attributes.

@paginate(pagination)
entity Job {
  Long jobId
  String jobTitle
}

In this example Job entity has the @paginate annotation with pagination property.

@dto(mapstruct)
entity JobHistory {
  startDate ZonedDateTime,
  endDate ZonedDateTime
}

In this example @dto annotation is applied on the JobHistory entity with mapstruct property.

Annotations can be combined.

@dto(mapstruct)
@paginate(infinite-scroll)
entity Employee {
  Long employeeId 
  String fullName
}

In this example @dto and @paginate annotations are applied together on the Employee entity.

About

UML support for JHipster

Resources

License

Unknown, Unknown licenses found

Licenses found

Unknown
LICENCE
Unknown
LICENCE.jhipster-uml

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%