From d0ec0abce3ab740813d8de05f0757f0d3153ab3a Mon Sep 17 00:00:00 2001 From: Kai Maetzel Date: Mon, 21 Jun 2004 17:59:31 +0000 Subject: updated Javadoc --- org.eclipse.text/src/org/eclipse/jface/text/Assert.java | 6 +++--- .../src/org/eclipse/jface/text/BadLocationException.java | 6 +++--- .../org/eclipse/jface/text/BadPartitioningException.java | 2 +- .../eclipse/jface/text/BadPositionCategoryException.java | 4 ++-- .../org/eclipse/jface/text/DefaultPositionUpdater.java | 7 +++---- .../eclipse/jface/text/FindReplaceDocumentAdapter.java | 16 +++++++++++----- .../src/org/eclipse/jface/text/SlaveDocumentEvent.java | 4 ++-- .../src/org/eclipse/jface/text/TextUtilities.java | 8 ++++---- 8 files changed, 29 insertions(+), 24 deletions(-) diff --git a/org.eclipse.text/src/org/eclipse/jface/text/Assert.java b/org.eclipse.text/src/org/eclipse/jface/text/Assert.java index ec790ff9145..6830c94f221 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/Assert.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/Assert.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -114,7 +114,7 @@ public final class Assert { * @exception Throwable an unspecified unchecked exception if the object * is null */ - public static void isNotNull(Object object) { + public static void isNotNull(Object object) throws Throwable { // succeed as quickly as possible if (object != null) { return; @@ -141,7 +141,7 @@ public final class Assert { * @exception Throwable an unspecified unchecked exception if the object * is null */ - public static void isNotNull(Object object, String message) { + public static void isNotNull(Object object, String message) throws Throwable { if (object == null) throw new AssertionFailedException("null argument;" + message);//$NON-NLS-1$ } diff --git a/org.eclipse.text/src/org/eclipse/jface/text/BadLocationException.java b/org.eclipse.text/src/org/eclipse/jface/text/BadLocationException.java index 8348b1f8281..2ad4478451d 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/BadLocationException.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/BadLocationException.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -13,8 +13,8 @@ package org.eclipse.jface.text; /** - * Indicates the attempt to access a non-existing position. - * The attempt has been performed on a text store such as a document or string. + * Indicates the attempt to access a non-existing position. The attempt has been + * performed on a text store such as a document or string. */ public class BadLocationException extends Exception { diff --git a/org.eclipse.text/src/org/eclipse/jface/text/BadPartitioningException.java b/org.eclipse.text/src/org/eclipse/jface/text/BadPartitioningException.java index d7a064618f7..f4c4be2c069 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/BadPartitioningException.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/BadPartitioningException.java @@ -1,5 +1,5 @@ /********************************************************************** -Copyright (c) 2000, 2003 IBM Corp. and others. +Copyright (c) 2000, 2004 IBM Corporation and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Common Public License v1.0 which accompanies this distribution, and is available at diff --git a/org.eclipse.text/src/org/eclipse/jface/text/BadPositionCategoryException.java b/org.eclipse.text/src/org/eclipse/jface/text/BadPositionCategoryException.java index c838292f156..379f2fc356c 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/BadPositionCategoryException.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/BadPositionCategoryException.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -16,7 +16,7 @@ package org.eclipse.jface.text; * Indicates the attempt to access a non-existing position * category in a document. * - * @see IDocument + * @see org.eclipse.jface.text.IDocument */ public class BadPositionCategoryException extends Exception { diff --git a/org.eclipse.text/src/org/eclipse/jface/text/DefaultPositionUpdater.java b/org.eclipse.text/src/org/eclipse/jface/text/DefaultPositionUpdater.java index a3fe149ea59..b8c72476f3b 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/DefaultPositionUpdater.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/DefaultPositionUpdater.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -8,12 +8,11 @@ * Contributors: * IBM Corporation - initial API and implementation *******************************************************************************/ - package org.eclipse.jface.text; /** - * Default implementation of IPositionUpdater. + * Default implementation of {@link org.eclipse.jface.text.IPositionUpdater}.

* A default position updater must be configured with the position category * whose positions it will update. Other position categories are not affected * by this updater.

@@ -209,7 +208,7 @@ public class DefaultPositionUpdater implements IPositionUpdater { } /* - * @see IPositionUpdater#update(DocumentEvent event) + * @see org.eclipse.jface.text.IPositionUpdater#update(org.eclipse.jface.text.DocumentEvent) */ public void update(DocumentEvent event) { diff --git a/org.eclipse.text/src/org/eclipse/jface/text/FindReplaceDocumentAdapter.java b/org.eclipse.text/src/org/eclipse/jface/text/FindReplaceDocumentAdapter.java index 9dc71a52d50..8b82bfba8f3 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/FindReplaceDocumentAdapter.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/FindReplaceDocumentAdapter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -17,17 +17,23 @@ import java.util.regex.PatternSyntaxException; /** - * Adapts {@link org.eclipse.jface.text.IDocument} for doing search and - * replace operations. + * Provides search and replace operations on + * {@link org.eclipse.jface.text.IDocument}. + *

+ * Replaces + * {@link org.eclipse.jface.text.IDocument#search(int, String, boolean, boolean, boolean)}. * * @since 3.0 */ public class FindReplaceDocumentAdapter implements CharSequence { + /** + * Internal type for operation codes. + */ private static class FindReplaceOperationCode { } - // Shortcuts to findReplace operation codes + // Find/replace operation codes. private static final FindReplaceOperationCode FIND_FIRST= new FindReplaceOperationCode(); private static final FindReplaceOperationCode FIND_NEXT= new FindReplaceOperationCode(); private static final FindReplaceOperationCode REPLACE= new FindReplaceOperationCode(); @@ -149,7 +155,7 @@ public class FindReplaceDocumentAdapter implements CharSequence { fFindReplaceMatchOffset= startOffset; if (fFindReplaceMatcher != null && fFindReplaceMatcher.pattern().pattern().equals(findString) && fFindReplaceMatcher.pattern().flags() == patternFlags) { /* - * Commented out for optimazation: + * Commented out for optimization: * The call is not needed since FIND_FIRST uses find(int) which resets the matcher */ // fFindReplaceMatcher.reset(); diff --git a/org.eclipse.text/src/org/eclipse/jface/text/SlaveDocumentEvent.java b/org.eclipse.text/src/org/eclipse/jface/text/SlaveDocumentEvent.java index 60fcd52909a..8161c8e4123 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/SlaveDocumentEvent.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/SlaveDocumentEvent.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -8,9 +8,9 @@ * Contributors: * IBM Corporation - initial API and implementation *******************************************************************************/ - package org.eclipse.jface.text; + /** * A slave document event represents a master document event as a slave-relative * document event. It also carries the master document event. diff --git a/org.eclipse.text/src/org/eclipse/jface/text/TextUtilities.java b/org.eclipse.text/src/org/eclipse/jface/text/TextUtilities.java index 2727bc12ebc..b8ea5e0575f 100644 --- a/org.eclipse.text/src/org/eclipse/jface/text/TextUtilities.java +++ b/org.eclipse.text/src/org/eclipse/jface/text/TextUtilities.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. + * Copyright (c) 2000, 2004 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at @@ -8,9 +8,9 @@ * Contributors: * IBM Corporation - initial API and implementation *******************************************************************************/ - package org.eclipse.jface.text; + import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; @@ -21,12 +21,12 @@ import java.util.Set; /** - * Collection of text functions. + * A collection of text functions. */ public class TextUtilities { /** - * Default line delimiters used by these text functions. + * Default line delimiters used by the text functions of this class. */ public final static String[] DELIMITERS= new String[] { "\n", "\r", "\r\n" }; //$NON-NLS-3$ //$NON-NLS-2$ //$NON-NLS-1$ -- cgit v1.2.3