KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > textmining > text > extraction > WordTextPiece


1 /* Copyright 2004 Ryan Ackley
2  *
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */

15
16 package org.textmining.text.extraction;
17
18 /**
19  * This class stores info about the data structure describing a chunk of text
20  * in a Word document. Specifically, whether or not a Range of text uses
21  * unicode or Cp1252 encoding.
22  *
23  * @author Ryan Ackley
24  */

25
26 class WordTextPiece
27 {
28   private int _fcStart;
29   private boolean _usesUnicode;
30   private int _length;
31
32   public WordTextPiece(int start, int length, boolean unicode)
33   {
34     _usesUnicode = unicode;
35     _length = length;
36     _fcStart = start;
37   }
38    public boolean usesUnicode()
39   {
40       return _usesUnicode;
41   }
42
43   public int getStart()
44   {
45       return _fcStart;
46   }
47   public int getLength()
48   {
49     return _length;
50   }
51
52
53
54 }
Popular Tags