Get Attribute Value from Bookmeta node
Having trouble deploying Oxygen XML Web Author? Got a bug to report? Post it all here.
-
- Posts: 9431
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Get Attribute Value from Bookmeta node
Hi Vivek,
Maybe you can give more details, is this for editing, is this for publishing? If it's publishing to what output format is it? If it's PDF publishing, do you publish using our CSS-based processor or the classic XSL-FO processor?
Is your question related to an XSLT customization where you attempt to retrieve information from the bookmeta element? If so what have you tried so far?
Regards,
Radu
Maybe you can give more details, is this for editing, is this for publishing? If it's publishing to what output format is it? If it's PDF publishing, do you publish using our CSS-based processor or the classic XSL-FO processor?
Is your question related to an XSLT customization where you attempt to retrieve information from the bookmeta element? If so what have you tried so far?
Regards,
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 37
- Joined: Mon Jul 14, 2014 9:48 am
Re: Get Attribute Value from Bookmeta node
Hi Radu,
It's not for either of them. I want it for making a rest api call based on the bookmap opened in the editor. I have tried with select node and get the attribute values but with no success. Also that will not be suitable for my requirement as I need to get the details of the bookmap as soon as the bookmap is loaded in the editor.
Any help is appreciated.
Regards,
Vivek.
It's not for either of them. I want it for making a rest api call based on the bookmap opened in the editor. I have tried with select node and get the attribute values but with no success. Also that will not be suitable for my requirement as I need to get the details of the bookmap as soon as the bookmap is loaded in the editor.
Any help is appreciated.
Regards,
Vivek.
-
- Posts: 9431
- Joined: Fri Jul 09, 2004 5:18 pm
Re: Get Attribute Value from Bookmeta node
Hi,
If you already have a workspace access plugin for Oxygen, maybe you can evaluate an XPath expression after an XML document is opened, something like:
Regards,
Radu
If you already have a workspace access plugin for Oxygen, maybe you can evaluate an XPath expression after an XML document is opened, something like:
Code: Select all
@Override
public void applicationStarted(StandalonePluginWorkspace pluginWorkspaceAccess) {
pluginWorkspaceAccess.addEditorChangeListener(new WSEditorChangeListener() {
public void editorOpened(URL editorLocation) {
WSEditor editorAccess = pluginWorkspaceAccess.getEditorAccess(editorLocation, PluginWorkspace.MAIN_EDITING_AREA);
WSEditorPage currentPage = editorAccess.getCurrentPage();
if(currentPage instanceof WSAuthorEditorPage) {
WSAuthorEditorPage authorPage = (WSAuthorEditorPage) currentPage;
try {
Object[] result = authorPage.getDocumentController().evaluateXPath("//bookmeta/*/@someattribute", false, false, false);
} catch (AuthorOperationException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
};
}, PluginWorkspace.MAIN_EDITING_AREA);
}
Radu
Radu Coravu
<oXygen/> XML Editor
http://www.oxygenxml.com
<oXygen/> XML Editor
http://www.oxygenxml.com
-
- Posts: 81
- Joined: Wed Jul 20, 2016 8:22 am
Re: Get Attribute Value from Bookmeta node
Post by mihai_coanda »
Hello,
The approach Radu suggested also works for Oxygen XML Web Author.
Regards,
Michael
The approach Radu suggested also works for Oxygen XML Web Author.
Regards,
Michael
Michael
https://www.oxygenxml.com
https://www.oxygenxml.com
Jump to
- Oxygen XML Editor/Author/Developer
- ↳ Feature Request
- ↳ Common Problems
- ↳ DITA (Editing and Publishing DITA Content)
- ↳ SDK-API, Frameworks - Document Types
- ↳ DocBook
- ↳ TEI
- ↳ XHTML
- ↳ Other Issues
- Oxygen XML Web Author
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Content Fusion
- ↳ Feature Request
- ↳ Common Problems
- Oxygen JSON Editor
- ↳ Feature Request
- ↳ Common Problems
- Oxygen PDF Chemistry
- ↳ Feature Request
- ↳ Common Problems
- Oxygen Feedback
- ↳ Feature Request
- ↳ Common Problems
- Oxygen XML WebHelp
- ↳ Feature Request
- ↳ Common Problems
- XML
- ↳ General XML Questions
- ↳ XSLT and FOP
- ↳ XML Schemas
- ↳ XQuery
- NVDL
- ↳ General NVDL Issues
- ↳ oNVDL Related Issues
- XML Services Market
- ↳ Offer a Service