Index: XIOS/trunk/src/fortran/ifield.F90
===================================================================
--- XIOS/trunk/src/fortran/ifield.F90	(revision 312)
+++ XIOS/trunk/src/fortran/ifield.F90	(revision 313)
@@ -5,4 +5,6 @@
    USE FIELD_INTERFACE
    USE FIELDGROUP_INTERFACE
+!   USE IFIELD_ATTR
+!   USE IFIELDGROUP_ATTR
    
    TYPE txios(field)
@@ -15,252 +17,4 @@
    
    CONTAINS ! Fonctions disponibles pour les utilisateurs.
-
-
-   SUBROUTINE xios(set_fieldgroup_attr)                                             &
-   (fieldgroup_id, name, standard_name, long_name, unit, operation, freq_op, level, &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-    
-      IMPLICIT NONE
-      TYPE(txios(fieldgroup))                      :: fieldgroup_hdl
-      CHARACTER(len = *)               , INTENT(IN) :: fieldgroup_id
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op
-      INTEGER                , OPTIONAL, INTENT(IN) :: level
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value
-        
-      CALL xios(get_fieldgroup_handle)(fieldgroup_id,fieldgroup_hdl)
-      CALL xios(set_fieldgroup_attr_hdl_)                                                  &
-         (fieldgroup_hdl, name, standard_name, long_name, unit, operation, freq_op, level, &
-          prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-
-   END SUBROUTINE xios(set_fieldgroup_attr)
-
-   SUBROUTINE xios(set_fieldgroup_attr_hdl)                                           &
-   (fieldgroup_hdl, name, standard_name, long_name, unit, operation, freq_op, level , &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-      IMPLICIT NONE
-      TYPE(txios(fieldgroup))         , INTENT(IN) :: fieldgroup_hdl
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op
-      INTEGER                , OPTIONAL, INTENT(IN) :: level
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value
-      
-      CALL  xios(set_fieldgroup_attr_hdl_)                                            &
-   (fieldgroup_hdl, name, standard_name, long_name, unit, operation, freq_op, level , &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value) 
-       
-   END SUBROUTINE xios(set_fieldgroup_attr_hdl)
-
-
-   SUBROUTINE xios(set_fieldgroup_attr_hdl_)                                                &
-   (fieldgroup_hdl, name_, standard_name_, long_name_, unit_, operation_, freq_op_, level_, &
-    prec_, enabled_, domain_ref_, axis_ref_, grid_ref_, field_ref_, default_value_)
-      IMPLICIT NONE
-      TYPE(txios(fieldgroup))         , INTENT(IN) :: fieldgroup_hdl
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op_
-      INTEGER                , OPTIONAL, INTENT(IN) :: level_
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec_
-      LOGICAL(kind = 1)                             :: enabled__
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref_
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value_
-      
-      IF (PRESENT(name_))           THEN
-         CALL cxios_set_fieldgroup_name(fieldgroup_hdl%daddr, name_, len(name_))
-      END IF
-      IF (PRESENT(standard_name_))  THEN
-         CALL cxios_set_fieldgroup_standard_name(fieldgroup_hdl%daddr, standard_name_, len(standard_name_))
-      END IF
-      IF (PRESENT(long_name_))      THEN
-         CALL cxios_set_fieldgroup_long_name(fieldgroup_hdl%daddr, long_name_, len(long_name_))
-      END IF
-      IF (PRESENT(unit_))           THEN
-         CALL cxios_set_fieldgroup_unit(fieldgroup_hdl%daddr, unit_, len(unit_))
-      END IF
-      IF (PRESENT(operation_))      THEN
-         CALL cxios_set_fieldgroup_operation(fieldgroup_hdl%daddr, operation_, len(operation_))
-      END IF
-      IF (PRESENT(freq_op_))        THEN
-         CALL cxios_set_fieldgroup_freq_op(fieldgroup_hdl%daddr, freq_op_, len(freq_op_))
-      END IF
-      IF (PRESENT(level_))          THEN
-         CALL cxios_set_fieldgroup_level(fieldgroup_hdl%daddr, level_)
-      END IF
-      IF (PRESENT(prec_))           THEN
-         CALL cxios_set_fieldgroup_prec(fieldgroup_hdl%daddr, prec_)
-      END IF
-      IF (PRESENT(enabled_))        THEN
-         enabled__ = enabled_  
-         CALL cxios_set_fieldgroup_enabled(fieldgroup_hdl%daddr, enabled__)
-      END IF
-      IF (PRESENT(domain_ref_))     THEN
-         CALL cxios_set_fieldgroup_domain_ref(fieldgroup_hdl%daddr, domain_ref_, len(domain_ref_))
-      END IF
-      IF (PRESENT(axis_ref_))       THEN
-         CALL cxios_set_fieldgroup_axis_ref(fieldgroup_hdl%daddr, axis_ref_, len(axis_ref_))
-      END IF
-      IF (PRESENT(grid_ref_))       THEN
-         CALL cxios_set_fieldgroup_grid_ref(fieldgroup_hdl%daddr, grid_ref_, len(grid_ref_))
-      END IF
-      IF (PRESENT(field_ref_))      THEN
-         CALL cxios_set_fieldgroup_field_ref(fieldgroup_hdl%daddr, field_ref_, len(field_ref_))
-      END IF
-      IF (PRESENT(default_value_))  THEN
-         CALL cxios_set_fieldgroup_default_value(fieldgroup_hdl%daddr, default_value_)
-      END IF
-
-   END SUBROUTINE xios(set_fieldgroup_attr_hdl_)
-
-   
-   SUBROUTINE xios(set_field_attr)                                             &
-   (field_id, name, standard_name, long_name, unit, operation, freq_op, level, &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-    
-      IMPLICIT NONE
-      TYPE(txios(field))                            :: field_hdl
-      CHARACTER(len = *)               , INTENT(IN) :: field_id
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op
-      INTEGER                , OPTIONAL, INTENT(IN) :: level
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value
-      
-      CALL xios(get_field_handle)(field_id,field_hdl)
-      CALL xios(set_field_attr_hdl_)                                                          &
-         (field_hdl, name, standard_name, long_name, unit, operation, freq_op, level,  &
-          prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-   END SUBROUTINE xios(set_field_attr)
-
-
-   SUBROUTINE xios(set_field_attr_hdl)                                          &
-   (field_hdl, name, standard_name, long_name, unit, operation, freq_op, level, &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)
-      IMPLICIT NONE
-      TYPE(txios(field))               , INTENT(IN):: field_hdl
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op
-      INTEGER                , OPTIONAL, INTENT(IN) :: level
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value
-
-      CALL xios(set_field_attr_hdl_)                                            &
-   (field_hdl, name, standard_name, long_name, unit, operation, freq_op, level, &
-    prec, enabled, domain_ref, axis_ref, grid_ref, field_ref, default_value)  
-        
-   END SUBROUTINE xios(set_field_attr_hdl)
-
-   SUBROUTINE xios(set_field_attr_hdl_)                                                &
-   (field_hdl, name_, standard_name_, long_name_, unit_, operation_, freq_op_, level_, &
-    prec_, enabled_, domain_ref_, axis_ref_, grid_ref_, field_ref_, default_value_)
-      IMPLICIT NONE
-      TYPE(txios(field))               , INTENT(IN):: field_hdl
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: standard_name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: long_name_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: unit_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: operation_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: freq_op_
-      INTEGER                , OPTIONAL, INTENT(IN) :: level_
-      INTEGER                , OPTIONAL, INTENT(IN) :: prec_
-      LOGICAL(kind = 1)                             :: enabled__
-      LOGICAL                , OPTIONAL, INTENT(IN) :: enabled_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: domain_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: axis_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: grid_ref_
-      CHARACTER(len = *)     , OPTIONAL, INTENT(IN) :: field_ref_
-      REAL(kind=8)           , OPTIONAL, INTENT(IN) :: default_value_
-      
-      IF (PRESENT(name_))           THEN
-         CALL cxios_set_field_name(field_hdl%daddr, name_, len(name_))
-      END IF
-      IF (PRESENT(standard_name_))  THEN
-         CALL cxios_set_field_standard_name(field_hdl%daddr, standard_name_, len(standard_name_))
-      END IF
-      IF (PRESENT(long_name_))      THEN
-         CALL cxios_set_field_long_name(field_hdl%daddr, long_name_, len(long_name_))
-      END IF
-      IF (PRESENT(unit_))           THEN
-         CALL cxios_set_field_unit(field_hdl%daddr, unit_, len(unit_))
-      END IF
-      IF (PRESENT(operation_))      THEN
-         CALL cxios_set_field_operation(field_hdl%daddr, operation_, len(operation_))
-      END IF
-      IF (PRESENT(freq_op_))        THEN
-         CALL cxios_set_field_freq_op(field_hdl%daddr, freq_op_, len(freq_op_))
-      END IF
-      IF (PRESENT(level_))          THEN
-         CALL cxios_set_field_level(field_hdl%daddr, level_)
-      END IF
-      IF (PRESENT(prec_))           THEN
-         CALL cxios_set_field_prec(field_hdl%daddr, prec_)
-      END IF
-      IF (PRESENT(enabled_))        THEN
-         enabled__ = enabled_  
-         CALL cxios_set_field_enabled(field_hdl%daddr, enabled__)
-      END IF
-      IF (PRESENT(domain_ref_))     THEN
-         CALL cxios_set_field_domain_ref(field_hdl%daddr, domain_ref_, len(domain_ref_))
-      END IF
-      IF (PRESENT(axis_ref_))       THEN
-         CALL cxios_set_field_axis_ref(field_hdl%daddr, axis_ref_, len(axis_ref_))
-      END IF
-      IF (PRESENT(grid_ref_))       THEN
-         CALL cxios_set_field_grid_ref(field_hdl%daddr, grid_ref_, len(grid_ref_))
-      END IF
-      IF (PRESENT(field_ref_))      THEN
-         CALL cxios_set_field_field_ref(field_hdl%daddr, field_ref_, len(field_ref_))
-      END IF
-      IF (PRESENT(default_value_))  THEN
-         CALL cxios_set_field_default_value(field_hdl%daddr, default_value_)
-      END IF
-
-   END SUBROUTINE xios(set_field_attr_hdl_)
-   
 
    SUBROUTINE xios(get_field_handle)(idt, ret)
