01: /*
02: * Copyright (c) 2000, Jacob Smullyan.
03: *
04: * This is part of SkunkDAV, a WebDAV client. See http://skunkdav.sourceforge.net/
05: * for the latest version.
06: *
07: * SkunkDAV is free software; you can redistribute it and/or
08: * modify it under the terms of the GNU General Public License as published
09: * by the Free Software Foundation; either version 2, or (at your option)
10: * any later version.
11: *
12: * SkunkDAV 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 GNU
15: * General Public License for more details.
16: *
17: * You should have received a copy of the GNU General Public License
18: * along with SkunkDAV; see the file COPYING. If not, write to the Free
19: * Software Foundation, 59 Temple Place - Suite 330, Boston, MA
20: * 02111-1307, USA.
21: */
22:
23: package org.skunk.dav.client.gui.editor;
24:
25: import java.awt.event.ActionListener;
26: import javax.swing.JComponent;
27:
28: public interface ISearchPanel {
29: /**
30: * literal search mode
31: */
32: int LITERAL_MODE = 0;
33:
34: /**
35: * case-insensitive search mode
36: */
37: int CASE_MODE = 1;
38:
39: /**
40: * regular expression search mode
41: */
42: int REGEXP_MODE = 2;
43:
44: String END_SEARCH = "end_search";
45:
46: String SEARCH_FROM_CARET = "search_from_caret";
47:
48: String SEARCH_FROM_SELECTION = "search_from_selection";
49:
50: /**
51: * indicator that the search should be resumed from the start or end,
52: * depending on whether the search is reversed or not
53: */
54: String SEARCH_FROM_START_OR_END = "search_from_start_or_end";
55:
56: String REPLACE_NEXT = "replace_next";
57:
58: String REPLACE_ALL = "replace_all";
59:
60: String END_REPLACE = "end_replace";
61:
62: JComponent getComponent();
63:
64: boolean isReverse();
65:
66: boolean isIncremental();
67:
68: boolean isWrapped();
69:
70: int getSearchMode();
71:
72: String getSearchText();
73:
74: String getReplaceText();
75:
76: void addActionListener(ActionListener listener);
77:
78: void removeActionListener(ActionListener listener);
79:
80: void focus();
81:
82: void fireActionEvent(String command);
83: }
|