Hi S L,

You do need a factory here, as JiBX asks for. Look at it from the JiBX
point of view: you have an XML file and want to bind to an object of an
abstract type. Hoe can you do that if you cannot instantiate an abstract
class? This is why JiBX asks for a factory to create a new object of the
desired type, so it can call the setters on that object. How the factory
creates the object is up to you, as long as it's a subclass of the
requested abstract class. You say that you already do set objects that are
subclasses of the 'ForwardLinkProfileData' class. So make a factory that
returns an object of a subtype, so JiBX can use that.
See http://jibx.sourceforge.net/details/binding-attributes.html#object for
details, good luck.

Erik


On Wed, Nov 14, 2012 at 8:01 PM, S L <jibxu...@yahoo.com> wrote:

> I am getting the following error when I run Jibx2Wsdl:
>
> Error: factory-method needed for abstract type
> 'ems.shared.config.ForwardLinkProfileData'; on structure element at (line
> 32, col 91, in config_vmtBinding.xml)
>
> In config_vmtBinding.xml, it has:
>
>   <mapping abstract="true" type-name="ns4:vmtData"
> class="ems.shared.config.vmt.VmtData">
>     <!-- other lines removed -->
>     <!-- this is line 32 -->
>     <structure map-as="ns1:forwardLinkProfileData" field="fl"
> usage="optional" name="fl"/>
>
> So our VmtData class has a private field named "fl" of type
> ForwardLinkProfileData, as well as getFl() and setFl() methods to get and
> set the fl field.  When we call getFl() and setFl(), we are actually
> getting and setting objects that are subclasses of the
> ForwardLinkProfileData class.
>
> I'm not sure how to go about creating a factory method for the
> ForwardLinkProfileData class, since you can't create an instance of an
> abstract class.  Any suggestions on how to resolve this error?
>
>
>
> ------------------------------------------------------------------------------
> Monitor your physical, virtual and cloud infrastructure from a single
> web console. Get in-depth insight into apps, servers, databases, vmware,
> SAP, cloud infrastructure, etc. Download 30-day Free Trial.
> Pricing starts from $795 for 25 servers or applications!
> http://p.sf.net/sfu/zoho_dev2dev_nov
> _______________________________________________
> jibx-users mailing list
> jibx-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jibx-users
>
>


-- 
*Erik Mulder*
Principal Consultant

*m*: +31 6 40 76 45 22
*@*: erik.mul...@qsd.nl


*
QSD B.V.
*Loolaan 89
3971 PM Driebergen-Rijsenburg
t: +31 343 76 41 50
*w*: http://www.qsd.nl/
*@*: i...@qsd.nl

Dit bericht is vertrouwelijk en kan geheime informatie bevatten enkel
bestemd voor de geadresseerde. Indien dit bericht niet voor u is bestemd,
verzoeken wij u dit onmiddellijk aan ons te melden en het bericht te
vernietigen. Aangezien de integriteit van het bericht niet veilig gesteld
is middels verzending via internet, kan QSD niet aansprakelijk worden
gehouden voor de inhoud daarvan. Hoewel wij ons inspannen een virusvrij
netwerk te hanteren, geven wij geen enkele garantie dat dit bericht
virusvrij is, noch aanvaarden wij enige aansprakelijkheid voor de mogelijke
aanwezigheid van een virus in dit bericht. Op al onze rechtsverhoudingen,
aanbiedingen en overeenkomsten waaronder QSD goederen en/of diensten levert
zijn met uitsluiting van alle andere voorwaarden de Leveringsvoorwaarden
van QSD van toepassing. Deze worden u op aanvraag direct kosteloos
toegezonden.

This e-mail and the documents attached are confidential and intended solely
for the addressee; it may also be privileged. If you receive this e-mail in
error, please notify the sender immediately and destroy it. As its
integrity cannot be secured on the Internet, the QSD liability cannot be
triggered for the message content. Although the sender endeavours to
maintain a computer virus-free network, the sender does not warrant that
this transmission is virus-free and will not be liable for any damages
resulting from any virus transmitted. On all offers and agreements under
which QSD supplies goods and/or services of whatever nature, the Terms of
Delivery from QSD exclusively apply. The Terms of Delivery shall be
promptly submitted to you on your request.

QSD B.V.
KvK Utrecht 53067231

<<QSD-icon-gradient.png>>

------------------------------------------------------------------------------
Monitor your physical, virtual and cloud infrastructure from a single
web console. Get in-depth insight into apps, servers, databases, vmware,
SAP, cloud infrastructure, etc. Download 30-day Free Trial.
Pricing starts from $795 for 25 servers or applications!
http://p.sf.net/sfu/zoho_dev2dev_nov
_______________________________________________
jibx-users mailing list
jibx-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jibx-users

Reply via email to