package baowen; import java.math.BigInteger; import java.util.Vector; import data_model.YuanshiByt; import publicclass.JugeNumber; import publicclass.ShowMessage; /**´¦ÀíԭʼÊý¾Ý*/ public class Dell_uanshi_byt { static Vector yuanshivec=new Vector<>(); /**²åÈëԭʼ²â¾àÊý¾Ý£¬Ã¿¸öipÒ»¸ö¼¯ºÏÿ¸öIPÉÏÀ´µÄÊý¾Ý×°Èë¸÷×ÔIPÖ®ÖÐ*/ public static void intsert(String ip,String hex,String time,int timestamp,int port) { if(get_ys(ip) !=null) { int lenth=hex.length()/2; for(int i=0;i data1=new Vector<>(); StringBuffer okhex=new StringBuffer(); ysbyt.setIp(ip); ysbyt.setPort(port); ysbyt.setData(data1); ysbyt.setTimestamp(timestamp); ysbyt.setTime(time); ysbyt.setUsart_state(0); ysbyt.setPack(okhex); ysbyt.setDatalen(0); ysbyt.setType(""); int lenth=hex.length()/2; for(int i=0;ia ) { ysbyt.getPack().setLength(0); ysbyt.setDatalen(0); ysbyt.setType(""); } break; } //ɾ³ý´¦Àí¹ýµÄÊý¾Ý ysbyt.getData().removeElement(hex); } } /**16½øÖÆ×ªÎª10½øÖÆ*/ public static int decodeHEX(String hexs){ String hex=hexs.trim(); boolean a=JugeNumber.isLetterDigit(hex); int numb=0; if(a) { BigInteger bigint=new BigInteger(hex,16); numb=bigint.intValue(); }else { ShowMessage.zidingyi_24("16½øÖÆ×ª10½øÖƳö´í,ÊÕµ½£º"+hex); } return numb; } }