Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » GMF (Graphical Modeling Framework) » Platform-/ file resource problem
Platform-/ file resource problem [message #194916] Mon, 30 June 2008 09:36 Go to next message
Eclipse UserFriend
Originally posted by: balancedblend.gmx.de

Hello,

one of our editors internally uses platform resources instead of file
resources like the others. This causes for example, that the
modification stamp in the document provider cannot be computed, because
no file can be retrieved from the platform resource (very bad in our
case). Does somebody know the reason for this?

Thanks in advance!

Kind regards,
Johannes
Re: Platform-/ file resource problem [message #194956 is a reply to message #194916] Mon, 30 June 2008 13:05 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: cdamus.zeligsoft.com

--=-9rIrwqtuqGRX3kVwqbVD
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hi, Johannes,

In EMF 2.4, the Resource interface now has API for accessing stuff like
the timestamp, for protocols (such as file: and platform:) that can
provide it. Have a look at the Resource::getTimestamp() method for
uniform access to your resources' timestamps.

HTH,

Christian


On Mon, 2008-06-30 at 11:36 +0200, Johannes Koehler wrote:

> Hello,
>
> one of our editors internally uses platform resources instead of file
> resources like the others. This causes for example, that the
> modification stamp in the document provider cannot be computed, because
> no file can be retrieved from the platform resource (very bad in our
> case). Does somebody know the reason for this?
>
> Thanks in advance!
>
> Kind regards,
> Johannes

--=-9rIrwqtuqGRX3kVwqbVD
Content-Type: text/html; charset=utf-8

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.16.0">
</HEAD>
<BODY>
Hi, Johannes,<BR>
<BR>
In EMF 2.4, the Resource interface now has API for accessing stuff like the timestamp, for protocols (such as file: and platform:) that can provide it.&nbsp; Have a look at the Resource::getTimestamp() method for uniform access to your resources' timestamps.<BR>
<BR>
HTH,<BR>
<BR>
Christian<BR>
<BR>
<BR>
On Mon, 2008-06-30 at 11:36 +0200, Johannes Koehler wrote:
<BLOCKQUOTE TYPE=CITE>
<PRE>
<FONT COLOR="#000000">Hello,</FONT>

<FONT COLOR="#000000">one of our editors internally uses platform resources instead of file </FONT>
<FONT COLOR="#000000">resources like the others. This causes for example, that the </FONT>
<FONT COLOR="#000000">modification stamp in the document provider cannot be computed, because </FONT>
<FONT COLOR="#000000">no file can be retrieved from the platform resource (very bad in our </FONT>
<FONT COLOR="#000000">case). Does somebody know the reason for this?</FONT>

<FONT COLOR="#000000">Thanks in advance!</FONT>

<FONT COLOR="#000000">Kind regards,</FONT>
<FONT COLOR="#000000">Johannes</FONT>
</PRE>
</BLOCKQUOTE>
</BODY>
</HTML>

--=-9rIrwqtuqGRX3kVwqbVD--
Re: Platform-/ file resource problem [message #195102 is a reply to message #194956] Tue, 01 July 2008 11:59 Go to previous messageGo to next message
Alexander Shatalin is currently offline Alexander ShatalinFriend
Messages: 2928
Registered: July 2009
Senior Member
Hello Christian,

> Hi, Johannes,
And you can submitt request for GMf to use corresponding methods in the generated
code.

-----------------
Alex Shatalin
Re: Platform-/ file resource problem [message #196349 is a reply to message #194956] Wed, 09 July 2008 17:46 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: balancedblend.gmx.de

Hi Christian,

thanks for your hint. Right now I can't use emf 2.4 for several reasons,
I fixed it in a similar way.
I assume the use of platform resources leads to another problem. Can you
tell me, why the editor uses those platform- instead of file resources?
It depends on the location where the file is stored, but not all editors
behave this way and I don't understand why.

Thanks in advance!

regards,
Johannes
Re: Platform-/ file resource problem [message #196573 is a reply to message #196349] Thu, 10 July 2008 21:44 Go to previous message
Eclipse UserFriend
Originally posted by: cdamus.zeligsoft.com

--=-r9Kjmh46HvRzQLXcKvo9
Content-Type: text/plain
Content-Transfer-Encoding: 7bit

Hi, Johannes,

It is generally recommended, in the Eclipse environment, to use the
platform: scheme URIs to access resources in the Eclipse environment.
This includes resources in the workspace, installed plugins, workspace
meta-data area, configuration meta-data area, and something else that I
forget at the moment.

Using platform URIs should solve more problems than it produces. The
benefit of these URIs is that they are portable; the don't depend on the
location of files in the user's filesystem. For shared resources, such
as workspace files shared in CVS or installed plug-ins, you don't want
URIs in your models that depend on a particular users's installed
location of Eclipse. These platform URIs abstract away that detail.

IMHO, editors that don't use platform URIs are broken! ;-)

Cheers,

Christian

On Wed, 2008-07-09 at 19:46 +0200, Johannes Koehler wrote:

> Hi Christian,
>
> thanks for your hint. Right now I can't use emf 2.4 for several reasons,
> I fixed it in a similar way.
> I assume the use of platform resources leads to another problem. Can you
> tell me, why the editor uses those platform- instead of file resources?
> It depends on the location where the file is stored, but not all editors
> behave this way and I don't understand why.
>
> Thanks in advance!
>
> regards,
> Johannes

--=-r9Kjmh46HvRzQLXcKvo9
Content-Type: text/html; charset=utf-8

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 TRANSITIONAL//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV="Content-Type" CONTENT="text/html; CHARSET=UTF-8">
<META NAME="GENERATOR" CONTENT="GtkHTML/3.16.0">
</HEAD>
<BODY>
Hi, Johannes,<BR>
<BR>
It is generally recommended, in the Eclipse environment, to use the platform: scheme URIs to access resources in the Eclipse environment.&nbsp; This includes resources in the workspace, installed plugins, workspace meta-data area, configuration meta-data area, and something else that I forget at the moment.<BR>
<BR>
Using platform URIs should solve more problems than it produces.&nbsp; The benefit of these URIs is that they are portable; the don't depend on the location of files in the user's filesystem.&nbsp; For shared resources, such as workspace files shared in CVS or installed plug-ins, you don't want URIs in your models that depend on a particular users's installed location of Eclipse.&nbsp; These platform URIs abstract away that detail.<BR>
<BR>
IMHO, editors that don't use platform URIs are broken!&nbsp; ;-)<BR>
<BR>
Cheers,<BR>
<BR>
Christian<BR>
<BR>
On Wed, 2008-07-09 at 19:46 +0200, Johannes Koehler wrote:
<BLOCKQUOTE TYPE=CITE>
<PRE>
<FONT COLOR="#000000">Hi Christian,</FONT>

<FONT COLOR="#000000">thanks for your hint. Right now I can't use emf 2.4 for several reasons, </FONT>
<FONT COLOR="#000000">I fixed it in a similar way.</FONT>
<FONT COLOR="#000000">I assume the use of platform resources leads to another problem. Can you </FONT>
<FONT COLOR="#000000">tell me, why the editor uses those platform- instead of file resources? </FONT>
<FONT COLOR="#000000">It depends on the location where the file is stored, but not all editors </FONT>
<FONT COLOR="#000000">behave this way and I don't understand why.</FONT>

<FONT COLOR="#000000">Thanks in advance!</FONT>

<FONT COLOR="#000000">regards,</FONT>
<FONT COLOR="#000000">Johannes</FONT>
</PRE>
</BLOCKQUOTE>
</BODY>
</HTML>

--=-r9Kjmh46HvRzQLXcKvo9--
Previous Topic:Exception "cannot modify a resource set without a write transaction"
Next Topic:Double click to open problem caused by label
Goto Forum:
  


Current Time: Mon May 25 06:17:45 GMT 2020

Powered by FUDForum. Page generated in 0.02237 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top