public boolean isEmpty() {
    return baos.size() == 0;
  }
Provides byte stream for testing. Use {@link #getDataInput()} and {@link #getDataOutput()} to get
DataInput or DataOutput as needed for testing.

@since GemFire 7.0
geode-core/src/test/java/org/apache/geode/internal/ByteArrayData.java