Hello Mr. VanderBeek-
I've been using WebWare for a month now and I am rather happy with
Webware. The thing I like best about Webware is it's simplicity which
makes it easy to alter to do what I want. As you have already seen,
a module such as Page isn't exactly right, you can easily follow the
and write your own. Previous projects I worked on were in Java and I'm
not sure if Webware being easy to understand and change is due to it
written in Python or because the designers did such a good job.
a combination of the two.
Regarding your proposed changes, I subclass from Page (PSPPage
I write mostly pages with a lot of content so I use Dreamweaver and I
don't use any of the writeHeader/Footer/Body() etc. So I like the idea
a class that is lighter than Page like you suggest. On the other hand,
adding another layer in the hierarchy before Page makes things
more complicated. What do others think? How do we handle the balance
between adding more features and avoiding feature bloat?
> (First try didn't go through due to a From-address mismatch.)
> I'm evaluating WebWare for possible uses at my company. However, I'm
> distressed by how heavyweight and html-specific WebKit.Page is. I
> it is bothersome, a little confusing, and not very graceful when it
> comes to wanting to write a webapp that extends the toolkit.
> My primary gripe is that Page seems to be the only reasonable extension
> point for writing things, and many things I need to write may not
> actually produce HTML. If I want to do MVC-like actions where
> are made and then forward()'ed away to a PSP, writeHTML() is pure
> overhead. If I want to generate a PNG, CSV or other type of content,
> it's confusing to override writeHTML() in my derived class.
> I suggest a new class, maybe named HTTPAction, be put between
> HTTPServlet and Page. It should contain all the much of what is called
> early in a Page (like respondToGet, respondToPost, and _respond) as
> as general utility methods (like forward()) but leave defaultAction():
> *blank* (or possibly just throwing an exception).
> Page should then override defaultAction() to call writeHTML(), which it
> provides along with all the HTML-specific helper-methods.
> With this, people who want to write a differently templated page (maybe
> something simpler like writeHeader(), writeBody(), writeFooter()) can
> derive from this class. Also, people who want to write elements that
> produce something other than a page of HTML have a more natural
> extension point that includes the handy _action_ functionality and
> utility routines I've mentioned.
> This can be done easily and without breaking current applications
> by pushing some methods into a new class.
> If this sounds reasonable, I'll write a patch. Please respond and
> Some people have a way with words, while others... erm... thingy.
> This SF.net email is sponsored by: IT Product Guide on
> Use IT products in your business? Tell us what you think of them. Give
> Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out
> Webware-devel mailing list