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 "Andreas Weck (JIRA)" <ji...@apache.org> on 2008/04/01 15:10:24 UTC
[jira] Created: (AXIS2-3689)
java.lang.String.valueOf(param).matches() work not with boolean param
java.lang.String.valueOf(param).matches() work not with boolean param
---------------------------------------------------------------------
Key: AXIS2-3689
URL: https://issues.apache.org/jira/browse/AXIS2-3689
Project: Axis 2.0 (Axis2)
Issue Type: Bug
Components: codegen
Affects Versions: 1.3
Reporter: Andreas Weck
Priority: Minor
If you generate code with the follwoing XSD:
<xs:element name="XY">
<xs:simpleType>
<xs:restriction base="xs:boolean">
<xs:pattern value="[01]"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
you will have a class with the method:
public void setXY_type0(boolean param) {
if (java.lang.String.valueOf(param).matches("[01]")) {
this.localXY_type0 = param;
} else {
throw new java.lang.RuntimeException();
}
}
The Problem:
The return value of java.lang.String.valueOf(param).matches("[01]") never can be true!!! java.lang.String.valueOf(boolean) returns "true" or "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