myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Kachanov (JIRA)" <...@myfaces.apache.org>
Subject [jira] Created: (MYFACES-1829) JSF Validator cannot be cast to javax.faces.validator.Validator
Date Sun, 02 Mar 2008 15:32:50 GMT
JSF Validator cannot be cast to javax.faces.validator.Validator
---------------------------------------------------------------

                 Key: MYFACES-1829
                 URL: https://issues.apache.org/jira/browse/MYFACES-1829
             Project: MyFaces Core
          Issue Type: Bug
    Affects Versions: 1.1.5
         Environment: JBoss Portal - Identity portlet
            Reporter: Alex Kachanov


JBoss portal is using idenityt portlet to regster new users and edit  profiles for existing
users
I added new my own JSF validator to the identty portlet which when opened throws the following
exception:

java.lang.ClassCastException: com.kachanov.test004.validators.MyValidator cannot be cast to
javax.faces.validator.Validator
	at org.apache.myfaces.application.ApplicationImpl.createValidator(ApplicationImpl.java:613)

The code of my validator is:

==========================================================
package com.kachanov.test004.validators;

import javax.faces.application.FacesMessage;
import javax.faces.component.UIComponent;
import javax.faces.context.FacesContext;
import javax.faces.validator.Validator;
import javax.faces.validator.ValidatorException;

public class MyValidator implements Validator {

	public void validate(FacesContext arg0, UIComponent arg1, Object arg2) throws ValidatorException
{
		
		System.out.println("testing this validator");
	}
}

==========================================================

So please thell me how can it bee that a class that implements Validator cannot be cast to
javax.faces.validator.Validator??????
Is in't it against basic design of Java languages?

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


Mime
View raw message