Examples of Packet


Examples of megamek.common.net.Packet

     * clients have connected
     */
    public void resetConnections() {
        for (Enumeration<IConnection> connEnum = connections.elements();connEnum.hasMoreElements();) {
            IConnection conn = connEnum.nextElement();
            send(conn.getId(), new Packet(Packet.COMMAND_RESET_CONNECTION));
        }
    }
View Full Code Here

Examples of net.minecraft.network.Packet

            // Update any tile entity data for this block
            TileEntity tileentity = world.getTileEntity(x, y, z);
            if (tileentity != null)
            {
                Packet pkt = tileentity.getDescriptionPacket();
                if (pkt != null)
                {
                    entityPlayer.playerNetServerHandler.sendPacket(pkt);
                }
            }
View Full Code Here

Examples of net.minecraft.network.packet.Packet

            player.sendChatToPlayer(new ChatMessageComponent().addText(StatCollector.translateToLocal("ChatMsg.SettingsSaved")));
            return true;
          } else if (card.getSettingsName(currentItem).equals(getUnlocalizedName() + ".name") || card.getSettingsName(currentItem).equals("AppEng.GuiITooltip.Blank"))
          {
            blockTE.readFromNBT(card.getData(currentItem));
            Packet description = blockTE.getDescriptionPacket();
            if (description != null)
              PacketDispatcher.sendPacketToAllPlayers(description);
            player.sendChatToPlayer(new ChatMessageComponent().addText(StatCollector.translateToLocal("ChatMsg.SettingsLoaded")));
            return true;
          } else
View Full Code Here

Examples of net.minecraft.server.v1_6_R3.Packet

      Class<? extends Packet> packetClass = (Class<? extends Packet>) packets[packetId];
      if (packetClass == null) {
        return null;
      }
      Constructor<? extends Packet> c = packetClass.getConstructor(new Class[]{});
      Packet r = c.newInstance(blank);

      return newInstance(packetId, r);
    } catch (SecurityException e) {
      throw new RuntimeException(e);
    } catch (NoSuchMethodException e) {
View Full Code Here

Examples of net.ripe.hadoop.pcap.packet.Packet

  }

  @Override
  public Object deserialize(Writable w) throws SerDeException {
    ObjectWritable obj = (ObjectWritable)w;
    Packet packet = (Packet)obj.get();

        for (int i = 0; i < numColumns; i++) {
            String columName = columnNames.get(i);
            Object value = packet.get(columName);
             row.set(i, value);
        }
        return row;
  }
View Full Code Here

Examples of net.sf.cindy.Packet

    public void sessionClosed(SessionFilterChain filterChain) throws Exception {
        try {
            if (engine != null) {
                engine.closeOutbound();
                if (!engine.isInboundDone()) {
                    Packet encodedPacket = encode(filterChain.getSession(),
                            new HandshakePacket());
                    if (encodedPacket != null)
                        encodedPacket.getContent().release();
                }
                engine.closeInbound();
            }
        } catch (SSLException ssle) {
            throw new SessionException(ssle);
View Full Code Here

Examples of net.sourceforge.jpcap.net.Packet

    // create a raw packet and abstract packet from the raw data
    Timeval tv = new Timeval(seconds, useconds);

    RawPacket rp = new RawPacket(tv, data,
                                 length > caplen ? length - caplen : 0);
    Packet p = PacketFactory.dataToPacket(linkType, data, tv);

    // dispatch the raw packet to registered listeners..
    dispatchRawPacket(rp);

    // dispatch the packet to listeners interested in packet objects..
View Full Code Here

Examples of nu.fw.jeti.jabber.elements.Packet

          packetReceiver.streamError(packet);
          break;
        }
        */
        try{
          Packet packet = packetHandeler.build();
          Log.xmlPacket(packet);
          packetReceiver.receivePackets(packet);
        }catch(InstantiationException e){Log.xmlParseException(e);}
        catch (UnsupportedOperationException e)
        {//only way to stop xml parser
View Full Code Here

Examples of org.ImmortalSockets.packet.Packet

  protected void writeChannel(SocketChannel channel) {
    // If there is a packet to send.
    if (!packetQueue.isEmpty()) {

      // Get the packet from the queue.
      Packet packetToSend;
      packetToSend = packetQueue.poll();

      try {
        // Write the packet content to the channel.
        channel.write(packetToSend.getByteBuffer());
      } catch (IOException e) {
        // If there is an IO Exception we assumed the connection died
        // and we try to reconnect.
        reconnect();
      }
View Full Code Here

Examples of org.activeio.Packet

        ClassLoader originalLoader = Thread.currentThread().getContextClassLoader();
        try {

            RequestChannel channel = createRequestChannel(target);
            Packet response;
            try {
                channel.start();
                Packet request = serialize(invocation);
                response = channel.request(request, Service.WAIT_FOREVER_TIMEOUT);
            } finally {
                channel.dispose();               
            }
           
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.