36 use,
intrinsic :: iso_c_binding
77 type,
bind(c) :: kim_simulator_model_handle_type
78 type(c_ptr) :: p = c_null_ptr
90 interface operator(.eq.)
91 module procedure kim_simulator_model_handle_equal
92 end interface operator(.eq.)
97 interface operator(.ne.)
98 module procedure kim_simulator_model_handle_not_equal
99 end interface operator(.ne.)
108 module procedure kim_simulator_model_get_simulator_name_and_version
118 module procedure kim_simulator_model_get_number_of_supported_species
128 module procedure kim_simulator_model_get_supported_species
138 module procedure kim_simulator_model_open_and_initialize_template_map
148 module procedure kim_simulator_model_template_map_is_open
157 module procedure kim_simulator_model_add_template_map
167 module procedure kim_simulator_model_close_template_map
177 module procedure kim_simulator_model_get_number_of_simulator_fields
187 module procedure kim_simulator_model_get_simulator_field_metadata
197 module procedure kim_simulator_model_get_simulator_field_line
207 module procedure kim_simulator_model_get_parameter_file_directory_name
217 module procedure kim_simulator_model_get_specification_file_name
227 module procedure kim_simulator_model_get_number_of_parameter_files
240 module procedure kim_simulator_model_get_parameter_file_name
250 module procedure kim_simulator_model_get_parameter_file_basename
260 module procedure kim_simulator_model_set_simulator_buffer_pointer
270 module procedure kim_simulator_model_get_simulator_buffer_pointer
279 module procedure kim_simulator_model_to_string
288 module procedure kim_simulator_model_set_log_id
298 module procedure kim_simulator_model_push_log_verbosity
307 module procedure kim_simulator_model_pop_log_verbosity
314 logical recursive function kim_simulator_model_handle_equal(lhs, rhs)
319 if ((.not. c_associated(lhs%p)) .and. (.not. c_associated(rhs%p)))
then
320 kim_simulator_model_handle_equal = .true.
322 kim_simulator_model_handle_equal = c_associated(lhs%p, rhs%p)
324 end function kim_simulator_model_handle_equal
329 logical recursive function kim_simulator_model_handle_not_equal(lhs, rhs)
334 kim_simulator_model_handle_not_equal = .not. (lhs == rhs)
335 end function kim_simulator_model_handle_not_equal
343 simulator_model_handle, ierr)
346 integer(c_int) recursive function create( &
347 simulator_model_name, simulator_model) &
348 bind(c, name="KIM_SimulatorModel_Create")
349 use,
intrinsic :: iso_c_binding
351 character(c_char),
intent(in) :: simulator_model_name(*)
352 type(c_ptr),
intent(out) :: simulator_model
355 character(len=*, kind=c_char),
intent(in) :: simulator_model_name
357 integer(c_int),
intent(out) :: ierr
359 type(c_ptr) :: psimulator_model
361 ierr = create(trim(simulator_model_name)//c_null_char, psimulator_model)
362 simulator_model_handle%p = psimulator_model
373 recursive subroutine destroy(simulator_model) &
374 bind(c, name="KIM_SimulatorModel_Destroy")
375 use,
intrinsic :: iso_c_binding
377 type(c_ptr),
intent(inout) :: simulator_model
378 end subroutine destroy
381 simulator_model_handle
383 type(c_ptr) :: psimulator_model
384 psimulator_model = simulator_model_handle%p
385 call destroy(psimulator_model)
386 simulator_model_handle%p = c_null_ptr
395 recursive subroutine kim_simulator_model_get_simulator_name_and_version( &
396 simulator_model_handle, simulator_name, simulator_version)
397 use kim_interoperable_types_module,
only: kim_simulator_model_type
398 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
401 recursive subroutine get_simulator_name_and_version( &
402 simulator_model, simulator_name, simulator_version) &
403 bind(c, name="KIM_SimulatorModel_GetSimulatorNameAndVersion")
404 use,
intrinsic :: iso_c_binding
405 use kim_interoperable_types_module,
only: kim_simulator_model_type
407 type(kim_simulator_model_type),
intent(in) :: simulator_model
408 type(c_ptr),
intent(out) :: simulator_name
409 type(c_ptr),
intent(out) :: simulator_version
410 end subroutine get_simulator_name_and_version
413 character(len=*, kind=c_char),
intent(out) :: simulator_name
414 character(len=*, kind=c_char),
intent(out) :: simulator_version
415 type(kim_simulator_model_type),
pointer :: simulator_model
417 type(c_ptr) psimulator_name, psimulator_version
419 call c_f_pointer(simulator_model_handle%p, simulator_model)
420 call get_simulator_name_and_version(simulator_model, psimulator_name, &
422 call kim_convert_c_char_ptr_to_string(psimulator_name, simulator_name)
423 call kim_convert_c_char_ptr_to_string(psimulator_version, simulator_version)
424 end subroutine kim_simulator_model_get_simulator_name_and_version
432 recursive subroutine kim_simulator_model_get_number_of_supported_species( &
433 simulator_model_handle, number_of_supported_species)
434 use kim_interoperable_types_module,
only: kim_simulator_model_type
437 recursive subroutine get_number_of_supported_species( &
438 simulator_model, number_of_supported_species) &
439 bind(c, name="KIM_SimulatorModel_GetNumberOfSupportedSpecies")
440 use,
intrinsic :: iso_c_binding
441 use kim_interoperable_types_module,
only: kim_simulator_model_type
443 type(kim_simulator_model_type),
intent(in) :: simulator_model
444 integer(c_int),
intent(out) :: number_of_supported_species
445 end subroutine get_number_of_supported_species
448 integer(c_int),
intent(out) :: number_of_supported_species
449 type(kim_simulator_model_type),
pointer :: simulator_model
451 call c_f_pointer(simulator_model_handle%p, simulator_model)
452 call get_number_of_supported_species(simulator_model, &
453 number_of_supported_species)
454 end subroutine kim_simulator_model_get_number_of_supported_species
462 recursive subroutine kim_simulator_model_get_supported_species( &
463 simulator_model_handle, index, species_name, ierr)
464 use kim_interoperable_types_module,
only: kim_simulator_model_type
465 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
468 integer(c_int) recursive function get_supported_species( &
469 simulator_model, index, species_name) &
470 bind(c, name="KIM_SimulatorModel_GetSupportedSpecies")
471 use,
intrinsic :: iso_c_binding
472 use kim_interoperable_types_module,
only: kim_simulator_model_type
474 type(kim_simulator_model_type),
intent(in) :: simulator_model
475 integer(c_int),
intent(in),
value :: index
476 type(c_ptr),
intent(out) :: species_name
477 end function get_supported_species
480 integer(c_int),
intent(in) :: index
481 character(len=*, kind=c_char),
intent(out) :: species_name
482 integer(c_int),
intent(out) :: ierr
483 type(kim_simulator_model_type),
pointer :: simulator_model
485 type(c_ptr) pspecies_name
487 call c_f_pointer(simulator_model_handle%p, simulator_model)
488 ierr = get_supported_species(simulator_model, index - 1, pspecies_name)
489 call kim_convert_c_char_ptr_to_string(pspecies_name, species_name)
490 end subroutine kim_simulator_model_get_supported_species
498 recursive subroutine kim_simulator_model_open_and_initialize_template_map( &
499 simulator_model_handle)
500 use kim_interoperable_types_module,
only: kim_simulator_model_type
503 recursive subroutine open_and_initialize_template_map(simulator_model) &
504 bind(c, name="KIM_SimulatorModel_OpenAndInitializeTemplateMap")
505 use,
intrinsic :: iso_c_binding
506 use kim_interoperable_types_module,
only: kim_simulator_model_type
508 type(kim_simulator_model_type),
intent(in) :: simulator_model
509 end subroutine open_and_initialize_template_map
512 type(kim_simulator_model_type),
pointer :: simulator_model
514 call c_f_pointer(simulator_model_handle%p, simulator_model)
515 call open_and_initialize_template_map(simulator_model)
516 end subroutine kim_simulator_model_open_and_initialize_template_map
524 integer(c_int) recursive function kim_simulator_model_template_map_is_open( &
525 simulator_model_handle)
526 use kim_interoperable_types_module,
only: kim_simulator_model_type
529 integer(c_int) recursive function template_map_is_open(simulator_model) &
530 bind(c, name="KIM_SimulatorModel_TemplateMapIsOpen")
531 use,
intrinsic :: iso_c_binding
532 use kim_interoperable_types_module,
only: kim_simulator_model_type
534 type(kim_simulator_model_type),
intent(in) :: simulator_model
535 end function template_map_is_open
538 type(kim_simulator_model_type),
pointer :: simulator_model
540 call c_f_pointer(simulator_model_handle%p, simulator_model)
541 kim_simulator_model_template_map_is_open = template_map_is_open( &
543 end function kim_simulator_model_template_map_is_open
550 recursive subroutine kim_simulator_model_add_template_map( &
551 simulator_model_handle, key, value, ierr)
552 use kim_interoperable_types_module,
only: kim_simulator_model_type
553 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
556 integer(c_int) recursive function add_template_map( &
557 simulator_model, key, value) &
558 bind(c, name="KIM_SimulatorModel_AddTemplateMap")
559 use,
intrinsic :: iso_c_binding
560 use kim_interoperable_types_module,
only: kim_simulator_model_type
562 type(kim_simulator_model_type),
intent(in) :: simulator_model
563 character(c_char),
intent(in) :: key(*)
564 character(c_char),
intent(in) ::
value(*)
565 end function add_template_map
568 character(len=*, kind=c_char),
intent(in) :: key
569 character(len=*, kind=c_char),
intent(in) :: value
570 integer(c_int),
intent(out) :: ierr
571 type(kim_simulator_model_type),
pointer :: simulator_model
573 call c_f_pointer(simulator_model_handle%p, simulator_model)
574 ierr = add_template_map(simulator_model, trim(key)//c_null_char, &
575 trim(
value)//c_null_char)
576 end subroutine kim_simulator_model_add_template_map
584 recursive subroutine kim_simulator_model_close_template_map( &
585 simulator_model_handle)
586 use kim_interoperable_types_module,
only: kim_simulator_model_type
589 recursive subroutine close_template_map(simulator_model) &
590 bind(c, name="KIM_SimulatorModel_CloseTemplateMap")
591 use,
intrinsic :: iso_c_binding
592 use kim_interoperable_types_module,
only: kim_simulator_model_type
594 type(kim_simulator_model_type),
intent(in) :: simulator_model
595 end subroutine close_template_map
598 type(kim_simulator_model_type),
pointer :: simulator_model
600 call c_f_pointer(simulator_model_handle%p, simulator_model)
601 call close_template_map(simulator_model)
602 end subroutine kim_simulator_model_close_template_map
610 recursive subroutine kim_simulator_model_get_number_of_simulator_fields( &
611 simulator_model_handle, number_of_simulator_fields)
612 use kim_interoperable_types_module,
only: kim_simulator_model_type
615 recursive subroutine get_number_of_simulator_fields( &
616 simulator_model, number_of_simulator_fields) &
617 bind(c, name="KIM_SimulatorModel_GetNumberOfSimulatorFields")
618 use,
intrinsic :: iso_c_binding
619 use kim_interoperable_types_module,
only: kim_simulator_model_type
621 type(kim_simulator_model_type),
intent(in) :: simulator_model
622 integer(c_int),
intent(out) :: number_of_simulator_fields
623 end subroutine get_number_of_simulator_fields
626 integer(c_int),
intent(out) :: number_of_simulator_fields
627 type(kim_simulator_model_type),
pointer :: simulator_model
629 call c_f_pointer(simulator_model_handle%p, simulator_model)
630 call get_number_of_simulator_fields(simulator_model, &
631 number_of_simulator_fields)
632 end subroutine kim_simulator_model_get_number_of_simulator_fields
640 recursive subroutine kim_simulator_model_get_simulator_field_metadata( &
641 simulator_model_handle, field_index, extent, field_name, ierr)
642 use kim_interoperable_types_module,
only: kim_simulator_model_type
643 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
646 integer(c_int) recursive function get_simulator_field_metadata( &
647 simulator_model, field_index, extent, field_name) &
648 bind(c, name="KIM_SimulatorModel_GetSimulatorFieldMetadata")
649 use,
intrinsic :: iso_c_binding
650 use kim_interoperable_types_module,
only: kim_simulator_model_type
652 type(kim_simulator_model_type),
intent(in) :: simulator_model
653 integer(c_int),
intent(in),
value :: field_index
654 integer(c_int),
intent(out) :: extent
655 type(c_ptr),
intent(out) :: field_name
656 end function get_simulator_field_metadata
659 integer(c_int),
intent(in) :: field_index
660 integer(c_int),
intent(out) :: extent
661 character(len=*, kind=c_char),
intent(out) :: field_name
662 integer(c_int),
intent(out) :: ierr
663 type(kim_simulator_model_type),
pointer :: simulator_model
665 type(c_ptr) pfield_name
667 call c_f_pointer(simulator_model_handle%p, simulator_model)
668 ierr = get_simulator_field_metadata(simulator_model, field_index - 1, &
670 call kim_convert_c_char_ptr_to_string(pfield_name, field_name)
671 end subroutine kim_simulator_model_get_simulator_field_metadata
679 recursive subroutine kim_simulator_model_get_simulator_field_line( &
680 simulator_model_handle, field_index, line_index, line_value, ierr)
681 use kim_interoperable_types_module,
only: kim_simulator_model_type
682 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
685 integer(c_int) recursive function get_simulator_field_line( &
686 simulator_model, field_index, line_index, line_value) &
687 bind(c, name="KIM_SimulatorModel_GetSimulatorFieldLine")
688 use,
intrinsic :: iso_c_binding
689 use kim_interoperable_types_module,
only: kim_simulator_model_type
691 type(kim_simulator_model_type),
intent(in) :: simulator_model
692 integer(c_int),
intent(in),
value :: field_index
693 integer(c_int),
intent(in),
value :: line_index
694 type(c_ptr),
intent(out) :: line_value
695 end function get_simulator_field_line
698 integer(c_int),
intent(in),
value :: field_index
699 integer(c_int),
intent(in),
value :: line_index
700 character(len=*, kind=c_char),
intent(out) :: line_value
701 integer(c_int),
intent(out) :: ierr
702 type(kim_simulator_model_type),
pointer :: simulator_model
704 type(c_ptr) pline_value
706 call c_f_pointer(simulator_model_handle%p, simulator_model)
707 ierr = get_simulator_field_line(simulator_model, field_index - 1, &
708 line_index - 1, pline_value)
709 call kim_convert_c_char_ptr_to_string(pline_value, line_value)
710 end subroutine kim_simulator_model_get_simulator_field_line
718 recursive subroutine kim_simulator_model_get_parameter_file_directory_name( &
719 simulator_model_handle, directory_name)
720 use kim_interoperable_types_module,
only: kim_simulator_model_type
721 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
724 recursive subroutine get_parameter_file_directory_name(simulator_model, &
726 bind(c, name="KIM_SimulatorModel_GetParameterFileDirectoryName")
727 use,
intrinsic :: iso_c_binding
728 use kim_interoperable_types_module,
only: kim_simulator_model_type
730 type(kim_simulator_model_type),
intent(in) :: simulator_model
731 type(c_ptr),
intent(out) :: directory_name
732 end subroutine get_parameter_file_directory_name
735 character(len=*, kind=c_char),
intent(out) :: directory_name
736 type(kim_simulator_model_type),
pointer :: simulator_model
738 type(c_ptr) pdirectory_name
740 call c_f_pointer(simulator_model_handle%p, simulator_model)
741 call get_parameter_file_directory_name(simulator_model, pdirectory_name)
742 call kim_convert_c_char_ptr_to_string(pdirectory_name, directory_name)
743 end subroutine kim_simulator_model_get_parameter_file_directory_name
751 recursive subroutine kim_simulator_model_get_specification_file_name( &
752 simulator_model_handle, specification_file_name)
753 use kim_interoperable_types_module,
only: kim_simulator_model_type
754 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
757 recursive subroutine get_specification_file_name( &
758 simulator_model, specification_file_name) &
759 bind(c, name="KIM_SimulatorModel_GetSpecificationFileName")
760 use,
intrinsic :: iso_c_binding
761 use kim_interoperable_types_module,
only: kim_simulator_model_type
763 type(kim_simulator_model_type),
intent(in) :: simulator_model
764 type(c_ptr),
intent(out) :: specification_file_name
765 end subroutine get_specification_file_name
768 character(len=*, kind=c_char),
intent(out) :: specification_file_name
769 type(kim_simulator_model_type),
pointer :: simulator_model
771 type(c_ptr) pspecification_file_name
773 call c_f_pointer(simulator_model_handle%p, simulator_model)
774 call get_specification_file_name(simulator_model, pspecification_file_name)
775 call kim_convert_c_char_ptr_to_string(pspecification_file_name, &
776 specification_file_name)
777 end subroutine kim_simulator_model_get_specification_file_name
785 recursive subroutine kim_simulator_model_get_number_of_parameter_files( &
786 simulator_model_handle, number_of_parameter_files)
787 use kim_interoperable_types_module,
only: kim_simulator_model_type
790 recursive subroutine get_number_of_parameter_files( &
791 simulator_model, number_of_parameter_files) &
792 bind(c, name="KIM_SimulatorModel_GetNumberOfParameterFiles")
793 use,
intrinsic :: iso_c_binding
794 use kim_interoperable_types_module,
only: kim_simulator_model_type
796 type(kim_simulator_model_type),
intent(in) :: simulator_model
797 integer(c_int),
intent(out) :: number_of_parameter_files
798 end subroutine get_number_of_parameter_files
801 integer(c_int),
intent(out) :: number_of_parameter_files
802 type(kim_simulator_model_type),
pointer :: simulator_model
804 call c_f_pointer(simulator_model_handle%p, simulator_model)
805 call get_number_of_parameter_files(simulator_model, &
806 number_of_parameter_files)
807 end subroutine kim_simulator_model_get_number_of_parameter_files
818 recursive subroutine kim_simulator_model_get_parameter_file_name( &
819 simulator_model_handle, index, parameter_file_name, ierr)
820 use kim_interoperable_types_module,
only: kim_simulator_model_type
821 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
824 integer(c_int) recursive function get_parameter_file_name( &
825 simulator_model, index, parameter_file_name) &
826 bind(c, name="KIM_SimulatorModel_GetParameterFileName")
827 use,
intrinsic :: iso_c_binding
828 use kim_interoperable_types_module,
only: kim_simulator_model_type
830 type(kim_simulator_model_type),
intent(in) :: simulator_model
831 integer(c_int),
intent(in),
value :: index
832 type(c_ptr),
intent(out) :: parameter_file_name
833 end function get_parameter_file_name
836 integer(c_int),
intent(in) :: index
837 character(len=*, kind=c_char),
intent(out) :: parameter_file_name
838 integer(c_int),
intent(out) :: ierr
839 type(kim_simulator_model_type),
pointer :: simulator_model
841 type(c_ptr) pparameter_file_name
843 call c_f_pointer(simulator_model_handle%p, simulator_model)
844 ierr = get_parameter_file_name(simulator_model, index - 1, &
845 pparameter_file_name)
846 call kim_convert_c_char_ptr_to_string(pparameter_file_name, &
848 end subroutine kim_simulator_model_get_parameter_file_name
856 recursive subroutine kim_simulator_model_get_parameter_file_basename( &
857 simulator_model_handle, index, parameter_file_basename, ierr)
858 use kim_interoperable_types_module,
only: kim_simulator_model_type
859 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
862 integer(c_int) recursive function get_parameter_file_basename( &
863 simulator_model, index, parameter_file_basename) &
864 bind(c, name="KIM_SimulatorModel_GetParameterFileBasename")
865 use,
intrinsic :: iso_c_binding
866 use kim_interoperable_types_module,
only: kim_simulator_model_type
868 type(kim_simulator_model_type),
intent(in) :: simulator_model
869 integer(c_int),
intent(in),
value :: index
870 type(c_ptr),
intent(out) :: parameter_file_basename
871 end function get_parameter_file_basename
874 integer(c_int),
intent(in) :: index
875 character(len=*, kind=c_char),
intent(out) :: parameter_file_basename
876 integer(c_int),
intent(out) :: ierr
877 type(kim_simulator_model_type),
pointer :: simulator_model
879 type(c_ptr) pparameter_file_basename
881 call c_f_pointer(simulator_model_handle%p, simulator_model)
882 ierr = get_parameter_file_basename(simulator_model, index - 1, &
883 pparameter_file_basename)
884 call kim_convert_c_char_ptr_to_string(pparameter_file_basename, &
885 parameter_file_basename)
886 end subroutine kim_simulator_model_get_parameter_file_basename
894 recursive subroutine kim_simulator_model_set_simulator_buffer_pointer( &
895 simulator_model_handle, ptr)
896 use kim_interoperable_types_module,
only: kim_simulator_model_type
899 recursive subroutine set_simulator_buffer_pointer(simulator_model, ptr) &
900 bind(c, name="KIM_SimulatorModel_SetSimulatorBufferPointer")
901 use,
intrinsic :: iso_c_binding
902 use kim_interoperable_types_module,
only: kim_simulator_model_type
904 type(kim_simulator_model_type),
intent(in) :: simulator_model
905 type(c_ptr),
intent(in),
value :: ptr
906 end subroutine set_simulator_buffer_pointer
909 type(c_ptr),
intent(in) :: ptr
910 type(kim_simulator_model_type),
pointer :: simulator_model
912 call c_f_pointer(simulator_model_handle%p, simulator_model)
913 call set_simulator_buffer_pointer(simulator_model, ptr)
914 end subroutine kim_simulator_model_set_simulator_buffer_pointer
922 recursive subroutine kim_simulator_model_get_simulator_buffer_pointer( &
923 simulator_model_handle, ptr)
924 use kim_interoperable_types_module,
only: kim_simulator_model_type
927 recursive subroutine get_simulator_buffer_pointer(simulator_model, ptr) &
928 bind(c, name="KIM_SimulatorModel_GetSimulatorBufferPointer")
929 use,
intrinsic :: iso_c_binding
930 use kim_interoperable_types_module,
only: kim_simulator_model_type
932 type(kim_simulator_model_type),
intent(in) :: simulator_model
933 type(c_ptr),
intent(out) :: ptr
934 end subroutine get_simulator_buffer_pointer
937 type(c_ptr),
intent(out) :: ptr
938 type(kim_simulator_model_type),
pointer :: simulator_model
940 call c_f_pointer(simulator_model_handle%p, simulator_model)
941 call get_simulator_buffer_pointer(simulator_model, ptr)
942 end subroutine kim_simulator_model_get_simulator_buffer_pointer
949 recursive subroutine kim_simulator_model_to_string(simulator_model_handle, &
951 use kim_convert_string_module,
only: kim_convert_c_char_ptr_to_string
952 use kim_interoperable_types_module,
only: kim_simulator_model_type
955 type(c_ptr)
recursive function model_string(simulator_model) &
956 bind(c, name="KIM_SimulatorModel_ToString")
957 use,
intrinsic :: iso_c_binding
958 use kim_interoperable_types_module,
only: kim_simulator_model_type
960 type(kim_simulator_model_type),
intent(in) :: simulator_model
961 end function model_string
964 character(len=*, kind=c_char),
intent(out) :: string
965 type(kim_simulator_model_type),
pointer :: simulator_model
969 call c_f_pointer(simulator_model_handle%p, simulator_model)
970 p = model_string(simulator_model)
971 call kim_convert_c_char_ptr_to_string(p, string)
972 end subroutine kim_simulator_model_to_string
979 recursive subroutine kim_simulator_model_set_log_id(simulator_model_handle, &
981 use kim_interoperable_types_module,
only: kim_simulator_model_type
984 recursive subroutine set_log_id(simulator_model, log_id) &
985 bind(c, name="KIM_SimulatorModel_SetLogID")
986 use,
intrinsic :: iso_c_binding
987 use kim_interoperable_types_module,
only: kim_simulator_model_type
989 type(kim_simulator_model_type),
intent(in) :: simulator_model
990 character(c_char),
intent(in) :: log_id(*)
991 end subroutine set_log_id
994 character(len=*, kind=c_char),
intent(in) :: log_id
995 type(kim_simulator_model_type),
pointer :: simulator_model
997 call c_f_pointer(simulator_model_handle%p, simulator_model)
998 call set_log_id(simulator_model, trim(log_id)//c_null_char)
999 end subroutine kim_simulator_model_set_log_id
1007 recursive subroutine kim_simulator_model_push_log_verbosity( &
1008 simulator_model_handle, log_verbosity)
1010 use kim_interoperable_types_module,
only: kim_simulator_model_type
1013 recursive subroutine push_log_verbosity(simulator_model, log_verbosity) &
1014 bind(c, name="KIM_SimulatorModel_PushLogVerbosity")
1015 use,
intrinsic :: iso_c_binding
1017 use kim_interoperable_types_module,
only: kim_simulator_model_type
1019 type(kim_simulator_model_type),
intent(in) :: simulator_model
1021 end subroutine push_log_verbosity
1024 type(kim_log_verbosity_type),
intent(in) :: log_verbosity
1025 type(kim_simulator_model_type),
pointer :: simulator_model
1027 call c_f_pointer(simulator_model_handle%p, simulator_model)
1028 call push_log_verbosity(simulator_model, log_verbosity)
1029 end subroutine kim_simulator_model_push_log_verbosity
1036 recursive subroutine kim_simulator_model_pop_log_verbosity( &
1037 simulator_model_handle)
1039 use kim_interoperable_types_module,
only: kim_simulator_model_type
1042 recursive subroutine pop_log_verbosity(simulator_model) &
1043 bind(c, name="KIM_SimulatorModel_PopLogVerbosity")
1044 use,
intrinsic :: iso_c_binding
1046 use kim_interoperable_types_module,
only: kim_simulator_model_type
1048 type(kim_simulator_model_type),
intent(in) :: simulator_model
1049 end subroutine pop_log_verbosity
1052 type(kim_simulator_model_type),
pointer :: simulator_model
1054 call c_f_pointer(simulator_model_handle%p, simulator_model)
1055 call pop_log_verbosity(simulator_model)
1056 end subroutine kim_simulator_model_pop_log_verbosity
Add a new key-value entry to the template map.
Close the template map and perform template substitutions.
Get the number of parameter files provided by the SimulatorModel.
Get the number of simulator fields provided by the SimulatorModel.
Get the number of species supported by the SimulatorModel.
Get the basename (file name without path) of a particular parameter file. The file is located in the ...
Get absolute path name of the temporary directory where parameter files provided by the simulator mod...
Get the basename (file name without path) of a particular parameter file. The file is located in the ...
Get the Simulator's buffer pointer from the SimulatorModel object.
Get a line for the simulator field of interest with all template substitutions performed (Requires th...
Get the SimulatorModel's simulator name and version.
Get the SimulatorModel's specification file basename (file name without path). The file is located in...
Get a species name supported by the SimulatorModel.
Open and initialize the template map for simulator field line substitutions.
Pop a LogVerbosity from the SimulatorModel object's Log object verbosity stack.
Push a new LogVerbosity onto the SimulatorModel object's Log object verbosity stack.
Set the identity of the Log object associated with the SimulatorModel object.
Set the Simulator's buffer pointer within the SimulatorModel object.
Determine if the template map is open.
Get a string representing the internal state of the SimulatorModel object.
An Extensible Enumeration for the LogVerbosity's supported by the KIM API.
Provides the primary interface to a KIM API SimulatorModel object and is meant to be used by simulato...
recursive subroutine, public kim_simulator_model_create(simulator_model_name, simulator_model_handle, ierr)
Create a new KIM API SimulatorModel object.
type(kim_simulator_model_handle_type), save, public, protected kim_simulator_model_null_handle
NULL handle for use in comparisons.
recursive subroutine, public kim_simulator_model_destroy(simulator_model_handle)
Destroy a previously SimulatorModel::Create'd object.
An Extensible Enumeration for the LogVerbosity's supported by the KIM API.
Provides the primary interface to a KIM API SimulatorModel object and is meant to be used by simulato...