cayenne-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From John Huss <johnth...@gmail.com>
Subject Adding a DI binding
Date Sun, 01 Jul 2012 17:16:23 GMT
I'm trying to add a new DI binding and it's not working so I could use some
help.

At the usage site I have this:

    *@Inject* private *ToManyCollectionFactory* *collectionFactory*;

    @Override

    public Object resolveFault(Persistent sourceObject, String
relationshipName) {

        return *collectionFactory*.createToManyList(sourceObject,
relationshipName);

    }

The module is configured like so:

        binder.bind(*ToManyCollectionFactory*.class
).to(DefaultToManyCollectionFactory.class);

But the collectionFactory is always null - it's not being injected.  What
do I need to be doing?

I'll attach the complete patch for reference.


Thanks,

John

Mime
  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message