私は、インターフェイスがある WSDLの生成正しく
class MySvcEndpoint implements MySvc_SEI {
public SomeOtherComplexType[] myCall(String[] argStrings)
throws javax.xml.soap.SOAPException
{
.
.
}
}
として
エンドポイントがコード化されているのWebsphere 6.1 Java2WSDLのアリのタスクを使用してエンドポイントクラスからWSDLファイルを生成しようとしています:
:WSDLが生成さpublic interface MySvc_SEI extends java.rmi.Remote {
public SomeOtherComplexType[] myCall(String[] argStrings)
throws javax.xml.soap.SOAPException;
}
には、次のエントリが含まれています210
<element name="myCall">
<complexType>
<sequence/>
</complexType>
</element>
<element name="myCallResponse">
<complexType>
<sequence/>
</complexType>
</element>
「argStrings」引数は消えましたが、の何かがあると認識されているようですが、があるはずです。また、戻り値の型も消えているようです。とにかく
、私はWSDLに基づいてスタブを生成する場合、生成されたインターフェイスは次のとおりです。
public interface MySvc {
public void myCall() throws java.rmi.RemoteException;
}
は、誰もが前に、この問題に遭遇しており、もしそうならどのように解決したのですか?
おかげ
[編集] OK、入力引数として配列があるときのようです。私は、次のことを試してみた:
public int m1(String s1) throws SOAPException {
return 0;
}
public int[] m2(String s1) throws SOAPException {
int[] a = { 0 };
return a;
}
public int m3(String[] sArr) throws SOAPException {
return 0;
}
public int[] m4(String[] sArr) throws SOAPException {
int[] a = { 0 };
return a;
}
と、次のWSDL出力を得:
<element name="m1">
<complexType>
<sequence>
<element name="s1" nillable="true" type="xsd:string"/>
</sequence>
</complexType>
</element>
<element name="m1Response">
<complexType>
<sequence>
<element name="m1Return" type="xsd:int"/>
</sequence>
</complexType>
</element>
<element name="m2">
<complexType>
<sequence>
<element name="s1" nillable="true" type="xsd:string"/>
</sequence>
</complexType>
</element>
<element name="m2Response">
<complexType>
<sequence>
<element name="m2Return" nillable="true" type="impl:ArrayOf_1368777266_int"/>
</sequence>
</complexType>
</element>
<element name="m3">
<complexType>
<sequence/>
</complexType>
</element>
<element name="m3Response">
<complexType>
<sequence/>
</complexType>
</element>
<element name="m4">
<complexType>
<sequence/>
</complexType>
</element>
<element name="m4Response">
<complexType>
<sequence/>
</complexType>
</element>
あなたが見ることができるように、簡単な引数を持つメソッドがOKに生成されたが、配列引数を持つメソッドがねじ込まれました。
これを修正しました。 WSDLを生成するWASが6.1.0.0であったことがわかります。私は修正プログラム23を基本インストールに適用し、WSDLが正しくインストールされるようになりました。 – GKelly
質問はもう開いていないので、私は自分自身で質問に答えて、それをただ受け入れるべきですか? – GKelly
お願いします。それ以外の場合は未回答のカテゴリにとどまります。 – user918176