|
Re: importURI semantics [message #786523 is a reply to message #786452] |
Mon, 30 January 2012 14:26 |
Henrik Rentz-Reichert Messages: 261 Registered: July 2009 |
Senior Member |
|
|
Hi Klaus,
relative paths should work. Please double check!
If you you are forced to use absolute paths (e.g. because of different drive letters on a windows machine) you can use the
following form:
import room.basic.types.java from "file:/C:/path/to/modellib/org.eclipse.etrice.modellib/models/JavaTypes.room"
HTH,
Henrik
Am 30.01.2012 13:56, schrieb Klaus Birken:
> Hi eTrice-team,
>
> I am using the importURI feature of eTrice, e.g.,
>
>
> import room.basic.types.java.* from "../../org.eclipse.etrice.modellib/models/JavaTypes.room"
>
>
> However, the org.eclipse.etrice.modellib is part of my Eclipse workspace, but the importing project is somewhere outside the
> workspace (and just imported).
> Unfortunately, eTrice cannot resolve the JavaTypes.room reference - is there the possibility to use a different kind of URI (e.g.
> platform-URI) to resolve cases like mine?
>
> Thanks in advance, regards,
> Klaus
>
>
|
|
|
|
|
Re: importURI semantics [message #787406 is a reply to message #787397] |
Tue, 31 January 2012 14:41 |
Ed Merks Messages: 33113 Registered: July 2009 |
Senior Member |
|
|
In stand-alone mode, you should be able to populate
EcorePlugin.getPlatformResourceMap with mappings for the locations of
all projects. There's even EcorePlugin.handlePlatformResourceOptions
for command line option processing...
On 31/01/2012 3:36 PM, Henrik Rentz-Reichert wrote:
> Hi Klaus,
>
> Am 30.01.2012 16:43, schrieb Klaus Birken:
>> But I experimented a bit and found that the following also works:
>> import room.basic.types.java.* from "platform:/resource/org.eclipse.etrice.modellib/models/JavaTypes.room"
>>
>> This works even if the referencing project physically is stored outside the Eclipse workspace directry. Two interesting questions
>> remain:
>> - Is this supposed to work? :)
> I've never tried. But since Xtext tries to create an EMF URI it's no complete surprise
>> - What happens with platform-URIs when running standalone (I do not have a proper example environment yet so I cannot test this...)?
> The eTrice generator (which is a plain Java application) is not able to deal with the platform: scheme. In this context there is
> no Eclipse Platform available that could help to resolve this...
>> Regards,
>> Klaus
>>
Ed Merks
Professional Support: https://www.macromodeling.com/
|
|
|
Powered by
FUDForum. Page generated in 0.04058 seconds