Listen to a port that is in use
Possible Duplicate: Get connecting IP from specified ports that using by other program. If a port is used by a program, is there any way I can listen that port and get the connected IP on that port? ...
Possible Duplicate: Get connecting IP from specified ports that using by other program. If a port is used by a program, is there any way I can listen that port and get the connected IP on that port? ...
My listener is filling Cache (Terracota) and if something goes wrong at application start, ExceptionInInitializerError is thrown. I would like to get server name (like on HttpServletRequest - getServerName()) to know where this happened. How can I come to this information?? import javax.servlet.ServletContextEvent; import net.f.core.s...
Hi, I am working on a Widget which will get the Current GPS location and pass this value to remote PHP page to get the Information and display it in the Widget. This is what I am trying to do. I am facing problem while implementing Location Listener for appWidget. It is not updating with the Current Location and It is showing the initi...
I have a listener inside Class A, and I want to pass Class A to my Class B inside the listener. Normally I'd just use this, but then I'd get the event that triggered the listener. ...
I'm writing an application and need some help with consistently storing and loading preferences related to certain resources. Let me give an example. Suppose I have 10 spinners. They all have the same functionality but different meaning. Because they have the same functionality, I can bind them to the same onItemSelectedListener, which ...
I'm working on my first Android project, and I created a menu via the XML method. My activity is pretty basic, in that it loads the main layout (containing a ListView with my String array of options). Here's the code inside my Activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentV...
Are there any exemplary examples of the GoF Observer implemented in Python? I have a bit code which currently has bits of debugging code laced through the key class (currently generating messages to stderr if a magic env is set). Additionally, the class has an interface for incrementally return results as well as storing them (in memory...
Hey Guys This time my question is rather short: Is it possible to add to the Softkeyboard an OnTouchListener? Like u can do it for an ordinary EditText field. Or is there any other way to implement an OnTouchListener above the Softkeyboard? Thanks in advance Ripei ...
Hi all, I attached a listener to the Shell on SWT.MouseUp and SWT.MouseDown events, but the handleEvent method never gets fired. I tried clicking at many places on the window, but it doesn't get even to the System.out.println(..) in the code below... Do you spot any error here? Thank you! //c is a Composite. final Listener l = new L...
Is there a better way to have a listener on a java collection than wrap it in a class implementing the observer pattern ? ...
in a simplified version, what i have is this: public class MyLabel extends JLabel implements MouseListener{ private SomeControl control; public MyLabel(SomeControl control){ this.addMouseListener(this); this.control = control; } @Override public void mouseClicked(MouseEvent arg0) { Object x = this.control.getSomeProperty(); } Eve...
Hi, I'm willing to make a isometric game but I'm having hard time with the mouseListener. I'm using Swing and make losanges by using square images with transparent pixels (GIF format). The problem is that making losanges touch each other edge means having the transparent pixels of one on the top of the others, which is a problem with ...
I am using onKeyListener to get the onKey events. It works fine with the normal keyboard. But it does not work with soft keyboard. I am only able to get onKey events for numerics and not alphabets. Is there any workaround to solve this? Any kind of help will be greatly appreciated. ...
I want to bind a JPA EntityManager to the current thread on each request (via ThreadLocal), what could be done via a ServletRequestListener or Filter. The listener looks cleaner and I don't need the additional possibilities of a filter in this case. But maybe the filter has an advantage I've missed. Should I use a Servlet Filter or a Se...
I am using a simple EditText and register an View.OnKeyListener. Some GUI changes should happen (fading in/out of views) when certain conditions for the EditView text apply. In the emulator, this works as expected. On the Motorola Droid/Milestone, the listener does not work, only after pressing DEL, the listener is called the first ti...
Is there a way to interfere between the blackberry keyboard input and the key events that reach the foreground application? i.e. what we want to do is build a predictive keyboard functionality to be used on any application that needs keyboard input (like textboxes, emails, etc.), so we need to: 1) get the keys that are pressed 2) present...
Hi , I use Eclipse with Websphere server . I need to add a session listener . I added the class SessionListener.java in the package net.test . When I add the < listener > tag to the web.xml file , I get the folowing error : Distribution of configuration failed. See log for details. Error unmarshaling return; nested exception is: ...
Requirement I'm using PRISM for developing a financial application. Our requirement is to be able to communicate across modules/process/machine boundaries. For our first delivery we only want to be able to communicate between modules. However, we want to build a design which can be extended to cross-process/machine at a later stage wi...
I have a program that uses the SD card, so I want to be informed if the state of the card changes by registering a listener if possible. I'm aware of the Environment class and its methods, but I don't really want to be constantly polling the state. I'd rather not have my program force close when running cause someone mounted the sd card ...
Can i set a mouselistener (Clicked) in WPF? ...