本文整理了Java中org.dcm4che3.data.Attributes.writeTo()
方法的一些代码示例,展示了Attributes.writeTo()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Attributes.writeTo()
方法的具体详情如下:
包路径:org.dcm4che3.data.Attributes
类名称:Attributes
方法名:writeTo
暂无
代码示例来源:origin: dcm4che/dcm4che
public void writeTo(DicomOutputStream out)
throws IOException {
if (isEmpty())
return;
if (groupLengths == null && out.getEncodingOptions().groupLength)
throw new IllegalStateException(
"groupLengths not initialized by calcLength()");
SpecificCharacterSet cs = getSpecificCharacterSet();
if (tags[0] < 0) {
int index0 = -(1 + indexOf(0));
writeTo(out, cs, index0, size, groupLengthIndex0);
writeTo(out, cs, 0, index0, 0);
} else {
writeTo(out, cs, 0, size, 0);
}
}
代码示例来源:origin: dcm4che/dcm4che
public void writeDataset(Attributes fmi, Attributes dataset)
throws IOException {
if (fmi != null)
writeFileMetaInformation(fmi);
if (dataset.bigEndian() != bigEndian
|| encOpts.groupLength
|| !encOpts.undefSequenceLength
|| !encOpts.undefItemLength)
dataset = new Attributes(dataset, bigEndian);
if (encOpts.groupLength)
dataset.calcLength(encOpts, explicitVR);
dataset.writeTo(this);
}
代码示例来源:origin: dcm4che/dcm4che
public void writeItemTo(DicomOutputStream out) throws IOException {
DicomEncodingOptions encOpts = out.getEncodingOptions();
int len = getEncodedItemLength(encOpts, out.isExplicitVR());
out.writeHeader(Tag.Item, null, len);
writeTo(out);
if (len == -1)
out.writeHeader(Tag.ItemDelimitationItem, null, 0);
}
代码示例来源:origin: dcm4che/dcm4che
public void writeGroupTo(DicomOutputStream out, int groupLengthTag)
throws IOException {
if (isEmpty())
throw new IllegalStateException("No attributes");
checkInGroup(0, groupLengthTag);
checkInGroup(size-1, groupLengthTag);
SpecificCharacterSet cs = getSpecificCharacterSet();
out.writeGroupLength(groupLengthTag,
calcLength(out.getEncodingOptions(), out.isExplicitVR(), cs, null));
writeTo(out, cs, 0, size, 0);
}
代码示例来源:origin: usnistgov/iheos-toolkit2
DicomOutputStream dos = new DicomOutputStream(out);
dos.writeFileMetaInformation(meta);
dataSet.writeTo(dos);
dos.close();
} catch (Exception e) {
内容来源于网络,如有侵权,请联系作者删除!