Struct amfnengine::core::list_amortization::ListAmortization
[−]pub struct ListAmortization { /* private fields */ }
Implementations
impl ListAmortization
impl ListAmortization
List of amortization elements implementation.
pub fn new() -> ListAmortization
pub fn new() -> ListAmortization
pub fn add_amortization(
&mut self,
event_type_param: &str,
orig_date_param: usize,
event_date_param: usize,
sort_order_param: usize,
value_param: Decimal,
value_expr_param: &str,
periods_param: usize,
intervals_param: usize,
frequency_param: FrequencyType,
principal_decrease_param: Decimal,
principal_increase_param: Decimal,
list_event_index_param: usize,
event_sequence_param: usize,
stat_sequence_param: usize,
elem_extension_param: ElemExtension,
list_parameter_param: Option<ListParameter>,
list_descriptor_param: Option<ListDescriptor>
) -> bool
pub fn add_amortization(
&mut self,
event_type_param: &str,
orig_date_param: usize,
event_date_param: usize,
sort_order_param: usize,
value_param: Decimal,
value_expr_param: &str,
periods_param: usize,
intervals_param: usize,
frequency_param: FrequencyType,
principal_decrease_param: Decimal,
principal_increase_param: Decimal,
list_event_index_param: usize,
event_sequence_param: usize,
stat_sequence_param: usize,
elem_extension_param: ElemExtension,
list_parameter_param: Option<ListParameter>,
list_descriptor_param: Option<ListDescriptor>
) -> bool
Add a new amortization element into the amortization list.
Arguments
event_type_param
- Event type.orig_date_param
- Original date.event_date_param
- Event date.sort_order_param
- Sort order.value_param
- Value parameter.value_expr_param
- Value expression parameter.periods_param
- Periods parameter.intervals_param
- Intervals parameter.frequency_param
- Frequency parameter.principal_decrease_param
- Principal decrease.principal_increase_param
- Principal increase.list_event_index_param
- List event index.event_sequence_param
- Event sequence.stat_sequence_param
- Event stat sequence.extension_param
- Extension (current value, interest change, principal change, statistic value).list_parameter_param
- List parameter.list_descriptor_param
- List descriptor.
Return
- True if successful, otherwise false.
pub fn add_amortization_ex(
&mut self,
event_type_param: &str,
orig_date_param: usize,
event_date_param: usize,
sort_order_param: usize,
value_param: Decimal,
value_expr_param: &str,
periods_param: usize,
intervals_param: usize,
frequency_param: FrequencyType,
principal_decrease_param: Decimal,
principal_increase_param: Decimal,
interest_param: Decimal,
sl_interest_param: Decimal,
value_to_interest_param: Decimal,
value_to_principal_param: Decimal,
acc_balance_param: Decimal,
balance_param: Decimal,
list_event_index_param: usize,
event_sequence_param: usize,
stat_sequence_param: usize,
elem_extension_param: ElemExtension,
list_parameter_param: Option<ListParameter>,
list_descriptor_param: Option<ListDescriptor>
) -> bool
pub fn add_amortization_ex(
&mut self,
event_type_param: &str,
orig_date_param: usize,
event_date_param: usize,
sort_order_param: usize,
value_param: Decimal,
value_expr_param: &str,
periods_param: usize,
intervals_param: usize,
frequency_param: FrequencyType,
principal_decrease_param: Decimal,
principal_increase_param: Decimal,
interest_param: Decimal,
sl_interest_param: Decimal,
value_to_interest_param: Decimal,
value_to_principal_param: Decimal,
acc_balance_param: Decimal,
balance_param: Decimal,
list_event_index_param: usize,
event_sequence_param: usize,
stat_sequence_param: usize,
elem_extension_param: ElemExtension,
list_parameter_param: Option<ListParameter>,
list_descriptor_param: Option<ListDescriptor>
) -> bool
Add a new amortization element into the amortization list.
Arguments
event_type_param
- Event type.orig_date_param
- Original date.event_date_param
- Event date.sort_order_param
- Sort order.value_param
- Value parameter.value_expr_param
- Value expression parameter.periods_param
- Periods parameter.intervals_param
- Intervals parameter.frequency_param
- Frequency parameter.principal_decrease_param
- Principal decrease.principal_increase_param
- Principal increase.interest_param
- Compounded interest.sl_interest_param
- Straight-line interest.value_to_interest_param
- Value to interest.value_to_principal_param
- Value to principal.acc_balance_param
- Accrued interest balance at start of event.balance_param
- Beginning active balance at start of event.list_event_index_param
- List event index.event_sequence_param
- Event sequence.stat_sequence_param
- Event stat sequence.extension_param
- Extension (current value, interest change, principal change, statistic value).list_parameter_param
- List parameter.list_descriptor_param
- List descriptor.
Return
- True if successful, otherwise false.
pub fn copy(&self, updating_json: bool) -> ListAmortization
pub fn copy(&self, updating_json: bool) -> ListAmortization
pub fn elem_type(&self) -> ExtensionType
pub fn elem_type(&self) -> ExtensionType
pub fn event_type(&self) -> &str
pub fn event_type(&self) -> &str
pub fn event_date(&self) -> usize
pub fn event_date(&self) -> usize
Get the date of the amortization element in YYYYMMDD format (major sort key).
Return
- See description.
pub fn sort_order(&self) -> usize
pub fn sort_order(&self) -> usize
pub fn orig_value(&self) -> Decimal
pub fn orig_value(&self) -> Decimal
pub fn value_expr(&self) -> &str
pub fn value_expr(&self) -> &str
Get the optional value expression evaluated when the amortization list is balanced.
Return
- See description.
pub fn frequency(&self) -> FrequencyType
pub fn frequency(&self) -> FrequencyType
pub fn principal_decrease(&self) -> Decimal
pub fn principal_decrease(&self) -> Decimal
pub fn principal_increase(&self) -> Decimal
pub fn principal_increase(&self) -> Decimal
pub fn sl_interest(&self) -> Decimal
pub fn sl_interest(&self) -> Decimal
pub fn value_to_interest(&self) -> Decimal
pub fn value_to_interest(&self) -> Decimal
pub fn value_to_principal(&self) -> Decimal
pub fn value_to_principal(&self) -> Decimal
pub fn acc_balance(&self) -> Decimal
pub fn acc_balance(&self) -> Decimal
pub fn list_event_index(&self) -> usize
pub fn list_event_index(&self) -> usize
pub fn event_sequence(&self) -> usize
pub fn event_sequence(&self) -> usize
pub fn stat_sequence(&self) -> usize
pub fn stat_sequence(&self) -> usize
Get the sequence number of principal change with statistics set or 0 (if not applicable).
Return
- See description.
pub fn elem_extension(&self) -> &ElemExtension
pub fn elem_extension(&self) -> &ElemExtension
pub fn list_parameter(&self) -> Option<&ListParameter>
pub fn list_parameter(&self) -> Option<&ListParameter>
pub fn list_descriptor(&self) -> Option<&ListDescriptor>
pub fn list_descriptor(&self) -> Option<&ListDescriptor>
pub fn set_all_index_values(
&mut self,
event_index_param: usize,
value_param: Decimal
)
pub fn set_all_index_values(
&mut self,
event_index_param: usize,
value_param: Decimal
)
Set the value of all amortization elements having a specified original event index.
Arguments
index_param
- Original event index.value_param
- New value.
pub fn set_all_interest_values(&mut self, value_param: Decimal)
pub fn set_all_interest_values(&mut self, value_param: Decimal)
pub fn set_principal_decrease(
&mut self,
principal_decrease_param: Decimal
) -> bool
pub fn set_principal_decrease(
&mut self,
principal_decrease_param: Decimal
) -> bool
pub fn set_principal_increase(
&mut self,
principal_increase_param: Decimal
) -> bool
pub fn set_principal_increase(
&mut self,
principal_increase_param: Decimal
) -> bool
pub fn set_interest(&mut self, interest_param: Decimal) -> bool
pub fn set_interest(&mut self, interest_param: Decimal) -> bool
pub fn set_sl_interest(&mut self, sl_interest_param: Decimal) -> bool
pub fn set_sl_interest(&mut self, sl_interest_param: Decimal) -> bool
pub fn set_value_to_interest(
&mut self,
value_to_interest_param: Decimal
) -> bool
pub fn set_value_to_interest(
&mut self,
value_to_interest_param: Decimal
) -> bool
pub fn set_value_to_principal(
&mut self,
value_to_principal_param: Decimal
) -> bool
pub fn set_value_to_principal(
&mut self,
value_to_principal_param: Decimal
) -> bool
pub fn set_acc_balance(&mut self, acc_balance_param: Decimal) -> bool
pub fn set_acc_balance(&mut self, acc_balance_param: Decimal) -> bool
pub fn set_balance(&mut self, balance_param: Decimal) -> bool
pub fn set_balance(&mut self, balance_param: Decimal) -> bool
pub fn set_stat_sequence(&mut self, stat_sequence_param: usize) -> bool
pub fn set_stat_sequence(&mut self, stat_sequence_param: usize) -> bool
pub fn sort(&mut self)
pub fn sort(&mut self)
Sort the amortization list.
Trait Implementations
impl Default for ListAmortization
impl Default for ListAmortization
List of amortization elements default implementation.
impl ListTrait for ListAmortization
impl ListTrait for ListAmortization
List of amortization elements list implementation.
Auto Trait Implementations
impl !RefUnwindSafe for ListAmortization
impl Send for ListAmortization
impl !Sync for ListAmortization
impl Unpin for ListAmortization
impl UnwindSafe for ListAmortization
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more