Microsoft SDK for Java

Timer Class Constructors

The Timer Class contains the following constructors:

Timer(long p)
Timer(long p, int id)
Timer(long p, boolean r)
Timer(long p, int id, boolean r)
Timer(TimerListener defaultListener, long p)
Timer(TimerListener defaultListener, long p, int id)
Timer(TimerListener defaultListener, long p, boolean r)
Timer(TimerListener defaultListener, long p, int id, boolean r)
Timer(TaskManager tm, long p)
Timer(TaskManager tm, long p, int id)
Timer(TaskManager tm, long p, boolean r)
Timer(TaskManager tm, long p, int id, boolean r)
Timer(TaskManager tm, TimerListener defaultListener, long p)
Timer(TaskManager tm, TimerListener defaultListener, long p, int id)
Timer(TaskManager tm, TimerListener defaultListener, long p, boolean r)
Timer(TaskManager tm, TimerListener defaultListener, long p, int id, boolean r)

Timer(long p)

Constructs a one-shot timer with the specified period (in milliseconds).

Syntax

public Timer(long p);

Parameters

p The initial period of the timer.

Timer(long p, int id)

Constructs a one-shot timer with a specific period (in milliseconds) and that includes a user-defined identifier.

Syntax

public Timer(long p, int id);

Parameters

p The initial period of the timer.
id The user-defined identifier of the timer.

Timer(long p, boolean r)

Constructs a one-shot or repeating timer with the specified period (in milliseconds).

Syntax

public Timer(long p, boolean r);

Parameters

p The initial period of the timer.
r Set to true if the timer is a repeating timer or false if it is a one-shot timer.

Timer(long p, int id, boolean r)

Constructs a one-shot or repeating timer with the specified period (in milliseconds).

Syntax

public Timer(long p, int id, boolean r);

Parameters

p The initial period of the timer.
id The user-defined identifier for the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

Timer(TimerListener defaultListener, long p)

Constructs a one-shot timer with the specified period (in milliseconds) and that includes a default listener.

Syntax

public Timer(TimerListener defaultListener, long p);

Parameters

defaultListener The initial listener to add to the timer.
p The initial period of the timer.

Timer(TimerListener defaultListener, long p, int id)

Constructs a one-shot timer with the specified period (in milliseconds) and listener.

Syntax

public Timer(TimerListener defaultListener, long p, int id);

Parameters

defaultListener The initial listener to add to the timer.
p The initial period of the timer.
id The user-defined identifier of the timer.

Timer(TimerListener defaultListener, long p, boolean r)

Constructs a one-shot or repeating timer with the specified period (in milliseconds) and that includes a default listener.

Syntax

public Timer(TimerListener defaultListener, long p, boolean r);

Parameters

defaultListener The initial listener to add to the timer.
p The initial period of the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

Timer(TimerListener defaultListener, long p, int id, boolean r)

Constructs a one-shot or repeating timer with the specified period (in milliseconds) and a default listener.

Syntax

public Timer(TimerListener defaultListener, long p, int id, boolean r);

Parameters

defaultListener An initial listener to add to the timer.
id A user-defined identifier for the listener.
p The initial period of the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

Timer(TaskManager tm, long p)

Constructs a one-shot timer with the specified period.

Syntax

public Timer(TaskManager tm, long p);

Parameters

tm The TaskManager that is to service this Timer.
p The initial period of the timer (in milliseconds).

Timer(TaskManager tm, long p, int id)

Constructs a one-shot timer with a specific period and that includes a user-defined identifier.

Syntax

public Timer(TaskManager tm, long p, int id);

Parameters

tm The TaskManager that is to service this Timer.
p The initial period of the timer (in milliseconds).
id The user-defined identifier of the timer.

Timer(TaskManager tm, long p, boolean r)

Constructs a one-shot or repeating timer with the specified period.

Syntax

public Timer(TaskManager tm, long p, boolean r);

Parameters

tm The task manager that is to service this timer.
p The initial period of the timer (in milliseconds).
r Set to true if the timer is a repeating timer or false if it is a one-shot timer.

Timer(TaskManager tm, long p, int id, boolean r)

Constructs a one-shot or repeating timer with the specified period.

Syntax

public Timer(TaskManager tm, long p, int id, boolean r);

Parameters

tm The task manager that is to service this timer.
p The initial period of the timer (in milliseconds).
id The user-defined identifier for the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

Timer(TaskManager tm, TimerListener defaultListener, long p)

Constructs a one-shot timer with the specified period and that includes a default listener.

Syntax

public Timer(TaskManager tm, TimerListener defaultListener, long p);

Parameters

tm The task manager that is to service this timer.
defaultListener The initial listener to add to the timer.
p The initial period of the timer.

Timer(TaskManager tm, TimerListener defaultListener, long p, int id)

Constructs a one-shot timer with the specified period and listener.

Syntax

public Timer(TaskManager tm, TimerListener defaultListener, long p, int id);

Parameters

tm The task manager that is to service this timer.
defaultListener The initial listener to add to the timer.
p The initial period of the timer.
id The user-defined identifier of the timer.

Timer(TaskManager tm, TimerListener defaultListener, long p, boolean r)

Constructs a one-shot or repeating timer with the specified period and that includes a default listener.

Syntax

public Timer(TaskManager tm, TimerListener defaultListener, long p, boolean r);

Parameters

tm The task manager that is to service this timer.
defaultListener The initial listener to add to the timer.
p The initial period of the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

Timer(TaskManager tm, TimerListener defaultListener, long p, int id, boolean r)

Constructs a one-shot or repeating timer with the specified period and a default listener.

Syntax

public Timer(TaskManager tm, TimerListener defaultListener, long p, int id, boolean r);

Parameters

tm The task manager that is to service this timer.
defaultListener An initial listener to add to the timer.
id A user-defined identifier for the listener.
p The initial period of the timer.
r Set to true if the timer is a repeating timer; set to false if it is a one-shot timer.

© 1999 Microsoft Corporation. All rights reserved. Terms of use.