! -*- coding: utf-8; mode: f90 -*-
!-------------------------------------------------------------------------------------
! Copyright (c) 2000-2016 Gtool Development Group. All rights reserved.
!-------------------------------------------------------------------------------------
! ** Important**
!
! This file is generated from gtdata_generic.erb by ERB included Ruby 2.3.3.
! Please do not edit this file directly. @see "gtdata_generic.erb"
!-------------------------------------------------------------------------------------

!--
! *** Caution!! ***
!
! This file is generated from "gtdata_generic.rb2f90" by Ruby 2.3.1.
! Please do not edit this file directly.
!
! [JAPANESE]
!
! â€»â€»â€» æ³¨æ„!!! â€»â€»â€»
!
! ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã¯ "gtdata_generic.rb2f90" ã‹ã‚‰ Ruby 2.3.1
! ã«ã‚ˆã£ã¦è‡ªå‹•ç”Ÿæˆã•ã‚ŒãŸãƒ•ã‚¡ã‚¤ãƒ«ã§ã™.
! ã“ã®ãƒ•ã‚¡ã‚¤ãƒ«ã‚’ç›´æŽ¥ç·¨é›†ã—ã¾ã›ã‚“ã‚ˆã†ãŠé¡˜ã„è‡´ã—ã¾ã™.
!
!
!++
!
!= gtdata_variable.f90 - gtool å¤‰æ•°ã®æ‰‹ç¶šç·ç§°å®£è¨€
!
! Authors::   Yasuhiro MORIKAWA, Eizi TOYODA
! Version::   $Id: gtdata_generic.rb2f90,v 1.5 2009-10-11 07:36:37 morikawa Exp $
! Tag Name::  $Name:  $
! Copyright:: Copyright (C) GFD Dennou Club, 2000-2005. All rights reserved.
! License::   See COPYRIGHT[link:../../COPYRIGHT]
!

