Get a description of a field

saf_describe_field is a function defined in field.c.

Synopsis:

int saf_describe_field(SAF_ParMode pmode, SAF_Field *field, SAF_FieldTmpl *ftmpl, char **name, SAF_Set *base_space, SAF_Unit *unit, hbool_t *is_coord, SAF_Cat *homog_decomp, SAF_Cat *coeff_assoc, int *assoc_ratio, SAF_Cat *eval_coll, SAF_Eval *eval_func, hid_t *data_type, int *num_comps, SAF_Field **comp_flds, SAF_Interleave *comp_intlv, int **comp_order)

Formal Arguments:

  • pmode: The parallel mode.
  • field: The field handle.
  • ftmpl: [OUT] The returned field template handle. Pass NULL if you do not want this value returned.
  • name: [OUT] The returned name of the field. Pass NULL if you do not want this value returned. (see *Returned Strings*).
  • base_space: [OUT] The returned base space of the field. Pass NULL if you do not want this value returned.
  • unit: [OUT] The returned unit of measure.
  • is_coord: [OUT] A returned boolean indicating if the field is a coordinate field. Pass NULL if you do not want this value returned.
  • homog_decomp: NULL: If the field is homogeneous, the value returned here, if requested, is always SAF__SELF. That is, SAF__EQUIV``(``SAF__SELF``(db), ``homog_decomp) will return true. Otherwise, it will return false, the field is inhomogeneous and this argument is the decomposition on which the field is presumably piecewise homogeneous. Pass NULL if you do not want this value returned.
  • coeff_assoc: [OUT] The collection with which the field coefficients are associated in an n:1 relationship. Pass NULL if you do not want this value returned.
  • assoc_ratio: [OUT] The n’ in the ``n:1` relationship described for the coeff_assoc argument. Pass NULL if you do not want this value returned.
  • eval_coll: [OUT] The collection whose sets decompose the base space set and over which the field is actually evaluated. Pass NULL if you do not want this value returned.
  • eval_func: [OUT] The evaluation function. Pass NULL if you do not want this value returned.
  • data_type: [OUT] The file datatype of the field. Pass NULL if you do not want this value returned. The caller is responsible for invoking H5Tclose when the datatype is no longer needed. A negative returned value indicates no known file datatype.
  • num_comps: [OUT] The number of components in the field. Pass NULL if you do not want this value returned.
  • comp_flds: [OUT] The component fields. Pass NULL if you do not want this value returned.
  • comp_intlv: [OUT] The particular fashion in which components are interleaved. Currently there are really only two: SAF__INTERLEAVE_VECTOR and SAF__INTERLEAVE_COMPONENT. These represent the XYZXYZ…``XYZ`` and the XXX…``XYYY``…``YZZZ``…``Z`` cases. Note that interleave really only deals within a single blob of storage. In the case of a composite field whose coefficients are stored independently on the component fields then interleave really has no meaning (use SAF__INTERLEAVE_INDEPENDENT). Interleave only has meaning on fields with storage. In the case of a scalar field interleave is also meaningless, both cases degenerate to the same layout: XXX…``X`` (use SAF__INTERLEAVE_NONE).
  • comp_order: [OUT] The component ordering in the field. Pass NULL if you do not want this value returned.

Description: NOT WRITTEN YET.

Preconditions:

  • pmode must be valid. (low-cost)
  • field must be a valid field handle for all participating processes. (low-cost)

Return Value: The constant SAF__SUCCESS is returned when this function is successful. Otherwise this function either returns an error number or throws an exception, depending on the value of the library’s error handling property.

See Also:

  • Fields: Introduction for current chapter