Re: Script Context custom Bindings for engines
Hi Mike, Is there any sample of an AdapterFactory, so that I can document this? AFAIK, there isn´t any example so far. However, the own OCM bundle implementation is based on an AdapterFactory [1]. So, I understand this might be a good starting point. This service is registered as OSGi service through a constructor method, but I suppose this migth be done using declarative services as it´s done in [2]. Pretty straightforward. Regards, Juanjo. [1] http://svn.apache.org/repos/asf/sling/trunk/bundles/jcr/ocm/src/main/java/org/apache/sling/jcr/ocm/impl/OcmAdapterFactory.java [2] http://svn.apache.org/repos/asf/sling/trunk/bundles/extensions/adapter/src/main/java/org/apache/sling/adapter/internal/AdapterManagerImpl.java
Re: Script Context custom Bindings for engines
If you mean mapping jcr nodes to domain objects you might want to use OCM [1]. You have an example appying OCM at [2]. And if you want to hand-craft the adapters you may even want to implement an AdapterFactory.. Maybe even better than OCM because it wouldn´t be tied up with JCR. Juanjo.
RE: Script Context custom Bindings for engines
Hi Felix, hi Juanjo If you mean mapping jcr nodes to domain objects you might want to use OCM [1]. You have an example appying OCM at [2]. And if you want to hand-craft the adapters you may even want to implement an AdapterFactory.. Maybe even better than OCM because it wouldn´t be tied up with JCR. Juanjo. Is there any sample of an AdapterFactory, so that I can document this? best regards mike