Telosys doc
WebsiteTwitterLinkedInNews
  • Telosys documentation
  • Telosys CLI
    • Installation on Linux
    • Installation on Windows
    • CLI configuration
    • CLI commands
    • Getting started
  • Telosys with VSCode
    • Extension installation
    • VSCode settings
    • Telosys terminal in VSCode
    • Telosys editor configuration
  • Telosys with JetBrains IDE
  • Project configuration
  • Project variables
  • Project databases
  • Models and entities
    • Model structure
    • Entity
    • Attribute / Link
    • Annotations
    • Tags
    • Examples
    • Model creation
    • Model installation
    • Models management
  • Bundles of templates
    • Bundle structure
    • Bundle creation
    • Bundles installation
    • Bundles management
    • Velocity language
    • Velocity directives
    • Velocity object types
    • Telosys directives
    • Telosys variables
    • Telosys objects
    • Code snippets
  • Code generation
    • "gen" command
    • "genb" command
  • Target languages
    • C++
    • C#
    • Golang
    • Java
    • JavaScript
    • Kotlin
    • PHP
    • Python
    • Scala
    • TypeScript
  • Target databases (SQL)
    • Predefined rules
    • Specific rules
    • Type size and precision
  • Telosys with Git
    • GitHub usage
    • Install with Git
    • Publish with Git
  • Support the project
  • How to contribute
  • Sponsors
  • IDE and editors
  • Telosys 3 Eclipse plugin
    • Eclipse plugin installation
    • Eclipse customization
    • Telosys 3 database model
Powered by GitBook
On this page
  • "genb" command syntax
  • "genb" command examples
  1. Code generation

"genb" command

"genb" is a special command to generate code in "batch mode" (or "bulk mode") with multiple models and/or multiple bundles. This command has been added in Telosys version 4.1.0

Principle of using entities (.entity) and templates (.vm) for code generation: - All entities present in the selected model(s) are used. - All templates defined in the selected bundle(s) are used.

You don't have to defined the current model and the current bundle before using the genb command (it can work with any models and any bundles)

"genb" command syntax

> genb model(s) bundle(s) [-r] [-y]
  • models: model name or part of name or "*" for all models

  • bundles: bundle name or part of name or "*" for all bundles

  • -r (optional) to copy the static resources provided by the bundle (if any)

  • -y (optional) to force "yes" answer (to avoid confirmation)

"genb" command examples

> genb * *

generates the code for all the models with all the bundles of templates

> genb cars java 

generates the code for all the models having "cars" in their name with all bundles having "java" in their name

Previous"gen" commandNextTarget languages

Last updated 4 months ago