source: dynamico_lmdz/simple_physics/phyparam/physics/writefield_mod.F90 @ 4235

Last change on this file since 4235 was 4235, checked in by dubos, 5 years ago

simple_physics : DYNAMICO driver

File size: 1.6 KB
Line 
1MODULE writefield_mod
2  USE logging, ONLY : missing_plugin
3  IMPLICIT NONE
4  PRIVATE
5  SAVE
6
7  INTERFACE
8     SUBROUTINE plugin_writefield1(name,longname,unit, var)
9       CHARACTER(*), INTENT(IN) :: name, longname, unit
10       REAL, INTENT(IN)         :: var(:)
11     END SUBROUTINE plugin_writefield1
12     SUBROUTINE plugin_writefield2(name,longname,unit, var)
13       CHARACTER(*), INTENT(IN) :: name, longname, unit
14       REAL, INTENT(IN)         :: var(:,:)
15     END SUBROUTINE plugin_writefield2
16  END INTERFACE
17
18#ifndef XCODEML
19
20  PROCEDURE(plugin_writefield1), POINTER, PUBLIC :: writefield1_plugin => NULL()
21  PROCEDURE(plugin_writefield2), POINTER, PUBLIC :: writefield2_plugin => NULL()
22
23#endif
24  INTERFACE writefield
25     PROCEDURE writefield1, writefield2
26  END INTERFACE writefield
27
28  PUBLIC :: writefield
29
30CONTAINS
31
32  SUBROUTINE writefield2(name, longname, unit, var)
33    CHARACTER(*), INTENT(IN) :: name, longname, unit
34    REAL, INTENT(IN)         :: var(:,:)
35#ifndef XCODEML
36    IF(ASSOCIATED(writefield2_plugin)) THEN
37       CALL writefield2_plugin(name, longname, unit, var)
38    ELSE
39       CALL missing_plugin('writefield2','writefield_mod')
40    END IF
41#endif
42  END SUBROUTINE writefield2
43
44  SUBROUTINE writefield1(name, longname, unit, var)
45    CHARACTER(*), INTENT(IN) :: name, longname, unit
46    REAL, INTENT(IN)         :: var(:)
47#ifndef XCODEML
48    IF(ASSOCIATED(writefield1_plugin)) THEN
49       CALL writefield1_plugin(name, longname, unit, var)
50    ELSE
51       CALL missing_plugin('writefield1','writefield_mod')
52    END IF
53#endif
54  END SUBROUTINE writefield1
55
56END MODULE writefield_mod
Note: See TracBrowser for help on using the repository browser.