### Hierarchy

- Console

### Implements

- IConsole

## Index

### Constructors

- constructor

### Properties

- mColor
- mIsOn
- mLevel
- mPrefix
- LEVELS
- LEVEL_DEFAULT

### Accessors

- color
- level
- on
- prefix

### Methods

- addContext
- buildPrefix
- clearContext
- debug
- error
- fatal
- format
- info
- isDebugEnabled
- isErrorEnabled
- isFatalEnabled
- isFormatEnabled
- isInfoEnabled
- isLevelEnabled
- isTraceEnabled
- isWarnEnabled
- removeContext
- trace
- warn
- writeStderr
- writeStdout
- getConsole
- isValidLevel
- validateLevel

## Constructors

### constructor

- new Console(mLevel?: string): Console

- - Defined in @zowe/imperative/src/console/src/Console.ts:48

  #### Parameters

  - ##### Default value mLevel: string = Console.LEVEL_DEFAULT

  #### Returns Console

## Properties

### Private mColor

mColor: boolean

- Defined in @zowe/imperative/src/console/src/Console.ts:47

### Private mIsOn

mIsOn: boolean

- Defined in @zowe/imperative/src/console/src/Console.ts:48

### Private mLevel

mLevel: string

- Defined in @zowe/imperative/src/console/src/Console.ts:50

### Private mPrefix

mPrefix: boolean

- Defined in @zowe/imperative/src/console/src/Console.ts:46

### Static Readonly LEVELS

LEVELS: string[] = ["trace", "debug", "info", "warn", "error", "fatal", "off"]

- Defined in @zowe/imperative/src/console/src/Console.ts:25

### Static Readonly LEVEL_DEFAULT

LEVEL_DEFAULT: "warn" = "warn"

- Defined in @zowe/imperative/src/console/src/Console.ts:26

## Accessors

### color

- get color(): boolean
- set color(isEnabled: boolean): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:253

  #### Returns boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:249

  #### Parameters

  - ##### isEnabled: boolean

  #### Returns void

### level

- get level(): string
- set level(level: string): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:237

  #### Returns string

- - Defined in @zowe/imperative/src/console/src/Console.ts:231

  #### Parameters

  - ##### level: string

  #### Returns void

### on

- get on(): boolean
- set on(isOn: boolean): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:261

  #### Returns boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:257

  #### Parameters

  - ##### isOn: boolean

  #### Returns void

### prefix

- get prefix(): boolean
- set prefix(isEnabled: boolean): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:245

  #### Returns boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:241

  #### Parameters

  - ##### isEnabled: boolean

  #### Returns void

## Methods

### addContext

- addContext(_key: string, _value: any): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:58

  #### Parameters

  - ##### _key: string

  - ##### _value: any

  #### Returns void

### Private buildPrefix

- buildPrefix(type: string): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:223

  #### Parameters

  - ##### type: string

  #### Returns string

### clearContext

- clearContext(): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:66

  #### Returns void

### debug

- debug(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:130

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### error

- error(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:158

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### fatal

- fatal(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:172

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### Private format

- format(data: string, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:202

  #### Parameters

  - ##### data: string

  - ##### Rest ...args: any[]

  #### Returns string

### info

- info(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:102

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### isDebugEnabled

- isDebugEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:78

  #### Returns boolean

### isErrorEnabled

- isErrorEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:90

  #### Returns boolean

### isFatalEnabled

- isFatalEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:94

  #### Returns boolean

### isFormatEnabled

- isFormatEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:98

  #### Returns boolean

### isInfoEnabled

- isInfoEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:82

  #### Returns boolean

### isLevelEnabled

- isLevelEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:70

  #### Returns boolean

### isTraceEnabled

- isTraceEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:74

  #### Returns boolean

### isWarnEnabled

- isWarnEnabled(): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:86

  #### Returns boolean

### removeContext

- removeContext(_key: string): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:62

  #### Parameters

  - ##### _key: string

  #### Returns void

### trace

- trace(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:116

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### warn

- warn(message: any, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:144

  #### Parameters

  - ##### message: any

  - ##### Rest ...args: any[]

  #### Returns string

### Private writeStderr

- writeStderr(message: string, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:186

  #### Parameters

  - ##### message: string

  - ##### Rest ...args: any[]

  #### Returns string

### Private writeStdout

- writeStdout(message: string, ...args: any[]): string

- - Defined in @zowe/imperative/src/console/src/Console.ts:194

  #### Parameters

  - ##### message: string

  - ##### Rest ...args: any[]

  #### Returns string

### Static getConsole

- getConsole(_category: string): Console

- - Defined in @zowe/imperative/src/console/src/Console.ts:28

  #### Parameters

  - ##### _category: string

  #### Returns Console

### Static isValidLevel

- isValidLevel(level: string): boolean

- - Defined in @zowe/imperative/src/console/src/Console.ts:32

  #### Parameters

  - ##### level: string

  #### Returns boolean

### Static validateLevel

- validateLevel(level: string): void

- - Defined in @zowe/imperative/src/console/src/Console.ts:36

  #### Parameters

  - ##### level: string

  #### Returns void

Generated using TypeDoc