code: static void writeEpochSec(long epochSec, DataOutput out) throws IOException {
          if (epochSec >= -4575744000L && epochSec < 10413792000L && epochSec % 900 == 0) {  // quarter hours between 1825 and 2300
              int store = (int) ((epochSec + 4575744000L) / 900);
              out.writeByte((store >>> 16) & 255);
              out.writeByte((store >>> 8) & 255);
              out.writeByte(store & 255);
          } else {
              out.writeByte(255);
              out.writeLong(epochSec);
          }
      }
docs: Writes the state to the stream.
  
  @param epochSec  the epoch seconds, not null
  @param out  the output stream, not null
  @throws IOException if an error occurs