jet.api
Class ReportSortInfo

java.lang.Object
  extended by jet.api.ReportSortInfo

public class ReportSortInfo
extends java.lang.Object

A infomation package of report sort


Constructor Summary
ReportSortInfo(boolean needTopN, int topN)
          Constructor.
ReportSortInfo(boolean needTopN, int topN, SortInfo[] sortInfo)
          Constructor.
 
Method Summary
 void addSortInfo(SortInfo info)
          add a sort information
 void downSortInfo(int index)
          move down specified sort informations
 boolean getNeedTopN()
          get topN status
 SortInfo[] getSortInfo()
          get all sort information of this report
 int getTopN()
          get topN number
 int indexOfSortInfo(SortInfo info)
          get specified sort information index number of sort informations
 int indexOfSortInfo(java.lang.String sortBy)
          get sort information index number of specified sortBy column name in sort informations
 boolean insertSortInfo(SortInfo sinfo, int index)
          add a sort information at specified index
 boolean isSortIn(java.lang.String sortBy)
          find sort information which is sorted by specified sortBy column
 void removeSortInfo(int index)
          remove the sort information at speicified index
 void removeSortInfo(SortInfo info)
          remove a sort information
 void removeSortInfo(java.lang.String sortBy)
          remove the sort information which is sorted by sortBy
 void setNeedTopN(boolean needTopN)
          set topN status
 void setSortInfo(SortInfo[] sinfo)
           
 void setTopN(int topN)
          set topN number
 void upSortInfo(int index)
          move up specified sort informations
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReportSortInfo

public ReportSortInfo(boolean needTopN,
                      int topN)
Constructor. Create report sort information.

Parameters:
needTopN - if set topN or not.
topN - the topN number.

ReportSortInfo

public ReportSortInfo(boolean needTopN,
                      int topN,
                      SortInfo[] sortInfo)
Constructor. Create report sort information.

Parameters:
needTopN - if set topN or not.
topN - the topN number.
sortInfo - sort informations
Method Detail

getNeedTopN

public boolean getNeedTopN()
get topN status

Returns:
true if report need sort topN

getTopN

public int getTopN()
get topN number

Returns:
topN number

setTopN

public void setTopN(int topN)
set topN number

Parameters:
topN - topN number

setNeedTopN

public void setNeedTopN(boolean needTopN)
set topN status

Parameters:
needTopN - needTopN status

setSortInfo

public void setSortInfo(SortInfo[] sinfo)

addSortInfo

public void addSortInfo(SortInfo info)
add a sort information

Parameters:
info - SortInfo infomation

insertSortInfo

public boolean insertSortInfo(SortInfo sinfo,
                              int index)
add a sort information at specified index

Parameters:
sinfo - SortInfo infomation
index - index number
Returns:
true if info is inserted sucessfully

removeSortInfo

public void removeSortInfo(SortInfo info)
remove a sort information

Parameters:
info - SortInfo infomation

removeSortInfo

public void removeSortInfo(java.lang.String sortBy)
remove the sort information which is sorted by sortBy

Parameters:
sortBy - sortby column

removeSortInfo

public void removeSortInfo(int index)
remove the sort information at speicified index

Parameters:
index - index number of sort informations

indexOfSortInfo

public int indexOfSortInfo(java.lang.String sortBy)
get sort information index number of specified sortBy column name in sort informations

Parameters:
sortBy - sortBy column name
Returns:
index number of specified sortby column name

indexOfSortInfo

public int indexOfSortInfo(SortInfo info)
get specified sort information index number of sort informations

Parameters:
info - sort infomation
Returns:
index number of specified sort infomation

upSortInfo

public void upSortInfo(int index)
move up specified sort informations

Parameters:
index - index number of sort infomation

downSortInfo

public void downSortInfo(int index)
move down specified sort informations

Parameters:
index - index number of sort infomation

isSortIn

public boolean isSortIn(java.lang.String sortBy)
find sort information which is sorted by specified sortBy column

Parameters:
sortBy - sortBy column name
Returns:
true if sucessful.

getSortInfo

public SortInfo[] getSortInfo()
get all sort information of this report

Returns:
SortInfo array.