code: public void writeToNoAddrs(Address src, DataOutput out, short ... excluded_headers) throws IOException {
          byte leading=0;
  
          boolean write_src_addr=src == null || sender != null && !sender.equals(src);
  
          if(write_src_addr)
              leading=Util.setFlag(leading, SRC_SET);
  
          if(buf != null)
              leading=Util.setFlag(leading, BUF_SET);
  
          // 1. write the leading byte first
          out.write(leading);
  
          // 2. the flags (e.g. OOB, LOW_PRIO)
          out.writeShort(flags);
  
          // 4. src_addr
          if(write_src_addr)
              Util.writeAddress(sender, out);
  
          // 5. headers
          Header[] hdrs=this.headers;
          int size=Headers.size(hdrs, excluded_headers);
          out.writeShort(size);
          if(size > 0) {
              for(Header hdr : hdrs) {
                  if(hdr == null)
                      break;
                  short id=hdr.getProtId();
                  if(Util.containsId(id, excluded_headers))
                      continue;
                  out.writeShort(id);
                  writeHeader(hdr, out);
              }
          }
  
          // 6. buf
          if(buf != null) {
              out.writeInt(length);
              out.write(buf, offset, length);
          }
      }
docs: Writes the message to the output stream, but excludes the dest and src addresses unless the
  src address given as argument is different from the message's src address
  @param excluded_headers Don't marshal headers that are part of excluded_headers