Examples of ShortBuffer


Examples of freenet.support.ShortBuffer

  public Object getObject(String key) {
    return _payload.get(key);
  }
 
  public byte[] getShortBufferBytes(String key) {
    ShortBuffer buffer = (ShortBuffer) getObject(key);
    return buffer.getData();
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

   */
  public void setRoutedToNodeFields(long uid, double targetLocation, short htl, byte[] nodeIdentity) {
    set(DMT.UID, uid);
    set(DMT.TARGET_LOCATION, targetLocation);
    set(DMT.HTL, htl);
    set(DMT.NODE_IDENTITY, new ShortBuffer(nodeIdentity));
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

    msg.set(DATA, data);
    return msg;
  }
 
  public static Message createFNPBulkPacketSend(long uid, int packetNo, byte[] data, boolean realTime) {
    return createFNPBulkPacketSend(uid, packetNo, new ShortBuffer(data), realTime);
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};

  public static Message createNodeToNodeMessage(int type, byte[] data) {
    Message msg = new Message(nodeToNodeMessage);
    msg.set(NODE_TO_NODE_MESSAGE_TYPE, type);
    msg.set(NODE_TO_NODE_MESSAGE_DATA, new ShortBuffer(data));
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};
 
  public static Message createFNPCHKDataFound(long id, byte[] buf) {
    Message msg = new Message(FNPCHKDataFound);
    msg.set(UID, id);
    msg.set(BLOCK_HEADERS, new ShortBuffer(buf));
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};
 
  public static Message createFNPDataInsert(long uid, byte[] headers) {
    Message msg = new Message(FNPDataInsert);
    msg.set(UID, uid);
    msg.set(BLOCK_HEADERS, new ShortBuffer(headers));
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

    Message msg = new Message(FNPSSKInsertRequest);
    msg.set(UID, uid);
    msg.set(HTL, htl);
    msg.set(FREENET_ROUTING_KEY, myKey);
    msg.set(NEAREST_LOCATION, 0.0);
    msg.set(BLOCK_HEADERS, new ShortBuffer(headers));
    msg.set(PUBKEY_HASH, new ShortBuffer(pubKeyHash));
    msg.set(DATA, new ShortBuffer(data));
    if(realTime) msg.boostPriority();
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};
 
  public static Message createFNPSSKInsertRequestHeaders(long uid, byte[] headers, boolean realTime) {
    Message msg = new Message(FNPSSKInsertRequestHeaders);
    msg.set(UID, uid);
    msg.set(BLOCK_HEADERS, new ShortBuffer(headers));
    if(realTime) msg.boostPriority();
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};
 
  public static Message createFNPSSKInsertRequestData(long uid, byte[] data, boolean realTime) {
    Message msg = new Message(FNPSSKInsertRequestData);
    msg.set(UID, uid);
    msg.set(DATA, new ShortBuffer(data));
    if(realTime) msg.boostPriority();
    return msg;
  }
View Full Code Here

Examples of freenet.support.ShortBuffer

  }};
 
  public static Message createFNPSSKDataFoundHeaders(long uid, byte[] headers, boolean realTime) {
    Message msg = new Message(FNPSSKDataFoundHeaders);
    msg.set(UID, uid);
    msg.set(BLOCK_HEADERS, new ShortBuffer(headers));
    if(realTime) msg.boostPriority();
    return msg;
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.