facebook

WSDL Documentation comments formatted improperly

  1. MyEclipse IDE
  2.  > 
  3. WebSphere Development
Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
    Posts
  • #297272 Reply

    nsoule
    Member

    Hello, I’m creating documentation within a node like below:

    <wsdl:documentation>

    for a wsdl. The documentation is written in sentence form. When I right click and select Source->Format the text in those comments seems to be formatted in a very odd way. Many words (short words included) end up on a line by themselves and all the lines seem to be of arbitrary length (I have the preference set at the default of 72 characters). Is there anything I can do to have this text format in a more visually acceptable way?

    Also, in some circumstances I can select format multiple times in a row and get a different format each time.

    Thank you.

    -Nate

    #297296 Reply

    Loyal Water
    Member

    Nate,
    Could you please paste a file here for us and list down the steps to help us reproduce this issue at our end. I’ll get this checked right away.

    #297424 Reply

    nsoule
    Member

    Hi Nipun. If you format the wsdl below once things look ok. If you then format it again it starts to put single words by themselves on a line. I’ve seen other cases where that incorrect formatting occurs on the first attempt. Thanks.

    -Nate

    <?xml version=”1.0″ encoding=”UTF-8″?>
    <wsdl:definitions xmlns:soap=”http://schemas.xmlsoap.org/wsdl/soap/&#8221;
    xmlns:tns=”http://www.example.org/NewWSDLFile/&#8221; xmlns:wsdl=”http://schemas.xmlsoap.org/wsdl/&#8221;
    xmlns:xsd=”http://www.w3.org/2001/XMLSchema&#8221; name=”NewWSDLFile”
    targetNamespace=”http://www.example.org/NewWSDLFile/”&gt;
    <wsdl:types>
    <xsd:schema targetNamespace=”http://www.example.org/NewWSDLFile/”&gt;
    <xsd:element name=”NewOperation”>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element name=”in” type=”xsd:string” />
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    <xsd:element name=”NewOperationResponse”>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element name=”out” type=”xsd:string” />
    </xsd:sequence>
    </xsd:complexType>
    </xsd:element>
    </xsd:schema>
    </wsdl:types>
    <wsdl:message name=”NewOperationRequest”>
    <wsdl:part element=”tns:NewOperation” name=”parameters” />
    </wsdl:message>
    <wsdl:message name=”NewOperationResponse”>
    <wsdl:part element=”tns:NewOperationResponse” name=”parameters” />
    </wsdl:message>
    <wsdl:portType name=”NewWSDLFile”>
    <wsdl:operation name=”NewOperation”>

    <wsdl:documentation>
    This is some text. Text text text. Typing some text. More text. This is
    is sample text to demonstrate issues with wrapping.
    This is a 2nd line. To generate the line break I pressed Enter on the
    keyboard. Text text text.
    </wsdl:documentation>
    <wsdl:input message=”tns:NewOperationRequest” />
    <wsdl:output message=”tns:NewOperationResponse” />
    </wsdl:operation>
    </wsdl:portType>
    <wsdl:binding name=”NewWSDLFileSOAP” type=”tns:NewWSDLFile”>
    <soap:binding style=”document”
    transport=”http://schemas.xmlsoap.org/soap/http&#8221; />
    <wsdl:operation name=”NewOperation”>
    <soap:operation soapAction=”http://www.example.org/NewWSDLFile/NewOperation&#8221; />
    <wsdl:input>
    <soap:body use=”literal” />
    </wsdl:input>
    <wsdl:output>
    <soap:body use=”literal” />
    </wsdl:output>
    </wsdl:operation>
    </wsdl:binding>
    <wsdl:service name=”NewWSDLFile”>
    <wsdl:port binding=”tns:NewWSDLFileSOAP” name=”NewWSDLFileSOAP”>
    <soap:address location=”http://www.example.org/&#8221; />
    </wsdl:port>
    </wsdl:service>
    </wsdl:definitions>

Viewing 3 posts - 1 through 3 (of 3 total)
Reply To: WSDL Documentation comments formatted improperly

You must be logged in to post in the forum log in