Dear ECS and Turbine users,

My name is Krzysztof and I'm graduating shortly from Warsaw University of
Technology, Faculty of Electronics & Information Techniques. I am quite a
new Turbine/ECS user - I have started using the framework about a month ago,
as it has proven to be the most seductive technology on the market today.

Currently I'm working for Era GSM, the biggest cell phone operator in
Poland, where I'm developing WAP based services. You may fully expect me to
contribute to Turbine and ECS at some later point, as I'm a true believer in
open source - I've worked at CERN (European Laboratory for Particle Physics,
Switzerland) for over a year, where almost everything is an open source :-).
Naturally, first I need to get more acquainted with the framework.

At the moment I would like to share some thoughts with you regarding the
usage of ecs.Document within Turbine. This is also the reason why I have
posted this message to both mailing lists.

ECS provides the following classes:

(-) org.apache.ecs.wml.WMLDocument
(-) org.apache.ecs.xml.XMLDocument
(-) org.apache.ecs.Document

The problem is, that Document is really an HTMLDocument, and is not a common
class for WMLDocument and XMLDocument. As a result, if one would like to use
Turbine for WAP services, such as myself, he or she would have to modify
Turbine.java in order for the correct document to be rendered. Below, I have
attached modifications which I have done in my working copy, which of course
solve the problem, but it is certainly not a clean solution :

cvs -q diff Turbine.java (in directory C:\JavaEra\turbine\src\java)
Index: Turbine.java
===================================================================
RCS file: /products/cvs/turbine/turbine/src/java/Turbine.java,v
retrieving revision 1.57
diff -r1.57 Turbine.java
82a83
> import org.apache.ecs.wml.WMLDocument;
86d86
<
351d350
<
353,354c352,353
<
<                     data.getPage().output ( data.getOut() );
---
>                     WMLDocument doc =
(WMLDocument)data.user.getTemp("_WMLDocument");
>                     doc.output(data.getOut());


To drive home a point, I would like to suggest to do the following changes
(I will be glad to do them myself if you will agree):

1) Make Document an interface to all other documents (WML,XML,HTML)
2) Convert the current org.apache.ecs.Document to org.apache.HTMLDocument

As a result, Turbine could be used without any modifications for WML and XML
as well. The only changes that users would have to do in their already
written applications would be to change Document to HTMLDocument.

Waiting for your reply,

Kind regards,

Krzysztof



------------------------------------------------------------
To subscribe:        [EMAIL PROTECTED]
To unsubscribe:      [EMAIL PROTECTED]
Problems?:           [EMAIL PROTECTED]

Reply via email to