WALTER | Workable Algorithms for Location-aware Transmission, Encryption Response

TestClock..::..Set Method

Sets the clock to a specified date and time. Assumes the DateTimeKind of the provided dateTime. If unspecified, DateTimeKind.Local is assumed.

Namespace:  Walter
Assembly:  Walter (in Walter.dll)

Syntax


public void Set(
	DateTime dateTime
)

Parameters

dateTime
Type: DateTime
The date and time to set the clock to.

Examples


C#
// Example of setting the clock to a specific date and time
testClock.Set(new DateTime(2022, 12, 25, 10, 30, 0));
Console.WriteLine(testClock.Now); // Displays 2022-12-25 10:30:00