Source Code Cross Referenced for IFindReplaceTarget.java in  » IDE-Eclipse » jface » org » eclipse » jface » text » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » IDE Eclipse » jface » org.eclipse.jface.text 
Source Cross Referenced  Class Diagram Java Document (Java Doc) 


001:        /*******************************************************************************
002:         * Copyright (c) 2000, 2005 IBM Corporation and others.
003:         * All rights reserved. This program and the accompanying materials
004:         * are made available under the terms of the Eclipse Public License v1.0
005:         * which accompanies this distribution, and is available at
006:         * http://www.eclipse.org/legal/epl-v10.html
007:         *
008:         * Contributors:
009:         *     IBM Corporation - initial API and implementation
010:         *******************************************************************************/package org.eclipse.jface.text;
011:
012:        import org.eclipse.swt.graphics.Point;
013:
014:        /**
015:         * Defines the target for finding and replacing strings.
016:         * <p>
017:         * The two main methods are <code>findAndSelect</code> and
018:         * <code>replaceSelection</code>. The target does not provide any way to
019:         * modify the content other than replacing the selection.
020:         * <p>
021:         *
022:         * In order to provide backward compatibility for clients of
023:         * <code>IFindReplaceTarget</code>, extension interfaces are used as a means
024:         * of evolution. The following extension interfaces exist:
025:         * <ul>
026:         * <li>{@link org.eclipse.jface.text.IFindReplaceTargetExtension} since version
027:         *     2.0 introducing the notion of find/replace session and of a find/replace
028:         *     scope. In additions, in allows clients to replace all occurrences of a given
029:         *     find query.</li>
030:         * <li>{@link org.eclipse.jface.text.IFindReplaceTargetExtension3} since
031:         *     version 3.0 allowing clients to specify search queries as regular
032:         *     expressions.</li>
033:         * </ul>
034:         * <p>
035:         * Clients of a <code>IFindReplaceTarget</code> that also implements the
036:         * <code>IFindReplaceTargetExtension</code> have to indicate the start of a find/replace
037:         * session before using the target and to indicate the end of the session when the
038:         * target is no longer used.
039:         *
040:         * @see org.eclipse.jface.text.IFindReplaceTargetExtension
041:         * @see org.eclipse.jface.text.IFindReplaceTargetExtension3
042:         */
043:        public interface IFindReplaceTarget {
044:
045:            /**
046:             * Returns whether a find operation can be performed.
047:             *
048:             * @return whether a find operation can be performed
049:             */
050:            boolean canPerformFind();
051:
052:            /**
053:             * Searches for a string starting at the given widget offset and using the specified search
054:             * directives. If a string has been found it is selected and its start offset is
055:             * returned.
056:             * <p>
057:             * Replaced by {@link IFindReplaceTargetExtension3#findAndSelect(int, String, boolean, boolean, boolean, boolean)}.
058:             *
059:             * @param widgetOffset the widget offset at which searching starts
060:             * @param findString the string which should be found
061:             * @param searchForward <code>true</code> searches forward, <code>false</code> backwards
062:             * @param caseSensitive <code>true</code> performs a case sensitive search, <code>false</code> an insensitive search
063:             * @param wholeWord if <code>true</code> only occurrences are reported in which the findString stands as a word by itself
064:             * @return the position of the specified string, or -1 if the string has not been found
065:             */
066:            int findAndSelect(int widgetOffset, String findString,
067:                    boolean searchForward, boolean caseSensitive,
068:                    boolean wholeWord);
069:
070:            /**
071:             * Returns the currently selected range of characters as a offset and length in widget coordinates.
072:             *
073:             * @return the currently selected character range in widget coordinates
074:             */
075:            Point getSelection();
076:
077:            /**
078:             * Returns the currently selected characters as a string.
079:             *
080:             * @return the currently selected characters
081:             */
082:            String getSelectionText();
083:
084:            /**
085:             * Returns whether this target can be modified.
086:             *
087:             * @return <code>true</code> if target can be modified
088:             */
089:            boolean isEditable();
090:
091:            /**
092:             * Replaces the currently selected range of characters with the given text.
093:             * This target must be editable. Otherwise nothing happens.
094:             * <p>
095:             * Replaced by {@link IFindReplaceTargetExtension3#replaceSelection(String, boolean)}.
096:             *
097:             * @param text the substitution text
098:             */
099:            void replaceSelection(String text);
100:        }
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.