DateAndOrTimeTryAsTimeOnly Method

Tries to convert the encapsulated data to a TimeOnly value.

Definition

Namespace: FolkerKinzel.VCards.Models
Assembly: FolkerKinzel.VCards (in FolkerKinzel.VCards.dll) Version: 8.0.1+a91cc3f0fd39aeb548e16006a60ca9dd10a304a2
C#
public abstract bool TryAsTimeOnly(
	out TimeOnly value
)

Parameters

value  TimeOnly
When the method returns true, contains a TimeOnly value that represents the data that is encapsulated in the instance. The parameter is passed uninitialized.

Return Value

Boolean
true if the conversion was successful, otherwise false.

Remarks

The conversion succeeds only if the encapsulated value is a TimeOnly, a DateTimeOffset, or a String that represents a TimeOnly. If the encapsulated value is a DateTimeOffset, its time will be converted to local time.

See Also