-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

hi igor,

| so if you want IDataProvider<A,B> A being iterator and B being model,
| why not do the A->B transform in iterator() itself? obviously you are
| caching the lookup anyways so there shouldnt be a performance hit...

there are two cases with the iterator/model mixing into one or the other.

a) separation of concerns

given the rssfeed example: in the iterator there is a list of feedurls (strings)
returned, which is a database lookup.

within model, the strings are converted in the actual rssfeed.

both are quite different tasks and could/are handled by different 
implementations.

b) wrapping implementation details

i have a common class which encpasulates id-lists and is provided a call-by-name
method to just do the id-lookup. this is handled by the model implementation and
isn't functional connected to the iterator at all.

your suggestion is as i understand making a B from A within the iterator. so, i
make a B from A in iterator, this object is then given to 'model' and there i
make an IdLoadableDetachableModel from it, again? that just doesn't look right
to me.

imho there are only two ways to go:

- - drop 'model' and have iterator walk an IModel<B>
- - have IDataProvider one generic for iterator and one for model.

best regards, --- jan.


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (Darwin)

iD8DBQFID32KLcYXCUxYsy4RAlU2AJ46YrGdkJi9mErdKnD/d7fdqiIt/QCg9ZqZ
AO5QSPdd8K/mM5iEe4u0rKo=
=9doM
-----END PGP SIGNATURE-----

Reply via email to