7 module subroutine lss_get_line_search(this, ls)
8 class(line_search_solver),
intent(in) :: this
9 class(line_search),
intent(out),
allocatable :: ls
10 if (
allocated(this%m_lineSearch)) &
11 allocate(ls, source = this%m_lineSearch)
15 module subroutine lss_set_line_search(this, ls)
16 class(line_search_solver),
intent(inout) :: this
17 class(line_search),
intent(in) :: ls
18 if (
allocated(this%m_lineSearch))
deallocate(this%m_lineSearch)
19 allocate(this%m_lineSearch, source = ls)
23 module subroutine lss_set_default(this)
24 class(line_search_solver),
intent(inout) :: this
25 type(line_search) :: ls
26 call this%set_line_search(ls)
30 pure module function lss_is_line_search_defined(this) result(x)
31 class(line_search_solver),
intent(in) :: this
33 x =
allocated(this%m_lineSearch)
37 pure module function lss_get_use_search(this) result(x)
38 class(line_search_solver),
intent(in) :: this
40 x = this%m_useLineSearch
44 module subroutine lss_set_use_search(this, x)
45 class(line_search_solver),
intent(inout) :: this
46 logical,
intent(in) :: x
47 this%m_useLineSearch = x