@@ -0,0 +1,897 @@
+package org.pcap4j.sample;%0D%0A%0D%0Aimport org.pcap4j.core.PcapDumper;%0D%0Aimport org.pcap4j.core.PcapHandle;%0D%0Aimport org.pcap4j.core.PcapNativeException;%0D%0Aimport org.pcap4j.core.Pcaps;%0D%0Aimport org.pcap4j.packet.Packet;%0D%0A%0D%0Apublic class PcapFileMerger %7B%0D%0A%0D%0A  public static void main(String%5B%5D args) throws PcapNativeException %7B%0D%0A    // args: pcap file list%0D%0A%0D%0A    PcapDumper dumper = null;%0D%0A    for (String pcapFile: args) %7B%0D%0A      PcapHandle handle = Pcaps.openOffline(pcapFile);%0D%0A%0D%0A      if (dumper == null) %7B%0D%0A        dumper = handle.dumpOpen(PcapFileMerger.class.getSimpleName() + %22.pcap%22);%0D%0A      %7D%0D%0A%0D%0A      Packet packet;%0D%0A      while ((packet = handle.getNextPacket()) != null) %7B%0D%0A        dumper.dump(%0D%0A          packet, handle.getTimestampInts(), handle.getTimestampMicros()%0D%0A        );%0D%0A      %7D%0D%0A%0D%0A      handle.close();%0D%0A    %7D%0D%0A%0D%0A    if (dumper != null) %7B%0D%0A      dumper.close();%0D%0A    %7D%0D%0A%0D%0A  %7D%0D%0A%0D%0A%7D%0D%0A

add a sample