Package de.mhus.lib.form2.definition

Examples of de.mhus.lib.form2.definition.FmDefaultSources


  @ALayoutModel
  public DefRoot createModel() throws MException {
    return new DefRoot(
        new FmInformation()
        ,
        new FmText("user",new FmNls("User","Beschreibung 1"),new FmDefaultSources())
        ,
        new FmPassword("password",new FmNls("Password","Beschreibung 2"),new FmDefaultSources())
        ,
        new FmNumber("number",FmNumber.TYPE.INTEGER,new FmNls("text3","Nr3","Beschreibung 3")).format(FmNumber.FORMAT.CURRENCY)
        ,
        new FmCombobox("sex", new FmNls("Sex","Geschlecht"),new FmDefaultSources())
        ).build();
  }
View Full Code Here


    try {
     
      DefRoot model = new DefRoot(
          new FmInformation()
          ,
          new FmText("user",new FmNls("User","Beschreibung 1"),new FmDefaultSources())
          ,
          new FmPassword("password",new FmNls("Password","Beschreibung 2"),new FmDefaultSources())
          ,
          new FmNumber("number",FmNumber.TYPE.INTEGER,new FmNls("text3","Nr3","Beschreibung 3")).format(FmNumber.FORMAT.CURRENCY)
          ,
          new FmCombobox("sex", new FmNls("Sex","Geschlecht"),new FmDefaultSources())
          ).build();

ConfigUtil.dump(model, System.out);

      MNls nls = model.createNls();
View Full Code Here

      builder.setFormFactory(new LayoutFactory());
     
      MyModel pojo = new MyModel();
      ActivatorControl control = new ActivatorControl();
      control.setFocusManager(new InformationFocus());
      LayoutModelByPojo layout = new LayoutModelByPojo(pojo);
      layout.setFormControl(control);
      layout.setFormFactory(builder.getFormFactory());
      layout.doBuild();
 
     
      builder.setRoot(layout.getModelRoot());
      builder.doBuild();
     
      builder.getRootComposit().setWidth("800px");
      mainWindow.addComponent(builder.getRootComposit());
     
View Full Code Here

//    if (a == null) a = element.getLayoutFactory().getActivator();
    MActivator a = element.getLayoutFactory().getActivator();
   
    String[] va = string.split(",");
    for (String v : va) {
      Validator validator;
      try {
        validator = (Validator) a.getObject(Validator.class,v);
      } catch (Exception e) {
        e.printStackTrace();
        return false;
      }
      if (validator != null && !validator.validate(this,element,value))
        return false;
    }
    return true;
  }
View Full Code Here

TOP

Related Classes of de.mhus.lib.form2.definition.FmDefaultSources

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.