|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.moneydance.apps.md.model.AbstractTxn
com.moneydance.apps.md.model.SplitTxn
public final class SplitTxn
Concrete class that represents the destination side of a transaction. The destination side of the transaction is associated with exactly one source (or parent) transactions. The amount of a SplitTxn is stored in terms of the currency of the account for the associated ParentTxn.
Field Summary |
---|
Constructor Summary | |
---|---|
SplitTxn(ParentTxn parentTxn,
long parentAmount,
double rate,
Account account,
java.lang.String description,
long txnId,
byte status)
Deprecated. Please use the other constructor |
|
SplitTxn(ParentTxn parentTxn,
long parentAmount,
long splitAmount,
double rate,
Account account,
java.lang.String description,
long txnId,
byte status)
Creates a SplitTxn with the parentAmount having a negative effect on the account of parentTxn, and splitAmount having a positive effect on the account of this SplitTxn. |
Method Summary | |
---|---|
long |
getAmount()
Get the amount of this transaction in terms of the currency of the parent transaction. |
java.lang.String |
getCheckNumber()
Get the checknumber associated with this transaction. |
long |
getDate()
Deprecated. use getDateInt() instead! |
long |
getDateEntered()
Get the date that this transaction was entered. |
int |
getDateInt()
Get the date of this transaction |
Txn |
getFlipSide()
Return the 'flip side' of this split transaction. |
AbstractTxn |
getOtherTxn(int i)
Return the "other transaction" for this split. |
int |
getOtherTxnCount()
Return the number of "other transactions". |
long |
getParentAmount()
Get the amount of this transaction in terms of the currency of the parent transaction. |
ParentTxn |
getParentTxn()
Get the ParentTxn for which this is a split. |
double |
getRate()
Get the rate for the transaction. |
long |
getTaxDate()
Deprecated. use getTaxDateInt() instead! |
int |
getTaxDateInt()
Get the date of this transaction for tax purposes. |
java.lang.String |
getTransferType()
Get the type of transaction. |
long |
getValue()
Get the amount that this transaction affects the account of the this transaction. |
boolean |
isTransferTo(Account acct)
Check whether or not this transaction includes a transfer to the given account. |
void |
negateAmount()
Reverses the sign of the amount of the split |
void |
setAmount(long newAmount)
Set the amount that this split affects the -other- side of the transaction. |
void |
setAmount(long newSplitAmount,
double newRate,
long newParentAmount)
Set the amounts for this transaction, including the amount of the transaction in the split account, the rate, and the amount of the transaction in the account of the parent transaction. |
void |
setAmount(long newSplitAmount,
long newParentAmount)
Set the amounts for this transaction, including the amount of the transaction in the split account, and the amount of the transaction in the account of the parent transaction. |
void |
setCheckNumber(java.lang.String newCheckNumber)
|
void |
setParentAmount(double newRate,
long newParentAmount)
Set the amount of the transaction in the parent account. |
void |
setRate(double newRate)
|
void |
takeAmounts(SplitTxn split)
Take the amount and rates from the given split. |
void |
takeValuesFrom(SplitTxn otherTxn)
|
java.lang.String |
toString()
|
Methods inherited from class com.moneydance.apps.md.model.AbstractTxn |
---|
getAccount, getCheckNumAsInt, getDescription, getFIID, getFiTxnId, getStatus, getStatusChar, getTag, getTag, getTags, getTxnId, isDirty, isNew, needsToBePrinted, removeTag, resetDirty, setAccount, setDescription, setDirty, setFIID, setFiTxnId, setIsNew, setStatus, setTag, setTags, wasDownloaded |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public SplitTxn(ParentTxn parentTxn, long parentAmount, double rate, Account account, java.lang.String description, long txnId, byte status)
public SplitTxn(ParentTxn parentTxn, long parentAmount, long splitAmount, double rate, Account account, java.lang.String description, long txnId, byte status)
Method Detail |
---|
public ParentTxn getParentTxn()
getParentTxn
in interface Txn
getParentTxn
in class AbstractTxn
public long getDate()
getDate
in class AbstractTxn
public long getDateEntered()
getDateEntered
in interface Txn
getDateEntered
in class AbstractTxn
public long getTaxDate()
getTaxDate
in class AbstractTxn
public int getDateInt()
getDateInt
in interface Txn
getDateInt
in class AbstractTxn
public int getTaxDateInt()
getTaxDateInt
in interface Txn
getTaxDateInt
in class AbstractTxn
public long getParentAmount()
public long getAmount()
public long getValue()
getValue
in interface Txn
getValue
in class AbstractTxn
public boolean isTransferTo(Account acct)
isTransferTo
in interface Txn
isTransferTo
in class AbstractTxn
public double getRate()
public java.lang.String getTransferType()
getTransferType
in interface Txn
getTransferType
in class AbstractTxn
public void setParentAmount(double newRate, long newParentAmount)
public void negateAmount()
public void takeAmounts(SplitTxn split)
public final void takeValuesFrom(SplitTxn otherTxn)
public void setAmount(long newSplitAmount, long newParentAmount)
public void setAmount(long newSplitAmount, double newRate, long newParentAmount)
public void setAmount(long newAmount)
public void setRate(double newRate)
public final java.lang.String getCheckNumber()
AbstractTxn
getCheckNumber
in interface Txn
getCheckNumber
in class AbstractTxn
public final void setCheckNumber(java.lang.String newCheckNumber)
public int getOtherTxnCount()
getOtherTxnCount
in interface Txn
getOtherTxnCount
in class AbstractTxn
public AbstractTxn getOtherTxn(int i)
getOtherTxn
in interface Txn
getOtherTxn
in class AbstractTxn
public Txn getFlipSide()
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |