summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorRobb Matzke <matzke@llnl.gov>1998-02-12 01:23:12 (GMT)
committerRobb Matzke <matzke@llnl.gov>1998-02-12 01:23:12 (GMT)
commit4854aa28f753f0997e3fb545735967b22ae750bc (patch)
treed5e7fcf67b02b19bc1f512555498a93bcbb5c67d /src
parent834ce78ca5d9e01d154489cffbdbd40b2e268d6d (diff)
downloadhdf5-4854aa28f753f0997e3fb545735967b22ae750bc.zip
hdf5-4854aa28f753f0997e3fb545735967b22ae750bc.tar.gz
hdf5-4854aa28f753f0997e3fb545735967b22ae750bc.tar.bz2
[svn-r255] Added a teeny tiny little miniscule amount of support for strings because
the VB-API work stores comments in some of the VB tables.
Diffstat (limited to 'src')
-rw-r--r--src/H5Odtype.c26
1 files changed, 26 insertions, 0 deletions
diff --git a/src/H5Odtype.c b/src/H5Odtype.c
index 776dd86..e8d57d8 100644
--- a/src/H5Odtype.c
+++ b/src/H5Odtype.c
@@ -103,6 +103,19 @@ H5O_dtype_decode_helper(const uint8 **pp, H5T_t *dt)
UINT16DECODE(*pp, dt->u.atomic.prec);
break;
+ case H5T_STRING:
+ /*
+ * Character string types...
+ */
+ dt->u.atomic.order = H5T_ORDER_NONE;
+ dt->u.atomic.prec = 8 * dt->size;
+ dt->u.atomic.offset = 0;
+ dt->u.atomic.lsb_pad = H5T_PAD_ZERO;
+ dt->u.atomic.msb_pad = H5T_PAD_ZERO;
+ dt->u.atomic.u.s.cset = H5T_CSET_ASCII;
+ dt->u.atomic.u.s.pad = H5T_STR_NULL;
+ break;
+
case H5T_FLOAT:
/*
* Floating-point types...
@@ -271,6 +284,19 @@ H5O_dtype_encode_helper(uint8 **pp, const H5T_t *dt)
UINT16ENCODE(*pp, dt->u.atomic.prec);
break;
+ case H5T_STRING:
+ /*
+ * Character string types... (not fully implemented)
+ */
+ assert (dt->u.atomic.order == H5T_ORDER_NONE);
+ assert (dt->u.atomic.prec == 8 * dt->size);
+ assert (dt->u.atomic.offset == 0);
+ assert (dt->u.atomic.lsb_pad == H5T_PAD_ZERO);
+ assert (dt->u.atomic.msb_pad == H5T_PAD_ZERO);
+ assert (dt->u.atomic.u.s.cset == H5T_CSET_ASCII);
+ assert (dt->u.atomic.u.s.pad == H5T_STR_NULL);
+ break;
+
case H5T_FLOAT:
/*
* Floating-point types...