f_udunits_2.inc 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. ! documentation for c code :
  2. ! http://www.unidata.ucar.edu/software/udunits/udunits-2.0.4/udunits2lib.html
  3. type, bind(C) :: UT_SYSTEM_PTR
  4. type(C_PTR) :: ptr
  5. end type
  6. type, bind(C) :: UT_UNIT_PTR
  7. type(C_PTR) :: ptr
  8. end type
  9. type, bind(C) :: CV_CONVERTER_PTR
  10. type(C_PTR) :: ptr
  11. end type
  12. type, bind(C) :: UT_STATUS
  13. integer(C_INT) :: value
  14. end type
  15. type :: CHAR_STAR
  16. character(len=1),dimension(:),pointer :: ptr
  17. end type
  18. !
  19. ! the following constants are lifted from C enum in udunits2.h
  20. ! and may have to be adjusted should any change be made to that file
  21. !
  22. ! a cleaner way would be to use a C program to produce this file
  23. !
  24. integer, parameter :: UT_ASCII = 0
  25. integer, parameter :: UT_ISO_8859_1 = 1
  26. integer, parameter :: UT_LATIN1 = UT_ISO_8859_1
  27. integer, parameter :: UT_UTF8 = 2
  28. integer, parameter :: UT_NAMES = 4
  29. integer, parameter :: UT_DEFINITION = 8
  30. integer, parameter :: UT_SUCCESS =0
  31. integer, parameter :: UT_BAD_ARG =1
  32. integer, parameter :: UT_EXISTS =2
  33. integer, parameter :: UT_NO_UNIT =3
  34. integer, parameter :: UT_OS =4
  35. integer, parameter :: UT_NOT_SAME_SYSTEM =5
  36. integer, parameter :: UT_MEANINGLESS =6
  37. integer, parameter :: UT_NO_SECOND =7
  38. integer, parameter :: UT_VISIT_ERROR =8
  39. integer, parameter :: UT_CANT_FORMAT =9
  40. integer, parameter :: UT_SYNTAX =10
  41. integer, parameter :: UT_UNKNOWN =11
  42. integer, parameter :: UT_OPEN_ARG =12
  43. integer, parameter :: UT_OPEN_ENV =13
  44. integer, parameter :: UT_OPEN_DEFAULT =14
  45. integer, parameter :: UT_PARSE =15