Martin Klang | 1 Aug 2003 03:47
Picon
Favicon

reflection extensions


I've checked a new set of extensions into CVS. It's reflection, and here's
a quick run-down for the brave who want to try it out (it's very alpha)
and the curious who want to know what's coming.

there's a single function defined, called program(), that returns an XML
tree representing all types and functions in the program. The reflection
types all inherit from Element, which makes it easy to query them using
XPath. Here's an example how:

<o:set match="ref:program()/type[ <at> name = 'String']/function[ <at> name ='match']"/>

ref:program() gets the whole tree
/type[ <at> name = 'String'] gets the String type
/function[ <at> name ='match']"/> gets the match() function

(but remember that there are _two_ String.match() functions!)

the reflection tree looks roughly this:

<type name="TypeName">
  <parent name="TypeName"/> *
  <function name="FunctionName"> *
    <param type="TypeName"/> *
  </function>
</type>

so types can be selected based on parent types, functions based on
parameters and parameter types.

(Continue reading)

Martin Klang | 1 Aug 2003 23:07
Picon
Favicon

Paper on o:XML


As I've already mentioned on this list, I'll be representing o:XML at
the Extreme Markup conference in Montreal next week.

The paper I'll be presenting there is now online:

html: http://www.o-xml.org/extreme2003/paper.html
pdf: http://www.o-xml.org/extreme2003/paper.pdf

for more information on the conference see:
http://www.extrememarkup.com/extreme/

from the paper abstract:

This paper examines some of the benefits of using XML to represent source
code, with a particular focus on the extensibility and processability
aspects.

Using as a basis for the discussion o:XML, a general-purpose
object-oriented language expressed in XML, it is demonstrated how
code can be developed, processed and repurposed using standard XML tools.

Vocabularies for Extreme Programming, Design By Contract, source code
documentation and Aspect Oriented Programming are introduced through
examples, and their use is examined in some detail. A method for layering
information using XML namespaces is presented. Implementations of the
extensions using code transformations are also provided.

The paper demonstrates how the often cited separation of content from
presentation achieved in XML publishing has a parallel in software
(Continue reading)

Glen Barnes | 21 Aug 2003 16:31
Picon
Gravatar

Article on the Reg

Martin,

Any comments on this story?

http://www.theregister.co.uk/content/4/32452.html

Here is the link to the company they mention 
http://www.hyfinity.com/Home.html

 From a quick read some of it seems very similar to oxml concepts. I 
tried top read some of the docs online but the webserver was returning 
errors...

later,
barnacle
Ken McCloskey | 27 Aug 2003 03:48
Picon
Favicon

ObjectBox servlet and WARs

Martin,

Just wanted to bring your attention to a problem I encountered when trying 
to use the ObjectBox servlet from within the context of a WAR file.

The problem occurs in the method init of org.oXML.extras.http.ObjectBox:

baseurl = servletConfig.getServletContext().getRealPath("/");

which will return null if called from within a WAR. My solution was to check 
for the null, and if it is encountered do the following:

java.net.URL baseurlURL = 
servletConfig.getServletContext().getResource("/");
baseurl = baseurlURL.toString();

On Tomcat, this will return a jndi reference to inside the WAR which seems 
to work ok.

Ken McCloskey

_________________________________________________________________
Get MSN 8 and help protect your children with advanced parental controls.  
http://join.msn.com/?page=features/parental
Martin Klang | 28 Aug 2003 15:45
Picon
Favicon

Bugzilla (was: ObjectBox servlet and WARs)


Ken,

I've sort of been aware of this problem but didn't know there was such an
elegant solution. I thought each file had to be retrieved using
getResource(), which would have been a pain (that's the real reason I
haven't tried to fix this already). Your solution is much better - thanks!

I think it's time to set up a Bugzilla [1] for easy bug reports and
tracking. We're going to need someone to monitor the system - some basic
maintenance but mostly just need someone to take responsibility, answer
the odd question from users etc.
Anyone volunteers? Experience with Bugzilla is a plus, but it's really
quite easy to admin and once I've set it up on the server it can all be
done over a web interface.

later,

/m

[1] Bugzilla: http://bugzilla.org/

Martin Klang
http://www.o-xml.org - the object-oriented XML programming language

On Wed, 27 Aug 2003, Ken McCloskey wrote:

> Martin,
>
> Just wanted to bring your attention to a problem I encountered when trying
(Continue reading)


Gmane