You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Dave Meier (JIRA)" <ji...@apache.org> on 2007/02/27 23:53:05 UTC
[jira] Created: (AXIS2-2271) [Axis2] WSDL2C boolean not handled
correctly - code does not compile
[Axis2] WSDL2C boolean not handled correctly - code does not compile
--------------------------------------------------------------------
Key: AXIS2-2271
URL: https://issues.apache.org/jira/browse/AXIS2-2271
Project: Axis 2.0 (Axis2)
Issue Type: Bug
Components: codegen
Affects Versions: nightly
Environment: Windows XP, Visual Studio 2003 C++.
Reporter: Dave Meier
Fix For: nightly
I have a boolean type in my WSDL and code is generated that fails to compile.
WSDL:
<?xml version="1.0" encoding="UTF-8"?>
<definitions name="test"
targetNamespace="http://localhost:80/gsoap/test.wsdl"
xmlns:tns="http://localhost:80/gsoap/test.wsdl"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:tt="urn:test"
xmlns:SOAP="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns:MIME="http://schemas.xmlsoap.org/wsdl/mime/"
xmlns:DIME="http://schemas.xmlsoap.org/ws/2002/04/dime/wsdl/"
xmlns:WSDL="http://schemas.xmlsoap.org/wsdl/"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<types>
<schema targetNamespace="urn:test"
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
xmlns:tt="urn:test"
xmlns="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
attributeFormDefault="qualified">
<import namespace="http://www.w3.org/2001/10/xml-exc-c14n#"/>
<import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/>
<import namespace="http://www.w3.org/2000/09/xmldsig#"/>
<import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"/>
<import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
<simpleType name="Attachment-Access-Type">
<restriction base="xsd:string">
<enumeration value="ATTACHACCESS-DEFAULT"/>
<enumeration value="ATTACHACCESS-RESTRICTED"/>
<enumeration value="ATTACHACCESS-UNRESTRICTED"/>
</restriction>
</simpleType>
<!-- operation request element -->
<element name="SetAccess">
<complexType>
<sequence>
<element name="activeInactive" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
</sequence>
</complexType>
</element>
<!-- operation response element -->
<element name="SetAccessResponse">
<complexType>
<sequence>
</sequence>
</complexType>
</element>
</schema>
</types>
<message name="SetAccess">
<part name="parameters" element="tt:SetAccess"/>
</message>
<message name="SetAccessResponse">
<part name="parameters" element="tt:SetAccessResponse"/>
</message>
<portType name="testPortType">
<operation name="SetAccess">
<documentation>SetAccess</documentation>
<input message="tns:SetAccess"/>
<output message="tns:SetAccessResponse"/>
</operation>
</portType>
<binding name="test" type="tns:testPortType">
<SOAP:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="SetAccess">
<SOAP:operation soapAction=""/>
<input>
<SOAP:body parts="parameters" use="literal"/>
</input>
<output>
<SOAP:body parts="parameters" use="literal"/>
</output>
</operation>
</binding>
<service name="test">
<documentation>gSOAP 2.7.6e generated service definition</documentation>
<port name="test" binding="tns:test">
<SOAP:address location="http://localhost:80/gsoap/gsoap_ssl.dll?test"/>
</port>
</service>
</definitions>
Generated code:
axis2_char_t text_value_1[64];
text_value_1 = (SetAccess->attrib_activeInactive)?"true":"false"; // Compile error on this line
The text value should be assigned like:
strcpy( text_value_1, (SetAccess->attrib_activeInactive)?"true":"false" );
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
[jira] Resolved: (AXIS2-2271) [Axis2] WSDL2C boolean not handled
correctly - code does not compile
Posted by "Amila Chinthaka Suriarachchi (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AXIS2-2271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Amila Chinthaka Suriarachchi resolved AXIS2-2271.
-------------------------------------------------
Resolution: Fixed
please report this issue at http://ws.apache.org/axis2/c/
> [Axis2] WSDL2C boolean not handled correctly - code does not compile
> --------------------------------------------------------------------
>
> Key: AXIS2-2271
> URL: https://issues.apache.org/jira/browse/AXIS2-2271
> Project: Axis 2.0 (Axis2)
> Issue Type: Bug
> Components: codegen
> Affects Versions: nightly
> Environment: Windows XP, Visual Studio 2003 C++.
> Reporter: Dave Meier
> Priority: Blocker
> Fix For: nightly
>
>
> I have a boolean type in my WSDL and code is generated that fails to compile.
> WSDL:
> <?xml version="1.0" encoding="UTF-8"?>
> <definitions name="test"
> targetNamespace="http://localhost:80/gsoap/test.wsdl"
> xmlns:tns="http://localhost:80/gsoap/test.wsdl"
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
> xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
> xmlns:tt="urn:test"
> xmlns:SOAP="http://schemas.xmlsoap.org/wsdl/soap/"
> xmlns:MIME="http://schemas.xmlsoap.org/wsdl/mime/"
> xmlns:DIME="http://schemas.xmlsoap.org/ws/2002/04/dime/wsdl/"
> xmlns:WSDL="http://schemas.xmlsoap.org/wsdl/"
> xmlns="http://schemas.xmlsoap.org/wsdl/">
> <types>
> <schema targetNamespace="urn:test"
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
> xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
> xmlns:tt="urn:test"
> xmlns="http://www.w3.org/2001/XMLSchema"
> elementFormDefault="qualified"
> attributeFormDefault="qualified">
> <import namespace="http://www.w3.org/2001/10/xml-exc-c14n#"/>
> <import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/>
> <import namespace="http://www.w3.org/2000/09/xmldsig#"/>
> <import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"/>
> <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
> <simpleType name="Attachment-Access-Type">
> <restriction base="xsd:string">
> <enumeration value="ATTACHACCESS-DEFAULT"/>
> <enumeration value="ATTACHACCESS-RESTRICTED"/>
> <enumeration value="ATTACHACCESS-UNRESTRICTED"/>
> </restriction>
> </simpleType>
> <!-- operation request element -->
> <element name="SetAccess">
> <complexType>
> <sequence>
> <element name="activeInactive" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
> </sequence>
> </complexType>
> </element>
> <!-- operation response element -->
> <element name="SetAccessResponse">
> <complexType>
> <sequence>
> </sequence>
> </complexType>
> </element>
> </schema>
> </types>
> <message name="SetAccess">
> <part name="parameters" element="tt:SetAccess"/>
> </message>
> <message name="SetAccessResponse">
> <part name="parameters" element="tt:SetAccessResponse"/>
> </message>
> <portType name="testPortType">
> <operation name="SetAccess">
> <documentation>SetAccess</documentation>
> <input message="tns:SetAccess"/>
> <output message="tns:SetAccessResponse"/>
> </operation>
> </portType>
> <binding name="test" type="tns:testPortType">
> <SOAP:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
> <operation name="SetAccess">
> <SOAP:operation soapAction=""/>
> <input>
> <SOAP:body parts="parameters" use="literal"/>
> </input>
> <output>
> <SOAP:body parts="parameters" use="literal"/>
> </output>
> </operation>
> </binding>
> <service name="test">
> <documentation>gSOAP 2.7.6e generated service definition</documentation>
> <port name="test" binding="tns:test">
> <SOAP:address location="http://localhost:80/gsoap/gsoap_ssl.dll?test"/>
> </port>
> </service>
> </definitions>
> Generated code:
> axis2_char_t text_value_1[64];
> text_value_1 = (SetAccess->attrib_activeInactive)?"true":"false"; // Compile error on this line
> The text value should be assigned like:
> strcpy( text_value_1, (SetAccess->attrib_activeInactive)?"true":"false" );
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org
[jira] Updated: (AXIS2-2271) [Axis2] WSDL2C boolean not handled
correctly - code does not compile
Posted by "Dave Meier (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/AXIS2-2271?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dave Meier updated AXIS2-2271:
------------------------------
Priority: Blocker (was: Major)
> [Axis2] WSDL2C boolean not handled correctly - code does not compile
> --------------------------------------------------------------------
>
> Key: AXIS2-2271
> URL: https://issues.apache.org/jira/browse/AXIS2-2271
> Project: Axis 2.0 (Axis2)
> Issue Type: Bug
> Components: codegen
> Affects Versions: nightly
> Environment: Windows XP, Visual Studio 2003 C++.
> Reporter: Dave Meier
> Priority: Blocker
> Fix For: nightly
>
>
> I have a boolean type in my WSDL and code is generated that fails to compile.
> WSDL:
> <?xml version="1.0" encoding="UTF-8"?>
> <definitions name="test"
> targetNamespace="http://localhost:80/gsoap/test.wsdl"
> xmlns:tns="http://localhost:80/gsoap/test.wsdl"
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
> xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
> xmlns:tt="urn:test"
> xmlns:SOAP="http://schemas.xmlsoap.org/wsdl/soap/"
> xmlns:MIME="http://schemas.xmlsoap.org/wsdl/mime/"
> xmlns:DIME="http://schemas.xmlsoap.org/ws/2002/04/dime/wsdl/"
> xmlns:WSDL="http://schemas.xmlsoap.org/wsdl/"
> xmlns="http://schemas.xmlsoap.org/wsdl/">
> <types>
> <schema targetNamespace="urn:test"
> xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
> xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
> xmlns:c14n="http://www.w3.org/2001/10/xml-exc-c14n#"
> xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
> xmlns:ds="http://www.w3.org/2000/09/xmldsig#"
> xmlns:wsse="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"
> xmlns:tt="urn:test"
> xmlns="http://www.w3.org/2001/XMLSchema"
> elementFormDefault="qualified"
> attributeFormDefault="qualified">
> <import namespace="http://www.w3.org/2001/10/xml-exc-c14n#"/>
> <import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"/>
> <import namespace="http://www.w3.org/2000/09/xmldsig#"/>
> <import namespace="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"/>
> <import namespace="http://schemas.xmlsoap.org/soap/encoding/"/>
> <simpleType name="Attachment-Access-Type">
> <restriction base="xsd:string">
> <enumeration value="ATTACHACCESS-DEFAULT"/>
> <enumeration value="ATTACHACCESS-RESTRICTED"/>
> <enumeration value="ATTACHACCESS-UNRESTRICTED"/>
> </restriction>
> </simpleType>
> <!-- operation request element -->
> <element name="SetAccess">
> <complexType>
> <sequence>
> <element name="activeInactive" type="xsd:boolean" minOccurs="1" maxOccurs="1"/>
> </sequence>
> </complexType>
> </element>
> <!-- operation response element -->
> <element name="SetAccessResponse">
> <complexType>
> <sequence>
> </sequence>
> </complexType>
> </element>
> </schema>
> </types>
> <message name="SetAccess">
> <part name="parameters" element="tt:SetAccess"/>
> </message>
> <message name="SetAccessResponse">
> <part name="parameters" element="tt:SetAccessResponse"/>
> </message>
> <portType name="testPortType">
> <operation name="SetAccess">
> <documentation>SetAccess</documentation>
> <input message="tns:SetAccess"/>
> <output message="tns:SetAccessResponse"/>
> </operation>
> </portType>
> <binding name="test" type="tns:testPortType">
> <SOAP:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
> <operation name="SetAccess">
> <SOAP:operation soapAction=""/>
> <input>
> <SOAP:body parts="parameters" use="literal"/>
> </input>
> <output>
> <SOAP:body parts="parameters" use="literal"/>
> </output>
> </operation>
> </binding>
> <service name="test">
> <documentation>gSOAP 2.7.6e generated service definition</documentation>
> <port name="test" binding="tns:test">
> <SOAP:address location="http://localhost:80/gsoap/gsoap_ssl.dll?test"/>
> </port>
> </service>
> </definitions>
> Generated code:
> axis2_char_t text_value_1[64];
> text_value_1 = (SetAccess->attrib_activeInactive)?"true":"false"; // Compile error on this line
> The text value should be assigned like:
> strcpy( text_value_1, (SetAccess->attrib_activeInactive)?"true":"false" );
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org