BrightSide Workbench Full Report + Source Code
org.turro.financials.model.document.AmountTaxableSet Class Reference
Inheritance diagram for org.turro.financials.model.document.AmountTaxableSet:
Collaboration diagram for org.turro.financials.model.document.AmountTaxableSet:

Public Member Functions

boolean add (Double perCent, Double tax, Double req, Double taxValue, Double taxRealValue, Double reqValue, Double subtotal, Double taxable, int fractionDigits)
 
AmountTaxable getPercent (Double perCent, Double tax, Double req)
 
double getTaxable ()
 
double getTaxAmount ()
 
double getTaxRealAmount ()
 
double getTotal ()
 
void clearEmpty ()
 

Detailed Description

Author
Lluis TurrĂ³ Cutiller lluis.nosp@m.@tur.nosp@m.ro.or.nosp@m.g

Definition at line 28 of file AmountTaxableSet.java.

Member Function Documentation

◆ add()

boolean org.turro.financials.model.document.AmountTaxableSet.add ( Double  perCent,
Double  tax,
Double  req,
Double  taxValue,
Double  taxRealValue,
Double  reqValue,
Double  subtotal,
Double  taxable,
int  fractionDigits 
)

Definition at line 30 of file AmountTaxableSet.java.

31  {
32  AmountTaxable at = getPercent(perCent, tax, req);
33  at.setFractionDigits(fractionDigits);
34  at.add(taxValue, taxRealValue, reqValue, subtotal, taxable);
35  return super.add(at);
36  }
AmountTaxable getPercent(Double perCent, Double tax, Double req)
Here is the call graph for this function:

◆ clearEmpty()

void org.turro.financials.model.document.AmountTaxableSet.clearEmpty ( )

Definition at line 79 of file AmountTaxableSet.java.

79  {
80  Iterator<AmountTaxable> it = iterator();
81  while(it.hasNext()) {
82  if(it.next().isEmpty()) {
83  it.remove();
84  }
85  }
86  }

◆ getPercent()

AmountTaxable org.turro.financials.model.document.AmountTaxableSet.getPercent ( Double  perCent,
Double  tax,
Double  req 
)

Definition at line 38 of file AmountTaxableSet.java.

38  {
39  for(AmountTaxable at : this) {
40  if(at.isPerCent(perCent)) {
41  return at;
42  }
43  }
44  return new AmountTaxable(perCent, tax, req);
45  }
Here is the call graph for this function:
Here is the caller graph for this function:

◆ getTaxable()

double org.turro.financials.model.document.AmountTaxableSet.getTaxable ( )

Definition at line 47 of file AmountTaxableSet.java.

47  {
48  double amount = 0;
49  for(AmountTaxable a : this) {
50  amount += a.getTaxable();
51  }
52  return amount;
53  }
Here is the call graph for this function:

◆ getTaxAmount()

double org.turro.financials.model.document.AmountTaxableSet.getTaxAmount ( )

Definition at line 55 of file AmountTaxableSet.java.

55  {
56  double amount = 0;
57  for(AmountTaxable a : this) {
58  amount += a.getTaxAmount();
59  }
60  return amount;
61  }
Here is the call graph for this function:

◆ getTaxRealAmount()

double org.turro.financials.model.document.AmountTaxableSet.getTaxRealAmount ( )

Definition at line 63 of file AmountTaxableSet.java.

63  {
64  double amount = 0;
65  for(AmountTaxable a : this) {
66  amount += a.getTaxRealAmount();
67  }
68  return amount;
69  }
Here is the call graph for this function:

◆ getTotal()

double org.turro.financials.model.document.AmountTaxableSet.getTotal ( )

Definition at line 71 of file AmountTaxableSet.java.

71  {
72  double amount = 0;
73  for(AmountTaxable a : this) {
74  amount += a.getTotal();
75  }
76  return amount;
77  }
Here is the call graph for this function:

The documentation for this class was generated from the following file: