Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/session.php on line 1007: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)

Strict Standards: Non-static method utf_normalizer::nfc() should not be called statically in /www/htdocs/w006661d/anddev/includes/utf/utf_tools.php on line 1781
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4362: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4364: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4365: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
[phpBB Debug] PHP Notice: in file /includes/functions.php on line 4366: Cannot modify header information - headers already sent by (output started at /includes/utf/utf_tools.php:1781)
anddev.org • View topic - yahoo messenger client using openymsg...

yahoo messenger client using openymsg...

Problems with WiFi, SQLite ,Bluetooth, WiMax, Proxies, etc...

yahoo messenger client using openymsg...

Postby rmd » Thu Jun 18, 2009 10:38 am

Hi all,

i want to develop a simple client for yahoo messenger on android 1.1. it will use openymsg api. is there anyone who have tried to use openymsg api on android before?
i've tried simple code like this:
Syntax: [ Download ] [ Hide ]
Using java Syntax Highlighting
  1. package com.simple.yahoo;
  2.  
  3. import java.io.IOException;
  4.  
  5. import org.openymsg.network.AccountLockedException;
  6. import org.openymsg.network.LoginRefusedException;
  7. import org.openymsg.network.Session;
  8. import org.openymsg.network.SessionState;
  9.  
  10. import android.app.Activity;
  11. import android.os.Bundle;
  12.  
  13. public class SimpleYahoo extends Activity {
  14.     /** Called when the activity is first created. */
  15.     @Override
  16.     public void onCreate(Bundle savedInstanceState) {
  17.         super.onCreate(savedInstanceState);
  18.         setContentView(R.layout.login_screen);
  19.         Session session = new Session();
  20.        
  21.                 try {
  22.                         session.login("anyuser","anypassword" );
  23.                 } catch (AccountLockedException e) {
  24.                         // TODO Auto-generated catch block
  25.                         e.printStackTrace();
  26.                 } catch (IllegalStateException e) {
  27.                         // TODO Auto-generated catch block
  28.                         e.printStackTrace();
  29.                 } catch (LoginRefusedException e) {
  30.                         // TODO Auto-generated catch block
  31.                         e.printStackTrace();
  32.                 } catch (IOException e) {
  33.                         // TODO Auto-generated catch block
  34.                         e.printStackTrace();
  35.                 }
  36.                 if (session!=null && session.getSessionStatus()== SessionState.LOGGED_ON)
  37.                 {
  38.                         try {
  39.                                 session.sendBuzz("other");
  40.                                 session.sendMessage("other", "testing");
  41.                         } catch (IllegalStateException e) {
  42.                                 // TODO Auto-generated catch block
  43.                                 e.printStackTrace();
  44.                         } catch (IOException e) {
  45.                                 // TODO Auto-generated catch block
  46.                                 e.printStackTrace();
  47.                         }
  48.                        
  49.                         try {
  50.                                 session.logout();
  51.                         } catch (IllegalStateException e) {
  52.                                 // TODO Auto-generated catch block
  53.                                 e.printStackTrace();
  54.                         } catch (IOException e) {
  55.                                 // TODO Auto-generated catch block
  56.                                 e.printStackTrace();
  57.                         }
  58.                 }
  59.     }
  60. }
Parsed in 0.016 seconds, using GeSHi 1.0.8.4


but when i run it from eclipse, it show error codes:
Code: Select all
06-18 16:24:45.989: ERROR/AndroidRuntime(966): ERROR: thread attach failed
06-18 16:24:48.050: ERROR/dalvikvm(977): pthread_setspecific failed, err=22
06-18 16:24:48.389: ERROR/AndroidRuntime(985): Uncaught handler: thread main exiting due to uncaught exception
06-18 16:24:48.409: ERROR/AndroidRuntime(985): java.lang.VerifyError: org.openymsg.network.chatroom.ChatroomManager
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at org.openymsg.network.Session.login(Unknown Source)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at com.simple.yahoo.SimpleYahoo.onCreate(SimpleYahoo.java:22)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1122)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2104)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2157)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.ActivityThread.access$1800(ActivityThread.java:112)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1581)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.os.Handler.dispatchMessage(Handler.java:88)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.os.Looper.loop(Looper.java:123)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at android.app.ActivityThread.main(ActivityThread.java:3739)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at java.lang.reflect.Method.invokeNative(Native Method)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at java.lang.reflect.Method.invoke(Method.java:515)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:739)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:497)
06-18 16:24:48.409: ERROR/AndroidRuntime(985):     at dalvik.system.NativeStart.main(Native Method)


can somebody tell me what was wrong with code above?
thanks...
rmd
Freshman
Freshman
 
Posts: 2
Joined: Thu Jun 18, 2009 9:33 am

Top

Return to Networking & Database Problems

Who is online

Users browsing this forum: No registered users and 4 guests