cc_value_config.xml manipulation and setting

Post here questions and problems related to oXygen frameworks/document types.
Vangelis
Posts: 4

cc_value_config.xml manipulation and setting

Thu Jun 30, 2016 5:50 pm

Dear Support,

Is an API available to set the content of cc_value_config.xml better than leaving the component always load this file from classpath.

To clarify we will need to provide the content completion configuration file dynamically to this API.

Best regards.
Radu
Posts: 5129

Re: cc_value_config.xml manipulation and setting

Thu Jun 30, 2016 6:06 pm

Hi,

If you edit the document type association for your type of document in the Document Type Association preferences page, in the Extensions tab you can set a content completion handler which extends the Java API ro.sync.contentcompletion.xml.SchemaManagerFilter.

https://www.oxygenxml.com/doc/versions/18.0/ug-editor/topics/dg-author-content-completion-handler.html

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
Vangelis
Posts: 4

Re: cc_value_config.xml manipulation and setting

Thu Jun 30, 2016 6:25 pm

Hello Radu,

We know the possibility you are talking about, but the goal was to reuse what you are proposing via the configuration completion parameter file.

Is there a way to tell to the completion Api to load/refresh the xml configuration file based on the structure/schema we have setup).

Or use case :
- we have another external xml rules from wich we have to extract restriction (element, attribute value) each time we open a document in Author component.
- then we have to provide this restriction to the content completion in Author component.
- ou idea was to generate dynamically the cc_value_config.xml content in order to be able to update the rules dynamically.
- another idea was to have default cc_value_config.xml (as today) and be able to overide/complete it if external xml rules are detected.

We would like to keep the cc_value_config file mecanism, if possible.

Best regards
Radu
Posts: 5129

Re: cc_value_config.xml manipulation and setting

Fri Jul 01, 2016 9:30 am

Hi,

Sorry but the XML configuration file is a static way to filter out content completion elements/attributes and the same configuration is cached and reused between multiple XML documents which belong to the same document type configuration.
So you will have to create your own SchemaManagerFilter Java implementation.

Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com

Return to “SDK-API, Frameworks - Document Types”

Who is online

Users browsing this forum: No registered users and 0 guests