-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
URI as a constant value #142
Comments
@BenjaminHofstetter Yes, it is related, but not the same. I declare URI templates outside the mappings, in a dedicated templates file. But templates ask for a value, typically from a referenced field or column. So I cannot do what I want to do with a template. My property value is a constant URI. |
No, the IRI value of the prefix itself cannot be used as constant. But with XRM version 1.2.0 comes support for using a class, property or datatype from a vocabulary as a constant value. Because
XRM version 1.2.0 is not officially released yet, but there is a preview build. I can give you the installation instructions, in case you are interested in using the preview build. What are you using: Eclipse of vscode? Another workaround is to use a template with fake (unused) parameter and ignore the warnings that are shown:
|
@mchlrch Version 1.2.0 sounds promising. I'd rather do that than ignore the warnings. I am using vscode, so could test the preview (or wait a bit). |
This comment was marked as outdated.
This comment was marked as outdated.
@mchlrch Thanks for the extension preview. Will test it, but have only Java 8 at the moment. |
@mchlrch a little bit later ... I am on XRM version 1.3, and your example above should work. It doesn't, because using that class declaration does not update declarations in the mapping file: I do (in mapping.xrm):
If I use it in |
@oschihin That sounds like a bug. Thanks for reporting it |
If the property value is a constant, but a URI, not a literal, can I use the prefixes defined in
vocabularies.xrm
?My point illustrated. I have a mapping:
The URI used as constant value is defined like this:
I want to use the prefix.
Is there a way or another idea?
The text was updated successfully, but these errors were encountered: