Merge pull request #28 from Cloudyle/issue-#26

Thanks for the submission! Looks good to me.
This commit is contained in:
James Agnew 2014-09-26 09:32:35 -04:00
commit e4009bcb4a
1 changed files with 7 additions and 1 deletions

View File

@ -741,7 +741,13 @@ class ParserState<T> {
@Override
public void attributeValue(String theName, String theValue) throws DataFormatException {
if ("contentType".equals(theName)) {
if ("id".equals(theName)) {
if (myInstance instanceof IIdentifiableElement) {
((IIdentifiableElement) myInstance).setElementSpecificId((theValue));
} else if (myInstance instanceof IResource) {
((IResource) myInstance).setId(new IdDt(theValue));
}
} else if ("contentType".equals(theName)) {
myInstance.setContentType(theValue);
} else if (myJsonMode && "value".equals(theName)) {
string(theValue);