BTW can't we use Glamour announcements? The Moose
Panel is a glamour panel isn't it?
Cheers,
Fabrizio
On 20 Jan 2011, at 21:35, Fabrizio Perin wrote:
Hi Doru,
yep you are right. In fact by triggering the same import operation on a model with the
panel close than the import has been really fast. The problem anyway persist because
functionalities like the import are usually accessed from the Moose Panel so of course i
have the Moose Panel open when i import something. You can always work from a workspace of
course but why having a GUI if you cannot use it :)
Anyway i like your solution so i will use a work around for the moment.
Thanks a lot,
Cheers,
Fabrizio
On 20 Jan 2011, at 20:47, Tudor Girba wrote:
Hi,
It is probably because you had Moose Panel open. The thing is that the Entity panel
listens to MooseEntityAdded to refresh the UI. So, if you have a MoosePanel open on the
model, it will get refreshed after each added entity.
What is needed is to simulate a transaction and suspend individual announcements until
the end of the session. I implemented this in Glamour, but we should get it in the main
Announcement package. For example, you can say:
announcer suspendAllWhile: [
"any announcements raised here by the announcer will be ignored" ].
Cheers,
Doru
On 20 Jan 2011, at 19:34, Fabrizio Perin wrote:
Hi,
I did star this morning to import a data base model into an already existing moose model
of a Java application and my image is still working. So in another image with the same
application's model loaded i did try to import the same data base model but as a
separate moose model (so without touching the already loaded one) and the work has been
done in 2 minutes.
Than i did try to investigate why to add to a model of ~680000 entities another ~8000
entities takes so long. I did notice that in the method MooseModel>>add: is set an
announcement (self announcer announce: (MooseEntityAdded new entity: anElement).). By
commenting this announcement the import is perform in 2 minutes. I'm not sure that
i'm right but anyway what is this announcement for? Cannot be moved into the method
MooseModel>>addAll: after having added all the entities? In this second case the
method addAll: can always use a "private" add method that does not perform the
announcement.
Cheers,
Fabrizio
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
--
www.tudorgirba.com
"It's not how it is, it is how we see it."
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch
https://www.iam.unibe.ch/mailman/listinfo/moose-dev
_______________________________________________
Moose-dev mailing list
Moose-dev(a)iam.unibe.ch