assign_string_to_json_file Subroutine

private subroutine assign_string_to_json_file(me, str)

Assignment operator for json_core = character. This is just a wrapper for the json_file_load_from_string routine.

Arguments

TypeIntentOptionalAttributesName
class(json_file), intent(inout) :: me
character(kind=CK,len=*), intent(in) :: str

Contents


Source Code

    subroutine assign_string_to_json_file(me,str)

    implicit none

    class(json_file),intent(inout) :: me
    character(kind=CK,len=*),intent(in) :: str

    if (associated(me%p)) call me%destroy()
    if (me%core%failed()) call me%core%clear_exceptions()
    call me%deserialize(str)

    end subroutine assign_string_to_json_file