Package org.apache.airavata.schemas.gfac

Examples of org.apache.airavata.schemas.gfac.NameValuePairType


      }
      for (int i = 0; i < defaultTableModel.getRowCount(); i++) {
            String parameterName = (String) defaultTableModel.getValueAt(i, 0);
            String paramValue = (String) defaultTableModel.getValueAt(i, 1);
            if (parameterName != null && !parameterName.trim().equals("")) {
              NameValuePairType envType = getShellApplicationDescriptionType().addNewApplicationEnvironment();
            envType.setName(parameterName);
                envType.setValue(paramValue);
            }
        }
    }
View Full Code Here


      }
      for (int i = 0; i < defaultTableModel.getRowCount(); i++) {
            String parameterName = (String) defaultTableModel.getValueAt(i, 0);
            String paramValue = (String) defaultTableModel.getValueAt(i, 1);
            if (parameterName != null && !parameterName.trim().equals("")) {
              NameValuePairType envType = getShellApplicationDescriptionType().addNewApplicationEnvironment();
            envType.setName(parameterName);
                envType.setValue(paramValue);
            }
        }
    }
View Full Code Here

      }
      for (int i = 0; i < defaultTableModel.getRowCount(); i++) {
            String parameterName = (String) defaultTableModel.getValueAt(i, 0);
            String paramValue = (String) defaultTableModel.getValueAt(i, 1);
            if (parameterName != null && !parameterName.trim().equals("")) {
              NameValuePairType envType = getShellApplicationDescriptionType().addNewApplicationEnvironment();
            envType.setName(parameterName);
                envType.setValue(paramValue);
            }
        }
    }
View Full Code Here

      }
      for (int i = 0; i < defaultTableModel.getRowCount(); i++) {
            String parameterName = (String) defaultTableModel.getValueAt(i, 0);
            String paramValue = (String) defaultTableModel.getValueAt(i, 1);
            if (parameterName != null && !parameterName.trim().equals("")) {
              NameValuePairType envType = getShellApplicationDescriptionType().addNewApplicationEnvironment();
            envType.setName(parameterName);
                envType.setValue(paramValue);
            }
        }
      int a=10;
    }
View Full Code Here

        HashMap<String,String> environmentVariables = applicationDescriptor.getEnvironmentVariables();
        if (environmentVariables != null && !environmentVariables.isEmpty()){
            NameValuePairType[] appEnviVariablesArray = new NameValuePairType[environmentVariables.size()];
            for(String key : environmentVariables.keySet()) {
                int i = 0;
                NameValuePairType nameValuePairType = applicationDescription.getType().addNewApplicationEnvironment();
                nameValuePairType.setName(key);
                nameValuePairType.setValue(environmentVariables.get(key));
                appEnviVariablesArray[i] = nameValuePairType;
                i++;
            }
            applicationDescription.getType().setApplicationEnvironmentArray(appEnviVariablesArray);
        }

        //set advanced options according app desc type
        if(applicationDescriptor.getApplicationDescType() != null && !applicationDescriptor.getApplicationDescType().isEmpty()){
            if (applicationDescriptor.getApplicationDescType().equals(ApplicationDescriptorTypes.HPC_APP_DEP_DESC_TYPE)){
                ApplicationDescription appDesc = new ApplicationDescription(HpcApplicationDeploymentType.type);
                appDesc.getType().setApplicationName(name);
                appDesc.getType().setExecutableLocation(applicationDescriptor.getExecutablePath());
                appDesc.getType().setScratchWorkingDirectory(applicationDescriptor.getWorkingDir());

                if (applicationDescriptor.getInputDir() != null){
                    appDesc.getType().setInputDataDirectory(applicationDescriptor.getInputDir());
                }
                if (applicationDescriptor.getOutputDir() != null){
                    appDesc.getType().setOutputDataDirectory(applicationDescriptor.getOutputDir());
                }
                if (applicationDescriptor.getStdIn() != null){
                    appDesc.getType().setStandardInput(applicationDescriptor.getStdIn());
                }
                if (applicationDescriptor.getStdOut() != null){
                    appDesc.getType().setStandardOutput(applicationDescriptor.getStdOut());
                }
                if (applicationDescriptor.getStdError() != null){
                    appDesc.getType().setStandardError(applicationDescriptor.getStdError());
                }
                if (applicationDescriptor.getStaticWorkigDir() != null){
                    appDesc.getType().setStaticWorkingDirectory(applicationDescriptor.getStaticWorkigDir());
                }

                HashMap<String,String> envVariables = applicationDescriptor.getEnvironmentVariables();
                if (envVariables != null && !envVariables.isEmpty()){
                    NameValuePairType[] appEnviVariablesArray = new NameValuePairType[envVariables.size()];
                    for(String key : envVariables.keySet()) {
                        int i = 0;
                        NameValuePairType nameValuePairType = applicationDescription.getType().addNewApplicationEnvironment();
                        nameValuePairType.setName(key);
                        nameValuePairType.setValue(envVariables.get(key));
                        appEnviVariablesArray[i] = nameValuePairType;
                        i++;
                    }
                    appDesc.getType().setApplicationEnvironmentArray(appEnviVariablesArray);
                }
View Full Code Here

TOP

Related Classes of org.apache.airavata.schemas.gfac.NameValuePairType

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.