Date: 2004-09-18T14:24:31
Editor: MichaelMcGrady <[EMAIL PROTECTED]>
Wiki: Apache Struts Wiki
Page: StrutsCatalogSimpleDispatchAction
URL: http://wiki.apache.org/struts/StrutsCatalogSimpleDispatchAction
no comment
Change Log:
------------------------------------------------------------------------------
@@ -405,6 +405,8 @@
* I did notice that your SimpleDispatchAction didn't subclass DispatchAction and my
comment about code bloat is just the fact that you have duplicated almost everything
in DispatchAction in your SimpleDispatchAction rather than sub-classing it and
re-using the code. The only ''real'' difference is in the contents of the
getMethodName() method. Comparing the SimpleDispatchAction methods to DispatchAction:
+ You are not getting the differences, Niall, please see below. All the methods
you mention are related to the reflection part of DispatchAction and the names and
code were kept simply to assist. Getting a method from a method name is not exactly
unique code. The difference is in how the method name is obtained. Now, does that
seem to be any sort of a difference to you? It is as if you are reading this as an
English major rather than as a logician. You are counting words instead of seeing the
abstraction. The patterns are different, Niall. Completely so. The reflection is
the same. DispatchAction is not there because of any special use of reflection, and
neither is my code, so they share that. This is something that is otiose.
+
* execute() - same code '''except''' SimpleDispatchAction doesn't handle
cancelled and doesn't retrieve a parameter from the action mapping.
* unspecified() - identical to DispatchAction
* cancelled() - identical to DispatchAction
@@ -414,10 +416,16 @@
* I don't see any 'bloat' in DispatchAction and think you're talking nonsense.
+
+ Well, since DispatchAction could be a subclass of SimpleDispatchAction without
adding any functionality and yet has other methods and other requirements should mean
something to someone. And, since the subclasses of DispatchAction are also in the
same category, that should also mean something. You focus on the logic in determining
the name of the request parameter and compare it to the logic of determining the value
of the request parameter, Niall, and you cannot seem to grasp the huge difference this
makes. It is like you are thinking that adding 0 to a number system is just not all
that important. You don't, that is, get it, and your comments show you don't.
* I'm not making any decisions - just taking part in a debate - so I don't
understand that comment.
* Seems to me that its you thats misapprehending whats going on and I can't
understand why you can't see that SimpleDispatchAction is ''almost'' identical to
DispatchAction.
+
+ The almost identical part, Niall, is just in the use of the getMethod(...)
functionality once a value for method is obtained. That is all. The rest is so
different they simply are not comparable. You don't see that, I think.
+
+'''Michael McGrady'''
'''Niall Pemberton'''
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]