Hi Sunburned,

  Why would we ever need to check and see if a CursorTool was rolling
back some action?

EditTransaction should not commit the change when invalid geometry is produce as part of the operation.  ROLLING_BACK_INVALID_EDITS_KEY is a flag that this is occuring so that other parts of the code know what is going on.  It is a blackboard key and not a variable so it should be fine with synchronization.

regards,
Larry


On 9/13/06, Sunburned Surveyor <[EMAIL PROTECTED]> wrote:
I'm still working my way through the source code for the
AbstractCursorTool class. I've run into some source code that I just
can't figure out, and I need to ask for some help again.

The source code for the AbstractCursorTool contains this source code:

protected boolean isRollingBackInvalidEdits() {
   return getWorkbench().getBlackboard().get(
      EditTransaction.ROLLING_BACK_INVALID_EDITS_KEY, false);
}


I believe this method is supposed to indicate if the CursorTool is
currently in the process of rolling back some operations. (For
example, the user was drawing a LineString on the LayerViewPanel, but
then decides to undo this action.)

I believe that this code is using a boolean variable stored on the
Workbench's Blackboard object to indicate if a CursorTool is in the
process of doing this. Here are some of my questions:

Would it ever be possible for there to be synchronization problems
with this variable? I suppose that could only happen if more than one
CursorTool is active at a time. Is that possible?

Why would we ever need to check and see if a CursorTool was rolling
back some action?

The Sunburned Surveyor

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to