public void run() {
    String fileName;
    ResponseCallback cb = new ResponseCallback(mComm, mEvent);

    try {

      if ((fileName = Serialization.DecodeString(mEvent.payload)) == null)
        throw new ProtocolException("Filename not properly encoded in request packet");

      mBroker.Remove(cb, fileName);

    } catch (ProtocolException e) {
      int error = cb.error(Error.PROTOCOL_ERROR, e.getMessage());
      log.severe("Protocol error (REMOVE) - " + e.getMessage());
      if (error != Error.OK)
        log.severe("Problem sending (REMOVE) error back to client - " + Error.GetText(error));
    }
  }
Exemplo n.º 2
0
 public void decode(ByteBuffer buf) {
   mMessage = Serialization.DecodeString(buf);
 }
Exemplo n.º 3
0
 public void encode(ByteBuffer buf) {
   Serialization.EncodeString(buf, mMessage);
 }
Exemplo n.º 4
0
 public int encodedLength() {
   return Serialization.EncodedLengthString(mMessage);
 }