Table of Contents

Class DutyStatusViolation

Namespace
Geotab.Checkmate.ObjectModel
Assembly
Geotab.Checkmate.ObjectModel.dll

A DutyStatusLog violation for a User.

[ReportClass]
public class DutyStatusViolation : EntityWithVersion, IEntity, IComparable, IIdentifiable, IVersion
Inheritance
DutyStatusViolation
Implements
Inherited Members

Constructors

DutyStatusViolation()

Initializes a new instance of the DutyStatusViolation class.

public DutyStatusViolation()

DutyStatusViolation(Id?, long?, DutyStatusViolationType?, User?, DateTime?, DateTime?, TimeSpan?, int?, int?, int?, Id?)

Initializes a new instance of the DutyStatusViolation class.

public DutyStatusViolation(Id? id, long? version, DutyStatusViolationType? type, User? driver, DateTime? fromDate, DateTime? toDate, TimeSpan? drivingDuration, int? hoursLimit, int? daysLimit, int? periodsLimit, Id? logId)

Parameters

id Id

The identifier.

version long?

The version.

type DutyStatusViolationType?

The DutyStatusViolationType.

driver User

The User.

fromDate DateTime?

From date.

toDate DateTime?

To date.

drivingDuration TimeSpan?

Duration of the driving.

hoursLimit int?

Maximum/minimum hours limit.

daysLimit int?

Maximum/minimum days limit.

periodsLimit int?

Maximum/minimum days limit for Cycle Rest violation.

logId Id

The DutyStatusLog Id that caused the violation.

DutyStatusViolation(User, DutyStatusViolationType?, DateTime?, DateTime?, in TimeSpan, int?, int?, int?)

Initializes a new instance of the DutyStatusViolation class.

[Obsolete("Deprecating. Use other constructor.")]
public DutyStatusViolation(User driver, DutyStatusViolationType? type, DateTime? fromDate, DateTime? toDate, in TimeSpan drivingDuration, int? hoursLimit, int? daysLimit, int? periodsLimit)

Parameters

driver User

The driver.

type DutyStatusViolationType?

The type.

fromDate DateTime?

From date.

toDate DateTime?

To date.

drivingDuration TimeSpan

Duration of the driving.

hoursLimit int?

Maximum/minimum hours limit.

daysLimit int?

Maximum/minimum days limit.

periodsLimit int?

Maximum/minimum days limit for Cycle Rest violation.

DutyStatusViolation(User, DutyStatusViolationType?, DateTime?, DateTime?, in TimeSpan, int?, int?, int?, Id)

Initializes a new instance of the DutyStatusViolation class.

[Obsolete("Deprecating. Use other constructor.")]
public DutyStatusViolation(User driver, DutyStatusViolationType? type, DateTime? fromDate, DateTime? toDate, in TimeSpan drivingDuration, int? hoursLimit, int? daysLimit, int? periodsLimit, Id logId)

Parameters

driver User

The driver.

type DutyStatusViolationType?

The type.

fromDate DateTime?

From date.

toDate DateTime?

To date.

drivingDuration TimeSpan

Duration of the driving.

hoursLimit int?

Maximum/minimum hours limit.

daysLimit int?

Maximum/minimum days limit.

periodsLimit int?

Maximum/minimum days limit for Cycle Rest violation.

logId Id

The DutyStatusLog that caused the violation.

DutyStatusViolation(User, DutyStatusViolationType?, DateTime?, DateTime?, in TimeSpan, string)

Initializes a new instance of the DutyStatusViolation class.

[Obsolete("Deprecating. Use other constructor.")]
public DutyStatusViolation(User driver, DutyStatusViolationType? type, DateTime? fromDate, DateTime? toDate, in TimeSpan drivingDuration, string reason)

Parameters

driver User

The driver.

type DutyStatusViolationType?

The type.

fromDate DateTime?

From date.

toDate DateTime?

To date.

drivingDuration TimeSpan

Duration of the driving.

reason string

The reason.

Properties

DaysLimit

Gets or sets the maximum or minimum days limit of the duty status violation.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationDaysLimit })]
public int? DaysLimit { get; set; }

Property Value

int?

int

Driver

Gets or sets the User associated with the duty status violation.

public User? Driver { get; set; }

Property Value

User

The. User

DrivingDuration

Gets or sets the driving duration of the duty status violation.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationDrivingDuration })]
public TimeSpan? DrivingDuration { get; set; }

Property Value

TimeSpan?

TimeSpan

FromDate

Gets or sets the date and time that the duty status violation started.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationStartDateTime })]
public DateTime? FromDate { get; set; }

Property Value

DateTime?

DateTime

HoursLimit

Gets or sets the maximum or minimum hours limit of the duty status violation.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationHoursLimit })]
public int? HoursLimit { get; set; }

Property Value

int?

int

LogId

Gets or sets the log Id.

public Id? LogId { get; set; }

Property Value

Id

The log Id.

Remarks

Stub for strict mode in debug.

PeriodsLimit

Gets or sets the maximum or minimum hours limit of the duty status Cycle Rest violation.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationPeriodsLimit })]
public int? PeriodsLimit { get; set; }

Property Value

int?

int

Reason

Gets or sets the stated reason why the duty status violation occurred.

[Obsolete("Deprecated. Will be removed in a future version. The data in the 'Reason' property string is now provided as 'DaysLimit' and 'HoursLimit' for better programmatic access.")]
[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationReason })]
public string? Reason { get; set; }

Property Value

string

string

ToDate

Gets or sets the date and time that the duty status violation ended.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationEndDateTime })]
public DateTime? ToDate { get; set; }

Property Value

DateTime?

DateTime

Type

Gets or sets the DutyStatusViolationType of the duty status violation.

[ExcelColumnHeader(new ReportHeading[] { ReportHeading.HosViolationType })]
public DutyStatusViolationType? Type { get; set; }

Property Value

DutyStatusViolationType?

DutyStatusViolationType

Methods

Clone()

Creates a new object that is a copy of the current instance.

public override IEntity Clone()

Returns

IEntity

A new object that is a copy of this instance.