|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Thread | +--rath.msnm.AbstractProcessor
°¢ DS, NS, SSÀÇ °øÅëÀÌ µÇ´Â ºÎºÐÀ» Ãß»óÀûÀ¸·Î ¹¾î³õÀº Ŭ·¡½ºÀÌ´Ù.
Âü°í·Î ÇØ´ç Processor´Â Á×±âÀü¿¡ ¹«Á¶°Ç OUTÀ» º¸³½´Ù. º¸³»Áö ¾Ê°Ô ÇÏ·Á¸é setAutoOutSend(false) ¸¦ Ç϶ó.
Field Summary | |
protected HashMap |
callbackMap
|
protected BufferedReader |
in
|
protected boolean |
isLive
|
MSNMessenger |
msn
|
protected PrintWriter |
out
|
protected Socket |
socket
|
Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
protected |
AbstractProcessor(MSNMessenger msn)
Client processor°¡ ¾Æ´Ñ Server processor·Î »ç¿ëÇÒ¶§ Áï, ServerInfo°¡ ÇÊ¿ä¾øÀ»¶§ ÀÌ »ý¼ºÀÚ¸¦ ÅëÇÏ¿© ÀνºÅϽº¸¦ »ý¼ºÇϵµ·Ï ÇÑ´Ù. |
protected |
AbstractProcessor(MSNMessenger msn,
ServerInfo info)
ÁÖ¾îÁø ServerInfo¸¦ °¡Áö´Â Processor¸¦ »ý¼ºÇÑ´Ù. |
protected |
AbstractProcessor(MSNMessenger msn,
ServerInfo info,
int trId)
ÁÖ¾îÁø ServerInfo¸¦ °¡Áö°í trId¸¦ ÃÖÃÊ Æ®·£Àè¼Ç ¾ÆÀ̵ð·Î °¡Áö´Â Processor¸¦ »ý¼ºÇÑ´Ù. |
Method Summary | |
abstract void |
cleanUp()
½º·¹µå°¡ Á¾·áµÇ°í ½ºÆ®¸²À» ´Ý±â Á÷Àü¿¡ È£ÃâµÈ´Ù. |
int |
getCurrentTransactionId()
´ÙÀ½¿¡ Àü¼ÛµÇ¾î¾ßÇÒ trId¸¦ ¹ÝȯÇÑ´Ù. |
String |
getServerName()
|
abstract void |
init()
¼¹ö¿ÍÀÇ ¿¬°áÀÌ ¸Î¾îÁø ÈÄ ÇØÁÖ¾î¾ß ÇÒ ÀÏÀÌ ÀÖ´Ù¸é ÀÌ°÷¿¡ ÇØÁÖµµ·Ï ÇÑ´Ù. |
boolean |
isAutoOutSend()
ÇØ´ç processor°¡ Á¾·áµÉ¶§ OUT ¸Þ½ÃÁö¸¦ ÀÚµ¿Àü¼ÛÇÏ°Ô µÇ¾îÀÖ´ÂÁö È®ÀÎÇÑ´Ù. |
protected Method |
lookupMethod(Callback cb)
|
protected void |
makeConnection()
ÇØ´ç server¿Í tcp/ip ¿¬°áÀ» ¸Î°í, ÀÔÃâ·Â ½ºÆ®¸²µéÀ» »ý¼ºÇÑ´Ù. |
void |
markTransactionId(OutgoingMessage msg)
ÇØ´ç ¸Þ½ÃÁö¿¡ ÀûÀýÇÑ trId¸¦ ¼³Á¤ÇØÁØ´Ù. |
void |
processError(Throwable e)
ÇØ´ç Processor¿¡¼ ¹ß»ýµÇ´Â ¸ðµç ¿¹¿Ü´Â ÀÌ°÷¿¡¼ ó¸®ÇÑ´Ù. |
void |
processMessage(IncomingMessage msg)
¼¹ö·ÎºÎÅÍ µµÂøÇÏ´Â ¸Þ½ÃÁö (ÀϹæÀûÀÎ push°¡ ¾Æ´Ñ)¸¦ ó¸®ÇÏ´Â ºÎºÐÀÌ´Ù. |
void |
processNotifyMessage(IncomingMessage msg)
Server·ÎºÎÅÍ ÀϹæÀûÀ¸·Î notifyµÇ´Â ¸Þ½ÃÁöµéÀ» ó¸®ÇÏ´Â ºÎºÐÀÌ´Ù. |
protected void |
registerCallback(Integer trId,
Callback cb)
¼öµ¿À¸·Î callbackÀ» µî·Ï½ÃŲ´Ù. |
void |
removeInfiniteTransactionId(int trId)
¹«ÇÑ Callback ÀÌ¿´´ø trId¿¡ ´ëÇØ Á¾·á½ÃÁ¡ÀÌ µÇ¸é ÀÌ ¸Þ¼Òµå¸¦ ÅëÇØ ´õÀÌ»ó callback map¿¡ Á¸ÀçÇÏÁö ¾Êµµ·Ï ÇØÁ¦ÇÏ¿©¾ß ÇÑ´Ù. |
void |
run()
Thread loop ºÎºÐ |
void |
sendCHLResponse(OutgoingMessage msg,
String hash)
|
void |
sendMessage(OutgoingMessage msg)
º¸³»°íÀÚ ÇÏ´Â ¸Þ½ÃÁö¸¦ Àü¼ÛÇÏ°í, trId¸¦ Çϳª Áõ°¡½ÃŲ´Ù. |
void |
sendMimeMessage(OutgoingMessage msg,
MimeMessage mime)
MIME¸Þ½ÃÁö¸¦ º¸³¾ ¶§ »ç¿ëÇÑ´Ù. |
void |
setAutoOutSend(boolean autoOut)
ÇØ´ç processor°¡ Á¾·áµÉ¶§ OUT ¸Þ½ÃÁö¸¦ ÀÚµ¿Àü¼ÛÇÒ °ÍÀÎÁö ¼³Á¤ÇÑ´Ù. |
void |
setServerName(String name)
|
Methods inherited from class java.lang.Thread |
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getContextClassLoader, getName, getPriority, getThreadGroup, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setName, setPriority, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public final MSNMessenger msn
protected HashMap callbackMap
protected Socket socket
protected boolean isLive
protected BufferedReader in
protected PrintWriter out
Constructor Detail |
protected AbstractProcessor(MSNMessenger msn)
protected AbstractProcessor(MSNMessenger msn, ServerInfo info)
protected AbstractProcessor(MSNMessenger msn, ServerInfo info, int trId)
Method Detail |
public void setServerName(String name)
public String getServerName()
public void setAutoOutSend(boolean autoOut)
public boolean isAutoOutSend()
protected void makeConnection() throws IOException
IOException
public abstract void init() throws IOException
IOException
public void sendMessage(OutgoingMessage msg) throws IOException
IOException
public void sendMimeMessage(OutgoingMessage msg, MimeMessage mime) throws IOException
IOException
public void sendCHLResponse(OutgoingMessage msg, String hash) throws IOException
IOException
public void markTransactionId(OutgoingMessage msg)
public int getCurrentTransactionId()
protected Method lookupMethod(Callback cb) throws NoSuchMethodException, SecurityException
NoSuchMethodException
SecurityException
protected void registerCallback(Integer trId, Callback cb)
public void processMessage(IncomingMessage msg) throws Exception
Exception
public void processNotifyMessage(IncomingMessage msg) throws Exception
Exception
public void removeInfiniteTransactionId(int trId)
public final void run()
run
in interface Runnable
run
in class Thread
public abstract void cleanUp()
public void processError(Throwable e)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |