ProgressBar_Class Module

module~~progressbar_class~~UsesGraph module~progressbar_class ProgressBar_Class module~variablekind variableKind module~variablekind->module~progressbar_class module~stopwatch_class Stopwatch_Class module~variablekind->module~stopwatch_class module~m_time m_time module~variablekind->module~m_time module~m_strings m_strings module~variablekind->module~m_strings module~m_parameters m_parameters module~variablekind->module~m_parameters module~m_errors m_errors module~variablekind->module~m_errors module~stopwatch_class->module~progressbar_class iso_fortran_env iso_fortran_env iso_fortran_env->module~progressbar_class iso_fortran_env->module~variablekind iso_fortran_env->module~stopwatch_class iso_fortran_env->module~m_strings iso_fortran_env->module~m_errors module~m_time->module~progressbar_class module~m_time->module~stopwatch_class module~m_strings->module~stopwatch_class module~m_parameters->module~m_strings module~m_errors->module~m_strings
Help

An inline and updateable command prompt progress bar

Example usage

use variableKind
use ProgressBar_Class
type(ProgressBar) :: P
integer(i32) :: i, N
N = 100000
call P%set(N, time = .false.)
call P%print(0)
do i = 1, N
  Compute some stuff
  call P%print(i)
enddo
call P%set(N, time = .true.)
call P%print(0)
do i = 1, N
  Compute some stuff
  call P%print(i)
enddo

Used By

module~~progressbar_class~~UsedByGraph module~progressbar_class ProgressBar_Class program~scaletest_coretran scaleTest_coretran module~progressbar_class->program~scaletest_coretran module~m_tests m_tests module~progressbar_class->module~m_tests program~test_coretran test_coretran module~m_tests->program~test_coretran
Help


Interfaces

public interface ProgressBar

  • private function ProgressBar_i1(N, title, time) result(res)

    Interfaced with class instantiation ProgressBar()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i32), intent(in) :: N

    Maximum expected number of iterations

    character(len=*), intent(in), optional :: title

    Title to give the progress bar

    logical, intent(in), optional :: time

    Show an estimated time to completion?

    Return Value type(ProgressBar)

  • private function ProgressBar_id1(N, title, time) result(res)

    Interfaced with class instantiation ProgressBar()

    Arguments

    Type IntentOptional AttributesName
    integer(kind=i64), intent(in) :: N

    Maximum expected number of iterations

    character(len=*), intent(in), optional :: title

    Title to give the progress bar

    logical, intent(in), optional :: time

    Show an estimated time to completion?

    Return Value type(ProgressBar)


Derived Types

type, public :: ProgressBar

A progress bar that displays a moving counter with percentage and optional estimated time remaining Print the progress Bar

Constructor

private function ProgressBar_i1(N, title, time)

Interfaced with class instantiation ProgressBar()

private function ProgressBar_id1(N, title, time)

Interfaced with class instantiation ProgressBar()

Type-Bound Procedures

generic, public :: print => print_i1_ProgressBar_, print_id1_ProgressBar_

Print the progress Bar