Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Accessing Socket in actionPerformed function

 
Realm Head
Greenhorn
Posts: 1
Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a Main class that creates the Socket object, and a UserLogin class that has a GUI to get some text as input.
My problem is that I am not able to access the same Socket object within the actionPerformed function of UserLogin.
I mean s.isClosed() returns TRUE within submitActionPerformed(ActionEvent ae)

I tried to solve it by making it final... but didn't work.



 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic