Hi........
I am interested in sending tweets using Java program.I wrote the following prgram.It doen't show any error in compiling.But while executing it shows
"Exception in thread "main" java.lang.NoClassDefFoundError: hi
Caused by: java.lang.ClassNotFoundException: hi
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
Could not find the main class: hi. Program will exit."
This is my code..
package twitter;
//import java.lang.object;
import net.unto.twitter.*;
import net.unto.twitter.TwitterProtos.Status;
public class hi
{
public static void main(String args[])
{
Api api = Api.builder().username("usename").password("password").build();
api.updateStatus("This is a test message.").build().post();
}
}
Can anybody help me ..Pls