Table of Contents

Struct CharacterLockState

Namespace
FishMMO.Database.Data
Assembly
FishMMO-DB.dll

A character's staff lock, as stored.

public readonly struct CharacterLockState
Inherited Members

Remarks

The lock is in force only while LockedUntil is in the future. Nothing sweeps a lapsed one, so every reader asks IsLocked(DateTime) with its own clock rather than trusting that a non-null end means a lock.

Constructors

CharacterLockState(DateTime?, string, string)

public CharacterLockState(DateTime? lockedUntil, string lockedBy, string lockReason)

Parameters

lockedUntil DateTime?
lockedBy string
lockReason string

Fields

LockReason

Why it was placed.

public readonly string LockReason

Field Value

string

LockedBy

The staff account that placed it.

public readonly string LockedBy

Field Value

string

LockedUntil

When the lock lapses (UTC), or null when none was placed.

public readonly DateTime? LockedUntil

Field Value

DateTime?

Methods

IsLocked(DateTime)

Whether the lock is in force at nowUtc.

public bool IsLocked(DateTime nowUtc)

Parameters

nowUtc DateTime

Returns

bool