Package com.portal.app.cc
Class PPayinfoTableModel
java.lang.Object
javax.swing.table.AbstractTableModel
com.portal.app.cc.PPayinfoTableModel
- All Implemented Interfaces:
Serializable
,TableModel
This is the table model commonly used for payment page, Move into Hierarchy invalid input: '&' View Bill Unit Hierarchy
This page has the dynamism to populate appropriate fields as per creation of model
- Author:
- Ramaprasad,Savitha T.M
- See Also:
-
Field Summary
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clears the model datareturns the bill info names and whether the open bill amount is there for respective BU name mapreturns the bill unit name and details of that bill unit mapgetColumnClass
(int column) returns the class type of the columnint
returns the column count of the tablegetColumnName
(int column) returns the column name of the table depending on the index of the columngets the current account namereturns the current account's account numberint
returns the current account's billunit countint
returns the row count of the tableObject[][]
returns the total model of the tablegetValueAt
(int rowIndex, int columnIndex) returns the value from the model at given row and column indexboolean
isCellEditable
(int row, int column) void
sets the bill info names and whether the open bill amount is there for respective BU name mapvoid
setBillUnitDetails
(Hashtable billUnitHash) bill unit name and details of that bill unit mapvoid
setCurrentAccountNumber
(String acctNumber) sets the current account's account numbervoid
setCurrentAcctRowCountDetails
(Object[][] currentAcct) sets the current account details to the modelvoid
setCurrentDataModel
(Object[][] tableData) updates the current account data to the modelvoid
setHierarchyFlag
(boolean flag) set the hierarchy flag true if the account is in hierarchyvoid
setPageType
(int pageType) sets the page type, that is whether this model is for payment page, move hierarchy or view BU hierarchyvoid
setTotalTableStructure
(Object[][] totalTableObj) sets the total table model, that is apart current account, rest of the hierarchy data also set to the modelvoid
updatePayType
(int row, int col, String payType) updates the data in the model for a given row and column indexMethods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener, setValueAt
-
Constructor Details
-
PPayinfoTableModel
-
-
Method Details
-
setPageType
public void setPageType(int pageType) sets the page type, that is whether this model is for payment page, move hierarchy or view BU hierarchy- Parameters:
pageType
- int, 0 is for view hierarchy, 1 is move hierarchy and 2 is for payment page
-
setCurrentAcctRowCountDetails
sets the current account details to the model- Parameters:
currentAcct
- Object[][], current account data
-
getCurrentAccountRowCount
public int getCurrentAccountRowCount()returns the current account's billunit count- Returns:
- int
-
getCurrentAccountName
gets the current account name- Returns:
- String, name of the current account.
-
setBillUnitDetails
bill unit name and details of that bill unit map- Parameters:
billUnitHash
- Hashtable
-
setHierarchyFlag
public void setHierarchyFlag(boolean flag) set the hierarchy flag true if the account is in hierarchy- Parameters:
flag
- boolean
-
getBillUnitDetails
returns the bill unit name and details of that bill unit map- Returns:
- Hashtable
-
clearData
public void clearData()clears the model data -
setTotalTableStructure
sets the total table model, that is apart current account, rest of the hierarchy data also set to the model- Parameters:
totalTableObj
- Object[][]
-
getTotalTableStructure
returns the total model of the table- Returns:
- Object[][]
-
isCellEditable
public boolean isCellEditable(int row, int column) - Specified by:
isCellEditable
in interfaceTableModel
- Overrides:
isCellEditable
in classAbstractTableModel
- Parameters:
row
- intcolumn
- int- Returns:
- boolean
-
getColumnCount
public int getColumnCount()returns the column count of the table- Returns:
- int
-
getColumnName
returns the column name of the table depending on the index of the column- Specified by:
getColumnName
in interfaceTableModel
- Overrides:
getColumnName
in classAbstractTableModel
- Parameters:
column
- int, tells which column name has to be returned- Returns:
- String
-
getColumnClass
returns the class type of the column- Specified by:
getColumnClass
in interfaceTableModel
- Overrides:
getColumnClass
in classAbstractTableModel
- Parameters:
column
- int, ells which column class type has to be returned- Returns:
- Class
-
getRowCount
public int getRowCount()returns the row count of the table- Returns:
- int
-
getValueAt
returns the value from the model at given row and column index- Parameters:
rowIndex
- int, row indexcolumnIndex
- int, column index- Returns:
- Object
-
updatePayType
updates the data in the model for a given row and column index- Parameters:
row
- int, row indexcol
- int, column indexpayType
- String the data to be updated
-
setCurrentDataModel
updates the current account data to the model- Parameters:
tableData
- Object[][], data to be set to the model
-
setBillInfoIdOpenBills
sets the bill info names and whether the open bill amount is there for respective BU name map- Parameters:
map
- HashMap
-
setCurrentAccountNumber
sets the current account's account number -
getCurrentAccountNumber
returns the current account's account number -
getBillInfoIdOpenBills
returns the bill info names and whether the open bill amount is there for respective BU name map- Returns:
- HashMap
-