pub struct ListTemplateGroup { /* private fields */ }
Implementations
impl ListTemplateGroup
impl ListTemplateGroup
Implementation for the list of template groups.
pub fn new(calc_manager_param: &Rc<RefCell<CalcManager>>) -> ListTemplateGroup
pub fn new(calc_manager_param: &Rc<RefCell<CalcManager>>) -> ListTemplateGroup
pub fn add_template_group(&mut self, group_param: &str) -> Result<(), ErrorType>
pub fn add_template_group(&mut self, group_param: &str) -> Result<(), ErrorType>
Add a new template group into the template group list. If the group name results in a duplicate entry, an incrementing number starting from 2 is appended to the group until a non-duplicate entry is found.
Arguments
group_param
- Group name of the template group.
Return
- ERROR_NONE if successful, otherwise error code.
pub fn append_template_groups(&mut self, list_template_group: ListTemplateGroup)
pub fn append_template_groups(&mut self, list_template_group: ListTemplateGroup)
pub fn create_template_group(
&self,
group_param: &str,
elem_preferences_orig_opt: Option<ElemPreferences>,
copy_propagate: bool
) -> Result<ElemTemplateGroup, ErrorType>
pub fn create_template_group(
&self,
group_param: &str,
elem_preferences_orig_opt: Option<ElemPreferences>,
copy_propagate: bool
) -> Result<ElemTemplateGroup, ErrorType>
Add a new template group into the template group list. If the group name results in a duplicate entry, an incrementing number starting from 2 is appended to the group until a non-duplicate entry is found.
Arguments
group_param
- Group name of the template group.elem_preferences_orig_opt
- Original preferences element to copy (or None).copy_propagate
- Copy only descriptors marked as “propagate” (otherwise copy all descriptors).
Return
- ERROR_NONE if successful, otherwise error code.
pub fn copy_with_calc_manager(
&self,
calc_manager_param: &Rc<RefCell<CalcManager>>
) -> ListTemplateGroup
pub fn copy_with_calc_manager(
&self,
calc_manager_param: &Rc<RefCell<CalcManager>>
) -> ListTemplateGroup
pub fn copy_selected(&self) -> ElemTemplateGroup
pub fn copy_selected(&self) -> ElemTemplateGroup
Performs a deep copy of the template group element and returns a new template group element.
Return
- ERROR_NONE if successful, otherwise error code.
pub fn evaluate_descriptors(&self)
pub fn evaluate_descriptors(&self)
Evaluate all of the descriptors in the template group. For each descriptor that specifies an expression, execute the expression using the list of parameters.
pub fn preferences(&self) -> &ElemPreferences
pub fn preferences(&self) -> &ElemPreferences
pub fn preferences_mut(&mut self) -> &mut ElemPreferences
pub fn preferences_mut(&mut self) -> &mut ElemPreferences
pub fn list_template_event(&self) -> &ListTemplateEvent
pub fn list_template_event(&self) -> &ListTemplateEvent
pub fn list_template_event_mut(&mut self) -> &mut ListTemplateEvent
pub fn list_template_event_mut(&mut self) -> &mut ListTemplateEvent
pub fn sort_on_add(&mut self) -> bool
pub fn sort_on_add(&mut self) -> bool
pub fn get_element_by_group(
&self,
group_param: &str,
select_param: bool
) -> bool
pub fn get_element_by_group(
&self,
group_param: &str,
select_param: bool
) -> bool
pub fn remove(&mut self) -> bool
pub fn remove(&mut self) -> bool
Remove the selected template group from the template group list.
Return
- True if successful, otherwise false.
pub fn set_sort_on_add(&mut self, sort_on_add_param: bool) -> bool
pub fn set_sort_on_add(&mut self, sort_on_add_param: bool) -> bool
pub fn set_sort_updated(&mut self, sort_updated_param: bool) -> bool
pub fn set_sort_updated(&mut self, sort_updated_param: bool) -> bool
pub fn sort(&mut self)
pub fn sort(&mut self)
Sort the template group list.
Trait Implementations
impl ListTrait for ListTemplateGroup
impl ListTrait for ListTemplateGroup
List of template groups list implementation.
Auto Trait Implementations
impl !RefUnwindSafe for ListTemplateGroup
impl !Send for ListTemplateGroup
impl !Sync for ListTemplateGroup
impl Unpin for ListTemplateGroup
impl !UnwindSafe for ListTemplateGroup
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