KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > armedbear > j > Line


1 /*
2  * Line.java
3  *
4  * Copyright (C) 1998-2002 Peter Graves
5  * $Id: Line.java,v 1.1.1.1 2002/09/24 16:08:10 piso Exp $
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, write to the Free Software
19  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20  */

21
22 package org.armedbear.j;
23
24 import java.io.UnsupportedEncodingException JavaDoc;
25
26 public interface Line
27 {
28     Line previous();
29
30     void setPrevious(Line line);
31
32     Line next();
33
34     void setNext(Line line);
35
36     void insertAfter(Line line);
37
38     String JavaDoc getText();
39
40     void setText(String JavaDoc s);
41
42     String JavaDoc getOriginalText();
43
44     void setOriginalText(String JavaDoc s);
45
46     boolean isModified();
47
48     boolean isNew();
49
50     void setNew(boolean b);
51
52     boolean isSaved();
53
54     void setSaved(boolean b);
55
56     void unmodified();
57
58     int lineNumber();
59
60     void setLineNumber(int n);
61
62     int originalLineNumber();
63
64     void setOriginalLineNumber(int n);
65
66     int getHeight();
67
68     int getWidth();
69
70     int flags();
71
72     void setFlags(int flags);
73
74     char charAt(int i);
75
76     String JavaDoc substring(int beginIndex);
77
78     String JavaDoc substring(int beginIndex, int endIndex);
79
80     String JavaDoc trim();
81
82     int length();
83
84     byte[] getBytes(String JavaDoc encoding) throws UnsupportedEncodingException JavaDoc;
85
86     boolean isBlank();
87
88     int getIndentation();
89
90     boolean isHidden();
91
92     void hide();
93
94     void unhide();
95
96     void show();
97
98     int getHidden();
99
100     void setHidden(int hidden);
101
102     Line previousVisible();
103
104     Line nextVisible();
105
106     boolean isBefore(Line line);
107
108     Line copy();
109
110     void copy(Line line);
111
112     Annotation getAnnotation();
113
114     void setAnnotation(Annotation annotation);
115 }
116
Popular Tags