[REBOL] Re: steel... update... of the week (for more advanced rebolers)
From: greggirwin:mindspring at: 28-Jun-2003 9:47
Hi Romano, et al
RPT> In my last vid programs I have found myself using more and and more stylize
RPT> and style, I encapsulate code in styles, re-use the code, inherited the code,
RPT> extend the class, add some methods or values (facets or words), replace them,
RPT> and all with styles (not only).
RPT> I am more and more thinking that writing Vid code is, at its best, writing
RPT> custom styles like oo class.
RPT> For me it is an example of a different approach to oo: with a dialect instead
RPT> of the usual methods of C++ and Java.
This is such an interesting topic that I wish I had time to dig into
it (from a research standpoint) and play with different ideas I have.
Basically, I think there are two sides to it. One side is the code
side, where we approach it with a more standard OO mindset. The other
side is the data/dialect side; and that's where it gets interesting.
It's not just that we can design and build styles in an OO way, but
that the data can be the driving force behind them and that data can
be shared with other interfaces. For example, rather than putting the
business rules in your style, you build them into a dialect-based
framwork. What you do first is model your domain, then, when you know
what a customer-ID is, or an order-number, you have use your custom
VID dialect to bind those rules to your styles, which then use the
rules to validate data entry. The same rules are used for messages
sent to the system in other ways as well.
This is not a new concept by any means, but REBOL will let us do it
more easily, and in a much more natural and accessible way, IMO.
Romano, I'm finding the same sort of thing, but I still haven't spent
much time understanding VID internals, and my styles are all very
basic. At this point, I'm reusing pieces of code more than entire
styles. Designing a good set of generic styles will be a lot of work,
and has no real payoff for me right now so I'm glad that I can build
new styles so easily for just a specific purpose.
-- Gregg