This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.


javax.swing.text
class TabSet

java.lang.Object extended by javax.swing.text.TabSet
All Implemented Interfaces:
Serializable

public class TabSet
extends Object
implements Serializable

A TabSet is comprised of many TabStops. It offers methods for locating the closest TabStop to a given position and finding all the potential TabStops. It is also immutable.

Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeansTM has been added to the java.beans package. Please see {@link java.beans.XMLEncoder}.


Constructor Summary
TabSet(TabStop[] tabs)

          Creates and returns an instance of TabSet.
 
Method Summary
 boolean

          Indicates whether this TabSet is equal to another one.
 TabStop
getTab(int index)

          Returns the TabStop at index index.
 TabStop
getTabAfter(float location)

          Returns the Tab instance after location.
 int

          Returns the number of Tab instances the receiver contains.
 int

          
 int
getTabIndexAfter(float location)

          Returns the index of the Tab to be used after location.
 int

          Returns a hashcode for this set of TabStops.
 String

          Returns the string representation of the set of tabs.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TabSet

public TabSet(TabStop[] tabs)
Creates and returns an instance of TabSet. The array of Tabs passed in must be sorted in ascending order.

Parameters:
tabs
Method Detail

equals

public boolean equals(Object o)
Indicates whether this TabSet is equal to another one.

Overrides:
equals in class Object
Parameters:
o - the TabSet instance which this instance should be compared to.
Returns:
true if o is the instance of TabSet, has the same number of TabStops and they are all equal, false otherwise.

getTab

public TabStop getTab(int index)
Returns the TabStop at index index. This will throw an IllegalArgumentException if index is outside the range of tabs.

Parameters:
index

getTabAfter

public TabStop getTabAfter(float location)
Returns the Tab instance after location. This will return null if there are no tabs after location.

Parameters:
location

getTabCount

public int getTabCount()
Returns the number of Tab instances the receiver contains.


getTabIndex

public int getTabIndex(TabStop tab)
Parameters:
tab
Returns:
the index of the TabStop tab, or -1 if tab is not contained in the receiver.

getTabIndexAfter

public int getTabIndexAfter(float location)
Returns the index of the Tab to be used after location. This will return -1 if there are no tabs after location.

Parameters:
location

hashCode

public int hashCode()
Returns a hashcode for this set of TabStops.

Overrides:
hashCode in class Object
Returns:
a hashcode value for this set of TabStops.

toString

public String toString()
Returns the string representation of the set of tabs.

Overrides:
toString in class Object


This documentation differs from the official API. Jadeite adds extra features to the API including: variable font sizes, constructions examples, placeholders for classes and methods, and auto-generated “See Also” links. Additionally it is missing some items found in standard Javadoc documentation, including: generics type information, “Deprecated” tags and comments, “See Also” links, along with other minor differences. Please send any questions or feedback to bam@cs.cmu.edu.
This page displays the Jadeite version of the documention, which is derived from the offical documentation that contains this copyright notice:
Copyright 2008 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.
The official Sun™ documentation can be found here at http://java.sun.com/javase/6/docs/api/.