PresenceInfo Class

Namespace:
Weavy.Core.Models
Assembly:
Weavy.Core.dll

A class for describing a user's presence information (active or away).

public class PresenceInfo
Inheritance:
System.Object → PresenceInfo

Constructors

PresenceInfo(IEnumerable, Boolean)

Properties

Connections Gets the total number of connections.
LastActiveAt Gets a time indicating when the user was last active. If a user has no connected clients then this property will be absent.
Status Gets the user's presence status. A user is active if they they have at least one active client connected (and they are not manually marked as away).

Extension Methods

IsNullOrDefault(T) Gets a value indicating if the specified value has the default value of the generic type.
Serialize(Object) Serializes an object, or graph of connected objects, to a byte array.
SerializeToJson(Object, Nullable, JsonSerializerSettings) Serializes an object, or graph of connected objects, to a json string.
IsValid(Object) Determines whether the specified object is valid by evaluating each ValidationAttribute instance that is attached to the object type.