@Override
  public byte[] encode(final NamingUnregisterRequest obj) {
    final AvroNamingUnRegisterRequest result = AvroNamingUnRegisterRequest.newBuilder()
        .setId(obj.getIdentifier().toString())
        .build();
    return AvroUtils.toBytes(result, AvroNamingUnRegisterRequest.class);
  }
@ Override public byte [ ] encode ( final NamingUnregisterRequest obj ) { final AvroNamingUnRegisterRequest result = AvroNamingUnRegisterRequest . newBuilder ( ) . setId ( obj . getIdentifier ( ) . toString ( ) ) . build ( ) ; return AvroUtils . toBytes ( result , AvroNamingUnRegisterRequest . class ) ; }
Encodes the naming un-registration request to bytes.

@param obj the naming un-registration request
@return a byte array