Theoretically Stuck
ke han
ke.han@REDACTED
Sun Sep 3 09:21:07 CEST 2006
On Sep 3, 2006, at 5:05 AM, Ulf Wiger ((TN/EAB)) wrote:
>
>
>
> But this was the one I was really after - ROK's
> dictionaries:
>
> http://www.erlang.org/ml-archive/erlang-questions/200309/msg00339.html
Exceptional post!!!..thanks for digging that up. I sure wish that in
the three years since this post was made some erlang master had
managed to come up with an implementation of this ;-).
In regards to Rudolph's issues, I am currently prototyping methods to
alleviate the trouble with treating "records as an object":
1 - I need a simple way to create and manage attributes of an entity
(either processes or some erlang term which I am careful to not
violate encapsulation)..in OO languages you get encapsulation for
free...in erlang you just need a little discipline to your coding
style. Even with some discipline, you will end up with repetitive
code for managing attribute values, events, changes to the collection
of attributes (adding a office_phone to the existing Person model),
etc...
In an MVC approach to app design, both Controllers and Models have
attributes...I need a simple approach which at least hides repetitive
code. I am closely following the work done on smerl and erlyDB for
methods to manage this.
It would be nice if ROK's dictionary already existed. This might
offer a lightweight and language transparent method for accomplishing
some of this...but its not here for now...
2 - Once I get something I like from step 1, I'm hoping I can
extrapolate to create general methods for mitigating otherwise
repetitive code for common behaviors...I don't know what it looks
like yet, but something along the lines of "-behavior" declarations
that automate delegation to helper modules is maybe an acceptable
approach.
your thought?
ke han
>
> BR,
> Ulf W
>
More information about the erlang-questions
mailing list