Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Modeling » EMF » CDO Explicit Lock works only for immediate children
CDO Explicit Lock works only for immediate children [message #951559] Sat, 20 October 2012 21:07 Go to next message
UmaShankar Subramani is currently offline UmaShankar SubramaniFriend
Messages: 144
Registered: December 2011
Location: SWEDEN
Senior Member
Hi,

When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are actually locked too.

But I still, I could edit the other objects(grand children). So, If I want to lock all the children of the locked object(including all grandchildren), how can I do it.

I have the source installed.



Thanks,
Uma

[Updated on: Sat, 20 October 2012 21:08]

Report message to a moderator

Re: CDO Explicit Lock works only for immediate children [message #951909 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951916 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951923 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951930 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951937 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951944 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951951 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951958 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951965 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951972 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951979 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951986 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #951993 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952000 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952007 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952014 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952021 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952028 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952036 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952044 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Re: CDO Explicit Lock works only for immediate children [message #952051 is a reply to message #951559] Sun, 21 October 2012 04:05 Go to previous message
Eike Stepper is currently offline Eike StepperFriend
Messages: 5590
Registered: July 2009
Senior Member
Am 20.10.2012 23:07, schrieb UmaShankar Subramani:
> Hi,
>
> When I lock an object explicitly(Right Click -> Locking -> Lock), only the immediate children of this object are
> actually locked too.
That surprises me. Children should generally not be locked automatically. With 3 objects parent, child1 and child2 and a
write lock (by someone else) on parent you can't commit changes to parent's attributes or references. I.e. you can not
change the order of the children (because that's an aspect of the parent) but you can change attributes or references of
both children.

> But I still, I could edit the other objects(grand children). So, If how want to lock all the children of the locked
> object(including all grandchildren), how can I do it.
The last parameter of this method is "recursive":

CDOView.lockObjects(Collection<? extends CDOObject>, LockType, long, boolean)

Cheers
/Eike

----
http://www.esc-net.de
http://thegordian.blogspot.com
http://twitter.com/eikestepper
Previous Topic:Decoration layer over EMF
Next Topic:Codegenerated UI Examples for model with a large number of EClasses
Goto Forum:
  


Current Time: Sun Dec 21 03:19:18 GMT 2014

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

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