hi,

i would appreciate having the choice to do something on
DataView.onPopulate (at end of populating process), but cannot
override this method (final at RefreshingView). i know i have the
choice to compare Item.getIndex() to DataView.getItemsPerPage() to
determine the end of populating process, but what about getting this
execution point by refactoring a bit, so:

AbstractRepeater {
        @Override
        protected void onBeforeRender()
        {
                // onPopulate(); not anymore...
                populate();
                ...
        }
        // protected abstract void onPopulate(); not anymore...
        protected abstract void populate();
}

RefreshingView {
        @Override
        protected final void populate() {
                ... // do same stuff...
                ...
                onPopulate();
        }
        protected void onPopulate() {
                // not final anymore, and overridable to do something
on populating
process ends
        }
}

moreover, using the method name "populate" to exactly do that,
populate, when "onBeforeRender" seems to be more semantic-precise; and
then, the same "onBeforeRender" responds to "beforeRender",
"onPopulate" now would respond to "populate".

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to