How to override the default DocumentsInputResolver in a component

I need to override the DocumentsInputResolver which is in :

org.nuxeo.ecm.automation.server.jaxrs.io.resolvers.DocumentsInputResolver

so I can handle space at the end of paths. But I don't know how.

https://answers.nuxeo.com/questions/644/how-to-use-input-when-path-contains-space-at-the-end/646

I haven't found doc on how to override an existing class. So

  1. What will be in the ?-contrib.xml file?
  2. Where will be the activate method in which I should put the JsonRequestReader.addInputResolver(new MyDocumentsInputResolver()); line
0 votes

1 answers

819 views

ANSWER



For examples of the -contrib.xml file and the activate method check out this chapter “9.3. A word from our sponsors at OSGi” in: DevBook, Ch 9

That same book will also help you with general understanding of contributing to nuxeo code. DevBook

However, for the most up-to-date information please use this book only along with the information on doc.nuxeo.com and answers.nuxeo.com, which have all the newest changes and additions to the platform.

Here again the links that I already provided in the other question you quoted above. They provide definitions, architectural description as well as examples of components in Nuxeo:

How-to implement an Action
Dev Cookbook
Component model overview
Component list, component API

Another good idea would be for you to try to use Nuxeo's Eclipse plugin Nuxeo-IDE which let you automatically create and test Nuxeo components and other boilerplate or more advanced code. NuxeoIDE

1 votes