|
From: Kevin D. <ke...@tr...> - 2008-07-17 14:55:39
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META content="MSHTML 6.00.2900.3059" name=GENERATOR></HEAD> <BODY leftMargin=1 topMargin=1 rightMargin=1><FONT face=Arial size=2> <DIV>Does anything need to be done at this phase to ensure support for an undo/redo handler downstream? Probably not, but I wanted to ask.</DIV> <DIV> </DIV> <DIV>Swing uses a class called ActionMap to group actions together, and to provide hierarchical groupings of Actions. The functionality here may or may not have applicability (the problems it attempts to solve may be addressed by Spring). The interceptor may cover the need for hierarchical groupings (and make things more decoupled). I'm just bringing this up in case there are any lessons that can be learned from that approach.</DIV> <DIV> </DIV> <DIV>- K<BR></DIV> <DIV> </DIV></FONT> <DIV style="FONT-SIZE: x-small; FONT-FAMILY: Tahoma"> <DIV>----------------------- <B>Original Message</B> -----------------------</DIV> <DIV> </DIV> <DIV><B>From:</B> "Peter De Bruycker" <A href="mailto:pet...@gm..."><FONT color=#0000ff><pet...@gm...></FONT></A></DIV> <DIV><B>To:</B> <A href="mailto:spr...@go..."><FONT color=#0000ff>spr...@go...</FONT></A></DIV> <DIV><B>Cc:</B> </DIV> <DIV><B>Date:</B> Thu, 17 Jul 2008 06:41:18 +0200</DIV> <DIV><B>Subject: <U>[spring-desktop] Action module design</U></B></DIV> <DIV> </DIV></DIV> <DIV dir=ltr>Here are some thoughts on the action module:<BR><BR><BR>The rcp commands are too complicated. Take a look at the org.springframework.richclient.command package and you'll see what I mean (I think this is one of the areas Keith was referring too when he said we need to simplify).<BR><BR>Action vs Command<BR>---------------------------<BR>The command framework was modeled after the Eclipse command system, hence the class names. I don't really remember why we didn't model it using javax.swing.Action, but I guess it has to do with the CommandGroup. I looked at the code, and I don't see any real reasons not to use Action. I also don't see any problems injecting the resources.<BR><BR>The Action interface defines the "ACTION_COMMAND_KEY" property that we can map to the bean name.<BR><BR>This means we can also handle arbitrary Action implementations loaded in the application context (using @Component, definition in the app context, ...), intercept them using a custom Bea nPostProcessor, and inject resources/dependencies into them, ...<BR><BR><BR>CommandInterceptor<BR>-----------------------------<BR>Allows interception of command execution, ... a keeper.<BR>This would become ActionInterceptor.<BR><BR><BR>CommandGroup<BR>----------------------<BR>Also a keeper. (would become ActionGroup + ActionGroupMember)<BR>It allows logical grouping of (related) commands/actions. Combined with a CommandGroupModelBuilder, it can be used to create a menubar with populated menus, a toolbar, popupmenu, button bar, ...<BR><BR><BR>Task<BR>------<BR>jsr 296 defines the Task concept, to spawn a background thread to execute long actions. Combined with Spin (<A href="http://spin.sf.net">http://spin.sf.net</A>) you can have transparant background threading<BR>You can also build a "TaskManager" or task watcher, that gives you a list of running/finished tasks, allowing you to cancel tasks, ...<BR><BR><BR>I don't know who will take the lead of the action module (I thin k Lieven may be interested), but it's important to have a (working) prototype asap.<BR><BR><BR>regards,<BR><BR>Peter<BR><BR></DIV><BR>--~--~---------~--~----~------------~-------~--~----~<BR>You received this message because you are subscribed to the Google Groups "Spring-Desktop" group. <BR>To post to this group, send email to spr...@go... <BR>To unsubscribe from this group, send email to spr...@go... <BR>For more options, visit this group at http://groups.google.com/group/spring-desktop?hl=en <BR>-~----------~----~----~----~------~----~------~--~---<BR><BR></BODY></HTML> |