|
The Gravey Framework and RATS RIA | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
Object
|
+--GrvObject
|
+--MVCObserver
|
+--MVCModel
|
+--MVCListModel
|
+--BalanceListModel
DOMAIN-OBJECT: This class encapsulates the data model
for the Balance list of a particular Account.
This model subscribes to a AccountSelectionModel
so that a new balance list can be downloaded whenever
a new account is selected.
Secondarily, this model implements the MVCBoolModel.isTrue()
interface where the value reflects whether this model is "dirty".
Version: 2.0
Author: Bruce Wallace (PolyGlotInc.com)
See:
| Constructor Summary | |
BalanceListModel
()
|
|
| Method Summary | |
int
|
appendTransaction( <int> sIndex )
append a new blank transaction associated with the specified balance |
boolean
|
canBalanceToggle(<int> i)
return whether the specified balance can expand/collapse |
boolean
|
canToggle( <boolean> doAllFlag, <int> si )
return whether balance(s) can expand/collapse |
int
|
createTransaction( <int> sIndex, <int> rIndex )
insert a new blank transaction associated with the specified balance |
void
|
deleteTransaction( <int> sIndex, <int> rIndex )
delete the specified transaction |
void
|
editTransaction( <int> sIndex, <int> rIndex )
enable editing on the specified transaction |
Object
|
getAccountKey()
return opaque key of our Account |
Float
|
getDiffA(<int> i)
return unreconciled balance A for specified balance |
Float
|
getDiffB(<int> i)
return unreconciled balance B for specified balance |
Float
|
getDiffC(<int> i)
return unreconciled balance C for specified balance |
Float
|
getDiffD(<int> i)
return unreconciled balance D for specified balance |
Float
|
getDiffTotal(<int> i)
return total of unreconciled amount for specified balance |
Float
|
getNetA()
return unreconciled balance A for the whole Account |
Float
|
getNetB()
return unreconciled balance B for the whole Account |
Float
|
getNetC()
return unreconciled balance C for the whole Account |
Float
|
getNetD()
return unreconciled balance D for the whole Account |
Float
|
getNetTotal()
return total unreconciled balances for the whole Account |
Transaction
|
getTransaction( <int> sIndex, <int> rIndex )
return the specified transaction |
int
|
getTransactionCount(<int> i)
return how many transactions are associated with the specified balance |
boolean
|
hasAllZeroDiff(<int> i)
return true iff all unreconciled amounts for specified balance are zero |
boolean
|
isAccountReconciled()
is the whole Account (i.e. |
boolean
|
isBalanceDirty(<int> i)
return whether the specified balance is being reconciled |
boolean
|
isBalanceExpanded(<int> i)
return whether the specified balance is expanded |
boolean
|
isBalanceOpen(<int> i)
return whether the specified balance is collapsed or open |
boolean
|
isBalanceReconciled(<int> i)
return whether the specified balance is reconciled and update the balance todo flag as a side effect. |
boolean
|
isDirty()
return whether any transactions are changed for the whole Account |
boolean
|
isTrue()
MVCBoolModel API: return "I am modified" flag |
Float
|
isValid()
return whether all transactions are valid for the whole Account |
void
|
konstructor( <AccountSelectionModel> accountSelectionModel )
|
Transaction
|
newTransaction()
return a new blank transaction |
Transaction
|
openTransaction( <int> sIndex, <int> rIndex )
return the specified transaction with the intent to change its attributes |
void
|
save()
save all of the edits into the database via service layer |
void
|
toggleOpen( <boolean> doAllFlag, <int> si )
toggle the "open" flag of the specified balance. |
void
|
undeleteTransaction( <int> sIndex, <int> rIndex )
undelete the specified transaction |
void
|
uneditTransaction( <int> sIndex, <int> rIndex )
rollback edit on the specified transaction |
void
|
update()
handle update events from the Account Selection Model |
| Methods inherited from class MVCListModel |
clone, dump, hash, _pop, _push, _del, _reset, reset, getCount, getItem, getItemStr, addItem, delItem, iterate, addBefore, getMemento, setMemento
|
| Methods inherited from class MVCModel |
dumpSubscribers, toString, dirty, clean, publish, GET, _SET, SET, updateStamp, BeginTransaction, EndTransaction, addObserver, delObserver, notifyObservers
|
| Methods inherited from class MVCObserver |
subscribe
|
| Methods inherited from class GrvObject |
souper
|
| Constructor Detail |
BalanceListModel()
| Method Detail |
int appendTransaction( <int> sIndex )
sIndex - index into "this" balance list
boolean canBalanceToggle(<int> i)
i - index into "this" balance list
boolean canToggle( <boolean> doAllFlag, <int> si )
doAllFlag - if true, check all of the balances
si - index into "this" balance list
int createTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
void deleteTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
void editTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
Object getAccountKey()
Float getDiffA(<int> i)
i - index into "this" balance list
Float getDiffB(<int> i)
i - index into "this" balance list
Float getDiffC(<int> i)
i - index into "this" balance list
Float getDiffD(<int> i)
i - index into "this" balance list
Float getDiffTotal(<int> i)
i - index into "this" balance list
Float getNetA()
Float getNetB()
Float getNetC()
Float getNetD()
Float getNetTotal()
Transaction getTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
int getTransactionCount(<int> i)
i - index into "this" balance list
boolean hasAllZeroDiff(<int> i)
i - index into "this" balance list
boolean isAccountReconciled()
boolean isBalanceDirty(<int> i)
i - index into "this" balance list
boolean isBalanceExpanded(<int> i)
i - index into "this" balance list
boolean isBalanceOpen(<int> i)
i - index into "this" balance list
boolean isBalanceReconciled(<int> i)
i - index into "this" balance list
boolean isDirty()
boolean isTrue()
Float isValid()
void konstructor( <AccountSelectionModel> accountSelectionModel )
accountSelectionModel - model of which account is selected
Transaction newTransaction()
Transaction openTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
void save()
void toggleOpen( <boolean> doAllFlag, <int> si )
doAllFlag - if true, set all of the balances to new value
si - index into "this" balance list
void undeleteTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
void uneditTransaction( <int> sIndex, <int> rIndex )
sIndex - index into "this" balance list
rIndex - index into transaction list for specified balance
void update()
|
The Gravey Framework and RATS RIA | ||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||