|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Element oriented programming
Peter Murray-Rust wrote: >It would be great if we could standardise on the API for this sort of >thing. Then element-oriented programming could become really attractive. >The domain-specific classes could use a standard core facility. Agree also. How would the Netscape proposal for "behavior sheets" fit in? The basic idea of using style sheet-like pattern matching (XEvent?) to map to method invocation (w/ parameter lists) was viable and would build on the work already done for style sheets (which presumably builds on XPointer). For java work, it would seem natural to use XEvent statements to register a bean with the "behavior processor". XEvent statements could map elements matching a pattern with a bean event to "fire". Further XEvent statements could map specific events to specific event listeners available in registered beans. As each element appears on the input, it is checked against the list of patterns. For each pattern matched, the corresponding event is created and all registered listeners executed. Element and attribute data must be mapped to event properties. Likewise, it must be possible to fire both when the event when the element is first encountered (pre-XXX) and after all of its contents have been read in are available to the event (post-XXX). Limiting the event input to the current element and its contents seems reasonable. If the application needs references to other elements, it can save the data for later reference as needed. Something similar can be done for other languages like C++. It isn't necessary to recreate the equivalent of Java beans entirely - just event definition. Is this an instance of the publisher-subscriber pattern? Linkage issues for C++ will be platform specific, but not too bad. To my mind behavior sheets, per se, are not the hardest part. What is lacking is better cohesion among the various methods of pattern matching. Xml, XPointer, XSL, et al need to share a unified view of specifying sets of elements. My $0.02 worth, Charlie Reitzel xml-dev: A list for W3C XML Developers. To post, mailto:xml-dev@i... Archived as: http://www.lists.ic.ac.uk/hypermail/xml-dev/ To (un)subscribe, mailto:majordomo@i... the following message; (un)subscribe xml-dev To subscribe to the digests, mailto:majordomo@i... the following message; subscribe xml-dev-digest List coordinator, Henry Rzepa (mailto:rzepa@i...)
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








