NetBeans style JSplitPane

Hi all,
I would like to create an invisible JSplitPane which the user can select and drag, but doesn't paint a border for the split pane bar.
I have debugged the Swing source code for JSplitPane and figured out the reason I can't hide the split bar is because it's a child component. So when you have a component on the left and right inside the split pane, there is a total of three components including the bar.
I can not find in JSplitPane.java any code which creates and adds this third component as a child.
My idea is to replace this component with a new component which doesn't paint anything for itself.
Any tips or direction would be cool.
Thanks,

I smack my head, cause the solution was right in front of me
public class HiddenSplitPane extends JSplitPane {
     /** Creates a new instance of HiddenSplitPane */
    public HiddenSplitPane(int newOrientation,
                      Component newLeftComponent,
                      Component newRightComponent){
        super(newOrientation, newLeftComponent, newRightComponent);
          setBorder( null );
          javax.swing.plaf.basic.BasicSplitPaneDivider d = (javax.swing.plaf.basic.BasicSplitPaneDivider)getComponent(2);
          d.setBorder( null );
}

Similar Messages

  • Shortcut keys for code completion

    Hi!
    I just wondered what keys are used to make use of the code completion functionality
    (I'm used to MS products where ctrl+space or ctrl+j often is used).
    Thanks, Thomas

    I don't think there is a public document available for planned new 9.0
    features.
    Code reformatting will be in 9.0, and will of course also apply to
    auto-generated code as it's inserted.
    If you have other features you'd like to see, please post them on this
    newsgroup.
    Josh
    Doug Orr wrote:
    Is code reformatting available in 8.1? If not, is it planned for 9.0? Is there
    a resource that describes planned enhancements?
    Josh Eckels <[email protected]> wrote:
    That will be part of version 9.0, but unfortunately is not included in
    8.1.
    Josh
    Richard Hendershot wrote:
    what about Netbeans-style aliases? With that, I type "sout " and the
    editor responds by expanding to System.out.println. I found the help
    about keyboard shortcuts but nothing about aliases, macros or such.help?
    TIA!
    -rsh
    Anurag Pareek wrote:
    Thomas,
    Code completion in Workshop can be done by adding a period (".") in
    front of
    the object variable.
    For example,
    HelloWorld h = new HelloWorld();
    h.
    As soon as you type the '.' in front of 'h'. it shows a dropdown list
    of all
    the public methods exposed in HelloWorld class.
    Regards,
    Anurag
    "Thomas Anderson" <[email protected]> wrote in message
    news:[email protected]..
    Hi!
    I just wondered what keys are used to make use of the code completionfunctionality
    (I'm used to MS products where ctrl+space or ctrl+j often is used).
    Thanks, Thomas

  • Need tech-book style book to learn Netbeans 6.5 with Javafx

    I am having a heck of a time geting started with Netbeans 6.5 JavaFx. Everytime I download code into my IDE I get all types of errors that I can't overcome. I have recently completed a text book course in Java by Lewis and Loftus. The book starts with the basics and work up. Most of the tutorials that I find on JavaFX start with huge amounts of code which is very confusing to people trying to learn this terminology. Can anybody direct me to a tech-book style book on Netbeans 6.5 with JavaFX or is it too early for such a book.

    Any tutorial about JavaFX dated prior to December 8 2008 should be disregarded utterly by a beginner.
    There are significant differences and trying to figure them out from old tutorials is futile!
    Books are coming, search Amazon, there is a title by Weiqi Gao or James Weaver (Jim Weaver).

  • Netbeans JAX-WS and RPC-Style basics to

    I have added a new web service client in NetBeans 6.8 using the JAX-RPC style because I am trying to consume a web service that does not seem to support the JAX-WS style.
    It (the wsimport I guess) generated a few classes like AuthenticationService, AuthenticationServiceSoapPort or AuthenticationService_Impl. So but what now?
    How to consume the service in my plain Java client application now? I searched the internet but can't find a sample. All I find seems that RPC is an old style and samples are only given for the JAX-WS style. But how to use the stuff generated in RPC style?

    Maybe I found something for you at http://java.sun.com/developer/technicalArticles/WebServices/getstartjaxrpc/
    From the client application's perspective, invoking methods on this Web service is similar to that of the model where stubs were generated from the service endpoint interface. The client first invokes the new statement to instantiate a new instance of the xrpcc-generated client service implementation file. Then, the client uses the getSunRegPort method to get a reference to the service's stub. This step is equivalent to getting a reference to a remote interface. Because the endpoint is included in the WSDL file, the xrpcc tool generates stubs preconfigured with the endpoint. These preconfigured stubs mean that the client does not have to set the target endpoint, a step the client had to do when generating stubs from the service endpoint interface. The client can invoke a method on the service through the stub reference obtained from the getSunRegPort method. For example, the client invokes stub.getCourseInfo:
    SunReg_Impl stub = SunRegIF_Stub(new
        SunReg_Impl()).getSunRegIF();
    Course[] courseArray = stub.getCourseInfo();Transform to your example you should code something like this:
    AuthenticationService_Impl stub = AuthenticationServiceIF_Stub(new
        AuthenticationService_Impl()).getAuthenticationServiceIF();
    MyResult result = stub.callMyMethod();Edited by: JBStonehenge on Mar 4, 2010 2:43 PM

  • Running a NetBeans 5.5.1 GUI in Java 1.5?

    Hi everyone, thanks for your interest.
    I've created a GUI in NetBeans 5.5.1 using the Group Layout package, which is included in Java 1.6.
    The only problem is I need this app to run in a Java 1.5 environment.
    I'm not an expert at this but after extensive searching it looks like I can import a .jar file to make everything work again?
    The problem is I add this swing-layout-1.0.jar to my class path but in the source file for my application it refers to these classes by javax.swing.________ and not by the org.whatever that the .jar I took uses. Futhermore, there seem to exist some differences between the classes in the javax.swing and my .jar file.
    Is there ANY way for me to make all this java 1.6 code to run in java 1.5. Perhaps by including some extra package?
    If so, where would I find such a package?
    If you don't think this can be done please let me know so I can stop bashing my head against the wall.
    Thanks,
    Craig

    From this URL
    http://java.sun.com/developer/technicalArticles/tools/nb_guibuilder/
    The Free Design layout has been available since NetBeans IDE 5.0. NetBeans IDE 5.0's GUI Builder provided support for this layout strategy by using a separate library called the Swing Layout Extensions. The IDE provided that library because the support for the underlying GroupLayout layout manager was not yet part of the core Java platform in J2SE 5.0. The Swing Layout Extensions are still available, but now that functionality also exists in the core libraries of the Java SE 6 platform.
    You can use NetBeans IDE 5.5 to develop applications and UIs for Java SE 6 or earlier Java platform versions. If you write applications for any platform version prior to Java SE 6, you must continue to use the Swing Layout Extensions. However, the new GUI builder can also generate your UI using the layout manager functionality supported in the Java SE 6 platform. In the latter case, you do not need to use or include the layout extensions in your final product.
    If you create a new project in NetBeans IDE 5.5 and your target platform is Java SE 6, the GUI builder will automatically generate your UI using the Java SE 6 platform's core libraries. However, if you import an old project into NetBeans IDE 5.5, you should manually update the project's layout to use the new Java SE 6 platform libraries. Of course, you can still use the layout extensions if you like, but doing so is not necessary with the Java SE 6 platform.
    You can change the Layout Generation Style for your UI by accessing the properties for your form. In the NetBeans IDE GUI Builder main window, make sure the Design mode is active. This shows your UI design graphically in the Design pane. Click on the form in the Inspector pane to see the form's properties. One of the properties is Layout Generation Style. You can select either Standard Java 6 Code or Swing Layout Extensions Library. Changing this setting does not affect how your UI will look, but it does change how the GUI builder generates the code to create the UI. Figure 16 shows the Layout Generation Style property.

  • Netbeans creating wsdl file having message with more than one part...

    Hi,
    I am using netbeans 6.0.1. I made an xml schema, then I wanted to make an wsdl that uses that schema.
    I wanted to put in a message more parts(3), and it would not let me. Then, i made the message with just one part, and added the other parts afterwards.
    But now, when I try to make a web service from that wsdl, it says that there is no service in the specified wsdl file.
    And if i let that message with just one part, it will make the Web Service.
    here is the xml schema and the wsdl file:
    XML Schema:
    <?xml version="1.0" encoding="UTF-8"?>
    <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    targetNamespace="http://xml.netbeans.org/schema/Abruf38"
    xmlns:tns="http://xml.netbeans.org/schema/Abruf38"
    elementFormDefault="qualified">
    <xsd:complexType name="FormRequest">
    <xsd:sequence>
    <xsd:element name="newRequest" type="xsd:boolean"/>
    <xsd:element name="requestNumber" type="xsd:int"/>
    <xsd:element name="vehicleClass" type="xsd:string"/>
    <xsd:element name="vehiclesNumber" type="xsd:int"/>
    <xsd:element name="prefferedType" type="xsd:string"/>
    <xsd:element name="kombi" type="xsd:boolean"/>
    <xsd:element name="usageMission" type="xsd:boolean"/>
    <xsd:element name="usageEducation" type="xsd:boolean"/>
    <xsd:element name="usageGeneral" type="xsd:boolean"/>
    <xsd:element name="usageOthers" type="xsd:string"/>
    <xsd:element name="eqVehicle" type="xsd:boolean"/>
    <xsd:element name="eqDangerous" type="xsd:boolean"/>
    <xsd:element name="eqPlaneSpriegel" type="xsd:boolean"/>
    <xsd:element name="eqBegrstll" type="xsd:boolean"/>
    <xsd:element name="eqMSitzBTruck" type="xsd:boolean"/>
    <xsd:element name="eqVerzurrAusst" type="xsd:boolean"/>
    <xsd:element name="eqOthers" type="xsd:string"/>
    <xsd:element name="bringService" type="xsd:boolean"/>
    <xsd:element name="holService" type="xsd:boolean"/>
    <xsd:element name="chauffService" type="xsd:boolean"/>
    <xsd:element name="otherService1" type="xsd:string"/>
    <xsd:element name="otherService1Chk" type="xsd:boolean"/>
    <xsd:element name="otherService2" type="xsd:string"/>
    <xsd:element name="otherService2Chk" type="xsd:boolean"/>
    <xsd:element name="otherService3" type="xsd:string"/>
    <xsd:element name="otherService3Chk" type="xsd:boolean"/>
    <xsd:element name="activity" type="xsd:string"/>
    <xsd:element name="costPayer" type="xsd:string"/>
    <xsd:element name="costCenter" type="xsd:string"/>
    <xsd:element name="vehicleCost" type="xsd:float"/>
    <xsd:element name="chauffServiceCost" type="xsd:float"/>
    <xsd:element name="holBringServiceCost" type="xsd:float"/>
    <xsd:element name="totalCost" type="xsd:float"/>
    <xsd:element name="tripPurpose" type="xsd:string"/>
    <xsd:element name="fixTermin" type="xsd:boolean"/>
    <xsd:element name="justificationFix" type="xsd:string"/>
    <xsd:element name="requestID" type="xsd:string"/>
    <xsd:element name="rentalPeriod" type="tns:RentalPeriod"/>
    <xsd:element name="carPool" type="tns:CarPool"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="CarPool">
    <xsd:sequence>
    <xsd:element name="poolID" type="xsd:string"/>
    <xsd:element name="poolName" type="xsd:string"/>
    <xsd:element name="orgNumber" type="xsd:string"/>
    <xsd:element name="vehicle" maxOccurs="unbounded" type="tns:Vehicle"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="RentalPeriod">
    <xsd:sequence>
    <xsd:element name="rentalPeriodID" type="xsd:string"/>
    <xsd:element name="startDate" type="xsd:date"/>
    <xsd:element name="endDate" type="xsd:date"/>
    <xsd:element name="startTime" type="xsd:time"/>
    <xsd:element name="endTime" type="xsd:time"/>
    <xsd:element name="startLocation" type="xsd:string"/>
    <xsd:element name="endLocation" type="xsd:string"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Vehicle">
    <xsd:sequence>
    <xsd:element name="vehicleID" type="xsd:string"/>
    <xsd:element name="vehicleClass" type="xsd:string"/>
    <xsd:element name="vehicleRegisterNo" type="xsd:int"/>
    <xsd:element name="vehicleType" type="xsd:string"/>
    <xsd:element name="seatsNumber" type="xsd:int"/>
    <xsd:element name="cost" type="xsd:float"/>
    <xsd:element name="available" type="xsd:boolean"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Contact">
    <xsd:sequence>
    <xsd:element name="contactID" type="xsd:string"/>
    <xsd:element name="contactName" type="xsd:string"/>
    <xsd:element name="telNumber" type="xsd:int"/>
    <xsd:element name="faxNumber" type="xsd:int"/>
    <xsd:element name="loNo" type="xsd:string"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Person">
    <xsd:sequence>
    <xsd:element name="personID"/>
    <xsd:element name="department" type="xsd:string"/>
    <xsd:element name="serviceNumber" type="xsd:int"/>
    <xsd:element name="contact" type="tns:Contact"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="Department">
    <xsd:sequence>
    <xsd:element name="departmentID" type="xsd:string"/>
    <xsd:element name="fundsDepartment" type="xsd:string"/>
    <xsd:element name="mvwdst" type="xsd:int"/>
    <xsd:element name="distributionNumber" type="xsd:int"/>
    <xsd:element name="contact" type="tns:Contact"/>
    </xsd:sequence>
    </xsd:complexType>
    <xsd:element name="formRequestElement" type="tns:FormRequest"/>
    <xsd:element name="personElement" type="tns:Person"/>
    <xsd:element name="departmentElement" type="tns:Department"/>
    <xsd:element name="vehicle" type="tns:Vehicle"/>
    <xsd:element name="loadFormReturn" type="xsd:boolean"/>
    <xsd:element name="editFormReturn" type="xsd:boolean"/>
    </xsd:schema>
    Wsdl File:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions name="userWS" targetNamespace="http://j2ee.netbeans.org/wsdl/userWS"
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:ns="http://xml.netbeans.org/schema/Abruf38" xmlns:plnk="http://docs.oasis-open.org/wsbpel/2.0/plnktype" xmlns:tns="http://j2ee.netbeans.org/wsdl/userWS" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
    <types>
    <xsd:schema targetNamespace="http://j2ee.netbeans.org/wsdl/userWS">
    <xsd:import namespace="http://xml.netbeans.org/schema/Abruf38" schemaLocation="Abruf38.xsd"/>
    </xsd:schema>
    </types>
    <message name="loadFormRequest">
    <part name="formRequest" element="ns:formRequestElement"/>
    <part name="person" element="ns:personElement"/>
    <part name="department" element="ns:departmentElement"/>
    </message>
    <message name="loadFormReply">
    <part name="retVal" element="ns:loadFormReturn"/>
    </message>
    <portType name="userWSPortType">
    <operation name="loadForm">
    <input name="input1" message="tns:loadFormRequest"></input>
    <output name="output1" message="tns:loadFormReply"/>
    </operation>
    </portType>
    <binding name="userWSBinding" type="tns:userWSPortType">
    <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
    <operation name="loadForm">
    <soap:operation/>
    <input name="input1">
    <soap:body use="literal"/>
    </input>
    <output name="output1">
    <soap:body use="literal"/>
    </output>
    </operation>
    </binding>
    <service name="userWSService">
    <port name="userWSPort" binding="tns:userWSBinding">
    <soap:address location="http://localhost:18181/userWSService/userWSPort"/>
    </port>
    </service>
    <plnk:partnerLinkType name="userWS1">
    <!-- A partner link type is automatically generated when a new port type is added. Partner link types are used by BPEL processes.
    In a BPEL process, a partner link represents the interaction between the BPEL process and a partner service. Each partner link is associated with a partner link type.
    A partner link type characterizes the conversational relationship between two services. The partner link type can have one or two roles.-->
    <plnk:role name="userWSPortTypeRole" portType="tns:userWSPortType"/>
    </plnk:partnerLinkType>
    </definitions>
    The message that Netbeans says when trying to put more parts to the message is:
    WS-I Basic Profile Rule R2210: If a document-literal binding in a DESCRIPTION does not specify the parts attribute on a soapbind:body element, the corresponding abstract wsdl:message MUST define zero or one wsdl:parts.
    Please...I am desperate, cause I am pressed by time!
    Can anyone tell me how can I make it work. Cause it is very common to use a Web service operation that has more than ONE parameter.
    I am waiting for your replys!

    Hi,
    Change the <soap:binding style="document"... to <soap:binding style="rpc"... and see if that works.
    I'm not sure how to get <soap:binding style="document"... working yet - I'm not that experienced in web services yet.
    Hope this helps and is not too late.
    Regards,
    Greg Nye

  • How to enter a style ID/Class for a box?

    I don't see any apparent way to enter a style ID or class name for a selected box.  Neither the "Layout" tab nor the "Styling" tab have a widget for this.  No such presence in the Right-Click menu, either.  Those are the places where I would expect this to be.
    Why would I want such a thing?  Because I'm a code jockey and will likely use ER as a preliminary layout designer.  Then I will, likely, load the code into an editor, like Dreamweaver or Netbeans and finish the design from there.  I use PHP a lot for dynamic designs such as database driven and things like "smart nav menus" that know not to display a menu item for the page that is currently loaded and that build auto-magically based on a site-map.  Plus I use jQuery a lot.
    Message was edited by: Steve Lawson -- qualified the need to code.

    You can change the IDs that are used by renaming the elements. Just double click the "box" or "image" label in the dom panel or selector at the bottom of the pages and type in what you want it to be.
    We only use ID selectors so this is just changing the ID. If you want to use classes you can change that code when you are inside of Dreamweaver, but at least with your own name it should be easier to find in the code exported from Reflow.
    Hope that helps and thanks for using Reflow!
    Chris

  • RichFaces' Ajax4JSF in NetBeans 6 not Rendering components

    Hi,
    My environment is Netbeans 6 visual web JSF app with RichFaces 3.1.3. I am unable to get any component to rerender upon completion of an ajax request. Is there something wrong in the logic i am following or is it a configuration issue or is it a bug?
    The event gets detected correctly and the backing bean function gets called and executes successfully. However, the components are not reRendered. Also, when i refresh, the textField1 displays its original data and not the data i set it to in the backing bean function.
    Any help in this regard will be greatly appreciated. Thank you.
    The JSP code:
    <jsp:root version="2.1" xmlns:a4j="http://richfaces.org/a4j" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
              xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:rich="http://richfaces.org/rich" xmlns:webuijsf="http://www.sun.com/webui/webuijsf">
        <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
        <f:view>
            <webuijsf:page binding="#{AboutUs.page1}" id="page1">
                <webuijsf:html binding="#{AboutUs.html1}" id="html1">
                    <webuijsf:head binding="#{AboutUs.head1}" id="head1">
                        <webuijsf:link binding="#{AboutUs.link1}" id="link1" url="/resources/stylesheet.css"/>
                    </webuijsf:head>
                    <webuijsf:body binding="#{AboutUs.body1}" id="body1" style="-rave-layout: grid">
                        <webuijsf:form binding="#{AboutUs.form1}" id="form1">
                            <webuijsf:image binding="#{AboutUs.image1}" height="2" id="image1"
                                            style="background-repeat: repeat-x; left: 6px; top: 493px; position: absolute" url="/resources/pic/blue_lt_gradient.gif" width="948"/>
                            <webuijsf:textField binding="#{AboutUs.textField1}" id="textField1"
                                                style="position: absolute; left: 174px; top: 72px; width: 228px; height: 18px" >
                                </webuijsf:textField>
                            <webuijsf:textField binding="#{AboutUs.textField2}" id="textField2" style="position: absolute;left: 174px; top: 132px; width: 132px; height: 24px">
                                <a4j:support action="#{AboutUs.textField1_action}" event="onChange" reRender="textField1"/>
                            </webuijsf:textField>
                        </webuijsf:form>
                    </webuijsf:body>
                </webuijsf:html>
            </webuijsf:page>
        </f:view>
        </jsp:root>
    The backing bean function that i am using:
    public String textField1_action() {
            this.getTextField1().setText("Hello World!");
            return null;
    }

    Webuijsf code is being transformed into javascript on client side. The problem is that standard ajax call DOES NOT execute javascript.
    Try using prototype.js instead. It has Ajax.Update function with parameter evalScripts:true, which you can use to execute javascript on
    client side

  • Using CSS Styles with Gridpanel

    Hello,
    It seems to me that the gridpanel component (and renderer) are
    producing incorrect HTML (or at least HTML that fails in IE and
    Netscape).
    The component has an attribute rowClass that renders as
    <TR class=specifiedClass> in the resulting table.
    Both IE and Netscape won't use the CSS class definition for
    the TR tag. They will however, use a style definition -- as in:
    gridpanel should have an attribute called rowStyle that is rendered
    as <TR style="specifiedStyle"> in the resulting table.
    Can anyone confirm this? Dispute this? Suggest a workaround?
    (other than creating my own component and renderer?
    Thanks!
    -Wile E

    This is a wrong forum for questions related to NetBeans and Spring.

  • Calling EJB with Annotation not successfull within Netbeans

    I am trying to call EJB but my simple program can't find a ejb
    within netbeans. I also download a stub file from the admin page and add to the ejb client path. but still without the luck
    @EJB
    private static ConverterBean converterBean;
    public static void main(String[] args) {
    // TODO code application logic here
    BigDecimal param = new BigDecimal ("100.00");
    BigDecimal amount = converterBean.dollarToYen(param);
    System.out.println( amount );
    }

    Thanks for your pointer. Could you please help me out with a small code snippet example?
    I want to make use of this existing bean (AMSProfileServiceBean ):
    @WebService(targetNamespace = "http://www.ttt.de/ota")
    @SOAPBinding(style = SOAPBinding.Style.DOCUMENT, use = SOAPBinding.Use.LITERAL, parameterStyle = SOAPBinding.ParameterStyle.BARE)
    // standard EJB3 annotations
    @Local(AMSAgencyWSPortType.class)
    @Stateless
    @TransactionAttribute(TransactionAttributeType.REQUIRES_NEW)
    // jboss propriatary annotations
    @WebContext(transportGuarantee = "NONE", secureWSDLAccess = false)
    public class AMSProfileServiceBean extends AbstractProfileBuilder implements AMSAgencyWSPortType
      private static Log log = LogFactory.getLog(AMSMappingServiceBean.class);
      @EJB(mappedName = "PotsdamProfileService/local")
      private PotsdamProfileService profileService;
      private Security              security;
      @EJB
      private OTAProfileBuilder     otaProfileBuilder;
      @EJB
      private OTAProfileUpdater     otaProfileUpdater;
    @Override
      public OTATTProfileReadRS otaTTReadRQ(Holder<Security> wsseHeader, OTATTReadRQ request)
    ...in my soap-connector :
    @WebServiceProvider(wsdlLocation = "WEB-INF/wsdl/PotsdamAMSAgencyWS.wsdl", targetNamespace = "http://www.ttt.de/ota", serviceName = "PotsdamAMSAgencyWS", portName = "PotsdamAMSAgencyWSPortType")
    @ServiceMode(value = Service.Mode.MESSAGE)
    public class PotsdamAgencyWSProvider extends WSProvider implements Provider<SOAPMessage>
      @Resource
      WebServiceContext     wsCtx;
    ...A small example would be really appreciated.
    Thanks.

  • JSF,Tiles, Sun App Server and NetBeans 5.5

    hi all,
    here is my environment :
    1.Server - Sun Application Server (Running On Suse Linux OS)
    2.IDE - NetBeans 5.5
    3.Project - JSF with Tiles
    here i found topic about tiles and jsf :
    http://forum.java.sun.com/thread.jspa?threadID=643536&messageID=3792238 but i think that Tiles is best alternative for JSF Layout Manager (It's my mind).
    is there anybody help me how to integrate tiles with jsf ?
    here is my example :
    1.web.xml :
        <servlet>
            <servlet-name>Tiles Servlet</servlet-name>
            <servlet-class>org.apache.struts.tiles.TilesServlet</servlet-class>
            <init-param>
                <param-name>definitions-config</param-name>
                <param-value>/WEB-INF/tiles-def.xml</param-value>
            </init-param>
            <load-on-startup>2</load-on-startup>
        </servlet>2. tiles-def.xml :
    <tiles-definitions>
             <!--****************************************************************-->
         <!--                     Global Layout                       -->
         <!--****************************************************************-->
         <definition name="global.layout" path="/pages/Mylayout/layout.jsp">
              <put name="title" value="Magti Billing System" type="string"></put>
                    <put name="subtitle" value="Magti Billing System" type="string"></put>
                    <put name="header" value="/pages/Mylayout/header.jsp"></put>
              <put name="subheader" value="/pages/Mylayout/sub_header.jsp"></put>          
              <put name="footer" value="/pages/Mylayout/footer.jsp"></put>
                    <put name="body" value="/pages/Mylayout/body.jsp"></put>
                    <put name="left_menu" value="/pages/Mylayout/left_menu.jsp"></put>
         </definition>   
    </tiles-definitions>3.and then i have 5 blank jsp pages : body.jps, footer.jsp, header.jsp, layout.jsp, left_menu.jsp, sub_header.jsp.
    4. here is my layout.jsp code :
    <?xml version="1.0" encoding="UTF-8"?>
    <jsp:root version="1.2"
              xmlns:f="http://java.sun.com/jsf/core"
              xmlns:h="http://java.sun.com/jsf/html"
              xmlns:jsp="http://java.sun.com/JSP/Page"
              xmlns:webuijsf="http://www.sun.com/webui/webuijsf"
              xmlns:tiles="http://jakarta.apache.org/struts/tags-tiles"
    >
        <tiles:importAttribute scope="request"></tiles:importAttribute>
        <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
        <f:view>
            <webuijsf:page binding="#{pages$Mylayout$layout.page1}" id="page1">
                <webuijsf:html binding="#{pages$Mylayout$layout.html1}" id="html1">
                    <webuijsf:head binding="#{pages$Mylayout$layout.head1}" id="head1">
                        <webuijsf:link binding="#{pages$Mylayout$layout.link1}" id="link1" url="/resources/stylesheet.css"/>
                    </webuijsf:head>
                    <webuijsf:body binding="#{pages$Mylayout$layout.body1}" id="body1" style="-rave-layout: grid">
                        <webuijsf:form binding="#{pages$Mylayout$layout.form1}" id="form1">
                            <h:panelGrid columns="2" cellspacing="0" cellpadding="0"
                                         border="0" styleClass="maingrid" columnClasses="maingrid">
                                <f:facet name="header">
                                    <f:subview id="header">
                                        <h:panelGrid columns="1" cellpadding="0" cellspacing="0">
                                            <tiles:insert attribute="header" flush="false" />
                                            <tiles:insert attribute="subheader" flush="false" />
                                        </h:panelGrid>
                                    </f:subview>
                                </f:facet>
                                <f:subview id="left_menu">
                                    <tiles:insert attribute="left_menu" flush="false" />
                                </f:subview>
                                <f:subview id="body">
                                    <tiles:insert attribute="body" flush="false" />
                                </f:subview>
                                <!--
                                <f:facet name="footer">
                                    <f:subview id="footer">
                                        <tiles:insert attribute="footer" flush="false" />
                                    </f:subview>
                                </f:facet>
                                -->
                            </h:panelGrid>
                        </webuijsf:form>
                    </webuijsf:body>
                </webuijsf:html>
            </webuijsf:page>
        </f:view>
    </jsp:root>5. and at last i have index.jsp:
    <?xml version="1.0" encoding="UTF-8"?>
    <jsp:root version="1.2"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:jsp="http://java.sun.com/JSP/Page"
    xmlns:webuijsf="http://www.sun.com/webui/webuijsf"
    xmlns:tiles="http://jakarta.apache.org/struts/tags-tiles"
    >
        <jsp:directive.page contentType="text/html;charset=UTF-8" pageEncoding="UTF-8"/>
        <f:view>
            <webuijsf:page binding="#{pages$main$index.page1}" id="page1">
                <webuijsf:html binding="#{pages$main$index.html1}" id="html1">
                    <webuijsf:head binding="#{pages$main$index.head1}" id="head1">
                        <webuijsf:link binding="#{pages$main$index.link1}" id="link1" url="/resources/stylesheet.css"/>
                    </webuijsf:head>
                    <webuijsf:body binding="#{pages$main$index.body1}" id="body1" style="-rave-layout: grid">
                        <webuijsf:form binding="#{pages$main$index.form1}" id="form1">
                            <tiles:insert definition="global.layout" flush="false"/>
                        </webuijsf:form>
                    </webuijsf:body>
                </webuijsf:html>
            </webuijsf:page>
        </f:view>
    </jsp:root>but i get an error like this :
    Can't leverage base class
    java.lang.IllegalStateException
            at com.sun.faces.taglib.jsf_core.ViewTag.getComponentType(ViewTag.java:259)
            at javax.faces.webapp.UIComponentELTag.createComponent(UIComponentELTag.java:219)
            at javax.faces.webapp.UIComponentClassicTagBase.createChild(UIComponentClassicTagBase.java:458)
            at javax.faces.webapp.UIComponentClassicTagBase.findComponent(UIComponentClassicTagBase.java:643)
            at javax.faces.webapp.UIComponentClassicTagBase.doStartTag(UIComponentClassicTagBase.java:1070)
            at com.sun.faces.taglib.jsf_core.ViewTag.doStartTag(ViewTag.java:180)
            at org.apache.jsp.pages.Mylayout.layout_jsp._jspx_meth_f_view_0(layout_jsp.java:140)
            at org.apache.jsp.pages.Mylayout.layout_jsp._jspService(layout_jsp.java:99)
            at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:111)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
            at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:353)
            at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:412)
            at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:318)Any Ideas Is Usefull. Thanks.
    Paata.

    Hi,
    I'm trying to use Tiles with NetBeans 6.0. I used a similar set up as the other writer did, except for the JSP:root part:
    <jsp:root version="2.1"
    xmlns:f="http://java.sun.com/jsf/core"
    xmlns:h="http://java.sun.com/jsf/html"
    xmlns:jsp="http://java.sun.com/JSP/Page"
    xmlns:webuijsf="http://www.sun.com/webui/webuijsf"
    xmlns:tiles="http://jakarta.apache.org/struts/tags-tiles">
    It complies and deploys OK, except it renders a blank page. The source code of the page is below. It seems that the "tiles:insertDefinition" was not expanded. Would you share some lights on how you get it to work. By the way I did not use shale-tiles, do I need it?
    Thanks in advance.
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <html xmlns="http://www.w3.org/1999/xhtml" xmlns:wairole="http://www.w3.org/2005/01/wai-rdf/GUIRoleTaxonomy#" xmlns:waistate="http://www.w3.org/2005/07/aaa">
    <head>
    <meta content="no-cache" http-equiv="Pragma" />
    <meta content="no-cache" http-equiv="Cache-Control" />
    <meta content="no-store" http-equiv="Cache-Control" />
    <meta content="max-age=0" http-equiv="Cache-Control" />
    <meta content="1" http-equiv="Expires" />
    <title></title>
    <link rel="stylesheet" type="text/css" href="/apogee-web-1.0-SNAPSHOT/theme/com/sun/webui/jsf/suntheme/css/css_master.css" />
    <script type="text/javascript">
    var djConfig = {
        "isDebug": false,
        "parseWidgets": false,
        "debugAtAllCosts": false
    </script>
    <script type="text/javascript" src="/apogee-web-1.0-SNAPSHOT/theme/META-INF/dojo/dojo.js"></script>
    <script type="text/javascript" src="/apogee-web-1.0-SNAPSHOT/theme/META-INF/json/json.js"></script>
    <script type="text/javascript" src="/apogee-web-1.0-SNAPSHOT/theme/META-INF/prototype/prototype.js"></script>
    <script type="text/javascript" src="/apogee-web-1.0-SNAPSHOT/theme/META-INF/com_sun_faces_ajax.js"></script>
    <script type="text/javascript">
    dojo.hostenv.setModulePrefix("webui.suntheme", "/apogee-web-1.0-SNAPSHOT/theme/com/sun/webui/jsf/suntheme/javascript");
    dojo.require('webui.suntheme.*');
    dojo.require('webui.suntheme.widget.*');
    dojo.require('webui.suntheme.widget.jsfx.*');
    </script>
    <link id="link1" rel="stylesheet" type="text/css" href="/apogee-web-1.0-SNAPSHOT/resources/stylesheet.css" />
    </head>
    <body id="body1" style="-rave-layout: grid" onload="" onunload="">
    <form id="form1" class="form" method="post" action="/apogee-web-1.0-SNAPSHOT/faces/Apogee.jsp" enctype="application/x-www-form-urlencoded">
    <tiles:insertDefinition flush="false" name="global.layout" />
    <input id="form1_hidden" name="form1_hidden" value="form1_hidden" type="hidden" />
    <input type="hidden" name="javax.faces.ViewState" id="javax.faces.ViewState" value="H4sIAAAAAAAAAKVWTWwbRRR+Xmexm4LSOCgEiZRIFESFsk7bCyIUSFInsfBPZZsU2kM6Xk/sDevdYXbWXreiag+ABBcQIIEUBBIcemhP3HoAqh4QSEUiEhdOFReEBBwQEj8HYGZs79qOZZNkZD2vd957M98333vja7+A6lKYOJfaRDWkmcgqa9niJtbZ/JvfPP/hIeeoqQB4BAAiDoUTul3VHNfSNpCOHQ0RYho6YoZtaXmGGE4jC5UxTVaJeaRAMc7YJfz7xo3Prs+tfH63yFM/A2KsdOfBHsOWw7PwlDXEENX4PLEtbDFHO40oM5BZoKiGqYPMNQPXc7bNxCIQ3Vw3Svxz3HNegkug1Gdl/pl2/jouuoa26WwEGXnCMgaVcHusMyo0OGqVVU1QK9x2RSlDojAq8Shuu6LCg6NShvUiqCa3u1lr0S41QC1y2xWlDo5atmkV1A1uj3muiBJD8Z+iwRM//3GpEpcZpraKnEoaETXy/c1bk+e/DYOyDKOmjUrLSGc2TcIBVqHYqdhmySNPPyNT3FWPikSCAAZHRC6vpQC+My4mbem5XC6RKayvJRNn1nPZbEEsPsbg0TYCIQLhrHEcPKCIHKwt5RILhcQpGeTvUSp50bZNjKzbM/Tyd1t//6pA6CyoNWS62CMhBjP9dpBNn85mxB6Sp/I820SAeIFS1EgZDvOubE+//yX6IAyhJIw4xgUsCyRUHxHSY21teYSwQKACSUweyziIidHVQjq1vriQTy4xOBhfIHYZY342hC96KFg0ZevIxJf+HD+/NffXzwqMJCFa4dTrvLJSENFt12K0wSAmCzguYMfzjBpWeT4FUfHT5ZsRyz7A3WuIGshi8qdH/uWDATBQsCVeHe5mL2kxzIs59sNHn/xx5bXHFYG2xV57i9Iv41aLmL567d3pg+/ceaPdLkKEEF87oT7KUjuUJZ7u2SGSkHg9ISfv7eK3WYWdcu1pYS0Grm+v/fjT9MUVf08MIkXDKvG5YGsc9COdQghKQ7a0VS5gTPOi+bzw9acn3966nVZAScEB3USOk0HVNrmjDvcpyRgGk83jMOx4HnPKTeMCKpp4nkuCL3e4rWZsamuCz4RHeKmIBiiaWvjG1eKDD3/1nmiYFKaae9vpWh+9fO7OF/+8pUi3Cd8t8Pj4ldfzv53dflLCr5+AsYcutmQmBfry8DZJiCfQTfomJswUx7czUvrL6R4zUAXh3apACVQguiprd7ze5vVYO3S246jFU5zIr+NdhEhFDSFE3AAtQo76ZgAhTX/SB3TwNLb3ImheD/uELSgcBpv7tGCf9M0g2MI/OH1CAv9u0+/d/1BMJKCsl9vdgZcEDgEvbuIW+Gd9MwB805+IBn9/nJeh7VLeU+IOa5j8LsSYabrjBNuGPvju27skmrf4/iQhq2kIK+KfRouVp3wzgJWmf8/gd9asuM5nTdSwXfbETJkapZ4GEhsuh6m90yWu5rl90iUpH0KX+IvVokv3zQC6pH9nBe0YfUoF/gMrokC8ywsAAA==" />
    </form>
    <script type="text/javascript">
    webui.suntheme.common.body = new webui.suntheme.body('/Apogee.jsp', '/apogee-web-1.0-SNAPSHOT/faces/Apogee.jsp',null,null,'com_sun_webui_util_FocusManager_focusElementId');</script>
    </body>
    </html>

  • JSF, NetBeans and customizing of Standard Validation Errors

    Hello together,
    i want to use german Standard Validation Errors via a own .properties File:
    1.
    Here is my faces-config.xml ( the entries are uncommented ! ):
    <faces-config>
    <application>
    <locale-config>
    <default-locale>de</default-locale>
    <supported-locale>de</supported-locale>
    <supported-locale>en</supported-locale>
    </locale-config>
    *<message-bundle>alles.mymessages</message-bundle>*
    </application>
    </faces-config>
    2.
    Here is mymessages.properties-File in package alles:
    javax.faces.validator.NOT_IN_RANGE=Das angegebene Attribut liegt nicht zwischen den erwarteten Werten {0} und {1}.
    javax.faces.validator.NOT_IN_RANGE_detail="{2}"\:Eingegebener Wert liegt nicht im erwarteten Bereich von {0} bis {1}.
    javax.faces.validator.LongRangeValidator.LIMIT=Validierungsfehler
    javax.faces.validator.LongRangeValidator.LIMIT_detail=Eingegebener Wert kann nicht in den korrekten Typ umgewandelt werden.
    javax.faces.validator.LongRangeValidator.MAXIMUM=Validierungsfehler
    javax.faces.validator.LongRangeValidator.MAXIMUM_detail="{1}"\:Wert ist gr\u00F6\u00DFer als das erlaubte Maximum"{0}".
    3.
    Here the part of the JSF-View with the Validator:
    <ui:textField binding="#{WorkTypeEdit.textFieldBeschartKzSoll}" converter="#{WorkTypeEdit.bigIntegerConverter1}"
    id="textFieldBeschartKzSoll" required="true" style="height: 24px; width: 48px" validator="#{WorkTypeEdit.longRangeValidator1.validate}"/>
    The application still shows the standard englisch validation error text. What is wrong here ?
    I' am using NetBeans 5.5.1 with VWP and the deploment is to Glassfish server.
    Thanks a lot.
    HJA

    Hello Raymond,
    i did some coding and create additional a custom validator:
    My JSF-View part:
    <ui:textField binding="#{WorkTypeEdit.textFieldBeschartKzSoll}" converter="#{WorkTypeEdit.integerConverter1}"
    id="textFieldBeschartKzSoll" maxLength="2" required="true" style="height: 24px; width: 48px" *validator="#{MyValidation.validateInput}">*
    *<f:validateLongRange minimum="1" maximum="9"></f:validateLongRange>*
    </ui:textField>
    My custom validator in Myvalidation class:
    public void validateInput (FacesContext facescontext, UIComponent component, Object value) throws ValidatorException
    long min = 0, max = 0;
    Locale locale = facescontext.getViewRoot ().getLocale ();
    String mb = facescontext.getApplication ().getMessageBundle ();
    ResourceBundle rb = ResourceBundle.getBundle (mb, locale);
    Validator[] validator = ((UIInput) component).getValidators ();
    for (int i=0; i < validator.length; i++)
    if (validator[i] instanceof LongRangeValidator)
    LongRangeValidator lv = (LongRangeValidator) validator;
    long lvalue = Long.valueOf ((String)value.toString ());
    min = lv.getMinimum ();
    max = lv.getMaximum ();
    if (lvalue < min || lvalue > max)
    ((UIInput) component).setValid (false);
    *String message = rb.getString ("javax.faces.validator.NOT_IN_RANGE");*
    *String messageDetail = rb.getString ("javax.faces.validator.NOT_IN_RANGE_detail");*
    *facescontext.addMessage (component.getClientId (facescontext), new FacesMessage (FacesMessage.SEVERITY_ERROR,message,messageDetail));* }
    What happen now is, at first i get the german message because of rb.getString........ so the locale is working
    and then the englisch message follows in the message component.
    Sorry that i take your time so long...
    HJA

  • RPC style web service client

    hi,
    i am new to web service technology. i want to create dynamic web service client for a "rpc" style web service in Netbeans.
    please, can anybody guide me for this?
    thanks in advance.

    Hi,
    To avoid creating new topic I will put my question here.
    I try to create new web service (rpc-style) client in netbeans. I have rpc plugin installed. In ejb module node I right click > new > web service client >
    I fill all filds, chose rpc-style and > after clicking finish - error occur:java.lang.LinkageError: com/sun/xml/rpc/processor/generator/Names
         at org.netbeans.modules.websvc.registry.util.Util.getParameterType(Util.java:856)
         at org.netbeans.modules.websvc.registry.jaxrpc.WrapperClientWriter.printOperations(WrapperClientWriter.java:275)
         at org.netbeans.modules.websvc.registry.jaxrpc.WrapperClientWriter.writeClass(WrapperClientWriter.java:219)
         at org.netbeans.modules.websvc.registry.jaxrpc.Wsdl2Java.createWrapperClients(Wsdl2Java.java:305)
         at org.netbeans.modules.websvc.registry.jaxrpc.Wsdl2Java.execute(Wsdl2Java.java:229)
         at org.netbeans.modules.websvc.registry.util.Util.createWSJar(Util.java:493)
         at org.netbeans.modules.websvc.registry.RegistryViewImpl.registerService(RegistryViewImpl.java:221)
         at org.netbeans.modules.websvc.registry.RegistryViewImpl.registerService(RegistryViewImpl.java:159)
         at org.netbeans.modules.websvc.registry.netbeans.RegisterViewImplNetBeansSide.registerService(RegisterViewImplNetBeansSide.java:91)
         at org.netbeans.modules.websvc.jaxrpc.client.wizard.ClientBuilder.generate(ClientBuilder.java:330)
         at org.netbeans.modules.websvc.jaxrpc.client.wizard.JaxRpcClientCreator$2.run(JaxRpcClientCreator.java:319)
         at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:572)
    [catch] at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:997)
    I use netbeans 6.5. In my project I choose java ee 5 as in 1.4 there is no web service client option
    Any ideas?
    I found some rpc tutorils for netbeans 4.0 but I wonder why it couldn't be done in netbean 6.5
    Regards,
    Lech

  • Standalone Web Service clients in NetBeans with WSIT security

    I'm having a problem create a secure app with NetBeans, any help would be appreciated, here's what I did:
    Following the WSIT tutorial (http://java.sun.com/webservices/reference/tutorials/wsit/doc/index.html) I was able to create a Web Service with (for example) Username Authentication with Symmetric Key. I select the keystore as being the either the default development settings (I installed V3 certificates previously) or what I imagine are the same as them: keystore from domain1, alias xws-server and a username and password that I've created in the glassfish admin console. All good so far.
    I then create a new web app servlet client, configuring the Web Service client with the corresponding cacerts keystore, alias xws-security-server from domain1 and the correct username and password. Deploy that and bingo, it works.
    Try that again with a standalone Java client configuring the client reference in exactly the same way and using:
            try { // Call Web Service Operation
                uk.ac.ox.sddag.glassfish.server.SecureWSService service = new uk.ac.ox.sddag.glassfish.server.SecureWSService();
                uk.ac.ox.sddag.glassfish.server.SecureWS port = service.getSecureWSPort();
                int x = 1200;
                int y = 36;
                int result = port.add(x, y);
                System.out.println("Result = "+result);
            } catch (Exception ex) {
                System.out.println("Exception:");
                ex.printStackTrace();
            }but this time, it doesn't work:
    Exception:
    javax.xml.ws.soap.SOAPFaultException: ERROR: No security header found in the message
            at com.sun.xml.ws.fault.SOAP11Fault.getProtocolException(SOAP11Fault.java:188)
            at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:130)
            at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
            at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:89)
            at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:118)
            at $Proxy29.add(Unknown Source)
            at securestandaloneclient.Main.main(Main.java:26)
    Caused by: javax.xml.ws.soap.SOAPFaultException: ERROR: No security header found in the message
            at com.sun.xml.ws.security.opt.impl.util.SOAPUtil.getSOAPFaultException(SOAPUtil.java:171)
            at com.sun.xml.wss.provider.wsit.WSITServerAuthContext.validateRequest(WSITServerAuthContext.java:277)
            at com.sun.xml.wss.provider.wsit.WSITServerAuthContext.validateRequest(WSITServerAuthContext.java:179)
            at com.sun.enterprise.webservice.CommonServerSecurityPipe.processRequest(CommonServerSecurityPipe.java:168)
            at com.sun.enterprise.webservice.CommonServerSecurityPipe.process(CommonServerSecurityPipe.java:129)
            at com.sun.xml.ws.api.pipe.helper.PipeAdapter.processRequest(PipeAdapter.java:115)
            at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:595)
            at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:554)
            at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:539)
            at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:436)
            at com.sun.xml.ws.server.WSEndpointImpl$2.process(WSEndpointImpl.java:243)
            at com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit.handle(HttpAdapter.java:444)
            at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:244)
            at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)
            at com.sun.enterprise.webservice.JAXWSServlet.doPost(JAXWSServlet.java:176)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
            at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
            at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:341)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:263)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:214)
            at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
            at com.sun.enterprise.web.connector.grizzly.ssl.SSLWorkerThread.run(SSLWorkerThread.java:106)I'm assuming that it's something to do with the WSDL being used to create the request, here's what the source view for the web service reference says:
    <?xml version="1.0" encoding="UTF-8"?><!-- Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://server.glassfish.sddag.ox.ac.uk/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://server.glassfish.sddag.ox.ac.uk/" name="SecureWSService">
    <ns1:Policy xmlns:ns1="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBindingPolicy">
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:SignedSupportingTokens xmlns:ns4="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:UsernameToken ns4:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:WssUsernameToken10></ns4:WssUsernameToken10>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns4:UsernameToken>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns4:SignedSupportingTokens>
    <ns5:SymmetricBinding xmlns:ns5="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:AlgorithmSuite>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:Basic128></ns5:Basic128>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:AlgorithmSuite>
    <ns5:IncludeTimestamp></ns5:IncludeTimestamp>
    <ns5:Layout>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:Strict></ns5:Strict>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:Layout>
    <ns5:OnlySignEntireHeadersAndBody></ns5:OnlySignEntireHeadersAndBody>
    <ns5:ProtectionToken>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:X509Token ns5:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:RequireIssuerSerialReference></ns5:RequireIssuerSerialReference>
    <ns5:WssX509V3Token10></ns5:WssX509V3Token10>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:X509Token>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:ProtectionToken>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:SymmetricBinding>
    <ns6:Wss11 xmlns:ns6="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns6:MustSupportRefEncryptedKey></ns6:MustSupportRefEncryptedKey>
    <ns6:MustSupportRefIssuerSerial></ns6:MustSupportRefIssuerSerial>
    <ns6:MustSupportRefThumbprint></ns6:MustSupportRefThumbprint>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns6:Wss11>
    <ns7:UsingAddressing xmlns:ns7="http://www.w3.org/2006/05/addressing/wsdl" ns1:Optional="true"></ns7:UsingAddressing>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    <ns8:Policy xmlns:ns8="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBinding_add_Input_Policy">
    <ns8:ExactlyOne>
    <ns8:All>
    <ns9:EncryptedParts xmlns:ns9="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns9:Body></ns9:Body>
    </ns9:EncryptedParts>
    <ns10:SignedParts xmlns:ns10="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns10:Body></ns10:Body>
    <ns10:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Namespace="http://www.w3.org/2005/08/addressing" Name="To"></ns10:Header>
    <ns10:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="AckRequested"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="CreateSequence"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="Sequence"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="SequenceAcknowledgement"></ns10:Header>
    </ns10:SignedParts>
    </ns8:All>
    </ns8:ExactlyOne>
    </ns8:Policy>
    <ns11:Policy xmlns:ns11="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBinding_add_Output_Policy">
    <ns11:ExactlyOne>
    <ns11:All>
    <ns12:EncryptedParts xmlns:ns12="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns12:Body></ns12:Body>
    </ns12:EncryptedParts>
    <ns13:SignedParts xmlns:ns13="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns13:Body></ns13:Body>
    <ns13:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Namespace="http://www.w3.org/2005/08/addressing" Name="To"></ns13:Header>
    <ns13:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="AckRequested"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="CreateSequence"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="Sequence"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="SequenceAcknowledgement"></ns13:Header>
    </ns13:SignedParts>
    </ns11:All>
    </ns11:ExactlyOne>
    </ns11:Policy>
    <types>
    <xsd:schema>
    <xsd:import namespace="http://server.glassfish.sddag.ox.ac.uk/" schemaLocation="http://localhost:8080/SecureApplication/SecureWSService?xsd=1"></xsd:import>
    </xsd:schema>
    </types>
    <message name="add">
    <part name="parameters" element="tns:add"></part>
    </message>
    <message name="addResponse">
    <part name="parameters" element="tns:addResponse"></part>
    </message>
    <portType name="SecureWS">
    <operation name="add">
    <input message="tns:add"></input>
    <output message="tns:addResponse"></output>
    </operation>
    </portType>
    <binding name="SecureWSPortBinding" type="tns:SecureWS">
    <ns14:PolicyReference xmlns:ns14="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBindingPolicy"></ns14:PolicyReference>
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"></soap:binding>
    <operation name="add">
    <soap:operation soapAction="add"></soap:operation>
    <input>
    <ns15:PolicyReference xmlns:ns15="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBinding_add_Input_Policy"></ns15:PolicyReference>
    <soap:body use="literal"></soap:body>
    </input>
    <output>
    <ns16:PolicyReference xmlns:ns16="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBinding_add_Output_Policy"></ns16:PolicyReference>
    <soap:body use="literal"></soap:body>
    </output>
    </operation>
    </binding>
    <service name="SecureWSService">
    <port name="SecureWSPort" binding="tns:SecureWSPortBinding">
    <soap:address location="http://localhost:8080/SecureApplication/SecureWSService"></soap:address>
    </port>
    </service>
    </definitions>The contents of META-INF (The WSDL):
    <?xml version="1.0" encoding="UTF-8"?><!-- Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://server.glassfish.sddag.ox.ac.uk/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://server.glassfish.sddag.ox.ac.uk/" name="SecureWSService" xmlns:wsp="http://www.w3.org/ns/ws-policy" xmlns:sc="http://schemas.sun.com/2006/03/wss/client" xmlns:wspp="http://java.sun.com/xml/ns/wsit/policy">
    <types>
    <xsd:schema>
    <xsd:import namespace="http://server.glassfish.sddag.ox.ac.uk/" schemaLocation="http://localhost:8080/SecureApplication/SecureWSService?xsd=1"></xsd:import>
    </xsd:schema>
    </types>
    <message name="add">
    <part name="parameters" element="tns:add"></part>
    </message>
    <message name="addResponse">
    <part name="parameters" element="tns:addResponse"></part>
    </message>
    <portType name="SecureWS">
    <operation name="add">
    <input message="tns:add"></input>
    <output message="tns:addResponse"></output>
    </operation>
    </portType>
    <binding name="SecureWSPortBinding" type="tns:SecureWS">
        <wsp:PolicyReference URI="#SecureWSPortBindingPolicy"/>
        <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"></soap:binding>
    <operation name="add">
    <soap:operation soapAction="add"></soap:operation>
    <input>
    <soap:body use="literal"></soap:body>
    </input>
    <output>
    <soap:body use="literal"></soap:body>
    </output>
    </operation>
    </binding>
    <service name="SecureWSService">
    <port name="SecureWSPort" binding="tns:SecureWSPortBinding">
    <soap:address location="http://localhost:8080/SecureApplication/SecureWSService"></soap:address>
    </port>
    </service>
        <wsp:Policy wsu:Id="SecureWSPortBindingPolicy">
            <wsp:ExactlyOne>
                <wsp:All>
                    <sc:CallbackHandlerConfiguration wspp:visibility="private">
                        <sc:CallbackHandler default="example1" name="usernameHandler"/>
                        <sc:CallbackHandler default="password1" name="passwordHandler"/>
                    </sc:CallbackHandlerConfiguration>
                    <sc:TrustStore wspp:visibility="private" type="JKS" storepass="changeit" location="/Applications/NetBeans/glassfish-v2ur2/domains/domain1/config/cacerts.jks" peeralias="xws-security-server"/>
                </wsp:All>
            </wsp:ExactlyOne>
        </wsp:Policy>
    </definitions>The wsit-client:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" name="mainclientconfig"
    >
        <import location="SecureWSService.xml" namespace="http://server.glassfish.sddag.ox.ac.uk/"/>
    </definitions>

    This bug still isn't fixed.
    Thank you, adding Glassfish's webservices-rt.jar does fix it.

  • Objects, web services and netbeans

    I am trying to make a web service that returns an array of objects (where each object is a small number of strings). I shall list what I have done, if you just want to read the problem skip to <PROBLEM>.
    1) Wrote .wsdl file [1]
    In netbeans:
    2) Generated web service from WSDL:
    A) New web application, using the sun application server
    B) New Web Service From WSDL (this gives an error, Illegal character in path at index 18: file:/<path of wsdl file>)
    C) Right click on web service, Refreash service. No error
    D) Run project, test web service, seems to work, returns null.
    3) Consumed service:
    A) New general application,
    B) In main method, right click / Web Service Client Resources / Call Web Service Operation
    C) Select method (getparams(String))
    D) Add import org.impress.PortType; as prompted
    E) Run project, Result = null
    Now I want to add some data to what I am passing. First I return a new namespace.webservice._new.Paramarrayel (what netbeans decided the method should return). The client now shows that something is returned (org.impress.Paramarrayel@1bb5c09).
    <PROBLEM>
    Now this is where I get stuck. I want to add the data, the client knows there should be a .getGetparamreturns() function in the returned org.impress.Paramarrayel object but I cannot figure out how to add it in the server. I have tryed extending the namespace.webservice._new.Paramarrayel and namespace.webservice._new.Paramreturns, and adding a Paramreturns as a member variable of Paramarrayel but .getGetparamreturns() returns null in the client.
    Anyone able to help?
    [1]
    <?xml version="1.0" encoding="UTF-8"?>
    <!-- edited with XMLSpy v2007 rel. 3 sp1 (http://www.altova.com) by andrew (Medical Research Council) -->
    <wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://new.webservice.namespace" targetNamespace="http://new.webservice.namespace">
         <wsdl:types>
              <xs:schema targetNamespace="http://new.webservice.namespace" elementFormDefault="qualified" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
                   <xs:element name="paramimpressidstring" type="xs:string"/>
                   <xs:complexType name="paramreturns">
                        <xs:sequence>
                             <xs:element name="name" nillable="true" type="xs:string"/>
                             <xs:element name="value" nillable="true" type="xs:string"/>
                        </xs:sequence>
                   </xs:complexType>
                   <xs:element name="paramarrayel">
                        <xs:complexType>
                             <xs:sequence>
                                  <xs:element name="getparamreturns" nillable="true" type="tns:paramreturns"/>
                             </xs:sequence>
                        </xs:complexType>
                   </xs:element>
              </xs:schema>
         </wsdl:types>
         <wsdl:message name="getparamsRequest">
              <wsdl:part name="impressid" element="tns:paramimpressidstring"/>
         </wsdl:message>
         <wsdl:message name="getparamsResponse">
              <wsdl:part name="paramsarray" element="tns:paramarrayel"/>
         </wsdl:message>
         <wsdl:portType name="portType">
              <wsdl:operation name="getparams">
                   <wsdl:input message="tns:getparamsRequest"/>
                   <wsdl:output message="tns:getparamsResponse"/>
              </wsdl:operation>
         </wsdl:portType>
         <wsdl:binding name="impressBinding" type="tns:portType">
              <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
              <wsdl:operation name="getparams">
                   <soap:operation soapAction="urn:#getparams"/>
                   <wsdl:input>
                        <soap:body use="literal"/>
                   </wsdl:input>
                   <wsdl:output>
                        <soap:body use="literal"/>
                   </wsdl:output>
              </wsdl:operation>
         </wsdl:binding>
         <wsdl:service name="impress">
              <wsdl:port name="impressport" binding="tns:impressBinding">
                   <soap:address location="http://impress.publicdevelopment.har.mrc.ac.uk/server.php"/>
              </wsdl:port>
         </wsdl:service>
    </wsdl:definitions>

    Yes it's true but Netbeans uses one of the existing SOAP implementations to do it. I'm almost sure that it uses one of the most popular implementations JAX-WS RI or Axis by default.
    Regards,
    S&#322;awomir Wojtasiak

Maybe you are looking for