module gtdata_generic
  !
  !== GT_VARIABLE åž‹å¤‰æ•°ã®æ‰‹ç¶šç·ç§°å®£è¨€
  !
  ! ãƒ•ã‚¡ã‚¤ãƒ«ã®å½¢å¼ã«ä¾å˜ã—ãªã„å¤šæ¬¡å…ƒãƒ‡ãƒ¼ã‚¿ã§ã‚ã‚‹ GT_VARIABLE åž‹å¤‰æ•°
  ! ã®æ“ä½œã«é–¢ã™ã‚‹æ‰‹ç¶šãã®å…¨ã¦ã¯ã“ã“ã§ç·ç§°å®£è¨€ã•ã‚Œã¦å…¬é–‹ã•ã‚Œã¾ã™ã€‚
  !
  ! ä»¥é™ã«ä¸€è¦§ã•ã‚Œã‚‹æ‰‹ç¶šã¯ã€ç¬¬ 1 å¼•æ•°ãŒä¸»ãªæ“ä½œå¯¾è±¡ã«ãªã‚‹ã‚ˆã†ãªã‚¹ã‚¿ã‚¤ãƒ«ã§
  ! è¨è¨ˆã•ã‚Œã¦ã„ã¾ã™ã€‚ ç¬¬ 1 å¼•æ•°ã‹ã‚‰ gtool4 ã®æ‰‹ç¶šã§ã‚ã‚‹ã“ã¨ãŒã‚ã‹ã‚‹ã®ã§ã€
  ! åå‰ã«ã‚ã–ã‚ã– GT ã¨ã¯ã¤ã‘ã¦ã„ã¾ã›ã‚“ã€‚
  !
  !== ç¨®é¡žåˆ¥æ‰‹ç¶šãä¸€è¦§
  !
  ! ASCII é †ã®æ‰‹ç¶šãä¸€è¦§ã¯ä¸‹è¨˜ã® "Methods" ã‚’å‚ç…§ã—ã¦ãã ã•ã„ã€‚
  !
  !=== å¤‰æ•°ã®ä½œæˆãƒ»åˆæœŸåŒ–ãƒ»çµ‚äº†
  !
  ! Create            ::    å¤‰æ•°ã®ä½œæˆ
  ! Open              ::    å¤‰æ•°ã®åˆæœŸåŒ–
  ! Close             ::    å¤‰æ•°ã®çµ‚äº†å‡¦ç†
  !
  !=== å•ã„åˆã‚ã›
  !
  ! Inquire           ::    å¤‰æ•°ã¾ãŸã¯å±žæ€§ã«é–¢ã™ã‚‹å•ã„åˆã‚ã›
  !
  !=== ãƒ‡ãƒ¼ã‚¿ã®å…¥å‡ºåŠ›
  !
  ! Get               ::    ãƒ•ã‚¡ã‚¤ãƒ«å…¥åŠ›
  ! Put, PutLine     ::    ãƒ•ã‚¡ã‚¤ãƒ«å‡ºåŠ›
  !
  !=== æ¬¡å…ƒé †åºç•ªå·ã®å•ã„åˆã‚ã›ãƒ»å¤‰æ›´
  !
  ! Dimname_To_Dimord ::    æ¬¡å…ƒç›¸å¯¾åã‹ã‚‰æ¬¡å…ƒé †åºç•ªå·ã®å•ã„åˆã‚ã›
  ! Exch_dim          ::    æ¬¡å…ƒé †åºç•ªå·ã®äº¤æ›
  !
  !=== å¤‰æ•°æ§‹æˆå†™åƒæ©Ÿèƒ½ï¼ˆãƒªãƒŸãƒƒãƒˆã€æ¬¡å…ƒã®åŠ é™¤ï¼‰
  !
  ! å¤‰æ•° (GT_VARIABLE åž‹) ã¯é †åºã®æ±ºã¾ã£ãŸæ¬¡å…ƒé›†åˆã‚’ã‚‚ã¡ã¾ã™ã€‚ãã‚Œãžã‚Œ
  ! ã®æ¬¡å…ƒã«ã¯æ±ºã¾ã£ãŸé•·ã•ãŒã‚ã‚Šã€1ã‹ã‚‰é•·ã•ã¾ã§ã®ç•ªå·ã§è˜åˆ¥ã•ã‚Œã‚‹æ ¼åã‹ã‚‰
  ! ãªã£ã¦ã„ã¾ã™ã€‚ã—ã‹ã—ãªãŒã‚‰ã€å¿…è¦ã«å¿œã˜ã¦å¤‰æ•°ãŒã‚‚ã¤æ¬¡å…ƒã®é †åºã‚’å…¥ã‚Œæ›¿ãˆ
  ! ãŸã‚Šã€æ¬¡å…ƒãŒå˜åœ¨ã—ãªã„ã‚ˆã†ã«ã¿ã›ã‹ã‘ãŸã‚Šã€å„ã€…ã®æ¬¡å…ƒã®é•·ã•ã‚’å¤‰ãˆãŸã‚Šæ ¼
  ! åç•ªå·ã‚’ä»˜ã‘æ›¿ãˆãŸã‚Šã§ãã¾ã™ã€‚
  !
  ! Limit             ::    å…¥å‡ºåŠ›ç¯„å›²ã‚’æ‹˜æŸ
  ! Add_Dim           ::    å¤‰æ•°ã«æ¬¡å…ƒã‚’è¿½åŠ
  ! Del_Dim           ::    å¤‰æ•°ã‹ã‚‰æ¬¡å…ƒã‚’éš è”½
  ! Transform         ::    2 ã¤ã®å¤‰æ•°ã®æ¬¡å…ƒé…ç½®ã®å…±é€šåŒ–
  !
  !=== å…¥å‡ºåŠ›ç¯„å›²é™å®šæ©Ÿèƒ½ï¼ˆã‚¹ãƒ©ã‚¤ã‚¹ï¼‰
  !
  ! Slice             ::    å…¥å‡ºåŠ›ç¯„å›²ã‚’é™å®š
  ! Slice_Next        ::    å…¥å‡ºåŠ›ç¯„å›²ã‚’ç§»å‹•
  ! Get_Slice         ::    å¤‰æ•°å…¥å‡ºåŠ›ç¯„å›²é™å®šæƒ…å ±ã‚’å•ã„åˆã‚ã›
  !
  !=== å±žæ€§é–¢ä¿‚
  !
  ! å±žæ€§åã¯è‹±å—ã€æ•°å—ã€ä¸‹ç·šã‹ã‚‰æ§‹æˆã•ã‚Œã¾ã™ã€‚å…ˆé ã®æ–‡å—ã¯è‹±å—ã¾ãŸã¯
  ! "<b><tt>+</tt></b>" ã§ãªã‘ã‚Œã°ãªã‚Šã¾ã›ã‚“ã€‚
  ! "<b><tt>+</tt></b>" ã‹ã‚‰å§‹ã¾ã‚‹å±žæ€§åã¯å†…éƒ¨çš„ã«ä½¿ç”¨ã•ã‚Œã‚‹ã‚‚ã®
  ! ã§ã€netCDF å®Ÿè£…ã§ã¯å¤§åŸŸå¤‰æ•°ã«å¯¾å¿œã—ã¾ã™ã€‚
  !
  ! Attr_Rewind       ::    å¤‰æ•°å±žæ€§åˆ—æŒ™ã®åˆæœŸåŒ–
  ! Attr_Next         ::    å¤‰æ•°å±žæ€§ã®åˆ—æŒ™
  ! Attr_True         ::    å¤‰æ•°å±žæ€§ã‚’è«–ç†åž‹ã¨ã—ã¦èªã¿å–ã‚Š
  ! Get_Attr          ::    å¤‰æ•°å±žæ€§ã®èªã¿å–ã‚Š
  ! Put_Attr          ::    å¤‰æ•°å±žæ€§ã®æ›¸ãå‡ºã—
  ! Copy_Attr         ::    å±žæ€§ã®ã‚³ãƒ”ãƒ¼
  ! Del_Attr          ::    å¤‰æ•°å±žæ€§ã®å‰Šé™¤
  !
  !=== ãã®ä»–
  !
  ! GTVarSearch       :: ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¸ã®å¤‰æ•°åã®åˆ—æŒ™
  ! GTVarSync         :: ãƒ•ã‚¡ã‚¤ãƒ«å…¥å‡ºåŠ›ã®åŒæœŸ
  ! GTDataTmpNam      :: å¤‰æ•°åã®è‡ªå‹•ä½œæˆ
  ! GTVarDel          :: ãƒ•ã‚¡ã‚¤ãƒ«ã®ä¸ã®å¤‰æ•°ã®å‰Šé™¤ (ä½œæˆä¸)
  ! operator(.equivalent.) [link:#M000133] :: åŒå€¤åˆ¤å®š

  implicit none
  !
  ! åŸºæœ¬é–‹é–‰å‹•ä½œ
  !

  interface Open
    subroutine GTVarOpenByDimOrd(var, source_var, dimord, &
      count_compact, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(out):: var
      type(GT_VARIABLE), intent(in):: source_var
      integer, intent(in):: dimord
      logical, intent(in), optional:: count_compact
      logical, intent(out), optional:: err
    end subroutine GTVarOpenByDimOrd
    subroutine GTVarOpen(var, url, writable, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(out):: var
      character(*), intent(in):: url
      logical, intent(in), optional:: writable
      logical, intent(out), optional:: err
    end subroutine GTVarOpen
  end interface

  interface Create
    subroutine GTVarCreate(var, url, dims, xtype, long_name, overwrite, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(out):: var
      character(len = *), intent(in):: url
      type(GT_VARIABLE), intent(in), optional:: dims(:)
      character(len = *), intent(in), optional:: xtype
      character(len = *), intent(in), optional:: long_name
      logical, intent(in), optional:: overwrite
      logical, intent(out), optional:: err
    end subroutine GTVarCreate
    subroutine GTVarCreateD(var, url, length, xtype, long_name, overwrite, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(out):: var
      character(len = *), intent(in):: url
      integer, intent(in):: length
      character(len = *), intent(in), optional:: xtype
      character(len = *), intent(in), optional:: long_name
      logical, intent(in), optional:: overwrite
      logical, intent(out), optional:: err
    end subroutine GTVarCreateD
  end interface Create

  interface Close
    subroutine GTVarClose(var, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      logical, intent(out), optional:: err
    end subroutine GTVarClose
  end interface Close

  !
  ! --- å±žæ€§é–¢ä¿‚ ---
  !

  interface Attr_Rewind
    subroutine GTVarAttrRewind(var)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
    end subroutine GTVarAttrRewind
  end interface Attr_Rewind

  interface Attr_Next
    subroutine GTVarAttrNext(var, name, end)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      character(*), intent(out):: name
      logical, intent(out), optional:: end
    end subroutine GTVarAttrNext
  end interface Attr_Next

  ! è«–ç†åž‹èªã¿å–ã‚Šã¯é–¢æ•°ã‚¤ãƒ³ã‚¿ãƒ¼ãƒ•ã‚§ã‚¤ã‚¹ã‚‚æä¾›
  interface Attr_True
    logical function GTVarAttrTrue(var, name, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      logical, intent(in), optional:: default
    end function GTVarAttrTrue
  end interface Attr_True

  interface Get_Attr
    ! ã‚¹ã‚«ãƒ©ã§å—ã‘å–ã‚‹ã®ãŒä¸€ç•ªç°¡å˜ã€‚è§£é‡ˆå¯èƒ½ãªå€¤ãŒã¨ã‚‰ã‚Œã€æ®‹ã‚Šã¯æ¨ã¦ã‚‰ã‚Œã‚‹ã€‚
    subroutine GTVarGetAttrI(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      integer, intent(out):: value
      integer, intent(in), optional:: default
    end subroutine GTVarGetAttrI
    subroutine GTVarGetAttrR(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real, intent(out):: value
      real, intent(in), optional:: default
    end subroutine GTVarGetAttrR

    subroutine GTVarGetAttrD(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real(DP), intent(out):: value
      real(DP), intent(in), optional:: default
    end subroutine GTVarGetAttrD

    ! ãƒã‚¤ãƒ³ã‚¿é…åˆ—ã‚’ä½¿ã£ã¦å—ã‘å–ã‚‹å ´åˆã¯è§£é‡ˆå¯èƒ½ãªæ•°ã ã‘å®Ÿä½“ãŒå‰²ã‚Šä»˜ã‘ã‚‰ã‚Œã‚‹ã€‚
    subroutine GTVarGetAttrIP(var, name, value)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      integer, pointer:: value(:)
    end subroutine GTVarGetAttrIP

    subroutine GTVarGetAttrRP(var, name, value)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real, pointer:: value(:)
    end subroutine GTVarGetAttrRP

    subroutine GTVarGetAttrDP(var, name, value)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real(DP), pointer:: value(:)
    end subroutine GTVarGetAttrDP

    ! integer é…åˆ—, real é…åˆ—ã¨ã—ã¦å—ã‘å–ã‚‹
    ! å ´åˆã¯å±žæ€§é•·ãŒã‚ã¾ã£ã¦ã„ã‚‹å ´åˆã«ã¯åˆ‡ã‚Šæ¨ã¦ã‚‰ã‚Œã€
    ! å±žæ€§é•·ãŒè¶³ã‚Šãªã„å ´åˆã¯ default å€¤ (ãƒã‚¤ãƒ³ã‚¿ã¨é•ã„å¿…é ˆ) ã‚’åŸ‹ã‚ã‚‹ã€‚

    subroutine GTVarGetAttrIA(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      integer, intent(out):: value(:)
      integer, intent(in):: default
    end subroutine GTVarGetAttrIA

    subroutine GTVarGetAttrRA(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real, intent(out):: value(:)
      real, intent(in):: default
    end subroutine GTVarGetAttrRA

    subroutine GTVarGetAttrDA(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      real(DP), intent(out):: value(:)
      real(DP), intent(in):: default
    end subroutine GTVarGetAttrDA

    ! character åž‹ã§å—ã‘å–ã‚‹å ´åˆã¯é€šå¸¸ã®æ–‡å—åž‹ä»£å…¥ã¨åŒæ§˜ã€
    ! å—ã‘å´å¤‰æ•°ã®é•·ã•ã«åˆã‚ã›ã¦åˆ‡ã‚Šæ¨ã¦ãƒ»ç©ºç™½åŸ‹ã‚ã‚’è¡Œã†ã€‚
    ! å±žæ€§ãŒå˜åœ¨ã—ãªã„å ´åˆ default å€¤ã‚’ä½¿ã†ã€‚

    subroutine GTVarGetAttrCC(var, name, value, default)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
      character(len = *), intent(out):: value
      character(len = *), intent(in), optional:: default
    end subroutine GTVarGetAttrCC

    ! æ–‡å—åˆ—ã¨ã—ã¦èªã¿å–ã‚‹å ´åˆã¯å…ƒã®é•·ã•ã¯æ£ç¢ºã«å—ã‘å–ã‚‰ã‚Œã‚‹ã€‚
    ! å±žæ€§ãŒå˜åœ¨ã—ãªã„å ´åˆ default å€¤ã‚’ä½¿ã†ã€‚

!    subroutine GTVarGetAttrSC(var, name, value, default)
!      use dc_string, only: VSTRING
!      use gtdata_types, only: GT_VARIABLE
!      type(GT_VARIABLE), intent(in):: var
!      character(len = *), intent(in):: name
!      type(VSTRING), intent(out):: value
!      character(len = *), intent(in), optional:: default
!    end subroutine GTVarGetAttrSC

  end interface Get_Attr

  interface Put_Attr
    subroutine GTVarPutAttrDouble(var, name, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      real(DP),           intent(in)            :: value(:)
      real,               intent(out), optional :: err
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
    end subroutine GTVarPutAttrDouble
    subroutine GTVarPutAttrReal(var, name, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: SP
      real(SP),           intent(in)            :: value(:)
      real(SP),           intent(out), optional :: err
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
    end subroutine GTVarPutAttrReal
    subroutine GTVarPutAttrInt(var, name, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,            intent(in)            :: value(:)
      real,               intent(out), optional :: err
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
    end subroutine GTVarPutAttrInt
    subroutine GTVarPutAttrChar(var, name, value, xtype, err)
      use gtdata_types, only: GT_VARIABLE
      character(len = *), intent(in)            :: value
      logical,            intent(out), optional :: err
      character(len = *), intent(in),  optional :: xtype
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
    end subroutine GTVarPutAttrChar
    subroutine GTVarPutAttrLogical(var, name, value, err)
      use gtdata_types, only: GT_VARIABLE
      logical,            intent(in)            :: value
      real,               intent(out), optional :: err
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
    end subroutine GTVarPutAttrLogical
  end interface Put_Attr

  interface Del_Attr
    subroutine GTVarDelAttr(var, name, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: name
      logical, intent(out), optional:: err
    end subroutine GTVarDelAttr
  end interface Del_Attr

  interface Copy_Attr
    subroutine GTVarCopyAttr(to, attrname, from, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: to
      character(len = *), intent(in):: attrname
      type(GT_VARIABLE), intent(in):: from
      logical, intent(out), optional:: err
    end subroutine GTVarCopyAttr
    subroutine GTVarCopyAttrAll(to, from, err, global)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: to
      type(GT_VARIABLE), intent(inout):: from
      logical, intent(out), optional:: err
      logical, intent(in), optional:: global
    end subroutine GTVarCopyAttrAll
  end interface Copy_Attr

  !
  ! --- æ¬¡å…ƒé–¢ä¿‚ ---
  !

  ! ç¾åœ¨ã®å…¥å‡ºåŠ›ç¯„å›²ã®å¤§ãã•ã¯ inquire(var, size=) ã§å–å¾—ã§ãã‚‹

  interface Slice
    ! ãŠã¾ã‹ã›æŒ‡ç¤º
    ! compatible ã‚’æŒ‡å®šã™ã‚‹ã¨ã¾ã£ãŸãåŒã˜ã«æŒ‡å®š
    subroutine GTVarSliceAuto(var, compatible)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      type(GT_VARIABLE), intent(in), optional:: compatible
    end subroutine GTVarSliceAuto
    ! æ¬¡å…ƒã‚’æŒ‡å®šã—ãŸæŒ‡ç¤º
    subroutine GTVarSlice(var, dimord, start, count, stride)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: dimord
      integer, intent(in), optional:: start
      integer, intent(in), optional:: count
      integer, intent(in), optional:: stride
    end subroutine GTVarSlice
    ! æ–‡å—åˆ—ã«ã‚ˆã‚‹æŒ‡ç¤º
    subroutine GTVarSliceC(var, string, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: string
      logical, intent(out):: err
    end subroutine GTVarSliceC
  end interface Slice

  interface Get_Slice
    ! æ¬¡å…ƒé †ç•ªã‚’æŒ‡å®šã—ã¦å–å¾—
    subroutine GTVarGetSlice(var, dimord, start, count, stride, count_compact)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: dimord
      integer, intent(out), optional:: start
      integer, intent(out), optional:: count
      integer, intent(out), optional:: stride
      logical, intent(in), optional:: count_compact
    end subroutine GTVarGetSlice
    ! å…¨æ¬¡å…ƒã«ã¤ã„ã¦ä¸€æ‹¬å–å¾—
    ! ã‚ã‚‰ã‹ã˜ã‚ inquire(var, alldims) ã—ã¦é…åˆ—ã‚’ç¢ºä¿ã™ã‚‹ã€‚
    subroutine GTVarGetSliceAll(var, start, count, stride)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(out), optional:: start(:), count(:), stride(:)
    end subroutine GTVarGetSliceAll
  end interface Get_Slice

  interface Dimname_to_Dimord
    integer function GTVarDimName2Ord(var, name)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len = *), intent(in):: name
    end function GTVarDimName2Ord
  end interface Dimname_to_Dimord

  ! limit: ç©ºé–“å¤‰æ›å™¨æ©Ÿèƒ½ã®ã‚»ãƒƒãƒˆã‚¢ãƒƒãƒ—
  !
  interface Limit
    subroutine GTVarLimit(var, string, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout) :: var
      character(len = *), intent(in)   :: string
      logical, intent(out), optional   :: err
    end subroutine GTVarLimit
    subroutine GTVarLimit_iiii(var, dimord, start, count, stride, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      integer, intent(in)             :: dimord
      integer, intent(in) , optional  :: start, count, stride
      logical, intent(out), optional  :: err
    end subroutine GTVarLimit_iiii
  end interface Limit

  interface Transform
    subroutine GTVarXformBinary(var1, var2, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var1, var2
      logical, intent(out), optional:: err
    end subroutine GTVarXformBinary
  end interface Transform

  ! æ˜Žç¤ºçš„ç©ºé–“å¤‰æ›æ©Ÿèƒ½

  ! å¤‰æ•°ãƒãƒ³ãƒ‰ãƒ« var ã® dimord ç•ªç›®ã®ä½ç½®ã«æ¬¡å…ƒ
  ! dimvar ã‚’è¿½åŠ ã™ã‚‹ã€‚dimord ç•ªç›®ä»¥é™ã®æ¬¡å…ƒã¯ä¸€ã¤å¾Œã‚ã«ãšã‚Œã‚‹ã€‚
  ! ã‚‚ã— dimord ãŒ var ã®æœ‰åŠ¹æ¬¡å…ƒæ•°ã‚ˆã‚Šå¤§ãã‘ã‚Œã° (æœ‰åŠ¹æ¬¡å…ƒæ•° + 1)
  ! ãŒä¸Žãˆã‚‰ã‚ŒãŸã‚‚ã®ã¨ã¿ãªã•ã‚Œã‚‹ã€‚
  interface Add_dim
    subroutine GTVarAddDim(var, dimord, dimvar, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      type(GT_VARIABLE), intent(in):: dimvar
      integer, intent(in):: dimord
      logical, intent(out):: err
    end subroutine gtvaradddim
  end interface Add_dim

  ! å¤‰æ•°ãƒãƒ³ãƒ‰ãƒ«ã‹ã‚‰æ¬¡å…ƒã‚’ã€Œé™¤åŽ»ã€ã™ã‚‹ã€‚å®Ÿéš›ã«ã¯ã€
  ! æ¬¡å…ƒå¯¾å¿œè¡¨ã®é †ä½ã‚’ä¸‹ã’æœ‰åŠ¹æ¬¡å…ƒæ•°ã‚’ãƒ‡ã‚¯ãƒªãƒ¡ãƒ³ãƒˆã™ã‚‹ã ã‘ãªã®ã§ã€
  ! å…¥å‡ºåŠ›ã«æ”¯éšœã¯ãªã„ã€‚
  interface Del_dim
    subroutine GTVarDelDim(var, dimord, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: dimord
      logical, intent(out):: err
    end subroutine gtvardeldim
  end interface Del_dim

  ! æ¬¡å…ƒå¯¾å¿œè¡¨ã®é †ä½ã®äº¤æ›
  interface Exch_dim
    subroutine GTVarExchDim(var, dimord1, dimord2, count_compact, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: dimord1, dimord2
      logical, intent(in), optional:: count_compact
      logical, intent(out):: err
    end subroutine gtvarexchdim
  end interface Exch_dim

  !
  ! --- å•ã„åˆã‚ã› ---
  !

  interface Inquire
    subroutine GTVarInquire(var, growable, &
      & rank, alldims, allcount, size, &
      & xtype, name, url, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len=*), intent(out), optional:: xtype
      character(len=*), intent(out), optional:: name
      character(len=*), intent(out), optional:: url
      integer, intent(out), optional:: rank
      integer, intent(out), optional:: alldims
      integer, intent(out), optional:: allcount
      integer, intent(out), optional:: size
      logical, intent(out), optional:: growable
      logical, intent(out), optional:: err
    end subroutine GTVarInquire
    subroutine GTVarInquire2(var, allcount)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(out):: allcount(:)
    end subroutine GTVarInquire2
    subroutine GTVarInquireD(var, dimord, url, allcount, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: dimord
      character(len=*), intent(out), optional:: url
      integer, intent(out), optional:: allcount
      logical, intent(out), optional:: err
    end subroutine GTVarInquireD
    subroutine GTVarInquireA(var, attrname, xtype)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      character(len=*), intent(in):: attrname
      character(len=*), intent(out), optional:: xtype
    end subroutine GTVarInquireA
  end interface Inquire

  ! ç·ãªã‚ç”¨ã‚¤ãƒ†ãƒ¬ãƒ¼ã‚¿
  interface Slice_Next
    subroutine GTVarSliceNext(var, dimord, err, stat)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in out):: var
      integer, intent(in), optional:: dimord
      logical, intent(out), optional:: err
      integer, intent(out), optional:: stat
    end subroutine GTVarSliceNext
  end interface Slice_Next

  ! åŒå€¤åˆ¤å®š
  interface operator(.equivalent.)
    logical function gtvarequivalent(var1, var2)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var1, var2
    end function gtvarequivalent
  end interface operator(.equivalent.)

  !
  !== å…¥å‡ºåŠ›
  !
  !=== å…¥åŠ›
  !
  ! Get(var, value, nvalue, [err])
  ! 1æ¬¡å…ƒé…åˆ—ã«ç¾åœ¨ã®å…¥å‡ºåŠ›ç¯„å›²ã‚’å–å¾—ã™ã‚‹ã€‚
  ! nvalue ã¯åˆ©ç”¨è€…ãŒé…åˆ—é•·ã‚’æ ¼ç´ã—ãªã‘ã‚Œã°ãªã‚‰ãªã„ã€‚
  ! å€‹åˆ¥å GTVarGetReal ã‚’ç”¨ã„ã‚‹ã¨å¤šæ¬¡å…ƒé…åˆ—ã«å…¥åŠ›
  ! ã™ã‚‹ã“ã¨ã‚‚ã§ãã‚‹ãŒã€å…¥å‡ºåŠ›ç¯„å›²ã¨ã®é–¢ä¿‚ã«æ³¨æ„ãŒå¿…è¦ã€‚
  !
  ! Get(var, value, [err]) ã¯ 1ã€œ 7 æ¬¡å…ƒã®ãƒã‚¤ãƒ³ã‚¿ã‚’ã¨ã‚‹ã€‚
  ! å…¥å‡ºåŠ›ç¯„å›²ã‚’ãƒã‚¤ãƒ³ã‚¿æ¬¡å…ƒæ•°ã«é™å®šã—ã€é…åˆ—ã‚’ç¢ºä¿ã—ã€
  ! å€¤ã‚’å…¥ã‚Œã¦è¿”ã™ã€‚
  !

  interface Get
    subroutine GTVarGetDouble(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      real(DP), intent(out):: value(*)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarGetDouble
    subroutine GTVarGetPointerDouble1(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble1
    subroutine GTVarGetPointerDouble2(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble2
    subroutine GTVarGetPointerDouble3(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble3
    subroutine GTVarGetPointerDouble4(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble4
    subroutine GTVarGetPointerDouble5(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble5
    subroutine GTVarGetPointerDouble6(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble6
    subroutine GTVarGetPointerDouble7(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: DP
      real(DP),          pointer               :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerDouble7
    subroutine GTVarGetReal(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: SP
      real(SP), intent(out):: value(*)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarGetReal
    subroutine GTVarGetPointerReal1(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal1
    subroutine GTVarGetPointerReal2(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal2
    subroutine GTVarGetPointerReal3(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal3
    subroutine GTVarGetPointerReal4(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal4
    subroutine GTVarGetPointerReal5(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal5
    subroutine GTVarGetPointerReal6(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal6
    subroutine GTVarGetPointerReal7(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types,     only: SP
      real(SP),          pointer               :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerReal7
    subroutine GTVarGetInt(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      integer,  intent(out):: value(*)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarGetInt
    subroutine GTVarGetPointerInt1(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt1
    subroutine GTVarGetPointerInt2(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt2
    subroutine GTVarGetPointerInt3(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt3
    subroutine GTVarGetPointerInt4(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt4
    subroutine GTVarGetPointerInt5(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt5
    subroutine GTVarGetPointerInt6(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt6
    subroutine GTVarGetPointerInt7(var, value, err)
      use gtdata_types, only: GT_VARIABLE
      integer,           pointer               :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE), intent(in)            :: var
      logical,           intent(out), optional :: err
    end subroutine GTVarGetPointerInt7
  end interface Get

  !
  ! --- å°å— ---
  !
  ! å°å—ã¨ã„ã†ã®ã¯å¤‰æ•°ã«ã—ã¦ã¿ã‚Œã°å…¥åŠ›ã ã—ãƒ•ã‚¡ã‚¤ãƒ«ã«ã—ã¦ã¿ã‚Œã°å‡ºåŠ›ã ã€‚
  ! ã ã‹ã‚‰ put ã¨ get ã‚’å…¼å–¶ã—ã¦ã„ã‚‹ã‚ˆã†ãªã‚‚ã®ã§ã¾ã“ã¨ã«ã‚ã‚„ã—ã„ã®ã ãŒã€
  ! ã„ã¡ãŠã† dc_string ã®æ‰‹ç¶šåã‚’ç¶™æ‰¿ã—ã¦ put_line ã«ã—ã¦ãŠãã€‚

  interface PutLine
    subroutine GTVarPutLine( var, unit, indent, err )
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in), optional:: unit
      character(*), intent(in), optional:: indent
      logical, intent(out), optional:: err
    end subroutine GTVarPutLine
  end interface

  !
  ! --- å‡ºåŠ› ---
  !
  interface Put
    subroutine GTVarPutDouble(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: DP
      real(DP), intent(in):: value(nvalue)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarPutDouble
    subroutine GTVarPutDouble1(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble1
    subroutine GTVarPutDouble2(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble2
    subroutine GTVarPutDouble3(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble3
    subroutine GTVarPutDouble4(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble4
    subroutine GTVarPutDouble5(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble5
    subroutine GTVarPutDouble6(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble6
    subroutine GTVarPutDouble7(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: DP
      real(DP), intent(in) :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutDouble7
    subroutine GTVarPutReal(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      use dc_types, only: SP
      real(SP), intent(in):: value(nvalue)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarPutReal
    subroutine GTVarPutReal1(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal1
    subroutine GTVarPutReal2(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal2
    subroutine GTVarPutReal3(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal3
    subroutine GTVarPutReal4(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal4
    subroutine GTVarPutReal5(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal5
    subroutine GTVarPutReal6(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal6
    subroutine GTVarPutReal7(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      use dc_types,       only: SP
      real(SP), intent(in) :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutReal7
    subroutine GTVarPutInt(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      integer, intent(in):: value(nvalue)
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      logical, intent(out), optional:: err
    end subroutine GTVarPutInt
    subroutine GTVarPutInt1(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt1
    subroutine GTVarPutInt2(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt2
    subroutine GTVarPutInt3(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt3
    subroutine GTVarPutInt4(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt4
    subroutine GTVarPutInt5(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt5
    subroutine GTVarPutInt6(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt6
    subroutine GTVarPutInt7(var, value, err)
      use gtdata_types,   only: GT_VARIABLE
      integer,  intent(in) :: value(:,:,:,:,:,:,:)
      type(GT_VARIABLE),intent(in):: var
      logical  ,intent(out), optional:: err
    end subroutine GTVarPutInt7
    subroutine GTVarPutChar(var, value, nvalue, err)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(in):: var
      integer, intent(in):: nvalue
      character(*), intent(in):: value(nvalue)
      logical, intent(out), optional:: err
    end subroutine GTVarPutChar
  end interface Put

  !
  ! === å¤‰æ•°ã¨ãƒ•ã‚¡ã‚¤ãƒ«ã®é–¢ä¿‚ ===
  !

  interface GTVarSearch
    subroutine GTVarSearchNext(url, end)
      character(len = *), intent(out):: url
      logical, intent(out):: end
    end subroutine GTVarSearchNext
    subroutine GTVarSearchInit(urlBase)
      character(len = *), intent(in):: urlBase
    end subroutine GTVarSearchInit
  end interface GTVarSearch

  !
  ! === å®‰å…¨ã®ãŸã‚ã®è„±å‡ºå£ ===
  !
  ! SysDepAbort ãŒå‘¼ã³å‡ºã™ã®ã§ã€StoreError ã‚’å‘¼ã‚“ã§ã¯ãªã‚‰ãªã„
  !

  interface
    subroutine GTVarSync(var, stat)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout), optional:: var
      integer, intent(out), optional:: stat
    end subroutine GTVarSync
  end interface

  !
  ! === ãƒ¦ãƒ¼ãƒ†ã‚£ãƒªãƒ†ã‚£ ===
  !
  ! gtdata å±¤ã ã‘ã§æ›¸ã‹ã‚ŒãŸãƒ©ã‚¤ãƒ–ãƒ©ãƒªã€‚

  interface Create
    subroutine GTVarCreateCopyC(var, url, copyfrom, copyvalue, &
      & overwrite, err)
      use gtdata_types, only: GT_VARIABLE
      implicit none
      type(GT_VARIABLE), intent(out):: var
      character(len = *), intent(in):: url
      type(GT_VARIABLE), intent(inout):: copyfrom
      logical, intent(in), optional:: copyvalue
      logical, intent(in), optional:: overwrite
      logical, intent(out), optional:: err
    end subroutine GTVarCreateCopyC
  end interface

  !
  ! å¤‰æ•°ã®å‰Šé™¤ (ä½œæˆä¸)
  !
  interface GTVarDel
    subroutine GTVarDel1(varname, err)
      character(len = *), intent(in):: varname
      logical, intent(out):: err
    end subroutine GTVarDel1
  end interface

  !
  ! --- æ§‹é€ ä½“é–¢ä¿‚ ---
  !

  interface Add_member
    subroutine GTVarAddMember(var, url, link_name)
      use gtdata_types, only: GT_VARIABLE
      type(GT_VARIABLE), intent(inout):: var
      character(len = *), intent(in):: url
      character(len = *), intent(in), optional:: link_name
    end subroutine GTVarAddMember
  end interface

  ! ä¸€æ„ãªå¤‰æ•°åã®è‡ªå‹•ä½œæˆ
  interface GTDataTmpNam
    subroutine GTVarTmpNam(file, base, result)
      character(len = *), intent(in):: file
      character(len = *), intent(in):: base
      character(len = *), intent(out):: result
    end subroutine GTVarTmpNam
  end interface

end module gtdata_generic