KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > net > sf > saxon > charcode > KOI8RCharacterSet


1 package net.sf.saxon.charcode;
2
3 /**
4 * This class defines properties of the KO18R Cyrillic character set
5 */

6
7 public class KOI8RCharacterSet implements CharacterSet {
8
9     private static KOI8RCharacterSet theInstance = new KOI8RCharacterSet();
10
11     private KOI8RCharacterSet() {}
12
13     public static KOI8RCharacterSet getInstance() {
14         return theInstance;
15     }
16
17     public final boolean inCharset(int c) {
18         return ( c <= 0x7f ) || ( (0x0410 <= c) && (c <= 0x044f) ) ||
19                     c == 0x0451 || c == 0x0401;
20     }
21
22 }
23
24 //
25
// The contents of this file are subject to the Mozilla Public License Version 1.0 (the "License");
26
// you may not use this file except in compliance with the License. You may obtain a copy of the
27
// License at http://www.mozilla.org/MPL/
28
//
29
// Software distributed under the License is distributed on an "AS IS" basis,
30
// WITHOUT WARRANTY OF ANY KIND, either express or implied.
31
// See the License for the specific language governing rights and limitations under the License.
32
//
33
// The Original Code is: all this file.
34
//
35
// The Initial Developer of the Original Code is
36
// Aleksei Makarov [makarov@iitam.omsk.net.ru]
37
//
38
// Portions created by (your name) are Copyright (C) (your legal entity). All Rights Reserved.
39
//
40
// Contributor(s): none.
41
//
42
Popular Tags