"KevinConner" wrote : ....
| Think of my solution as the PrintWriter that surrounds the Writer ;-)
|
E-e :/
It is not correct type of comparition. But thanks for sample. Let's have a closer look
at it, by first showing present state of JBossAOP API
| public void MyAspect
| extends KevinConnersNiceSolution //or/and additional configuration
| {
|
| Object firstAdviceBefore(...) //@@before
| Object firstAdviceAfter(...) //@@after
| }
|
| // and try to imagine that this class has only one! write method
|
| public java.io.Writer {
| void write(char[] cbuf)
| //Write an array of characters.
| abstract void close()
| //Close the stream, flushing it first.
| abstract void flush()
| //Flush the stream.
| }
|
|
But true and useful Writer looks little different - it has write(String) method! (just
like number of other methods which don't give you additional funcionallity but help
you using other code)
| public java.io.Writer {
| void write(String str)
| //Write a string.
| void write(String str, int off, int len)
| //Write a portion of a string.void write(char[] cbuf)
| ...
| }
|
| // and the way I try to persuade you to
|
| public void MyAspect
| {
|
| @before Object firstPersistenceAdvice(...)
| @after Object secondAdviceAfter(...)
|
| Object standardAroundAdvice(..)...
| }
|
And I'm sure you don't use this writer.write("Open your eyes") and
System.out.println("And keep them opened") and you've written several emails to Sun
complaining about Java API too big in this case
;)
Yeah, nice to be on the second side of the mirror...
Regards,
Tomasz Nazar
View the original post :
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3851422#3851422
Reply to the post :
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3851422
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development