This repository was archived by the owner on Mar 12, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6
Simpler xml parsing #211
Closed
Closed
Simpler xml parsing #211
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…mes. Add support for XInclude.
…) throwing errors.
Contributor
Author
|
I added support for concatenating pre-existing StringT parameters, rather than overwriting. This is needed for HCAL_CFGSCRIPT. The syntax is, e.g., |
Collaborator
|
This should close #28, right? |
Collaborator
|
no, #219 aka GrandMaster should. |
kakwok
suggested changes
Jan 27, 2017
| } else { | ||
| functionManager.getHCALparameterSet().put(new FunctionManagerParameter<StringT>(parameterName, new StringT(parameterValue))); | ||
| } | ||
| break; |
Collaborator
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this line is needed.
| //} | ||
|
|
||
| } catch ( DOMException | ParserConfigurationException | SAXException | IOException e) { | ||
| logger.error("[HCAL " + functionManager.FMname + "]: Got an error when parsing masterSnippet: " + e.getMessage()); |
Collaborator
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We should goToError when MasterSnippet is not a well-formed XML
goToError when mastersnippet is a malformed XML
kakwok
approved these changes
Jan 27, 2017
Member
|
Are there plans for this PR? |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Working version of new master snippet parser enforcing XML tag <=> FM parameter (#170). Replaces the previous include method (which used HCALxmlHandler::readFile()) with XInclude. Also adds support for specifying VectorT, and MapT parameters in JSON format, which are parsed with the rcms JsonUtil (for example, [1,2,3] or {"key1":"value1","key2":"value2"}).