cayenne-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Øyvind Harboe <oyvind.har...@zylin.com>
Subject Cayenne 3.1 - how to create autoadapter
Date Thu, 10 Feb 2011 08:10:47 GMT
I have a warning that this 'new AutoAdapter(dataSource)' is
deprecated.

What do I do instead?

The implementation of the above uses deprecated methods,
otherwise I would have thought that the source provided the
solution on this one.

While injection is an implementation detail, it is used in the
documentation:

    /**
     * Returns a DbAdapterFactory configured to detect all databases
officially supported
     * by Cayenne.
     *
     * @deprecated since 3.1 in favor of
     *             {@link
org.apache.cayenne.configuration.server.DbAdapterFactory}
     *             configured via dependency injection.
     */
    public static DbAdapterFactory getDefaultFactory() {
        return new DbAdapterFactoryChain(defaultFactories);
    }


-- 
Øyvind Harboe

Can Zylin Consulting help on your project?

US toll free 1-866-980-3434 / International +47 51 87 40 27

http://www.zylin.com/zy1000.html
ARM7 ARM9 ARM11 XScale Cortex
JTAG debugger and flash programmer

Mime
View raw message