
io.jhdf.object.message.FillValueOldMessage Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jhdf Show documentation
Show all versions of jhdf Show documentation
A pure Java HDF5 library
/*
* This file is part of jHDF. A pure Java library for accessing HDF5 files.
*
* https://jhdf.io
*
* Copyright (c) 2025 James Mudd
*
* MIT License see 'LICENSE' file
*/
package io.jhdf.object.message;
import io.jhdf.Utils;
import java.nio.ByteBuffer;
import java.util.BitSet;
/**
*
* Fill Value (Old) Message
*
*
*
* Format
* Spec
*
*
* @author James Mudd
*/
public class FillValueOldMessage extends Message {
public static final int MESSAGE_TYPE = 4;
private final ByteBuffer fillValue;
/* package */ FillValueOldMessage(ByteBuffer bb, BitSet flags) {
super(flags);
final int size = Utils.readBytesAsUnsignedInt(bb, 4);
fillValue = Utils.createSubBuffer(bb, size);
}
/**
* The fill value. The bytes of the fill value are interpreted using the same
* datatype as for the dataset.
*
* @return a buffer containing the fill value
*/
public ByteBuffer getFillValue() {
return fillValue.asReadOnlyBuffer();
}
@Override
public int getMessageType() {
return MESSAGE_TYPE;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy