2009-08-19 11 views
0

JIRAの問題追跡システムWSDL用のgsoapクラスを生成しようとしています。私は必要なクラスを生成するために、これらのコマンドを実行します。gsoapクラス生成の問題

$ wsdl2h -o JIRASoap.h <url to wsdl> 
$ soapcpp2 -C JIRASoap.h

はsoapcpp2コマンドでは、次のような出力が得られますが、それを修正する方法を示すものではありません。

There were errors: 
3 syntax errors 
1 semantic error 
2 warnings

これらのエラー(のほとんど)は次のとおりです。ここ

JIRASoap.h(935): syntax error 
JIRASoap.h(934): Syntax error: input before ; skipped 
JIRASoap.h(940): syntax error 
JIRASoap.h(939): Syntax error: input before ; skipped 

JIRASoap.h(942): **ERROR**: Duplicate declaration of __size (already declarared at line 937) 

JIRASoap.h(947): syntax error 
JIRASoap.h(946): Syntax error: input before ; skipped

はJIRASoap.hの関連部分(行928から947)である:

/// SOAP encoded array of xs:byte[] 
class ArrayOf_USCORExsd_USCOREbase64Binary 
{ public: 
/// SOAP encoded array of xs:byte 
class 
{ public: 
/// Pointer to array of xsd__byte. 
    xsd__byte       *__ptr       ; 
/// Size of the dynamic array. 
    int         __size      ; 
/// Offset for partially transmitted arrays (uncomment only when required). 
// int         __offset      ; 
    }         *__ptr       ; 
/// Size of the dynamic array. 
    int         __size      ; 
/// Offset for partially transmitted arrays (uncomment only when required). 
// int         __offset      ; 
/// A handle to the soap struct that manages this instance (automatically set) 
    struct soap       *soap       ; 
};

私がしようとすると、私のプログラムをコンパイルすると、私はこのエラーになります:

soapStub.h:2799: error: ISO C++ forbids declaration of ‘ArrayOf_USCORExsd_USCOREbase64Binary’ with no type

ここではWSDLの関連セクションさ:

<complexType name="ArrayOf_xsd_base64Binary"> 
    <complexContent> 
    <restriction base="soapenc:Array"> 
     <attribute ref="soapenc:arrayType" wsdl:arrayType="xsd:byte[][]"/> 
    </restriction> 
    </complexContent> 
</complexType>

は、私の知る限り、ほとんどの種類はsoapStub.hで定義されていますが、ArrayOf_USCORExsd_USCOREbase64Binaryではありません。

私はCのみのファイルを生成すると、 "ArrayOf_USCORExsd_USCOREbase64Binary"の代わりに "struct/*?* /"を取得します。

答えて

0

I、クラス自体及び(パラメータとしてArrayOf_USCORExsd_USCOREbase64Binaryへのポインタを取る)ns4_addAttachmentsToIssue法を含むJIRASoap.hからArrayOf_USCORExsd_USCOREbase64Binaryへのすべての参照を除去することにより、コンパイルするためのコードを得ることができました。

ns4_addAttachmentsToIssueを削除せずに上記のエラーを修正する方法が見つかった場合は、教えてください。