私の xsd スキーマには、27 個の要素を持つ complexType "expression" があり、それらすべてが共通の complexType "StepElement" を拡張しています。次に、complexType 式のサンプルを示します (簡単にするために、8 つだけを示しています)。
<xs:complexType name="expression">
<xs:sequence maxOccurs="unbounded">
<xs:element name="STEP_ANIMATION" type="Animation_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_EXPECT_REPLY" type="Expect_Reply_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_RESTART" type="Restart_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_REDIRECT" type="Redirect_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_SUBGOAL" type="Subgoal_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_TIMER" type="Timer_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_SITUATION" type="Situation_Attributes" minOccurs="0" maxOccurs="unbounded"/>
<xs:element name="STEP_SOUND" type="Sound_Attributes" minOccurs="0" maxOccurs="unbounded"/>
</xs:sequence>
<xs:attribute name="ID" type="xs:integer"/>
<xs:attribute name="SUCCESS_EVT" type="xs:string"/>
<xs:attribute name="DELAY" type="xs:float"/>
</xs:complexType>
これらの各要素タイプは次のようになります (これらはすべて StepElement を拡張しますが、異なる属性を持ちます)。
<xs:complexType name="Animation_Attributes">
<xs:complexContent>
<xs:extension base="StepElement">
<xs:attribute name="AGENT" type="xs:string" default="$CURRENTBOT"/>
<xs:attribute name="SUCCESS_EVT" type="xs:string"/>
<xs:attribute name="FAIL_EVT" type="xs:string"/>
</xs:extension>
</xs:complexContent>
</xs:complexType>
StepElement は次のようになります。
<xs:complexType name="StepElement">
<xs:simpleContent>
<xs:extension base="xs:string">
<xs:attribute name="ID" type="xs:integer"/>
<xs:attribute name="ENGLISH" type="xs:string"/>
</xs:extension>
</xs:simpleContent>
今私が抱えている問題は、このスキーマを解析するときに、JAXB が Expression クラスで生成する getter メソッドがこれであるということです
public List<StepElement> getSTEPANIMATIONAndSTEPEXPECTREPLYAndSTEPRESTART()
これが発生する原因となっているスキーマ構造で何か間違ったことをしていますか、またはメソッド名を微調整する解決策はありますか?