jPenguin Project: An Overview of the TOTSP Commons
Submitted by kebernet on Thu, 03/17/2005 - 13:36
Tagged:
Ok There is a bunch of stuff in here that really shouldn't be, but I am not going to stress over it right now.
Right now, this project is in the FeedPod stuff at java.net. web cvs and :pserver:@cvs.dev.java.net:/cvs /feedpod/totsp/commons. Unless there is any big objection, I am thinking it can just stay there and we can pull it as a lib into the JWPortal project at sourceforge.
Several things that will be of use to many people:
1. com.totsp.html.safetags.SafeTagFilter. This is a class that will (a) XHTML correct fragments, deprecating the jTidyInterface. It is pretty smart and knows how to replace "font" tags with styled "span"s and do some other things (b) filter unsafe content from XHTML fragments and (c) limit the number of non-tag characters in the output while still closing all open tags properly. It is an implementation of the com.totsp.xml.engine.DOMEngine class. The DOMEngine is used a few places to, and is kind of neat on its own. It is a minimalist version of the XML Interpreter system I built at AnyDevice, without the actual interpreter stuff. It is also used to "speech-friendly" things for the FeedPod reader.
2. com.totsp.util.QueueManager. This is a process queue system. Basically it creates a queue with an executor threat that will wake up every now and then and run a QueueProcessor implementation on whatever is in the queue. This is used all over the place (to fetch feeds for the cache, to queue up TTS executions in feedpod, etc).
3. com.totsp.util.BeanVector. This is perhaps the most useful class I have ever written. It is basically an extension of the Vector class that has sorting, filtering on range, filtering on string patters, page chunking, basic statistical stuff (mean median mode), and a bunch of other utilities based on getter/setter reflection.
4. com.totsp.util.CachingHashtable. I have written this a few times, but this is the end all be all of the class. It is basically a Hashtable that will only store things for a limited amount of time.
5. com.totsp.application.GenericUser this is a basic interface that all "user" objects should extend in whatever application. It basically is just one method (isUserInRole(String)). It is used by teh com.totsp.application.web.IsUserInRole servlet filter. See the JavaDocs on the filter for how to use it in your web.xml.
6. com.totsp.util.web.GZIPFilter this is a gzip compression filter for browsers that support it. Stolen from O'Reilly, it is really cool, and will work through ajp13 when the Tomcat compressions won't.
There are some other things in the util package (StringUtility, StreamUtility, BeanUtility, XMLUtility) that are very useful too.
Feel free to poke around. Really the com.totsp.excel and com.totsp.irc packages shouldn't be there. One day I will move them out. There are also some cool XML-RPC service utility classes that will become part of my Java-JavaScript "AJAX" toolkit soon. They may be moving out of the commons into a new subproject for that, though. Not sure yet. The com.totsp.html.table contains my AJAX Data-Bound tabular data control that is pretty cool. It needs good documentation though.







Comments
RE: jPenguin Project: An Overview of the TOTSP Commons
RE: jPenguin Project: An Overview of the TOTSP Commons
RE: jPenguin Project: An Overview of the TOTSP Commons