Examples of XFormDialogBuilder


Examples of com.eviware.x.form.XFormDialogBuilder

  protected XFormDialog buildDialog( final AbstractInterface<?> iface )
  {
    if( iface == null )
      return null;

    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Add JMS endpoint" );

    mainForm = builder.createForm( "Basic" );
    mainForm.addTextField( HERMES_CONFIG, "choose folder where hermes-config.xml is", XForm.FieldType.FOLDER )
        .addFormFieldListener( new XFormFieldListener()
        {
          public void valueChanged( XFormField sourceField, String newValue, String oldValue )
          {
            if( !"".equals( newValue ) )
            {
              Hermes hermes = null;
              try
              {
                Context ctx = getHermesContext( iface, newValue );
                iface.getProject().setHermesConfig( newValue );
                String[] sessions = getSessionOptions( iface, newValue );
                mainForm.setOptions( SESSION, sessions );
                if( sessions != null && sessions.length > 0 )
                {
                  hermes = ( Hermes )ctx.lookup( sessions[0] );
                }
              }
              catch( Exception e )
              {
                SoapUI.logError( e );
              }
              if( hermes != null )
              {
                updateDestinations( hermes );
              }
              else
              {
                mainForm.setOptions( SESSION, new String[] {} );
                mainForm.setOptions( SEND, new String[] {} );
                mainForm.setOptions( RECEIVE, new String[] {} );
              }
            }
          }
        } );
    mainForm.addComboBox( SESSION, new String[] {}, "Session name from HermesJMS" ).addFormFieldListener(
        new XFormFieldListener()
        {

          public void valueChanged( XFormField sourceField, String newValue, String oldValue )
          {
            String hermesConfigPath = mainForm.getComponent( HERMES_CONFIG ).getValue();

            Hermes hermes = null;
            try
            {
              Context ctx = getHermesContext( iface, hermesConfigPath );
              hermes = ( Hermes )ctx.lookup( newValue );
            }
            catch( Exception e )
            {
              SoapUI.logError( e );
            }
            if( hermes != null )
            {
              updateDestinations( hermes );
            }
            else
            {
              mainForm.setOptions( SEND, new String[] {} );
              mainForm.setOptions( RECEIVE, new String[] {} );
            }
          }

        } );
    mainForm.addComboBox( SEND, new String[] {}, "Queue/Topic  sending/publishing" );
    mainForm.addComboBox( RECEIVE, new String[] {}, "Queue/Topic  receive/subscribe" );

    return builder.buildDialog( builder.buildOkCancelActions(), "create JMS endpoint by selecting proper values",
        null );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    for( Interface iface : ModelSupport.getChildren( project, WsdlInterface.class ) )
    {
      endpoints.addAll( iface.getEndpoints() );
    }

    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Launch LoadTestRunner" );
    generalForm = builder.createForm( "General" );

    dialog.setIntValue( LaunchForm.PORT, ( int )settings.getLong( LaunchForm.PORT, 8081 ) );
    dialog.setOptions( LaunchForm.REQUEST_WSS,
        StringUtils.merge( project.getWssContainer().getIncomingWssNames(), "<none>" ) );
    dialog.setOptions( LaunchForm.RESPONSE_WSS,
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

  protected XFormDialog buildDialog( WsdlProject modelItem )
  {
    if( modelItem == null )
      return null;

    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Launch Security TestRunner" );

    mainForm = builder.createForm( "Basic" );
    mainForm.addComboBox( TESTSUITE, new String[] {}, "The TestSuite to run" ).addFormFieldListener(
        new XFormFieldListener()
        {

          public void valueChanged( XFormField sourceField, String newValue, String oldValue )
          {
            List<String> testCases = new ArrayList<String>();
            String tc = mainForm.getComponentValue( TESTCASE );

            if( newValue.equals( ALL_VALUE ) )
            {
              for( TestSuite testSuite : testSuites )
              {
                for( TestCase testCase : testSuite.getTestCaseList() )
                {
                  if( !testCases.contains( testCase.getName() ) )
                    testCases.add( testCase.getName() );
                }
              }
            }
            else
            {
              TestSuite testSuite = getModelItem().getTestSuiteByName( newValue );
              if( testSuite != null )
                testCases.addAll( Arrays.asList( ModelSupport.getNames( testSuite.getTestCaseList() ) ) );
            }

            testCases.add( 0, ALL_VALUE );
            mainForm.setOptions( TESTCASE, testCases.toArray() );

            if( testCases.contains( tc ) )
            {
              mainForm.getFormField( TESTCASE ).setValue( tc );
            }
          }
        } );

    mainForm.addComboBox( TESTCASE, new String[] {}, "TestCase" ).addFormFieldListener( new XFormFieldListener()
    {

      public void valueChanged( XFormField sourceField, String newValue, String oldValue )
      {
        List<String> securityTests = new ArrayList<String>();
        String st = mainForm.getComponentValue( SECURITY_TEST_NAME );

        if( newValue.equals( ALL_VALUE ) )
        {
          for( TestSuite testSuite : testSuites )
          {
            for( TestCase testCase : testSuite.getTestCaseList() )
            {
              for( SecurityTest securityTest : testCase.getSecurityTestList() )
              {
                if( !securityTests.contains( securityTest.getName() ) )
                  securityTests.add( securityTest.getName() );
              }
            }
          }
        }
        else
        {
          TestCase testCase = null;
          try
          {
            testCase = getModelItem().getTestSuiteByName( mainForm.getComponentValue( TESTSUITE ) )
                .getTestCaseByName( mainForm.getComponentValue( TESTCASE ) );
          }
          catch( NullPointerException npe )
          {
          }
          if( testCase != null )
            securityTests.addAll( Arrays.asList( ModelSupport.getNames( testCase.getSecurityTestList() ) ) );
        }

        securityTests.add( 0, ALL_VALUE );
        mainForm.setOptions( SECURITY_TEST_NAME, securityTests.toArray() );

        if( securityTests.contains( st ) )
        {
          mainForm.getFormField( SECURITY_TEST_NAME ).setValue( st );
        }
      }
    } );

    mainForm.addComboBox( SECURITY_TEST_NAME, new String[] {}, "The Security Test to run" );
    mainForm.addCheckBox( SAVEPROJECT, "Saves project before running" ).setEnabled( !modelItem.isRemote() );
    mainForm.addSeparator();
    mainForm.addTextField( TESTRUNNERPATH, "Folder containing SecurityTestRunner.bat to use", XForm.FieldType.FOLDER );

    setToolsSettingsAction( null );
    buildArgsForm( builder, false, "TestRunner" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.TESTRUNNER_HELP_URL, modelItem ),
        "Specify arguments for launching soapUI Security TestRunner", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    super( "Apache CXF", "Generates Apache CXF code using the wsdl2java utility" );
  }

  protected XFormDialog buildDialog( Interface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Apache CXF Stubs" );

    XForm mainForm = builder.createForm( "Basic" );
    addWSDLFields( mainForm, modelItem );

    mainForm.addTextField( OUTPUT, "Root directory for all emitted files.", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( PACKAGE, "Default Package for generated classes", XForm.FieldType.JAVA_PACKAGE );
    mainForm.addNameSpaceTable( NAMESPACE_MAPPING, modelItem );

    mainForm.addCheckBox( CLIENT_STUBS, "Generates starting point code for a client mainline" );
    mainForm.addCheckBox( SERVER_STUBS, "Generates starting point code for a server mainline" );
    mainForm.addCheckBox( IMPL_STUBS, "Generates starting point code for an implementation object" );
    mainForm.addCheckBox( ANT_FILE, "Generates the Ant build.xml file" );
    mainForm.addCheckBox( GENERATE_ALL,
        "<html>Generates all starting point code: types, <br>service proxy, service interface, server mainline, "
            + "<br>client mainline, implementation object, and an Ant build.xml file</html>" );

    XForm advForm = builder.createForm( "Advanced" );

    advForm.addTextField( BINDING_FILES, "Space-separated list of JAXWS or JAXB binding files", XForm.FieldType.TEXT );
    advForm.addCheckBox( COMPILE, "Compiles generated Java files" );
    advForm.addTextField( CLASSDIR, "The directory into which the compiled class files are written",
        XForm.FieldType.FOLDER );

    advForm.addTextField( CATALOG_FILE, "The catalog file to map the imported wsdl/schema", XForm.FieldType.FILE );

    advForm.addNameSpaceTable( EXCLUDE_NAMESPACES, modelItem );
    advForm.addCheckBox( EXSH, "Enables processing of extended soap header message binding" );
    advForm.addCheckBox( DNS, "Enables loading of the default namespace package name mapping" );
    advForm.addCheckBox( DEX, "Enables loading of the default excludes namespace mapping" );
    advForm.addCheckBox( VALIDATE, "Enables validating the WSDL before generating the code" );

    buildArgsForm( builder, true, "wsdl2java" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.CXFWSDL2JAVA_HELP_URL, modelItem ),
        "Specify arguments for Apache CXF wsdl2java", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    return values;
  }

  protected XFormDialog buildDialog( Interface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "XmlBeans Classes" );

    XForm mainForm = builder.createForm( "Basic" );
    addWSDLFields( mainForm, modelItem );

    mainForm.addTextField( XSBTARGET, "Target directory for CLASS and XSB files", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( SRCTARGET, "Target directory for generated JAVA files", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( JARFILE, "The name of the output JAR that will contain the result of compilation",
        XForm.FieldType.PROJECT_FILE );

    mainForm.addCheckBox( SRCONLY, "(Do not compile JAVA files or jar the output)" );
    mainForm.addCheckBox( DOWNLOADS, "(Permit network downloads for imports and includes)" );
    mainForm.addCheckBox( NOUPA, "(Do not enforce the unique particle attribution rule)" );
    mainForm.addCheckBox( NOPVR, "(Do not enforce the particle valid (restriction) rule)" );
    mainForm.addCheckBox( NOANN, "(Ignore annotations)" );
    mainForm.addCheckBox( NOVDOC, "(Do not validate contents of <documentation> elements)" );
    mainForm.addCheckBox( DEBUG, "(Compile with debug symbols)" );

    mainForm.addComboBox( JAVASOURCE, new String[] { "1.5", "1.4" },
        "Generate Java source compatible for the specified Java version" );

    mainForm.addTextField( ALLOWMDEF,
        "Ignore multiple defs in given namespaces. Use  ##local  to specify the no-namespace in that list",
        XForm.FieldType.TEXT );
    mainForm.addTextField( CATALOG, "Catalog file to use for resolving external entities",
        XForm.FieldType.PROJECT_FILE );
    mainForm.addTextField( XSDCONFIG, "Path to .xsdconfig file containing type-mapping information",
        XForm.FieldType.PROJECT_FILE );

    mainForm.addCheckBox( VERBOSE, "(Print more informational messages)" );

    buildArgsForm( builder, false, "scomp" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.XMLBEANS_HELP_URL, modelItem ),
        "Specify arguments for XmlBeans 2.X scomp", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    return values;
  }

  protected XFormDialog buildDialog( Interface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "JAXB Artifacts" );

    XForm mainForm = builder.createForm( "Basic" );
    addWSDLFields( mainForm, modelItem );

    mainForm.addTextField( OUTPUT, "generated files will go into this directory", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( PACKAGE, "the target package", XForm.FieldType.JAVA_PACKAGE );

    mainForm.addTextField( BINDINGS, "external bindings file(s), comma-separated", XForm.FieldType.PROJECT_FILE );
    mainForm.addTextField( CATALOG, "catalog files to resolve external entity references",
        XForm.FieldType.PROJECT_FILE );
    mainForm.addTextField( CLASSPATH, "where to find user class files", XForm.FieldType.PROJECT_FOLDER );

    mainForm.addTextField( HTTPPROXY, "set HTTP/HTTPS proxy. Format is [user[:password]@]proxyHost[:proxyPort]",
        XForm.FieldType.TEXT );
    mainForm.addCheckBox( READONLY, "(generated files will be in read-only mode)" );
    mainForm.addCheckBox( NOVALIDATION, "(do not resolve strict validation of the input schema(s))" );
    mainForm.addCheckBox( NPA, "(suppress generation of package level annotations (**/package-info.java))" );

    mainForm.addCheckBox( VERBOSE, "(be extra verbose)" );

    buildArgsForm( builder, false, "xjc" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.JABXJC_HELP_URL, modelItem ),
        "Specify arguments for the JAXB 2 xjc compiler", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    return values;
  }

  protected XFormDialog buildDialog( Interface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( ".NET 2.0 artifacts" );

    XForm mainForm = builder.createForm( "Basic" );
    addWSDLFields( mainForm, modelItem );

    mainForm.addTextField( OUTPUT, "root directory for generated files.", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( NAMESPACE, "The namespace for the generated proxy or template", XForm.FieldType.TEXT );

    mainForm.addCheckBox( SERVER, "(Generates interfaces for server-side implementation of an ASP.Net Web Service)" );
    mainForm.addComboBox( LANGUAGE, new String[] { "CS", "VB", "JS", "VJS", "CPP" }, "add scope to deploy.wsdd" );

    mainForm.addComboBox( PROTOCOL, new String[] { "SOAP", "SOAP12", "HttpGet", "HttpPost" },
        "override the default protocol to implement" );

    XForm advForm = builder.createForm( "Advanced" );

    advForm.addCheckBox( SHARETYPES, "(turns on type sharing feature)" );
    advForm.addCheckBox( FIELDS, "(generate fields instead of properties)" );
    advForm.addCheckBox( ORDER, "(generate explicit order identifiers on particle members)" );
    advForm.addCheckBox( ENABLEDATABINDING, "(implement INotifyPropertyChanged interface on all generated types)" );
    advForm.addTextField( URLKEY, "configuration key to use in the code generation to read the default URL value",
        XForm.FieldType.URL );
    advForm.addTextField( BASEURL, "base url to use when calculating the url fragment", XForm.FieldType.URL );

    XForm httpForm = builder.createForm( "HTTP settings" );
    httpForm.addTextField( USERNAME, "username to access the WSDL-URI", XForm.FieldType.TEXT );
    httpForm.addTextField( PASSWORD, "password to access the WSDL-URI", XForm.FieldType.PASSWORD );
    httpForm.addTextField( DOMAIN, "domain to access the WSDL-URI", XForm.FieldType.TEXT );
    httpForm.addTextField( PROXY, "username to access the WSDL-URI", XForm.FieldType.TEXT );
    httpForm.addTextField( PROXYUSERNAME, "proxy username to access the WSDL-URI", XForm.FieldType.TEXT );
    httpForm.addTextField( PROXYPASSWORD, "proxy password to access the WSDL-URI", XForm.FieldType.PASSWORD );
    httpForm.addTextField( PROXYDOMAIN, "proxy domain to access the WSDL-URI", XForm.FieldType.TEXT );

    buildArgsForm( builder, false, "wsdl.exe" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.DOTNET_HELP_URL, modelItem ),
        "Specify arguments for .NET 2 wsdl.exe", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    super( "Regenerate with JBossWS", "Regenerates WSDL with the jbossws wstools utility" );
  }

  protected XFormDialog buildDialog( WsdlInterface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Regenerate JBossWS WSDL Artifacts" );

    XForm mainForm = builder.createForm( "Basic" );

    mainForm.addTextField( ENDPOINT, "Serice Endpoint Interface", XForm.FieldType.JAVA_CLASS );
    mainForm.addTextField( SERVICE_NAME, "The name of the generated Service", XForm.FieldType.TEXT );
    mainForm
        .addComboBox( STYLE, new String[] { Style.DOCUMENT.toString(), Style.RPC.toString() }, "The style to use" );
    mainForm.addComboBox( PARAMETER_STYLE,
        new String[] { ParameterStyle.BARE.toString(), ParameterStyle.WRAPPED.toString() }, "The style to use" );
    mainForm.addTextField( CLASSPATH, "Classpath to use", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( OUTPUT, "The root directory for all emitted files.", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( MAPPING, "mapping file to generate", XForm.FieldType.PROJECT_FILE );
    mainForm.addTextField( TARGET_NAMESPACE, "The target namespace for the generated WSDL", XForm.FieldType.TEXT );
    mainForm.addTextField( TYPES_NAMESPACE, "The namespace for the generated types", XForm.FieldType.TEXT );
    mainForm.addTextField( EJB_LINK, "The name of the source EJB to link to", XForm.FieldType.TEXT );
    mainForm.addTextField( SERVLET_LINK, "The name of the source Servlet to link to", XForm.FieldType.TEXT );

    buildArgsForm( builder, false, "wstools" );

    ActionList actions = buildDefaultActions( HelpUrls.WSTOOLS_HELP_URL, modelItem );
    actions.addAction( new ShowConfigFileAction( "JBossWS Wsdl2Java", "Contents of generated wsconfig.xml file" )
    {
      protected String getConfigFile()
      {
        ConfigurationDocument configDocument = createConfigFile( getDialog().getValues() );
        return configDocument.toString();
      }
    } );

    return builder.buildDialog( actions, "Specify arguments for JBossWS wstools java2wsdl functionality",
        UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    if( modelItem == null )
      return null;

    proVersion = isProVersion( modelItem );

    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "Launch SecurityTestRunner" );
    createTestCaseRunnerTabs( modelItem, builder );

    // TODO: update help URL
    return builder.buildDialog( buildDefaultActions( HelpUrls.TESTRUNNER_HELP_URL, modelItem ),
        "Specify arguments for launching soapUI Security TestRunner", UISupport.TOOL_ICON );
  }
View Full Code Here

Examples of com.eviware.x.form.XFormDialogBuilder

    super( "JAX-WS Artifacts", "Generates JAX-WS artifacts using wsimport" );
  }

  protected XFormDialog buildDialog( Interface modelItem )
  {
    XFormDialogBuilder builder = XFormFactory.createDialogBuilder( "JAX-WS Artifacts" );

    XForm mainForm = builder.createForm( "Basic" );
    addWSDLFields( mainForm, modelItem );

    mainForm.addTextField( OUTPUT, "target directory for generated files.", XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( PACKAGE, "target package nam", XForm.FieldType.JAVA_PACKAGE );
    mainForm.addTextField( SOURCE_OUTPUT, "target directory for generated source files",
        XForm.FieldType.PROJECT_FOLDER );
    mainForm.addTextField( HTTPPROXY, "HTTP Proxy-server", XForm.FieldType.TEXT );
    mainForm.addTextField( CATALOG, "catalog file to resolve external entity references",
        XForm.FieldType.PROJECT_FILE );
    mainForm.addTextField( BINDING_FILES, "comma-separated list of external JAX-WS or JAXB binding files",
        XForm.FieldType.TEXT );
    mainForm.addTextField( WSDLLOCATION, "@WebService.wsdlLocation and @WebServiceClient.wsdlLocation value",
        XForm.FieldType.TEXT );

    mainForm.addCheckBox( KEEP, "(keep generated files)" );

    buildArgsForm( builder, false, "WSImport" );

    return builder.buildDialog( buildDefaultActions( HelpUrls.WSIMPORT_HELP_URL, modelItem ),
        "Specify arguments for JWSDP/JAX-WS wsimport", UISupport.TOOL_ICON );
  }
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.