DatabaseClientFactory.Bean clientFactoryBean = makeClientBeanFactory(); clientFactoryBean.getHandleRegistry().register( JAXBHandle.newFactory(Product.class) );
: clientFactoryBean.getHandleRegistry();
/** * Creates a client for bean applications based on the properties. * Other applications can use the static newClient() factory methods * of DatabaseClientFactory. * The client accesses the database by means of a REST server. * @return a new client for making database requests */ public DatabaseClient newClient() { DatabaseClientImpl client = (DatabaseClientImpl) DatabaseClientFactory.newClient( host, port, database, (securityContext!=null? securityContext:makeSecurityContext(user, password, authentication, context, verifier)), connectionType); client.setHandleRegistry(getHandleRegistry().copy()); return client; } }
/** * Initializes a handle registry with the default associations * between the content handles provided by the API and the supported * IO representation classes. Use this method only after clearing * or overwriting associations in the handle registry. */ public void registerDefaultHandles() { HandleFactoryRegistryImpl.registerDefaults(getHandleRegistry()); }
/** * Creates a client for bean applications based on the properties. * Other applications can use the static newClient() factory methods * of DatabaseClientFactory. * The client accesses the database by means of a REST server. * @return a new client for making database requests */ public DatabaseClient newClient() { DatabaseClientImpl client = newClientImpl(host, port, user, password, authentication, context, verifier); client.setHandleRegistry(getHandleRegistry().copy()); return client; } }
/** * Initializes a handle registry with the default associations * between the content handles provided by the API and the supported * IO representation classes. Use this method only after clearing * or overwriting associations in the handle registry. */ public void registerDefaultHandles() { HandleFactoryRegistryImpl.registerDefaults(getHandleRegistry()); }