lib/converters/json_to_jdl_option_converter.js
function convertServerOptionsToJDL(config, jdl) {
  const jdlObject = jdl || new JDLObject();
  const jhipsterConfig = config || {};
  [SKIP_CLIENT, SKIP_SERVER, SKIP_USER_MANAGEMENT].forEach(option => {
    if (jhipsterConfig[option] === true) {
      jdlObject.addOption(
        new JDLUnaryOption({
          name: option,
          value: jhipsterConfig[option]
        })
      );
    }
  });
  return jdlObject;
}
function convertServerOptionsToJDL(config, jdl) {
  const jdlObject = jdl || new JDLObject();
  const jhipsterConfig = config || {};
  [SKIP_CLIENT, SKIP_SERVER, SKIP_USER_MANAGEMENT].forEach(option => {
    if (jhipsterConfig[option] === true) {
      jdlObject.addOption(
        new JDLUnaryOption({
          name: option,
          value: jhipsterConfig[option]
        })
      );
    }
  });
  return jdlObject;
}
function convertServerOptionsToJDL ( config , jdl ) { const jdlObject = jdl || new JDLObject ( ) ; const jhipsterConfig = config || { } ; [ SKIP_CLIENT , SKIP_SERVER , SKIP_USER_MANAGEMENT ] . forEach ( option => { if ( jhipsterConfig [ option ] === true ) { jdlObject . addOption ( new JDLUnaryOption ( { name : option , value : jhipsterConfig [ option ] } ) ) ; } } ) ; return jdlObject ; }
Parses the jhipster configuration into JDL.
@param config the jhipster config ('generator-jhipster' in .yo-rc.json)
@param jdl {JDLObject} to which the parsed options are added. If undefined a new JDLObject is created.
@returns {JDLObject} the JDLObject
Parses the jhipster configuration into JDL .