KIM API V2
kim_temperature_unit_module.f90
Go to the documentation of this file.
1 !
2 ! CDDL HEADER START
3 !
4 ! The contents of this file are subject to the terms of the Common Development
5 ! and Distribution License Version 1.0 (the "License").
6 !
7 ! You can obtain a copy of the license at
8 ! http://www.opensource.org/licenses/CDDL-1.0. See the License for the
9 ! specific language governing permissions and limitations under the License.
10 !
11 ! When distributing Covered Code, include this CDDL HEADER in each file and
12 ! include the License file in a prominent location with the name LICENSE.CDDL.
13 ! If applicable, add the following below this CDDL HEADER, with the fields
14 ! enclosed by brackets "[]" replaced with your own identifying information:
15 !
16 ! Portions Copyright (c) [yyyy] [name of copyright owner]. All rights reserved.
17 !
18 ! CDDL HEADER END
19 !
20 
21 !
22 ! Copyright (c) 2016--2018, Regents of the University of Minnesota.
23 ! All rights reserved.
24 !
25 ! Contributors:
26 ! Ryan S. Elliott
27 !
28 
29 !
30 ! Release: This file is part of the kim-api-v2.0.0-alpha.0 package.
31 !
32 
33 
35  use, intrinsic :: iso_c_binding
36  implicit none
37  private
38 
39  public &
40  kim_temperature_unit_type, &
41  kim_temperature_unit_from_string, &
42  operator (.eq.), &
43  operator (.ne.), &
44  kim_temperature_unit_string, &
45 
48 
49  type, bind(c) :: kim_temperature_unit_type
50  integer(c_int) temperature_unit_id
51  end type kim_temperature_unit_type
52 
53  type(kim_temperature_unit_type), protected, &
54  bind(c, name="KIM_TEMPERATURE_UNIT_unused") &
56  type(kim_temperature_unit_type), protected, &
57  bind(c, name="KIM_TEMPERATURE_UNIT_K") &
59 
60  interface operator (.eq.)
61  logical function kim_temperature_unit_equal(left, right)
62  use, intrinsic :: iso_c_binding
63  import kim_temperature_unit_type
64  implicit none
65  type(kim_temperature_unit_type), intent(in) :: left
66  type(kim_temperature_unit_type), intent(in) :: right
67  end function kim_temperature_unit_equal
68  end interface operator (.eq.)
69 
70  interface operator (.ne.)
71  logical function kim_temperature_unit_not_equal(left, right)
72  use, intrinsic :: iso_c_binding
73  import kim_temperature_unit_type
74  implicit none
75  type(kim_temperature_unit_type), intent(in) :: left
76  type(kim_temperature_unit_type), intent(in) :: right
77  end function kim_temperature_unit_not_equal
78  end interface operator (.ne.)
79 
80  interface
81  subroutine kim_temperature_unit_from_string(string, temperature_unit)
82  import kim_temperature_unit_type
83  implicit none
84  character(len=*), intent(in) :: string
85  type(kim_temperature_unit_type), intent(out) :: temperature_unit
86  end subroutine kim_temperature_unit_from_string
87 
88  subroutine kim_temperature_unit_string(temperature_unit, string)
89  import kim_temperature_unit_type
90  implicit none
91  type(kim_temperature_unit_type), intent(in), value :: temperature_unit
92  character(len=*), intent(out) :: string
93  end subroutine kim_temperature_unit_string
94  end interface
type(kim_temperature_unit_type), public, protected kim_temperature_unit_k
type(kim_temperature_unit_type), public, protected kim_temperature_unit_unused