type

HxUtil

const class HxUtil : Obj

Haxall utility methods

methods

parseEnum

Parse enum as ordered map of Str:Dict keyed by name.

parseEnumNames

Convenience for parseEnum which returns only a list of string names.

pid

Process id or null if cannot be determined

pods

List pods as grid

threadDump

Dump a specific thread by its id

threadDumpAll

Dump all threads

threadDumpDeadlocks

Dump thread deadlocks if detected

threadId

Current thread id

tzdb

List timezones as grid

unitdb

List units as grid

Slot Details

parseEnum

static Str:Dict parseEnum(Obj? enum)

Parse enum as ordered map of Str:Dict keyed by name. Dict tags:

  • name: str key
  • doc: fandoc string if available

Supported inputs:

  • null returns empty list
  • Dict of Dicts
  • Str[] names
  • Str newline separated names
  • Str comma separated names
  • Str fandoc list as - name: fandoc lines

parseEnumNames

static Str[] parseEnumNames(Obj? enum)

Convenience for parseEnum which returns only a list of string names. Using this method is more efficient than calling parseEnums and then mapping the keys.

pid

static Int? pid()

Process id or null if cannot be determined

pods

static Grid pods()

List pods as grid

threadDump

static Str threadDump(Int id)

Dump a specific thread by its id

threadDumpAll

static Str threadDumpAll()

Dump all threads

threadDumpDeadlocks

static Str threadDumpDeadlocks()

Dump thread deadlocks if detected

threadId

static Int threadId()

Current thread id

tzdb

static Grid tzdb()

List timezones as grid

unitdb

static Grid unitdb()

List units as grid