Example usage for java.lang Character isJavaLetter

List of usage examples for java.lang Character isJavaLetter

Introduction

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

Prototype

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

Source Link

Document

Determines if the specified character is permissible as the first character in a Java identifier.

Usage

From source file:Main.java

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

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

    System.out.println(b1);/*from  w w  w .  j  a  v a 2 s .  co  m*/
    System.out.println(b2);
}