📄 q.java
字号:
// pica客户端J2ME源码,100%可运行可修改,J2ME逆向工程经典作品
// 作者:fangji999
// QQ:57979471 Email:fangji999@163.com
// 博客:http://hi.baidu.com/ccall_net
// QQ群:51719370
// 如用此源码重新改写的软件或转载,请保留本人联系方式,作品原创作者
package pica;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.util.Vector;
import utils.a;
import utils.b;
// Referenced classes of package pica:
// Pica, ae, ag, b,
// g, s, w
public final class q extends Thread
{
public String a;
public boolean b;
public boolean c;
public boolean d;
public String e;
public boolean f;
public boolean g;
public s h;
public Vector i;
String j;
public ag k;
public q(s s1)
{
a = null;
b = false;
c = false;
f = false;
h = null;
i = null;
k = null;
h = s1;
a = w.ls + "@" + "pica";
k = new ag(this);
}
//核心主要循环函数
private void k()
throws Exception
{
long l1;
int i1;
// Object obj = null;
l1 = System.currentTimeMillis();
i1 = 0;
g = false;
pica.b b1;
//_L4:
while(true) {
b1=new pica.b();
if (c || b && i.size() <= 0)
break; /* Loop/switch isn't completed */
b1 = new pica.b();
if (!i.isEmpty())
{
b1 = null;
synchronized (i)
{
b1 = (pica.b)i.firstElement();
i.removeElementAt(0);
}
} else
if (!b){
if (System.currentTimeMillis() - l1 > (long)(Pica.aI * 1000) || !g)
{
if (!Pica.aK)
{
if (Pica.aL)
{
i1 = 0;
Pica.aL = false;
}
if (g && i1 < 7)
i1++;
if (!g)
{
i1 = 0;
Pica.aL = true;
}
Pica.aI = Pica.aJ[i1];
}
b1 = null;
b1 = new pica.b("cache", "/cache.xml", null);
l1 = System.currentTimeMillis();
} else
{
Thread.sleep(2000);
}
}
if (b1.d != null)
{
if (!b || b && b1.c.startsWith("logout"))
{
if (b1.g == pica.b.a)
d(b1.c, b1.d, b1.e);//消息连接
else
if (b1.g == pica.b.b)//网页连接
utils.b.a(pica.g.a, b1.d, b1.f);
if (!b1.c.startsWith("cache"))
{
if (!Pica.aK)
{
Pica.aI = Pica.aJ[0];
i1 = 0;
}
l1 = System.currentTimeMillis() - (long)(Pica.aI * 1000 - 4000);
}
}
if (b1.c.equals("logout"))
return;
}
Thread.yield();
Thread.sleep(500);
}
// continue; /* Loop/switch isn't completed */
// JVM INSTR dup ;
// Exception exception;
// exception;
// getMessage();
// JVM INSTR dup ;
// String s1;
// s1;
// JVM INSTR ifnull 401;
// goto _L1 _L2
//_L1:
// break MISSING_BLOCK_LABEL_390;
//_L2:
// break MISSING_BLOCK_LABEL_401;
// if (s1.equals("disconnected"))
// break MISSING_BLOCK_LABEL_421;
//if (b1.d == null || !b1.c.equals("logout"))
if (b1.d.equals(null)|| !b1.c.equals("logout"))
//break MISSING_BLOCK_LABEL_422;
return;
if (Pica.W)
return;
pica.b b2;
if (b1.d != null && !b1.c.equals("cache"))
synchronized (i)
{
if (i.size() > 0)
{
if ((b2 = (pica.b)i.firstElement()).c.equals("login"))
i.insertElementAt(b1, 1);
} else
{
i.insertElementAt(b1, 0);
}
}
// if (true) goto _L4; else goto _L3
//_L3:
}
//连入主要函数
public final void run()
{
c = false;
b = false;
d = false;
// Pica.d="0.904.442.cn";
// Pica.b="pica";
if (i == null)
i = new Vector();
try
{
System.out.println("test11");
h.a();
if (w.g == null || w.g.length() == 0)
{
w.g = w.fs;
Pica.k.a("查找服务器...");
System.out.println("test22");
l();
Pica.k.a("连接服务器...");
}
System.out.println("test33");
a(true);
System.out.println("test44");
h.c();
}
catch (Exception exception)
{
h.a(exception.getMessage());
return;
}
try
{
System.out.println("test55");
k();
}
catch (Exception e) { }
try
{
if (!c)
h.b(j);
}
catch (Exception e) { }
if (b)
h.b();
}
public final void a(String s1)
throws IOException
{
String s2 = "<iq type='set'><query xmlns='jabber:iq:blacklist'><item jid='" + (s1.indexOf("@") <= 0 ? s1 + "@pica" : s1) + "' status='block'/></query></iq>";
e("blacklist", "/raw.xml", s2.toString());
}
public final void a(String s1, String s2, String s3)
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("<iq type='get' to='cluster.pica'><query xmlns='jabber:iq:newsearch'>");
if (s1 != null && s1.length() > 0)
stringbuffer.append("<CLUSTER>" + s1 + "</CLUSTER>");
if (s2 != null && s2.length() > 0)
stringbuffer.append("<CATEGORY>" + utils.b.b(s2) + "</CATEGORY>");
if (s3 != null && s3.length() > 0)
stringbuffer.append("<NICKNAME>" + utils.b.b(s3) + "</NICKNAME>");
stringbuffer.append("</query></iq>");
e("searchCluster", "/raw.xml", stringbuffer.toString());
}
public final void b(String s1)
throws IOException
{
String s2 = "<iq type='set'><query xmlns='jabber:iq:blacklist'><item jid='" + (s1.indexOf("@") <= 0 ? s1 + "@pica" : s1) + "' status='unblock'/></query></iq>";
e("unblock", "/raw.xml", s2.toString());
}
private void l()
throws Exception
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("id=");
stringbuffer.append(w.ls + "@" + "pica");
stringbuffer.append("&version=");
stringbuffer.append(Pica.d);
stringbuffer.append("&type=hz");
stringbuffer.append("&source=");
stringbuffer.append(pica.Pica.b);
d("dispatch", "/dispatch.xml?" + stringbuffer.toString(), null);
}
private void a(boolean flag)
throws Exception
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("jid=");
stringbuffer.append(w.ls + "@" + "pica");
stringbuffer.append("&pass=");
stringbuffer.append(w.m);
stringbuffer.append("&version=");
stringbuffer.append(Pica.d);
stringbuffer.append("&source=");
stringbuffer.append(pica.Pica.b);
if (flag)
{
d("login", "/login-sid.xml?" + stringbuffer.toString(), null);
return;
}
synchronized (i)
{
pica.b b1 = new pica.b("login", "/login-sid.xml?" + stringbuffer.toString(), null);
i.insertElementAt(b1, 0);
}
}
public final void a()
throws Exception
{
h.d();
}
public final void c(String s1)
throws Exception
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("<iq type='set' to='");
stringbuffer.append(utils.b.b(s1));
stringbuffer.append("'><query xmlns='jabber:iq:register'><remove/></query></iq>");
e("logout-im", "/raw.xml", stringbuffer.toString());
}
public final void b()
throws Exception
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("<iq type='get' to='");
stringbuffer.append(utils.b.b("qq.pica"));
stringbuffer.append("'><query xmlns='jabber:x:roster'><number>30</number></query></iq>");
e("offlineqqfriends", "/raw.xml", stringbuffer.toString());
}
public final void b(String s1, String s2, String s3)
{
StringBuffer stringbuffer;
(stringbuffer = new StringBuffer()).append("<iq type='set' to='");
stringbuffer.append(utils.b.b(s1));
stringbuffer.append("'><query xmlns='jabber:iq:register'><username>");
stringbuffer.append(utils.b.b(s2));
stringbuffer.append("</username><password>");
stringbuffer.append(utils.b.b(s3));
stringbuffer.append("</password><nick/>");
if (s1.equals("qq.pica"))
{
stringbuffer.append("<invisible>");
if (Pica.aE)
stringbuffer.append(utils.b.b("yes"));
else
stringbuffer.append(utils.b.b("no"));
stringbuffer.append("</invisible>");
stringbuffer.append("<group>");
if (Pica.aD)
stringbuffer.append(utils.b.b("yes"));
else
stringbuffer.append(utils.b.b("no"));
stringbuffer.append("</group>");
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -