uk.ac.starlink.topcat
Class RowSubset

java.lang.Object
  extended by uk.ac.starlink.topcat.RowSubset
Direct Known Subclasses:
BitsRowSubset, BooleanColumnRowSubset, InverseRowSubset, SyntheticRowSubset

public abstract class RowSubset
extends Object

Defines a selection of rows in a table model.

Author:
Mark Taylor (Starlink)

Field Summary
static RowSubset ALL
          A subset containing all rows (isIncluded always true).
static RowSubset NONE
          A subset containing no rows (isIncluded always false).
 
Constructor Summary
RowSubset(String name)
          Constructor.
 
Method Summary
 String getName()
          Returns the name of this subset.
abstract  boolean isIncluded(long lrow)
          Indicates whether a given row is in the subset or not.
 void setName(String name)
          Sets the name of this subset.
 String toString()
          Returns this subset's name.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ALL

public static RowSubset ALL
A subset containing all rows (isIncluded always true).


NONE

public static RowSubset NONE
A subset containing no rows (isIncluded always false).

Constructor Detail

RowSubset

public RowSubset(String name)
Constructor.

Parameters:
name - subset name
Method Detail

getName

public String getName()
Returns the name of this subset.

Returns:
name

setName

public void setName(String name)
Sets the name of this subset.

Parameters:
name - new name

isIncluded

public abstract boolean isIncluded(long lrow)
Indicates whether a given row is in the subset or not.

Parameters:
lrow - the index of the row in question
Returns:
true iff row lrow is to be included

toString

public String toString()
Returns this subset's name.

Overrides:
toString in class Object


Copyright © 2003-2018 CCLRC: Council for the Central Laboratory of the Research Councils. All Rights Reserved.