Example usage for java.lang Character isJavaLetterOrDigit

List of usage examples for java.lang Character isJavaLetterOrDigit

Introduction

In this page you can find the example usage for java.lang Character isJavaLetterOrDigit.

Prototype

@Deprecated(since = "1.1")
public static boolean isJavaLetterOrDigit(char ch) 

Source Link

Document

Determines if the specified character may be part of a Java identifier as other than the first character.

Usage

From source file:Main.java

public static void main(String[] args) {
    char ch1 = '3', ch2 = '_';

    boolean b1 = Character.isJavaLetterOrDigit(ch1);
    boolean b2 = Character.isJavaLetterOrDigit(ch2);

    System.out.println(b1);/* ww w.j a  v  a2 s .com*/
    System.out.println(b2);
}