I'm developing a frameword for handle Actions from Java Swing components;
I would like to know if there is a way of checking if a given method name (that will be accessed by reflections) exists in compile time, and show a compiler error if not?
I want to track the face using web camera in java.
How to do this? can any one tell me the way or else the link on which i can get the information about this?
I i have developed a java web application using spring mvc and used jetty server,
its a intranet application where i want to distribute it to the end user in a form of binary format where user can install the application using installers(please suggest the which one will be suitable ) for windows platform,
my other requirement is i dont want the end user to see the jsp code.
Say I have a MyClass class in Java, is there a way to check in JNI that a jobject is a MyClass[][]?
My initial idea was to use env->IsInstanceOf(myobj, myArrayClass), but calling env->FindClass("[MyClass") throws a NoClassDefFoundError.
I have two Numbers. Eg:
Number a = 2;
Number b = 3;
//Following is an error:
Number c = a + b;
Why arithmetic operations are not supported on Numbers? Anyway how would I add these two numbers in java? (Of course I'm getting them from somewhere and I don't know if they are Integer or float etc).
Is there a way to format a UTC time into any arbitrary string format I want in java? Basically I was thinking of having some class take the timestamp and I pass it is string telling it how I want it formated, and it returns the formatted string for me. Is there a way to do this?
Hi,
I have problem with Runtime.exec() in Java
My code:
String lol = "/home/pc/example.txt";
String[] b = {"touch", lol};
try {
Runtime.getRuntime().exec(b);
} catch(Exception ex) {
doSomething(ex);
}
It's working good but when I trying changle variable "lol" files doesn't create in hard disk
for instance:
String lol = x.getPath(); where getPath() returns String
What should I do ?
Thanks for your reply :)
In Java an anonymous inner class can refer to variables in it's local scope:
public class A {
public void method() {
final int i = 0;
doStuff(new Action() {
public void doAction() {
Console.printf(i); // or whatever
}
});
}
}
My question is how is this actually implemented? How does i get to the anonymous inner doAction implementation, and why does it have to be final?
I am using the Java Robot class to take screenshots, my problem is that in W7 when the UAC dialog is shown (i right click on any application and select run as Admin) it will not appear in the screen shot or the whole screen is just black. Running my application with admin rights or as a service does not solve the problem.
Please, does any one know what to do so that i will be able to capture the screen even when the UAC is showing?
Thanks
hi,
I'm learning the IEEE paper "Monitoring the Application Layer for DDoS Attacks " .
I need to implement HSMM(Hidden Semi Markov Model) Algorithm in Java.
Please help me to do this
Is there a way to manage the window z-ordering of JDialog windows within java?
I would like to able to assign each window to a layer such that windows on lower layers can never go above and obscure windows on higher layers. Even when they have focus. Similar to the Z-order capability that exists for components but for JDialog windows.
The solution does not need to work across all OSes. A linux specific solution is acceptable.
greetings, today i have started to learn java using netbeans ide.
i would like my jframe to display an icon as stated in the following:
setIconImage(Toolkit.getDefaultToolkit().getImage("SartreIcon.jpg"));
the questin is under netbeans ide.. exactly in which folder do i place the graphic in question in order to load it?
thanks.
when I call System.getProperty("java.class.path") I only get this:
/Users/pswenson/dev/sag/gradle-0.8/lib/gradle-core-0.8.jar
The other classes in question are loaded at dynamically. Any ideas on finding the full classpath?
Somewhat related to this question, but in the absence of any answer about QuickBooks specifically, does anyone knows of an address parser for Java. Something that can take unstructured address information and parse out the address line 1, 2 and city state postal code and country?
Hi all,
I have a Java app that has an icon in the system tray.
How can I check if the tray (or tray icon) has current focus?
Tray and TrayIcon don't seem to have .isFocused() or similar.
Is this possible?
Thanks!
hello every one ,
how can i make java program working with multiple languages
(frensh, english , arabic .. etc) ,
i mean i wanna make a comboBox ,when i choose one language, all the labels in the GUI interfaces change to the selected language and even the stdin also change to that language.
thanx in advance
Alaa
For Example in shell script :
_CLASSPATH =.
for jar in lib/*.jar
do
_CLASSPATH=${_CLASSPATH}:${jar}
done
how to build dynamically a Java classpath in Perl ?
Hi,
Can somebody point me to some tutorials and best practices that show to make a build from source code for a java desktop / jee web application ?
I want to learn what needs to be packaged as a war/jar from source and how it must be structured?
br
/jon
I have a Ubuntu Server.
From the terminal, how should I install JDK?
In this guide it says to use this command:
sudo apt-get install sun-java6-bin sun-java6-jre sun-java6-jdk
But on Suns website, it says JDK includes the JRE, so why the JRE in the line above?
Anybody know how to actually install Java?
Every guide and every forum shows different ways of doing it.
BTW: It is a VPS (virtual private server)
Thanks
A simple question: what is the more efficient way to access a db in Java/JDBC?
I'm a web developper and I'd like to write some reusable and scalable code.
What can you suggest?
Hi everyone,
Is it possible to write a GUI in Java that would display Japanese fonts correctly regardless of the language settings of the OS it's being run on?
I'd like to write a program which is able to do this but I'm not sure how to start going about this. Any advice would be a huge help!
write an interface with one method,two classes that implement the interface, and a main method with an array holding an instance from both classes.Using this array variable call the method in a foreach loop.This is a interview question in java anybody?