/** * @param vl * @param i * @exception IOException * @exception DicomException */ private void doCommonConstructorStuff(long vl, DicomInputStream i) throws IOException, DicomException { flushCachedCopies(); if (vl % bytesPerValue != 0) { i.skipInsistently(vl); throw new DicomException( "incorrect value length (" + vl + " dec) for VR " + getVRAsString() + " - skipping value length bytes to get to next data element"); } else { int vm = (int) (vl / bytesPerValue); values = null; for (int j = 0; j < vm; ++j) addValue((short) (i.readSigned16())); } }