Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » GMF Filename - passing it down to model attribute.
GMF Filename - passing it down to model attribute. [message #115922] Mon, 02 April 2007 01:06 Go to next message
Eclipse UserFriend
Originally posted by: evaandoli.dodo.com.au

Hi,
I'd like to pass the filename from the creation wizard down to an attribute
in the model.
I look at the creation wizard classes but must admit I'm struggling to see
where it creates the model impl.
I also puts break points in the model create but looking back up the stack I
can't see the filename anywhere.

I'm sure its there just a few pointers would help thanks,

Stu
Re: GMF Filename - passing it down to model attribute. [message #122086 is a reply to message #115922] Fri, 27 April 2007 02:57 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: renwart.lippmann.lu

Stu a écrit :
> Hi,
> I'd like to pass the filename from the creation wizard down to an attribute
> in the model.
> I look at the creation wizard classes but must admit I'm struggling to see
> where it creates the model impl.
> I also puts break points in the model create but looking back up the stack I
> can't see the filename anywhere.
>
> I'm sure its there just a few pointers would help thanks,
>
> Stu
>
>

Hello, I'd like to do the same as you, but I don't know where (and how?)
the "diagram name" (with full path if possible) is accessible in the
model Impl classes...

Did you find some interesting things for that problem ?

Thanks ,

benren.
Re: GMF Filename - passing it down to model attribute. [message #122097 is a reply to message #122086] Fri, 27 April 2007 03:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: evaandoli.dodo.com.au

Sorry mate, it was a low priority for me and I never got around to it for my
version 1.

I do need to address it though.

Let me know how you go.

Stu

"Ben Renwart" <renwart@lippmann.lu> wrote in message
news:f0s6ov$vjr$1@build.eclipse.org...
> Stu a
<solved>Re: GMF Filename - passing it down to model attribute. [message #123317 is a reply to message #115922] Wed, 02 May 2007 08:07 Go to previous message
Eclipse UserFriend
Originally posted by: evaandoli.dodo.com.au

I finally got around to spending too much time on this and came up with the
following solution:-
Look at class (replace YourDiagramDomain with yours)
<YourDiagramDomain>DiagramEditorUtil

It contains a method called:-
createDiagram(

Which itself contains a method called:-
protected CommandResult doExecuteWithResult(

In here you get access to the top level model created.
So you can do somthing like:-

model.setName(modelURI.path());

Anyway that is how I did it,

Stuart

"Stu" <evaandoli@dodo.com.au> wrote in message
news:euq30h$jeg$1@build.eclipse.org...
> Hi,
> I'd like to pass the filename from the creation wizard down to an
> attribute in the model.
> I look at the creation wizard classes but must admit I'm struggling to see
> where it creates the model impl.
> I also puts break points in the model create but looking back up the stack
> I can't see the filename anywhere.
>
> I'm sure its there just a few pointers would help thanks,
>
> Stu
>
Previous Topic:Passing the diagram filename to a model element property ??
Next Topic:Tracking add child event fired from popup bar, before model is updated.
Goto Forum:
  


Current Time: Mon May 12 16:40:07 EDT 2025

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

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

Back to the top