MCPcopy Create free account
hub / github.com/codemix/graph / compareTo

Method compareTo

packages/graph/src/TemporalTypes.ts:683–691  ·  view source on GitHub ↗
(other: LocalDateTimeValue)

Source from the content-addressed store, hash-verified

681 }
682
683 public compareTo(other: LocalDateTimeValue): number {
684 if (this.#year !== other.#year) return this.#year - other.#year;
685 if (this.#month !== other.#month) return this.#month - other.#month;
686 if (this.#day !== other.#day) return this.#day - other.#day;
687 if (this.#hour !== other.#hour) return this.#hour - other.#hour;
688 if (this.#minute !== other.#minute) return this.#minute - other.#minute;
689 if (this.#second !== other.#second) return this.#second - other.#second;
690 return this.#nanosecond - other.#nanosecond;
691 }
692}
693
694/**

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected