[
https://issues.apache.org/jira/browse/WICKET-3983?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13088801#comment-13088801
]
Don Ngo commented on WICKET-3983:
---------------------------------
As Martin have mentioned, I think having LoadableDetachableModel chainable will
allow me to do something like this:
public abstract class AuditableCompoundPropertyModel<E extends Auditable>
extends CompoundPropertyModel<E> {
}
public abstract class AuditableCoppoundLoadableDetachablePropertyModel<E
extends Auditable, D extends AuditableDao<E>>
extends LoadableDetachableModel<E> {
public AuditableLoadableDetachableModel(E entity) {
super(new
AuditableCompoundPropertyModel<E>(entity));
}
...
}
final class HolidayCompoundPropertyModel extends
AuditableLoadableDetachableModel<Holiday> {
}
That will be cleaner, no more having to have the inner class in
HolidayCompoundPropertyModel and any other entity model.
But then looking back at this, I think it's syntactically impossible to have
the line below:
super(new
AuditableCompoundPropertyModel<E>(entity));
So I think it would be nice if you can create a new model class that have the
combined functionalities of both the CompoundPropertyModel and the
LoadableDetachableModel would be nice. A good name for this class would be
something like CompoundLoadableDetachablePropertyModel.
> Update LoadableDetachableModel to include implementation of IChainingModel
> --------------------------------------------------------------------------
>
> Key: WICKET-3983
> URL: https://issues.apache.org/jira/browse/WICKET-3983
> Project: Wicket
> Issue Type: Improvement
> Components: wicket
> Affects Versions: 1.5-RC5.1
> Reporter: Don Ngo
> Assignee: Igor Vaynberg
> Priority: Minor
>
> Please consider updating LoadableDetachableModel to include implementation of
> IChainingModel. Doing so will allow the LoadableDetachableModel to be
> chained with other chainable models such as CompoundPropertyModel.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira