KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > jdt > core > dom > rewrite > ITrackedNodePosition


1 /*******************************************************************************
2  * Copyright (c) 2004 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11 package org.eclipse.jdt.core.dom.rewrite;
12
13 /**
14  * A tracked node position is returned when a rewrite change is
15  * requested to be tracked.
16  * <p>
17  * This interface is not intended to be implemented by clients.
18  * </p>
19  *
20  * @see ASTRewrite#track(org.eclipse.jdt.core.dom.ASTNode)
21  * @since 3.0
22  */

23 public interface ITrackedNodePosition {
24     
25     /**
26      * Returns the original or modified start position of the tracked node depending if called before
27      * or after the rewrite is applied. <code>-1</code> is returned for removed nodes.
28      *
29      * @return the original or modified start position of the tracked node
30      */

31     public int getStartPosition();
32     
33     /**
34      * Returns the original or modified length of the tracked node depending if called before
35      * or after the rewrite is applied. <code>-1</code> is returned for removed nodes.
36      *
37      * @return the original or modified length of the tracked node
38      */

39     public int getLength();
40     
41     
42 }
43
Popular Tags