org.melati.poem
Class DisplayLevel

Package class diagram package DisplayLevel
java.lang.Object
  extended by org.melati.poem.DisplayLevel

public final class DisplayLevel
extends Object

An attribute of a Column which indicates what level of reporting of a Table it should be included in.


Nested Class Summary
static class DisplayLevel.NameUnrecognisedException
          Thrown when a DisplayLevel which doesn't exist is referenced, by misspelling for example.
 
Field Summary
static DisplayLevel detail
          Display level of Columns included in a detailed display of a single record.
 Integer index
          The numeric Id of the Level.
static DisplayLevel never
          Display level of Columns hidden from users.
static DisplayLevel primary
          Display level of a Column used as the name of the whole record.
static DisplayLevel record
          Display level of Columns included in display focusing on a single record, but without detail.
static DisplayLevel summary
          Display level of Columns to be included in a summary of records in a set.
 
Method Summary
static int count()
           
static DisplayLevel forIndex(int index)
          Get by numeric id.
 Integer getIndex()
           
 String getName()
           
static DisplayLevel named(String name)
          Get by name.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

index

public final Integer index
The numeric Id of the Level.


primary

public static final DisplayLevel primary
Display level of a Column used as the name of the whole record.

See Also:
Table.displayColumn()

summary

public static final DisplayLevel summary
Display level of Columns to be included in a summary of records in a set.

This is the default display level for a Column.

See Also:
Table.getSummaryDisplayColumns(), Column.defaultDisplayLevel(), Persistent.getSummaryDisplayFields()

record

public static final DisplayLevel record
Display level of Columns included in display focusing on a single record, but without detail.

See Also:
Table.getRecordDisplayColumns(), Persistent.getRecordDisplayFields()

detail

public static final DisplayLevel detail
Display level of Columns included in a detailed display of a single record.

See Also:
Table.getRecordDisplayColumns(), Persistent.getDetailDisplayFields()

never

public static final DisplayLevel never
Display level of Columns hidden from users.

Method Detail

getName

public String getName()
Returns:
the name

getIndex

public Integer getIndex()
Returns:
the index.

forIndex

public static DisplayLevel forIndex(int index)
Get by numeric id.

Parameters:
index - the numeric Id of the level
Returns:
the level corresponding to the index

count

public static int count()
Returns:
the number of levels.

named

public static DisplayLevel named(String name)
Get by name.

Parameters:
name - The name of the required level
Returns:
the named level

toString

public String toString()
Overrides:
toString in class Object
Returns:
the name and index.
See Also:
Object.toString()


Copyright © 2000-2010 PanEris. All Rights Reserved.