You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Bart Kummel (JIRA)" <de...@myfaces.apache.org> on 2009/09/19 15:56:17 UTC

[jira] Created: (EXTVAL-59) Static referencing for @JoinValidation

Static referencing for @JoinValidation
--------------------------------------

                 Key: EXTVAL-59
                 URL: https://issues.apache.org/jira/browse/EXTVAL-59
             Project: MyFaces Extensions Validator
          Issue Type: Improvement
          Components: Core, Property Validation
    Affects Versions: 1.2.3-SNAPSHOT, 2.0.3-SNAPSHOT, 1.1.3-SNAPSHOT
            Reporter: Bart Kummel
            Priority: Minor


Currently, three options exist to refer to another property to inherit the validation from:
- local property (e.g. @JoinValidation("lastName")
- property chain (e.g. @JoinValidation("person.lastName")
- Expression Language (EL) (e.g. @JoinValidation("#{personBean.lastName}")

Consider the following situation: we have a Manager class that only has a List of Person objects. Suppose the Manager has a lastName property and we want that property to inherit the validation of the lastName property from the Person class. We cannot property chain in this case. EL might be possible, but only if we know there is a Person object we can use for that in the View layer. Even if this is going to work, it isn't good, because we have to have detailed knowledge of our View layer within our Model, something we don't want.

It would be nice if we could just write: @JoinValidation("com.pany.package.Person.lastName"). In this case we sort of statically refer to the Person class by its fully classified name.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (EXTVAL-59) Static referencing for @JoinValidation

Posted by "Gerhard Petracek (JIRA)" <de...@myfaces.apache.org>.
     [ https://issues.apache.org/jira/browse/EXTVAL-59?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gerhard Petracek resolved EXTVAL-59.
------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.1.3-SNAPSHOT
                   2.0.3-SNAPSHOT
                   1.2.3-SNAPSHOT

> Static referencing for @JoinValidation
> --------------------------------------
>
>                 Key: EXTVAL-59
>                 URL: https://issues.apache.org/jira/browse/EXTVAL-59
>             Project: MyFaces Extensions Validator
>          Issue Type: Improvement
>          Components: Core, Property Validation
>    Affects Versions: 1.2.3-SNAPSHOT, 2.0.3-SNAPSHOT, 1.1.3-SNAPSHOT
>            Reporter: Bart Kummel
>            Priority: Minor
>             Fix For: 1.2.3-SNAPSHOT, 2.0.3-SNAPSHOT, 1.1.3-SNAPSHOT
>
>         Attachments: JoinValidationMetaDataInterceptor.java
>
>
> Currently, three options exist to refer to another property to inherit the validation from:
> - local property (e.g. @JoinValidation("lastName")
> - property chain (e.g. @JoinValidation("person.lastName")
> - Expression Language (EL) (e.g. @JoinValidation("#{personBean.lastName}")
> Consider the following situation: we have a Manager class that only has a List of Person objects. Suppose the Manager has a lastName property and we want that property to inherit the validation of the lastName property from the Person class. We cannot property chain in this case. EL might be possible, but only if we know there is a Person object we can use for that in the View layer. Even if this is going to work, it isn't good, because we have to have detailed knowledge of our View layer within our Model, something we don't want.
> It would be nice if we could just write: @JoinValidation("com.pany.package.Person.lastName"). In this case we sort of statically refer to the Person class by its fully classified name.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.