I would also go for the socket appoach (maybe in combination with the lock). You could make a (small) http server to manage yout daemon(s) in the same way as you can configure / manage a router or any network attached device. Since your daemons are running on several machines, you can administer...
The Observer wrote So, basically, I need to find a way to use getConnection(...) that will either use ONE string parameter for all DBs, or THREE strings parameters for all DBs I want to use with this code. I should be able to pull this info from the ResourceBundle and use one programmatical...
I never used JNI, but I have a question for you.
In class "Example" you have a method
public native int A(String in);
And in class "Ex" you have a method
public native int A(String in);
does that mean that the method is both in library "API2" and in library "API3" ?
Same disclaimer as sedj ...
If you, instead of changing the source code, just extend it (you don't want to change the classes in the jdk anyway), you don't have to pay any license. The client just has to download the jdk or jre from Sun... It's then up to the client if he has to pay any license...
>>I have a table that I need to make sure is updated in a transactionally clean fashion.
>>Meaning only one client can update it at a time.
This is not the same thing. Transactions are used so that updates to multiples files are done to ALL the files or NONE at all.
If you are talking about 1...
Like Stefan Wagner said, you'll have to take a look at java.nio...
e.g. ByteBuffer --> getShort(), getInt(), getLong(), ...
... the bytes will be marshaled to or from the requested primitive data type according to the current byte-order setting in effect for the buffer.
ByteBuffer has a method...
IF you want to do it with EJB, have a look at "Message-Driven Beans" to see if they might be helpfull.
See the EJB articles at : http://www.theserverside.com/articles/index.tss
The reason why the first click on the InternalFrame does not work is because the first click is used to activate/focus on the InternalFrame. A work around could be to add the following :
In the method InternalFrameActivated(), you can do ... whatever you want. On the first mousePress on the...
Your main method is static.
WinCloser is not.
So if you change
class WinCloser extends WindowAdapter
to
class WinCloser extends WindowAdapter
your problem is solved.
What I normally do is get out of the static context as soon as possible :
public static void main(String[] args) {...
I think you have to put a 'try/catch' around every single statement that can throw an exception and just fall through (continue with the statement after the catch block). I don't think there is a "clean" way to jump back.
This is a pure java question, on forum269 you will get more answers faster.
Because, like Ion Filipski says :
'\u0020" is the space character
'\u0032' is the character '2'
If you need "32" then you need two chars, you can't get it in 1 char :
'\u0033' is the character '3'
'\u0032' is the character '2'
You can find the ascii table at : http://www.asciitable.com/
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.