Eclipse Platform
2.0

org.eclipse.jface.text
Class TypedPosition

java.lang.Object
  |
  +--org.eclipse.jface.text.Position
        |
        +--org.eclipse.jface.text.TypedPosition

public class TypedPosition
extends Position

Convenience class for position like typed regions.


Field Summary
 
Fields inherited from class org.eclipse.jface.text.Position
isDeleted, length, offset
 
Constructor Summary
TypedPosition(int offset, int length, String type)
          Creates a position along the given specification.
TypedPosition(ITypedRegion region)
          Creates a position based on the typed region.
 
Method Summary
 boolean equals(Object o)
           
 String getType()
          Returns the type of the position
 int hashCode()
           
 
Methods inherited from class org.eclipse.jface.text.Position
delete, getLength, getOffset, includes, isDeleted, overlapsWith, setLength, setOffset, undelete
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TypedPosition

public TypedPosition(int offset,
                     int length,
                     String type)
Creates a position along the given specification.

Parameters:
offset - the offset of this position
length - the length of this position
type - the type of this position

TypedPosition

public TypedPosition(ITypedRegion region)
Creates a position based on the typed region.

Parameters:
region - the typed region
Method Detail

getType

public String getType()
Returns the type of the position

Returns:
the type of this position

equals

public boolean equals(Object o)
Overrides:
equals in class Position

hashCode

public int hashCode()
Overrides:
hashCode in class Position

Eclipse Platform
2.0

Copyright (c) IBM Corp. and others 2000, 2002. All Rights Reserved.