I get a null value when I pass a constant obtained with o:importConstants to an o:validator even when they both seems to be accessible on render time.
public class Test {
public static final String PATTERN = "\\d+";
}
The constant value is obtained correctly cos I can print it:
<o:importConstants type="Test"/>
Pattern is: #{Test.PATTERN}
<p:password id="password" value="#{password}">
<o:validator validatorId="javax.faces.RegularExpression" pattern="#{Test.PATTERN}"/>
</p:password>
When I check pattern variable in RegexValidator, it's null.
I tried also using f:attribute with a custom validator and checked these posts but without success (BalusC, help! :) :