load_url Subroutine

private impure elemental subroutine load_url(this)

Uses

    • json_module
  • proc~~load_url~3~~UsesGraph proc~load_url~3 foropenai_ImageGeneration::ImageGeneration%load_url json_module json_module proc~load_url~3->json_module

Type Bound

ImageGeneration

Arguments

Type IntentOptional Attributes Name
class(ImageGeneration), intent(inout) :: this

Calls

proc~~load_url~3~~CallsGraph proc~load_url~3 foropenai_ImageGeneration::ImageGeneration%load_url destroy destroy proc~load_url~3->destroy get get proc~load_url~3->get initialize initialize proc~load_url~3->initialize load_file load_file proc~load_url~3->load_file

Called by

proc~~load_url~3~~CalledByGraph proc~load_url~3 foropenai_ImageGeneration::ImageGeneration%load_url proc~load_imagegeneration_data foropenai_ImageGeneration::ImageGeneration%load_ImageGeneration_data proc~load_imagegeneration_data->proc~load_url~3 proc~set_imagegeneration_data foropenai_ImageGeneration::ImageGeneration%set_ImageGeneration_data proc~set_imagegeneration_data->proc~load_imagegeneration_data program~test_imagegeneration test_ImageGeneration program~test_imagegeneration->proc~set_imagegeneration_data

Source Code

   elemental impure subroutine load_url(this)
      use json_module, only: json_file
      class(ImageGeneration), intent(inout) :: this
      type(json_file)                      :: json
      character(len=:), allocatable        :: tmp
      logical                              :: found
      call json%initialize()
      call json%load_file(trim(this%file_name))
      call json%get("ImageGeneration.url", tmp, found=found)
      if (found) this%url = trim(tmp)
      call json%destroy()
   end subroutine load_url