What is the proper way to set a timer in android in order to kick off a task (a function that I create which does not change the UI)?
Use this the Java way:
Or there is a better way in android (android's handler)?
You may consider using the very convenient Handler class (android.os.Handler) and send messages to the handler via
sendMessageAtTime(android.os.Message, long) or
sendMessageDelayed(android.os.Message, long). Once you receive a message, you can run desired tasks. Second option would be to create a Runnable object and schedule it via Handler's functions
postAtTime(java.lang.Runnable, long) or