|
JML | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.jqql.QQClient
public class QQClient
A class of QQ clinet, provid a convenient interface to user, for example send message , like that just need invoke a method to implement QQ的客户端类,这个类为用户提供一个方便的接口,比如发送消息之类的,只需要调用一个 方法便可以完成了。 network layer of Luma QQ was implemented by NIO , each Client allocate a Selector, every Selector can listening mulity Channel and channel was package in the implmented class of IPort, for a Client , there is a Main Port ,this one define as a port of connect QQ login server there is a port before login System ,also be Main port, according to require can start other port. LumaQQ网络层通过NIO实现,每个Client分配一个Selector,每个Selector可以监听多个 Channel,channel包装在IPort的实现类中,对于一个Client,有一个Main Port,这个 Main Port定义为连接QQ登陆服务器的那个Port。系统登陆之初之有一个Port即Main Port, 根据需要可以开启其他Port
Field Summary | |
---|---|
protected static SingleExecutor |
executor
singnal thread processor 单线程执行器 |
protected Map<InPacket,String> |
inConn
输入包和port的映射,用来判断一个包来自于哪个port |
protected ScheduledFuture<?> |
keepAliveFuture
|
protected Runnable |
keepAliveTrigger
Keep Alive过程 |
protected Callable<Object> |
packetEventTrigger
包事件触发过程 |
protected static int |
PROCESSOR_COUNT
包处理器数目 |
protected Queue<InPacket> |
receiveQueue
接收队列 |
protected ResendTrigger<Object> |
resendTrigger
重发过程 |
Constructor Summary | |
---|---|
QQClient()
constructor 构造函数 |
Method Summary | |
---|---|
void |
acceptSendFile(int receiver,
int directPort,
char sequence,
boolean udp)
send approve accept file package 发送同意接收文件包 |
void |
activateCluster(int clusterId)
activate cluster 激活群 |
void |
activateTempCluster(byte type,
int clusterId,
int parentClusterId)
activate temp cluster 激活临时群 |
char |
addFriend(int qqNum)
Add afriend 添加一个好友 |
void |
addFriendToList(int group,
int qqNum)
添加好友到服务器端的好友列表中 |
void |
addIncomingPacket(InPacket packet,
String portName)
add a package to queue 添加一个包到接收队列 |
void |
addQQListener(IQQListener listener)
add a qq evnet listening 添加一个QQ事件监听器 |
void |
addResendPacket(OutPacket packet,
String port)
add a package to resend queue 添加一个包到重发队列 |
void |
applyDisk(String localIp)
apply network hard disk 申请网络硬盘 |
void |
approveAddMe(int qqNum)
if i accept the request which a person who add me as friend use this method to send the approve message 如果我要同意一个人加我为好友的请求,用这个方法发送同意消息 |
void |
approveJoinCluster(int clusterId,
int receiver)
Approve join into the cluster 同意加入群 |
void |
authenticateDisk(String localIp,
String nick,
String password)
authenticate network disk 网络硬盘认证 |
void |
batchDownloadFriendRemark(int page)
batch download remark of friend 批量下载好友备注 |
void |
cancelDiskPassword(String localIp,
String oldPassword)
cancel the pass word of network hard disk 取消网络硬盘密码 |
void |
cancelSendFile(int receiver,
char sequence)
cansel transport file 取消发送文件 |
char |
commitMemberOrganization(int clusterId,
List<Member> members)
commit member organized 提交成员组织 |
char |
commitOrganization(int clusterId,
List<QQOrganization> organizations)
commit structure of organized 提交组织架构 |
void |
createDirectory(String localIp,
String name,
int parentId)
create directory 创建目录 |
void |
createFile(String localIp,
String name,
int parentId,
int length)
create file 创建文件 |
void |
createPermanentCluster(String name,
String notice,
String description,
List<Integer> members,
int category,
byte authType)
create a fixed cluster 创建一个固定群 |
char |
createTemporaryCluster(String name,
byte type,
int parentClusterId,
List<Integer> members)
create a temp cluster 创建一个临时群 |
void |
deleteDirectory(String localIp,
int id)
delete directory 删除目录 |
void |
deleteDirectory(String localIp,
String id)
delete directory 删除目录 |
void |
deleteFile(String localIp,
String id)
delete file 删除文件 |
char |
deleteFriend(int qqNum)
delete a friend 删除一个好友 |
void |
deleteShared(String localIp,
int qq)
cancel other share with self 取消某人对自己的共享 |
char |
deleteSignature()
delete the singnature 删除个性签名 |
void |
detectHidden(int receiver)
explore opposite whether is hidden... |
void |
dismissCluster(int clusterId)
dismiss the cluster 解散群 |
void |
downloadFile(String localIp,
int diskOwner,
String fileId,
int offset,
int length)
dowmload file 下载一个文件 |
void |
downloadFriend(int beginFrom)
download the friends groupping 下载好友分组 |
void |
downloadFriendRemark(int qqNum)
download remark information of friend 下载好友备注信息 |
void |
downloadGroup()
download groupping 下载分组名称 |
void |
exitCluster(int clusterId)
exit a cluster 退出一个群 |
void |
exitTempCluster(byte type,
int clusterId,
int parentClusterId)
exit a temp cluster 退出一个临时群 |
void |
finalizeUpload(String localIp,
String id)
finish the upload 结束上传 |
void |
firePacketArrivedEvent(PacketEvent e)
notify the package reach event to package processor 通知包处理器包到达事件 |
void |
fireQQEvent(QQEvent e)
fire QQ event 触发QQ事件 |
String |
generateCrashReport(Throwable e,
Packet p)
when catch a Exceotion , generate a crash report 在程序出现运行时异常时产生一个崩溃报告 |
void |
getCard(int clusterId,
int qq)
get the cluster Card which contain someone who is the member in thr cluster 得到某个成员的群名片 |
void |
getCardBatch(int clusterId,
int start)
batch get the Cards of cluster 批量得到群名片 |
void |
getClusterInfo(int clusterId)
request for information of cluster 请求群的信息 |
void |
getClusterMemberInfo(int clusterId,
List<? extends Object> members)
get the information of member in the cluster 得到群中成员的信息 |
void |
getClusterOnlineMember(int clusterId)
get the online members in the cluster 得到群的在线成员 |
IConnection |
getConnection(InetSocketAddress address)
according the remote address to get a port 根据远程地址得到一个port |
IConnection |
getConnection(String name)
get a port 得到一个端口 |
IConnectionPolicy |
getConnectionPolicy(InPacket in)
get the policy of the input package that relate port 得到和某个输入包相关的端口策略 |
IConnectionPolicyFactory |
getConnectionPolicyFactory()
|
IConnectionPool |
getConnectionPool()
|
IConnectionPoolFactory |
getConnectionPoolFactory()
|
void |
getCustomHeadData(int qq,
int timestamp,
int offset,
int length,
String port)
request get data of the custom head 请求得到自定义头像数据 |
void |
getCustomHeadData(int qq,
int timestamp,
String port)
request get the data of custom head 请求得到自定义头像数据 |
void |
getCustomHeadInfo(List<Integer> qq,
String port)
request gte the information of custom face 请求得到自定义头像信息 |
void |
getDialogList()
requset get the list of muliti dialog 请求得到多人对话列表 |
void |
getDiskServerList(String localIp)
request get the list of network disk server 请求得到网络硬盘服务器列表 |
void |
getFileSize(String localIp,
String id)
get the size of file 得到文件大小 |
void |
getFriendLevel(List<Integer> friends)
get the level of friend 得到好友等级 |
void |
getFriendList()
request to get the friends , if succesful ,will fire the event which are get Friend list success and get friend list end user need to listening the evnets to get all the informations of friend 请求取得好友名单,如果成功,将会触发get friend list success和 get friend list end事件,用户需要监听这两个事件来得到所有的 好友信息 |
void |
getFriendList(char position)
request to get the friend list , the position point to the Offset that is beginning of list, suggest that elementary user do not use the API 请求取得好友名单,position指定了名单开始的偏移,建议初级用户不要使用此API |
void |
getFriendOnline()
get the current online buddy list 请求取得当前在线好友列表 |
void |
getFriendOnline(int startPosition)
get the current online buddy list 请求取得当前在线好友列表 |
String |
getLoginServer()
ip of login server |
IConnectionPool |
getPortGate()
|
int |
getProxyType()
|
IRobot |
getRobot()
|
void |
getSharedDisk(String localIp)
get the share list of network dist 得到共享网络硬盘列表 |
void |
getShareList(String localIp,
int dirId)
get the diretory which the list that share with many friend 得到某个目录对哪些好友共享的列表 |
void |
getSignature(List<Signature> sigs)
get the singnatrue 得到个性签名 |
void |
getSubjectList(int clusterId)
request get the list of discussion 请求得到讨论组列表 |
void |
getTempClusterInfo(byte type,
int clusterId,
int parentClusterId)
request message of temp cluster 请求临时群信息 |
QQUser |
getUser()
|
void |
getUserInfo(int qqNum)
get the detial information of user 得到一个用户的详细信息 |
void |
getUserProperty(char startPosition)
get the property of user 得到用户属性 |
char |
getWeather()
request the weather forecast of self 请求自己这里的天气预报 |
char |
getWeather(byte[] ip)
request weather forecast 请求天气预报 |
boolean |
isEmpty()
|
boolean |
isLogging()
|
boolean |
isRobotMode()
|
char |
joinCluster(int clusterId)
join into cluster 加入群 |
void |
keepAlive()
send keep alive package 发送keep alive包 |
void |
listMyDiskDir(String localIp)
show the directory of my network disk 列我的网络硬盘目录 |
void |
listMyDiskDir(String localIp,
int dirId,
int unknown)
show the directory of my network disk 列我的网络硬盘目录 |
void |
listSharedDiskDir(String localIp,
int diskOwner)
show the share directory of network disk 列共享网络硬盘目录 |
void |
login()
login , use the defaul port 登陆,使用缺省端口 |
protected void |
login(String server,
int p)
use the indicate server and port to login 用指定的服务器和端口登录 |
void |
logout()
exit the QQ dialog 退出QQ会话 |
void |
makeMeAway()
make my statu change to away 使我的状态改变成离开 |
void |
makeMeHidden()
make my statu change to hidden 使我的状态改变为隐身 |
void |
makeMeOnline()
make my statu change to online 使我的状态改变成在线 |
void |
modifyCard(int clusterId,
Card card)
modify Card of cluster 修改群名片 |
char |
modifyClusterInfo(int clusterId,
String name,
String notice,
String description,
int oldCategory,
int category,
byte authType)
modify information of fixed cluster 修改固定群信息 |
char |
modifyClusterMember(int clusterId,
byte operation,
List<Integer> members)
modify member list of cluster 修改群的成员列表 |
void |
modifyInfo(String oldPassword,
String newPassword,
ContactInfo contactInfo)
modify personal information of user 修改用户的个人信息 |
char |
modifySignature(String sig)
modify singnature 修改个性签名 |
char |
modifyTempClusterInfo(byte type,
int clusterId,
int parentClusterId,
String name)
modify information of temp cluster 修改临时群信息 |
char |
modifyTempClusterMember(byte type,
int clusterId,
int parentClusterId,
byte operation,
List<Integer> members)
modify information of temp cluster 修改临时群成员 |
void |
moveDirectory(String localIp,
int id,
int fromId,
int toId)
move directory 移动目录 |
void |
moveFile(String localIp,
String id,
int fromId,
int toId)
move file 移动文件 |
void |
notifyFilePort(int receiver,
int directPort,
byte[] localIp,
int localPort,
char sequence)
senf information package that is notity to port 发送通知端口信息包 |
void |
pleaseConnectMe(int receiver,
int directPort,
char sequence)
request opposite connect to me 请求对方连接我 |
void |
prepareUpload(String localIp,
String id)
ready to uplaod 准备上传 |
void |
qqEvent(QQEvent e)
QQ event, user can get concrete event type from the variable type. |
void |
rejectAddMe(int qqNum,
String message)
if i wanna reject the request which a person wanna add me as friend , invoke this method to send the reject message 如果我要拒绝一个人加我为好友的请求,用这个方法发送拒绝消息 |
void |
rejectJoinCluster(int clusterId,
int receiver,
String message)
reject join the cluster 拒绝加入群 |
void |
rejectSendFile(int receiver,
char sequence,
boolean udp)
send package that is reject received file 发送拒绝接收文件包 |
void |
release()
release the QQClient , if not continute to use the QQClient , must release rhe resource by singleExecutor 释放这个QQClient,如果不继续使用QQClient,则必须释放此客户端以便 SingleExecutor释放资源 |
void |
releaseConnection(String name)
close a port 关闭一个端口 |
void |
removeFriendFromList(int qqNum)
把好友从服务器端的好友列表中删除 |
InPacket |
removeIncomingPacket()
received the first package in the queue , and remove it 从接收队列中得到第一个包,并且把这个包从队列中移除 |
void |
removeQQListener(IQQListener listener)
removed a QQ event listening 移去一个QQ事件监听器 |
void |
removeResendPacket(InPacket packet)
delete a resend package 删除一个重发包 |
void |
removeSelfFrom(int qqNum)
delete self from other's buddy list 把某人的好友列表中的自己删除 |
void |
renameDirectory(String localIp,
int id,
String newName)
rename a directory 重命名一个目录 |
void |
renameDirectory(String localIp,
String id,
String newName)
rename directory 重命名一个目录 |
void |
renameFile(String localIp,
String id,
String newName)
rename file 重命名一个文件 |
char |
replyFaceData(int sessionId,
String port)
reply the data of face which transit server have received 回复中转服务器已经收到表情数据 |
char |
requestAgent(int clusterId,
int imageLength,
byte[] md5,
String fileName,
String port)
request transit server 请求中转服务器 |
char |
requestData(int sessionId,
String port)
request to send the face picture data 请求发送表情图片数据 |
char |
requestFace(int clusterId,
int sessionId,
byte[] key,
String port)
request to get the face picture 请求得到表情图片 |
char |
requestJoinCluster(int clusterId,
String message)
request to join the cluster 请求加入群 |
void |
requestKey(byte request)
request the key 请求密钥 |
char |
requestReceiveBegin(int sessionId,
byte[] key,
String port)
request start to received session 请求开始接收会话 |
void |
requestSendBegin(int sessionId,
byte[] md5,
String port)
request start a session 请求开始一个会话 |
char |
requestSendFile(int receiver,
String filePath,
int fileSize,
int directPort,
boolean udp)
send request package which is transport file , return the package sequence as session sequence 发送传送文件请求包,我们把包序号用作会话序号返回 |
char |
searchClusterById(int externalId)
according external id to search the cluster 根据外部ID搜索群 |
char |
searchDemoCluster()
search the demo cluster 搜索示范群 |
char |
searchUser(int page)
search all the users who is online 搜索所有的在线用户 |
char |
searchUser(int page,
String qqStr,
String nick,
String email)
custom search user 自定义搜索用户 |
char |
searchUserAdvanced(int page,
boolean online,
boolean hasCam,
int provinceIndex,
int cityIndex,
int ageIndex,
int genderIndex)
|
char |
sendAddFriendAuth(int qqNum,
String message)
if the person who we wanna add as friend need authorize ,use this method to send the authenticate request 如果要加的人需要认证,用这个方法发送验证请求 |
void |
sendClusterIM(int clusterId,
String message)
send cluster message 发送群消息 |
void |
sendClusterIM(int clusterId,
String message,
char messageId,
int totalFragments,
int fragmentSequence)
send the message of fixed cluster 发送固定群消息 |
void |
sendClusterIM(int clusterId,
String message,
char messageId,
int totalFragments,
int fragmentSequence,
String fontName,
boolean bold,
boolean italic,
boolean underline,
int fontSize,
int red,
int green,
int blue)
send the message of fixed cluster 发送固定群消息 |
void |
sendIM(int receiver,
byte[] message)
send a message , use the indicate font 发送一个消息,用给定的字体 |
void |
sendIM(int receiver,
byte[] message,
byte replyType)
send a message , can indicate the reply type 发送一条消息,可以指定回复类型 |
void |
sendIM(int receiver,
byte[] message,
char messageId,
int totalFragments,
int fragementSequence,
String fontName,
boolean bold,
boolean italic,
boolean underline,
int size,
int red,
int green,
int blue,
byte replyType)
发送普通消息 |
void |
sendIM(int receiver,
byte[] message,
String fontName,
boolean bold,
boolean italic,
boolean underline,
int size,
int red,
int green,
int blue,
byte replyType)
send a message , indicate the font and color 发送一个消息,指定字体和字体颜色 |
void |
sendPacket(OutPacket packet)
General method , send a package this method use in the complex circs which some construct package , for example the package that upload the information of groupping the source of the data in the package is unknow .. |
void |
sendPacket(OutPacket packet,
String port)
send a pcakage by appoint to the port 通过指定port发送一个包 |
void |
sendPacket(OutPacket packet,
String port,
boolean monitor)
send a pcakage by appoint to the port 通过指定port发送一个包 |
void |
sendPacketAnyway(OutPacket packet,
String port)
no matter whether is loginging , send the package anyway. |
char |
sendSMS(List<String> mobiles,
List<Integer> qq,
String senderName,
byte[] message,
char seq)
send short message 发送短信 |
void |
sendTempClusterIM(byte type,
int clusterId,
int parentClusterId,
String message)
send message of temp cluster 发送临时群消息 |
void |
sendTempClusterIM(byte type,
int clusterId,
int parentClusterId,
String message,
char messageId,
int totalFragments,
int fragmentSequence)
send message of temp cluster 发送临时群消息 |
void |
sendTempClusterIM(byte type,
int clusterId,
int parentClusterId,
String message,
char messageId,
int totalFragments,
int fragmentSequence,
String fontName,
boolean bold,
boolean italic,
boolean underline,
int fontSize,
int red,
int green,
int blue)
send message of temp cluster 发送临时群消息 |
void |
sendTempSessionIM(int receiver,
String message,
String myNick)
send the message of temp session 发送临时会话消息 |
void |
sendTempSessionIM(int receiver,
String message,
String myNick,
String fontName,
boolean bold,
boolean italic,
boolean underline,
int size,
int red,
int green,
int blue)
发送临时会话消息 |
void |
setConnectionPolicyFactory(IConnectionPolicyFactory policyFactory)
|
void |
setConnectionPoolFactory(IConnectionPoolFactory poolFactory)
|
void |
setDiskPassword(String localIp,
String oldPassword,
String newPassword)
set the pass word of network hard disk 设置网络硬盘密码 |
void |
setLogging(boolean logging)
set loginig logo 设置正在登陆标志 |
void |
setLoginRedirect(boolean loginRedirect)
|
void |
setLoginServer(String loginServer)
|
void |
setMemberRole(int clusterId,
int qq,
byte opCode)
set role of member in the cluster 设置群成员角色 |
void |
setProxy(InetSocketAddress proxyAddress)
set proxy server address 设置代理服务器地址 |
void |
setProxyPassword(String password)
|
void |
setProxyType(String type)
set proxy type 设置代理类型 |
void |
setProxyUsername(String username)
|
void |
setRobot(IRobot robot)
|
void |
setRobotMode(boolean robotMode)
set robot statu 设置机器人状态 |
void |
setSearchMeByQQOnly()
set only can find me out by QQ number 设置仅能通过QQ号找到我 |
void |
setTcpLoginPort(int tcpLoginPort)
|
void |
setUser(QQUser user)
|
void |
shareDirectory(String localIp,
int dirId,
List<Integer> remove,
List<Integer> add)
share the directory 共享某个目录 |
void |
shareMyGeography()
share my geographical position 共享我的地理位置 |
char |
transferFaceData(int sessionId,
byte[] fragment,
boolean last,
String port)
send the face file data 传送表情文件数据 |
char |
transferFaceInfo(int sessionId,
int imageLength,
String fileName,
byte[] md5,
String port)
send the face file information 传送表情文件信息 |
void |
transferRole(int clusterId,
int qq)
trnasfer role 转让身份 |
void |
unsetSearchMeByQQOnly()
cancel set only find me out by QQ number 取消设置仅能通过QQ号找到我 |
void |
unshareDirectory(String localIp,
int dirId,
List<Integer> remove,
List<Integer> add)
cansel the direcotry that is share with others 取消共享某个目录 |
void |
unshareMyGeography()
not share my geographical position 不共享我的地理位置 |
void |
updateOrganization(int clusterId)
update structure of organized 更新组织架构 |
void |
uploadFile(String localIp,
String id,
int offset,
int length,
byte[] bytes)
upload file 上传文件 |
void |
uploadFriendRemark(int qqNum,
FriendRemark remark)
upload remark information of friend 上传好友备注信息 |
void |
uploadGroup(List<String> groups)
upload groupping 上传分组名称 |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final SingleExecutor executor
protected Callable<Object> packetEventTrigger
protected ResendTrigger<Object> resendTrigger
protected Runnable keepAliveTrigger
protected ScheduledFuture<?> keepAliveFuture
protected Queue<InPacket> receiveQueue
protected Map<InPacket,String> inConn
protected static final int PROCESSOR_COUNT
Constructor Detail |
---|
public QQClient()
Method Detail |
---|
public IConnectionPolicy getConnectionPolicy(InPacket in)
in
- reply package
回复包
public void setProxyType(String type)
type
- public int getProxyType()
public void setProxy(InetSocketAddress proxyAddress)
proxyAddress
- public void keepAlive()
public void shareMyGeography()
public void unshareMyGeography()
public void setSearchMeByQQOnly()
public void unsetSearchMeByQQOnly()
public char getWeather(byte[] ip)
ip
- public char getWeather()
ip
- public void uploadFriendRemark(int qqNum, FriendRemark remark)
qqNum
- QQ number of friend
好友的QQ号remark
- public void downloadFriendRemark(int qqNum)
qqNum
- QQ number of friend
好友的QQ号public void batchDownloadFriendRemark(int page)
page
- sequencepublic char searchUserAdvanced(int page, boolean online, boolean hasCam, int provinceIndex, int cityIndex, int ageIndex, int genderIndex)
page
- online
- hasCam
- provinceIndex
- cityIndex
- ageIndex
- genderIndex
-
public char searchUser(int page)
page
- sequence ,start 0
public char searchUser(int page, String qqStr, String nick, String email)
page
- sequenceqqNum
- Stringnick
- nickname of we wanna search the QQ useremail
- matchEntire
- whether mathc the entire string
public char addFriend(int qqNum)
qqNum
- qq number who we wanna add
public char deleteFriend(int qqNum)
qqNum
-
public void removeSelfFrom(int qqNum)
qqNum
- we wanna delete self in the other's buddy listpublic void removeFriendFromList(int qqNum)
qqNum
- 要删除的好友QQ号public void addFriendToList(int group, int qqNum)
group
- 好友的组号,我的好友组是0,然后是1,2,...qqNum
- 要添加的好友QQ号public char sendAddFriendAuth(int qqNum, String message)
qqNum
- qq number of person who we wanna add as friendmessage
- the request addistional message
public void detectHidden(int receiver)
public char requestSendFile(int receiver, String filePath, int fileSize, int directPort, boolean udp)
filePath
- the file name , but not caontian the pathfileSize
- directPort
- udp
- true indicate by UDP
public void cancelSendFile(int receiver, char sequence)
receiver
- sequence
- public void acceptSendFile(int receiver, int directPort, char sequence, boolean udp)
receiver
- directPort
- my directPortsequence
- the sequence of sessionudp
- true indicate by UDPpublic void rejectSendFile(int receiver, char sequence, boolean udp)
receiver
- sequence
- session seqenceudp
- true indicate UDP , else TCPpublic void notifyFilePort(int receiver, int directPort, byte[] localIp, int localPort, char sequence)
receiver
- directPort
- localIp
- localPort
- sequence
- public void pleaseConnectMe(int receiver, int directPort, char sequence)
receiver
- directPort
- sequence
- public void rejectAddMe(int qqNum, String message)
qqNum
- the qq number of a person who wanna add me as friendthe
- additional messagepublic void approveAddMe(int qqNum)
qqNum
- the qq number of someone who wanna add me as friendpublic void downloadFriend(int beginFrom)
beginFrom
- the number where is begin from
起始好友号public void uploadGroup(List<String> groups)
groups
- public void downloadGroup()
public char createTemporaryCluster(String name, byte type, int parentClusterId, List<Integer> members)
name
- cluster's nametype
- type of the temp clusterparentClusterId
- inner ID of parent cluster
父群内部IDmembers
-
public void createPermanentCluster(String name, String notice, String description, List<Integer> members, int category, byte authType)
name
- cluster's namenotice
- notice of clusterdescription
- description of clustermembers
- members in the clusterauthType
- the type of authentication in the clustercategory
- assort clusterspublic void getClusterInfo(int clusterId)
clusterId
- cluster inner ID
群内部IDpublic void setMemberRole(int clusterId, int qq, byte opCode)
clusterId
- cluster inner ID
群内部idqq
- the member that is need to set
需要设置的成员opCode
- Operatoin codepublic void transferRole(int clusterId, int qq)
clusterId
- cluster inner ID
群内部idqq
- who you wanna transfer the role topublic void getCardBatch(int clusterId, int start)
clusterId
- start
- public void getCard(int clusterId, int qq)
clusterId
- qq
- public void modifyCard(int clusterId, Card card)
clusterId
- card
- public void updateOrganization(int clusterId)
clusterId
- cluster inner ID
群内部IDpublic char commitOrganization(int clusterId, List<QQOrganization> organizations)
clusterId
- organizations
- public char commitMemberOrganization(int clusterId, List<Member> members)
clusterId
- members
-
public void getTempClusterInfo(byte type, int clusterId, int parentClusterId)
type
- clusterId
- parentClusterId
- public void getClusterOnlineMember(int clusterId)
clusterId
- public void activateCluster(int clusterId)
clusterId
- public void activateTempCluster(byte type, int clusterId, int parentClusterId)
type
- clusterId
- parentClusterId
- public void getClusterMemberInfo(int clusterId, List<? extends Object> members)
clusterId
- the inner ID of clustermembers
- QQ number list of member, the type of elemnet is Inreger or Member
成员的QQ号列表,元素类型是Integer或者Memberpublic char modifyClusterMember(int clusterId, byte operation, List<Integer> members)
clusterId
- operation
- Typemembers
-
public char modifyTempClusterMember(byte type, int clusterId, int parentClusterId, byte operation, List<Integer> members)
type
- of temp clusterclusterId
- of temp cluster
临时群idparentClusterId
- 父群IDoperation
- type of operattionmembers
- 成员QQ号数组
public char modifyClusterInfo(int clusterId, String name, String notice, String description, int oldCategory, int category, byte authType)
clusterId
- cluster Inner IDname
- of clusternotice
- of clusterdescription
- of clusteroldCategory
- cluster category at the old version 2004category
- authType
- authorize type of cluster
public char modifyTempClusterInfo(byte type, int clusterId, int parentClusterId, String name)
type
- clusterId
- parentClusterId
- name
-
public char sendSMS(List<String> mobiles, List<Integer> qq, String senderName, byte[] message, char seq)
mobiles
- the moblie number of receiver
接受者的手机号码qq
- the qq number of receiver
接受者的QQ号码senderName
- 发送者名称message
- 消息字节数组seq
- sequence of message
消息序号
public void sendClusterIM(int clusterId, String message)
clusterId
- the inner id of clustermessage
- message content
消息内容public void sendClusterIM(int clusterId, String message, char messageId, int totalFragments, int fragmentSequence)
clusterId
- the inner id of cluster
群内部IDmessage
- 消息messageId
- 消息idtotalFragments
- the number of total fragments
分片数fragmentSequence
- 分片序号public void sendClusterIM(int clusterId, String message, char messageId, int totalFragments, int fragmentSequence, String fontName, boolean bold, boolean italic, boolean underline, int fontSize, int red, int green, int blue)
clusterId
- message
- messageId
- totalFragments
- fragmentSequence
- fontName
- bold
- italic
- underline
- fontSize
- red
- green
- blue
- public void sendTempClusterIM(byte type, int clusterId, int parentClusterId, String message)
type
- type is temp cluster
临时群类型clusterId
- inner id of cluster
群内部idparentClusterId
- 父群idmessage
- 消息public void sendTempClusterIM(byte type, int clusterId, int parentClusterId, String message, char messageId, int totalFragments, int fragmentSequence)
type
- type is temp cluster
临时群类型clusterId
- inner id of cluster
群内部idparentClusterId
- 父群idmessage
- 消息messageId
- 消息idtotalFragments
- number of total fragments
分片数fragmentSequence
- 分片序号public void sendTempClusterIM(byte type, int clusterId, int parentClusterId, String message, char messageId, int totalFragments, int fragmentSequence, String fontName, boolean bold, boolean italic, boolean underline, int fontSize, int red, int green, int blue)
type
- clusterId
- parentClusterId
- message
- messageId
- totalFragments
- fragmentSequence
- fontName
- bold
- italic
- underline
- fontSize
- red
- green
- blue
- public void exitCluster(int clusterId)
clusterId
- inner id of cluster
群内部IDpublic void dismissCluster(int clusterId)
clusterId
- public void exitTempCluster(byte type, int clusterId, int parentClusterId)
type
- clusterId
- parentClusterId
- public char searchClusterById(int externalId)
externalId
- external id of cluster
群的外部ID
public char searchDemoCluster()
public char joinCluster(int clusterId)
clusterId
-
public char requestJoinCluster(int clusterId, String message)
clusterId
- inner id of cluster
群内部IDmessage
- addtional message of request
请求的附加信息
public void approveJoinCluster(int clusterId, int receiver)
clusterId
- public void rejectJoinCluster(int clusterId, int receiver, String message)
clusterId
- message
- public void modifyInfo(String oldPassword, String newPassword, ContactInfo contactInfo)
oldPassword
- the old pass word , if do not changed it ,set it null
老密码,如果不修改密码,设成nullnewPassword
- the new pass word, if do not changed it ,set it null
新密码,如果不修改密码,设成nullcontactInfo
- other information
其他信息public char modifySignature(String sig)
sig
- singnature
个性签名public char deleteSignature()
public void getSignature(List<Signature> sigs)
sigs
- public void getFriendLevel(List<Integer> friends)
friends
- public void getUserInfo(int qqNum)
qqNum
- the number of user that we wanna get
想要得到的用户QQ号public void getFriendList()
public void getFriendList(char position)
position
- public void getFriendOnline()
public void getFriendOnline(int startPosition)
public void getUserProperty(char startPosition)
startPosition
- public void makeMeOnline()
public void makeMeAway()
public void makeMeHidden()
public void requestKey(byte request)
request
- public void getDialogList()
public void getSubjectList(int clusterId)
clusterId
- cluster Idpublic void sendPacket(OutPacket packet)
packet
- sub class of the OutPacket
OutPacket子类public void sendPacket(OutPacket packet, String port)
packet
- port
- public void sendPacket(OutPacket packet, String port, boolean monitor)
packet
- output package object
输出包对象port
- port name
port名称monitor
- true mean add to listening buffer of package
true表示加入到包监视缓冲public void sendPacketAnyway(OutPacket packet, String port)
packet
- port
- public String getLoginServer()
public QQUser getUser()
public void addQQListener(IQQListener listener)
listener
- QQListenerpublic void removeQQListener(IQQListener listener)
listener
- QQListenerpublic void fireQQEvent(QQEvent e)
e
- QQEventpublic void login() throws Exception
Exception
- if login occur error ,throw the Exception
如果登录出错protected void login(String server, int p) throws Exception
server
- login serverp
- the port for login
Exception
- if login occur error ,throw the Exception
如果登录出错public void logout()
public void release()
public void qqEvent(QQEvent e)
IQQListener
qqEvent
in interface IQQListener
e
- QQEventpublic void sendTempSessionIM(int receiver, String message, String myNick)
receiver
- message
- public void sendTempSessionIM(int receiver, String message, String myNick, String fontName, boolean bold, boolean italic, boolean underline, int size, int red, int green, int blue)
receiver
- message
- fontName
- bold
- italic
- underline
- size
- red
- green
- blue
- public void sendIM(int receiver, byte[] message)
receiver
- the qq number of receiver
接受者QQ号message
- 消息fontName
- 字体public void sendIM(int receiver, byte[] message, byte replyType)
receiver
- the qq number of receiver
接收者QQ号message
- 消息fontName
- 字体名replyType
- reply type , normal or automatic
回复方式,正常回复还是自动回复public void sendIM(int receiver, byte[] message, String fontName, boolean bold, boolean italic, boolean underline, int size, int red, int green, int blue, byte replyType)
receiver
- 接受者QQ号message
- 消息fontName
- 字体bold
- 是否粗体italic
- 是否斜体underline
- 是否下划线size
- 字体大小,最大是31red
- 颜色Redgreen
- 颜色Greenblue
- 颜色BluereplyType
- reply type , normal or automatic
回复类型,自动回复还是正常回复public void sendIM(int receiver, byte[] message, char messageId, int totalFragments, int fragementSequence, String fontName, boolean bold, boolean italic, boolean underline, int size, int red, int green, int blue, byte replyType)
receiver
- message
- messageId
- totalFragments
- fragementSequence
- fontName
- bold
- italic
- underline
- size
- red
- green
- blue
- replyType
- public void setLoginServer(String loginServer)
loginServer
- the ip string of login server
登陆服务器IPpublic void setUser(QQUser user)
user
- The user to set.public boolean isLogging()
public void setProxyPassword(String password)
password
- The password to set.public void setProxyUsername(String username)
username
- The username to set.public void setLoginRedirect(boolean loginRedirect)
loginRedirect
- The loginRedirect to set.public void setTcpLoginPort(int tcpLoginPort)
tcpLoginPort
- The tcpLoginPort to set.public boolean isRobotMode()
public void setRobotMode(boolean robotMode)
robotMode
- public void setLogging(boolean logging)
logging
- public void addIncomingPacket(InPacket packet, String portName)
packet
- public InPacket removeIncomingPacket()
public boolean isEmpty()
public void firePacketArrivedEvent(PacketEvent e)
e
- public IConnectionPool getPortGate()
public void removeResendPacket(InPacket packet)
packet
- public void addResendPacket(OutPacket packet, String port)
packet
- port
- public void releaseConnection(String name)
name
- port name
端口名称public IConnection getConnection(String name)
name
- port name
端口名
public IConnection getConnection(InetSocketAddress address)
address
- romote port address
端口远程地址
public char requestAgent(int clusterId, int imageLength, byte[] md5, String fileName, String port)
clusterId
- inner id of cluster
群内部IDimageLength
- length of image
图片大小md5
- md5 of image
图片md5port
- port name
端口名称
public void requestSendBegin(int sessionId, byte[] md5, String port)
sessionId
- id of session
会话idport
- port name
端口名称public char requestReceiveBegin(int sessionId, byte[] key, String port)
sessionId
- key
- port
-
public char requestData(int sessionId, String port)
port
-
public char replyFaceData(int sessionId, String port)
sessionId
- port
-
public char transferFaceInfo(int sessionId, int imageLength, String fileName, byte[] md5, String port)
sessionId
- imageLength
- fileName
- md5
- port
-
public char transferFaceData(int sessionId, byte[] fragment, boolean last, String port)
sessionId
- fragment
- last
- port
-
public char requestFace(int clusterId, int sessionId, byte[] key, String port)
clusterId
- sessionId
- agentToken
- key
-
public void getCustomHeadInfo(List<Integer> qq, String port)
qq
- qq number list of request
请求的QQ号列表port
- send port
发送端口名public void getCustomHeadData(int qq, int timestamp, String port)
qq
- timestamp
- port
- public void getCustomHeadData(int qq, int timestamp, int offset, int length, String port)
qq
- timestamp
- offset
- length
- port
- public void getDiskServerList(String localIp)
localIp
- public void authenticateDisk(String localIp, String nick, String password)
localIp
- 本地ipnick
- 昵称password
- 密码,如果没有密码,置为nullpublic void getSharedDisk(String localIp)
localIp
- public void listSharedDiskDir(String localIp, int diskOwner)
localIp
- diskOwner
- public void listMyDiskDir(String localIp)
localIp
- public void listMyDiskDir(String localIp, int dirId, int unknown)
localIp
- dirId
- public void setDiskPassword(String localIp, String oldPassword, String newPassword)
localIp
- oldPassword
- newPassword
- public void cancelDiskPassword(String localIp, String oldPassword)
localIp
- oldPassword
- public void downloadFile(String localIp, int diskOwner, String fileId, int offset, int length)
localIp
- diskOwner
- fileId
- offset
- length
- public void renameFile(String localIp, String id, String newName)
localIp
- id
- newName
- public void renameDirectory(String localIp, int id, String newName)
localIp
- id
- newName
- public void renameDirectory(String localIp, String id, String newName)
localIp
- id
- newName
- public void deleteFile(String localIp, String id)
localIp
- id
- public void deleteDirectory(String localIp, int id)
localIp
- id
- public void deleteDirectory(String localIp, String id)
localIp
- id
- public void deleteShared(String localIp, int qq)
localIp
- qq
- public void createDirectory(String localIp, String name, int parentId)
localIp
- name
- parentId
- public void createFile(String localIp, String name, int parentId, int length)
localIp
- name
- parentId
- length
- public void moveFile(String localIp, String id, int fromId, int toId)
localIp
- id
- fromId
- toId
- public void moveDirectory(String localIp, int id, int fromId, int toId)
localIp
- id
- fromId
- toId
- public void uploadFile(String localIp, String id, int offset, int length, byte[] bytes)
localIp
- id
- offset
- length
- bytes
- public void finalizeUpload(String localIp, String id)
localIp
- id
- public void prepareUpload(String localIp, String id)
localIp
- id
- public void getFileSize(String localIp, String id)
localIp
- id
- public void getShareList(String localIp, int dirId)
localIp
- dirId
- public void shareDirectory(String localIp, int dirId, List<Integer> remove, List<Integer> add)
localIp
- dirId
- remove
- add
- public void unshareDirectory(String localIp, int dirId, List<Integer> remove, List<Integer> add)
localIp
- dirId
- remove
- add
- public void applyDisk(String localIp)
localIp
- public void setRobot(IRobot robot)
robot
- The robot to set.public IRobot getRobot()
public String generateCrashReport(Throwable e, Packet p)
e
- exceptoin object
异常对象p
- package object
包对象
public IConnectionPolicyFactory getConnectionPolicyFactory()
public void setConnectionPolicyFactory(IConnectionPolicyFactory policyFactory)
policyFactory
- the policyFactory to setpublic IConnectionPool getConnectionPool()
public IConnectionPoolFactory getConnectionPoolFactory()
public void setConnectionPoolFactory(IConnectionPoolFactory poolFactory)
poolFactory
- the poolFactory to set
|
JML | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |