Examples of IModel


Examples of org.apache.wicket.model.IModel

* Displays a message suggesting the user to login or to elevate his privileges
*/
public class GeoServerErrorPage extends GeoServerBasePage {

    public GeoServerErrorPage(Page originatingPage, Throwable error) {
        IModel notice = null, errorText = new Model("");
       
        boolean trace = false;
        if (getSession().getAuthentication() != null &&
            getSession().getAuthentication().isAuthenticated())
        {
View Full Code Here

Examples of org.apache.wicket.model.IModel

                    error(e);
                }
            }
        });

        IModel gsApp = new GeoServerApplicationModel();

        // controls whether wicket paths are being generated
        final AjaxCheckBox wicketPaths = new AjaxCheckBox("wicketPaths",
                new PropertyModel(gsApp, "debugSettings.outputComponentPath")) {
View Full Code Here

Examples of org.apache.wicket.model.IModel

* Displays a message suggesting the user to login or to elevate his privileges
*/
public class UnauthorizedPage extends GeoServerBasePage {

    public UnauthorizedPage() {
        IModel model = null;
        if(getSession().getAuthentication() == null || !getSession().getAuthentication().isAuthenticated())
            model = new ResourceModel( "UnauthorizedPage.loginRequired" );
        else
            model = new ResourceModel( "UnauthorizedPage.insufficientPrivileges" );
        add(new Label("unauthorizedMessage", model));
View Full Code Here

Examples of org.jamesii.core.model.IModel

    modelInterfaces = supportedModelInterfaces;
  }

  @Override
  public boolean appliesTo(ParameterBlock parameters) {
    IModel model = ModelFeatureExtractor.getModelRuntime(parameters);
    for (Class<? extends IModel> supportedInterface : modelInterfaces) {
      if (supportedInterface.isAssignableFrom(model.getClass())) {
        return true;
      }
    }
    return false;
  }
View Full Code Here

Examples of org.resmedicinae.application.healthcare.resdata.model.IModel

        }

        else if (action.equalsIgnoreCase("DoctorLogin")) {

            //check of the correkt login
            IModel myModelLogin  = getModel( param, loginmodel_param );
            IModel myModelDoctor = getModel( param, doctormodel_param );

            myModelLogin.run( param );
            if ( myModelLogin.getModelstatus() == Model.DOCTOR_LOGIN_SUCCESSFULL ) {

                param.putAll( myModelLogin.getModelData() );
                myModelDoctor.run( param );
                page = "ResDataDoctor.jsp";
            }

            else if ( myModelLogin.getModelstatus() == Model.DOCTOR_LOGIN_UNSUCCESSFULL ) {

                //Errorpage for incorrekt Login
                page = "ResDataLoginDoctorIncorrect.jsp";
            }

            else if ( myModelLogin.getModelstatus() == Model.DOCTOR_LOGIN_REQUIRED ) {

                //Loginpage for Doctor
                page = "ResDataLoginDoctor.jsp";
            }

            else {

                //no useful modelstatus
                page = "no_modelstatus.jsp";
            }
        }

        else if (action.equalsIgnoreCase("AdminLogin")) {

            //check of the correkt login
            IModel myModelLogin  = getModel( param, loginmodel_param );
            IModel myModelDoctor = getModel( param, doctormodel_param );
            IModel myModelDate   = getModel( param, datemodel_param );

            myModelLogin.run( param );
            if ( myModelLogin.getModelstatus() == Model.ADMIN_LOGIN_SUCCESSFULL ) {

        myModelDate.run(param);

                param.putAll( myModelLogin.getModelData() );
                myModelDoctor.run( param );
                page = "ResDataAdmin.jsp";
            }

            else if ( myModelLogin.getModelstatus() == Model.ADMIN_LOGIN_UNSUCCESSFULL ) {

                page = "ResDataLoginAdminIncorrect.jsp";
            }

            else if ( myModelLogin.getModelstatus() == Model.ADMIN_LOGIN_REQUIRED ) {

                page = "ResDataLoginAdmin.jsp";
            }

            else {

                //no useful modelstatus
                page = "no_modelstatus.jsp";
            }
        }

        else if (action.equalsIgnoreCase("DoctorSave")) {

            //check of the correkt login
            IModel myModel = getModel( param, doctormodel_param );

            myModel.run( param );

            if  (myModel.getModelstatus() == Model.DOCTOR_SAVE_SUCCESSFULL ) {

                page = "ResDataDoctorSaveOK.jsp";
            }

            else if  (myModel.getModelstatus() == Model.DOCTOR_SAVE_UNSUCCESSFULL ) {

                page = "ResDataDoctorSaveFailed.jsp";
            }

            else {

                //no useful modelstatus
                page = "no_modelstatus.jsp";
            }

        }

        else if (action.equalsIgnoreCase("AdminDoctorSave")) {

            //check of the correkt login
            IModel myModel = getModel( param, doctormodel_param );

            myModel.run( param );

            if  (myModel.getModelstatus() == Model.DOCTOR_SAVE_SUCCESSFULL ) {

                page = "ResDataAdminSaveOK.jsp";
            }

            else if  (myModel.getModelstatus() == Model.DOCTOR_SAVE_UNSUCCESSFULL ) {

                page = "ResDataAdminSaveFailed.jsp";
            }

            else if  (myModel.getModelstatus() == Model.DOCTOR_SAVE_PWD_NOT_CONFIRM ) {

                page = "ResDataAdminSaveFailed.jsp";
            }
            else {

                //no useful modelstatus
                page = "no_modelstatus.jsp";
            }

        }

        else if (action.equalsIgnoreCase("DoctorList")) {

            page = "ResDataDoctorList.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorListAll")) {

            IModel myModelDate = getModel( param, datemodel_param );
           
            myModelDate.run( param );
     
            page = "ResDataDoctorList.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorSearch")) {
         
            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );
           
            page = "ResDataDoctorList.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDateOverview")) {

            IModel myModelDoctor = getModel( param, doctormodel_param );

            myModelDoctor.run( param );

            IModel myModelDate = getModel( param, datemodel_param );

            myModelDate.run( param );

            page = "ResDataDate.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDatePred")) {

            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );

            page = "ResDataDate.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDateNext")) {

            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );

            page = "ResDataDate.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDateDesired")) {

            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );

            page = "ResDataDateDesired.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorSendMailDesired")) {

            IModel myModel = getModel( param, mailmodel_param );

            myModel.run( param );

            if ( myModel.getModelstatus() == Model.MAIL_SEND_SUCCESSFULL ) {

                //the Mail was send successfull
                //now you must a index in the table
                myModel = getModel( param, datemodel_param );
                myModel.run( param );
   
                page = "ResDataDate.jsp";
            }
            else if ( myModel.getModelstatus() == Model.MAIL_SEND_UNSUCCESSFULL ) {
             
                page = "ResDataMailNoSend.jsp";
            }
            else {
               
                //
                page = "no_status.jsp";
            }

        }
/*
        else if (action.equalsIgnoreCase("DoctorSendMailConfirm")) {

            IModel myModel = getModel( param, mailmodel_param );

            myModel.run( param );

            if ( myModel.getModelstatus() == Model.MAIL_SEND_SUCCESSFULL ) {

                //the Mail was send successfull
                //now you must ein Index in the table
                myModel = getModel( param, datemodel_param );
                myModel.run( param );
            }

            page = "ResDataDateConfirmList.jsp";
        }
*/
        else if ( (action.equalsIgnoreCase("DoctorSendMailCancel")) ||
               (action.equalsIgnoreCase("DoctorSendMailConfirm")) ) {

            IModel myModel = getModel( param, mailmodel_param );

            myModel.run( param );

            if ( myModel.getModelstatus() == Model.MAIL_SEND_SUCCESSFULL ) {


              myModel = getModel( param, doctormodel_param );
 
              myModel.run( param );
 
              param.putAll( myModel.getModelData() );
 
              myModel = getModel( param, datemodel_param );
 
              myModel.run( param );
             
              if ( myModel.getModelstatus() == Model.DOCTOR_NO_CONFIRM_LIST ) {    
 
                  page = "ResDataDateNoConfirmList.jsp";
              }
              else {
                  page = "ResDataDateConfirmList.jsp";
              }
            }
            else if ( myModel.getModelstatus() == Model.MAIL_SEND_UNSUCCESSFULL ) {

              page = "ResDataMailNoSend.jsp";
            }
            else {
             
              page = "no_modelstatus.jsp";
            }
          
        }

        else if (action.equalsIgnoreCase("DoctorDateConfirmList")) {

            IModel myModel = getModel( param, doctormodel_param );

            myModel.run( param );

            param.putAll( myModel.getModelData() );

            myModel = getModel( param, datemodel_param );

            myModel.run( param );
           
            if ( myModel.getModelstatus() == Model.DOCTOR_NO_CONFIRM_LIST ) {    

                page = "ResDataDateNoConfirmList.jsp";
            }
            else {
                page = "ResDataDateConfirmList.jsp";
            }
        }

        else if (action.equalsIgnoreCase("DoctorDateConfirm")) {

            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );

            page = "ResDataDateConfirm.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDateCancel")) {

            IModel myModel = getModel( param, datemodel_param );

            myModel.run( param );

            page = "ResDataDateCancel.jsp";
        }

        else if (action.equalsIgnoreCase("DoctorDateDelete")) {

            IModel myModel = getModel( param, doctormodel_param );

            myModel.run( param );

            param.putAll( myModel.getModelData() );

            myModel = getModel( param, datemodel_param );

            myModel.run( param );

            if ( myModel.getModelstatus() == Model.DOCTOR_NO_CONFIRM_LIST ) {    

                page = "ResDataDateNoConfirmList.jsp";
            }
            else {
                page = "ResDataDateConfirmList.jsp";
            }
        }

        else if (action.equalsIgnoreCase("AdminNewDoc")) {

            IModel myModel = getModel( param, doctormodel_param );
           
            myModel.run( param );

            page = "ResDataAdminDoctor.jsp";
        }

        else if (action.equalsIgnoreCase("AdminEditDoc")) {

            IModel myModel = getModel( param, doctormodel_param );
           
            myModel.run( param );

            page = "ResDataAdminDoctor.jsp";
        }

        else if (action.equalsIgnoreCase("AdminDeleteDoc")) {

            IModel myModel = getModel( param, doctormodel_param );
           
            myModel.run( param );

            page = "ResDataAdmin.jsp";
        }
        else {

View Full Code Here

Examples of sg.edu.nus.comp.simTL.engine.IModel

      throw new ValidationException("FirstCall in statement ("+caller+") is null!");
    }
    callSoFar.append(caller);
    callSoFar.append("."+loadAttribute(firstCall, REF_METHODNAME));
    //Check whether caller is a model
    IModel inputModel = template.getInputModel(caller);
    PlaceHolderReturnContainer firstCallPhrc = null;
    if(inputModel!=null){
      //load model
      if(!inputModel.getModelResource().isLoaded()){
        try {
          inputModel.getModelResource().load(Collections.EMPTY_MAP);
        } catch (IOException e) {
          throw new ValidationException("Cannot load InputModel",e);
        }
      }
      //first call needs to interpret model-resource
View Full Code Here

Examples of sg.edu.nus.comp.simTL.engine.IModel

    SimTLEngine engine = new SimTLEngine(
        template,
        URI.createFileURI(new File("output/TV_templateInstance.java").getAbsolutePath()),
        decisionMaker);
    log.info("Ready");
    IModel instance = engine.getTemplateInstance();
    Resource instanceResource = instance.getModelResource();
    EObject javaRoot = instanceResource.getContents().get(0);
    EObject javaClass = javaRoot.eContents().get(0);
    EStructuralFeature memberFeature = javaClass.eClass().getEStructuralFeature("members");
    List<EObject> classMembers = (List<EObject>)javaClass.eGet(memberFeature);
    assert(Util.getElementName(classMembers.get(1)).matches("p1"));
View Full Code Here

Examples of sg.edu.nus.comp.simTL.engine.IModel

    ITemplate template = new TemplateMockup().getTemplateVersion();
    SimTLEngine engine = new SimTLEngine(template,
        URI.createFileURI(new File("output/TV_templateInstance.java").getAbsolutePath()),
        decisionMaker);
    log.info("Ready");
    IModel instance = engine.getTemplateInstance();
    Resource instanceResource = instance.getModelResource();
    EObject javaRoot = instanceResource.getContents().get(0);
    EObject javaClass = javaRoot.eContents().get(0);
    EStructuralFeature memberFeature = javaClass.eClass().getEStructuralFeature("members");
    List<EObject> classMembers = (List<EObject>)javaClass.eGet(memberFeature);
    assert(Util.getElementName(classMembers.get(2)).matches("p2"));
View Full Code Here

Examples of wicket.model.IModel

      ConceptConfig countryLanguageConceptConfig = countryLanguages
          .getConceptConfig();
      String currentLanguage = countryLanguage.getLanguage();
      List languageList = countryLanguages.getLanguageList();

      IModel choiceModel = new Model(currentLanguage);
      DropDownChoice countryLanguageChoice = new CountryLanguageChoice(
          "countryLanguageChoice", choiceModel, languageList);
      add(countryLanguageChoice);
      if (!app.isConceptDisplayAllowed(getAppSession(),
          countryLanguageConceptConfig)) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.