/*
 *  IsJpHalfWidth
 *
 * Created: Mon Apr 22 02:59:32 2002
 * $Revision$
 * Modified: $Date$
 *
 * Author: Jun Inamori
 * E-mail: jun@oop-reserch.com
 *
 * Copyright (c) 1998-2001 Jun Inamori
 * 2-24-7 Shinsenri-Kitamachi, Toyonaka ,
 * Osaka 560-0081 , Japan.
 * All rights reserved.
 *
 */
package com.oopreserch.web;

/**
 * Implementation of {@link FormValueVerifier} interface.
 * Returns <i>true</i> for the half wide characters or space.
 *
 * @author Jun Inamori
 */
public class IsJpHalfWidth extends AbstractVerifier{

/**
 * Returns <i>true</i> for the half wide characters or space.
 * Otherwise <i>false</i>.
 * <br>
 * <br>
 * <font colors="#ff0000">This method works well only for
 * characters from the typical Japanese environment.</font>
 * <br>
 * <br>
 * @param ch <i>char</i> to be tested.
 * @return <i>true</i> for the half wide characters or space.
 */
    public boolean isValid(char ch){
	if(Character.isWhitespace(ch)){
	    return true;
	}
	return isJpHalfWidth(ch);
    }

} //End of : IsJpHalfWidth