Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Programming > Java Programmer > Re: Easily impl...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 2 of 5 Topic 52661 of 55513
Post > Topic >>

Re: Easily implementing a Timer

by ram@[EMAIL PROTECTED] (Stefan Ram) May 12, 2008 at 11:57 AM

"DaveN" <DaveN@[EMAIL PROTECTED]
> writes:
>void MainFunction()

  In Java, »function« usually does not have the implied meaning.

  Class declarations contain /method/ declarations.

>if(UserMakesStartSelection == 1)

  The user should not be able to create multiple timers in
  parallel this way. Also, user events often are trans****ted as
  invocations, so often one will not use »if«, but an event
  handling method.

>void TimerFunctionToCall()

  To be able to designate a method as an argument value (as
  above), it needs to be wrapped in some object. There are no
  method references in Java - only object references. And method
  names usually start with a lower-case letter.

>All the examples I've seen seem to have these functions all
>wrapped together in a class which makes it difficult to
>understand and follow.  Like I say it's probably my lack of OOP
>but if anyone can help to clear the muddy waters I would
>appreciate it.

  You do not need to learn OOP (as in Smalltalk), it is
  sufficient to learn Java. Possibly, start with the
  fundamentals and then read approach more complicated topics
  later.

  1st step: Learn about invocations of operations (methods)
  including argument passing, learn to use standard types
  (primitive types, cl***** and interfaces including standard
  methods), learn to read JavaDocs, learn the terms. take some
  time for exercises. Take care to learn the difference between
  static and non-static operations (AKA methods).

  2nd step: Learn how to write and use declarations for
  variables, methods, cl*****, interfaces, and JavaDoc.  Do more
  exercises.

  3rd step: Learn fundamentals of Swing (like the EDT and the
  delegation event model) and something about threads.  Learn
  some common patterns, like »Observer«.
 




 5 Posts in Topic:
Easily implementing a Timer
"DaveN" <Dav  2008-05-12 12:29:09 
Re: Easily implementing a Timer
ram@[EMAIL PROTECTED] (S  2008-05-12 11:57:57 
Re: Easily implementing a Timer
Roedy Green <see_websi  2008-05-12 12:50:49 
Re: Easily implementing a Timer
"DaveN" <Dav  2008-05-12 23:33:23 
Re: Easily implementing a Timer
"DaveN" <Dav  2008-05-13 00:09:18 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Wed Dec 3 18:28:52 CST 2008.