You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Prakash Udupa (Created) (JIRA)" <de...@myfaces.apache.org> on 2012/03/08 19:57:57 UTC
[jira] [Created] (TRINIDAD-2239) Improve the ancestor based change
filtering mechanism by introducing a formal ComponentChangeFilter
Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
---------------------------------------------------------------------------------------------------
Key: TRINIDAD-2239
URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
Project: MyFaces Trinidad
Issue Type: Improvement
Components: Components
Affects Versions: 2.0.2-core
Reporter: Prakash Udupa
TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
public abstract class ComponentChangeFilter
{
public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
public enum Result
{
ACCEPT,
REJECT
}
}
2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
------------
Implementation:
In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (TRINIDAD-2239) Improve the ancestor based
change filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Scott O'Bryan (Commented) (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13233523#comment-13233523 ]
Scott O'Bryan commented on TRINIDAD-2239:
-----------------------------------------
I'll add the Trinidad number to these.
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Issue Comment Edited] (TRINIDAD-2239) Improve the ancestor
based change filtering mechanism by introducing a formal
ComponentChangeFilter
Posted by "Prakash Udupa (Issue Comment Edited) (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13233432#comment-13233432 ]
Prakash Udupa edited comment on TRINIDAD-2239 at 3/20/12 2:38 PM:
------------------------------------------------------------------
The checkin for this specific issue was combined with code changes for other issues, so the information in 'Subversion commits' tab for this issue could be confusing.
The actual checkin were the following:
- 1302847 (UIXComponentBase.java) -> http://svn.apache.org/viewvc?view=rev&rev=1302847
- 1302852 (UIXComponentChangeFilter.java) -> http://svn.apache.org/viewvc?view=rev&rev=1302852
- 1302853 (ComponentReferencingComponentChangeFilter.java) -> http://svn.apache.org/viewvc?view=rev&rev=1302853
was (Author: pudupa):
The noted revision above was not for this issue, the right checkin for this issue is ASF revision #1302846
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (TRINIDAD-2239) Improve the ancestor based
change filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Prakash Udupa (Commented) (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13233432#comment-13233432 ]
Prakash Udupa commented on TRINIDAD-2239:
-----------------------------------------
The noted revision above was not for this issue, the right checkin for this issue is ASF revision #1302846
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (TRINIDAD-2239) Improve the ancestor based change
filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Scott O'Bryan (Updated) (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Scott O'Bryan updated TRINIDAD-2239:
------------------------------------
Resolution: Fixed
Fix Version/s: 2.0.2-core
Status: Resolved (was: Patch Available)
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (TRINIDAD-2239) Improve the ancestor based change
filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Prakash Udupa (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prakash Udupa updated TRINIDAD-2239:
------------------------------------
Status: Patch Available (was: Reopened)
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch, TRINIDAD-2239_get_api_patch_over_trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final ComponentChangeFilter[] getComponentChangeFilters()
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (TRINIDAD-2239) Improve the ancestor based change
filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Prakash Udupa (Updated) (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prakash Udupa updated TRINIDAD-2239:
------------------------------------
Status: Patch Available (was: Open)
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Reopened] (TRINIDAD-2239) Improve the ancestor based change
filtering mechanism by introducing a formal ComponentChangeFilter
Posted by "Prakash Udupa (JIRA)" <de...@myfaces.apache.org>.
[ https://issues.apache.org/jira/browse/TRINIDAD-2239?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Prakash Udupa reopened TRINIDAD-2239:
-------------------------------------
Reopening because we have one API method pending on this issue to be implemented, see my previous comment.
> Improve the ancestor based change filtering mechanism by introducing a formal ComponentChangeFilter
> ---------------------------------------------------------------------------------------------------
>
> Key: TRINIDAD-2239
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2239
> Project: MyFaces Trinidad
> Issue Type: Improvement
> Components: Components
> Affects Versions: 2.0.2-core
> Reporter: Prakash Udupa
> Assignee: Scott O'Bryan
> Fix For: 2.0.2-core
>
> Attachments: Change_Filter_TRINIDAD-2239_For_Trunk.patch
>
> Original Estimate: 24h
> Remaining Estimate: 24h
>
> TRINIDAD-2221 provided mechanism for ancestors to decide if ComponentChange targeting one of its descendants should be added to ChangeManager.
> This one is asking for further improvement to this mechanism, by formalizing the contract more. Proposal is to add the following API:
> 1. An abstract class 'org.apache.myfaces.trinidad.change.ComponentChangeFilter' that clients / listeners can implement specializations to accept / reject certain changes on certain components, and then add to the components.
> public abstract class ComponentChangeFilter
> {
> public abstract Result accept(ComponentChange componentChange, UIComponent changeTargetComponent);
> public enum Result
> {
> ACCEPT,
> REJECT
> }
> }
> 2. An abstract implementation 'org.apache.myfaces.trinidad.change.ComponentReferencingComponentChangeFilter' to solve usecases where such a filter needs to hold component reference.
> One such usecase is where ComponentChanges belonging to certain component subtree is rejected, by keeping a reference to the subtree root component. We leverage on 'org.apache.myfaces.trinidad.util.ComponentReference' for this implementation.
> 3. The following methods on UIXComponentBase to be able to attach / detach ComponentChangeFilters to the components:
> public final void addComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final void removeComponentChangeFilter(ComponentChangeFilter componentChangeFilter)
> public final ComponentChangeFilter[] getComponentChangeFilters()
> ------------
> Implementation:
> In implementation of UIXComponentBase.addComponentChange(UIComponent component, ComponentChange change), we will not add a ComponentChange if any of the ComponentChangeFilters that is attached to the target component itself or any of its ancestors rejects the ComponentChange.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira