PlatformBrokerError class

詳細なブローカー情報を保持する MSAL ランタイム エラーのエラー クラス

Extends

プロパティ

statusCode

MSAL ランタイムからの数値エラー コード

tag

MSAL ランタイムからのエラー タグ

継承されたプロパティ

correlationId

エラーに関連付けられている CorrelationId

errorCode

短い文字列の説明エラー

errorMessage

エラーの詳細な説明

message
name
platformBrokerError

ブローカーが有効になっている場合の MsalNodeRuntime からの既定の PlatformBrokerError

stack
stackTraceLimit

Error.stackTraceLimitの性質は、スタックトレースによって収集されるスタックフレームの数(new Error().stackであれError.captureStackTrace(obj)であれ)を指定します。

デフォルト値は 10 ですが、有効なJavaScript番号に設定することができます。 変更は、値が変更 された後に キャプチャされたスタックトレースに影響を与えます。

非数値値、または負数に設定した場合、スタックトレースはフレームをキャプチャしません。

subError

エラーのサブクラスについて説明します

継承されたメソッド

captureStackTrace(object, Function)

.stacktargetObjectプロパティを作成し、アクセスするとError.captureStackTrace()が呼び出されたコード内の位置を表す文字列を返します。

const myObject = {};
Error.captureStackTrace(myObject);
myObject.stack;  // Similar to `new Error().stack`

トレースの最初の行は ${myObject.name}: ${myObject.message}で接頭辞付きになります。

オプションの constructorOpt 引数は関数を受け入れます。 もし与えられた場合、 constructorOpt以上のフレーム( constructorOptを含む)は生成されたスタックトレースから除外されます。

constructorOptの議論は、エラー発生の実装詳細をユーザーから隠すのに役立ちます。 次に例を示します。

function a() {
  b();
}

function b() {
  c();
}

function c() {
  // Create an error without stack trace to avoid calculating the stack trace twice.
  const { stackTraceLimit } = Error;
  Error.stackTraceLimit = 0;
  const error = new Error();
  Error.stackTraceLimit = stackTraceLimit;

  // Capture the stack trace above function b
  Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
  throw error;
}

a();
prepareStackTrace(Error, CallSite[])

https://v8.dev/docs/stack-trace-api#customizing-stack-traces」を参照してください。

setCorrelationId(string)

コンストラクターの詳細

PlatformBrokerError(string, string, number, number)

new PlatformBrokerError(errorStatus: string, errorContext: string, errorCode: number, errorTag: number)

パラメーター

errorStatus

string

errorContext

string

errorCode

number

errorTag

number

プロパティの詳細

statusCode

MSAL ランタイムからの数値エラー コード

statusCode: number

プロパティ値

number

tag

MSAL ランタイムからのエラー タグ

tag: string

プロパティ値

string

継承されたプロパティの詳細

correlationId

エラーに関連付けられている CorrelationId

correlationId: string

プロパティ値

string

AuthError.correlationIdから継承

errorCode

短い文字列の説明エラー

errorCode: string

プロパティ値

string

AuthError.errorCodeから継承

errorMessage

エラーの詳細な説明

errorMessage: string

プロパティ値

string

AuthError.errorMessageから継承

message

message: string

プロパティ値

string

AuthError.messageから継承

name

name: string

プロパティ値

string

AuthError.name から継承

platformBrokerError

ブローカーが有効になっている場合の MsalNodeRuntime からの既定の PlatformBrokerError

platformBrokerError?: PlatformBrokerError

プロパティ値

AuthError.platformBrokerError から継承

stack

stack?: string

プロパティ値

string

AuthError.stackから継承

stackTraceLimit

Error.stackTraceLimitの性質は、スタックトレースによって収集されるスタックフレームの数(new Error().stackであれError.captureStackTrace(obj)であれ)を指定します。

デフォルト値は 10 ですが、有効なJavaScript番号に設定することができます。 変更は、値が変更 された後に キャプチャされたスタックトレースに影響を与えます。

非数値値、または負数に設定した場合、スタックトレースはフレームをキャプチャしません。

static stackTraceLimit: number

プロパティ値

number

AuthError.stackTraceLimitから継承

subError

エラーのサブクラスについて説明します

subError: string

プロパティ値

string

AuthError.subErrorから継承

継承済みメソッドの詳細

captureStackTrace(object, Function)

.stacktargetObjectプロパティを作成し、アクセスするとError.captureStackTrace()が呼び出されたコード内の位置を表す文字列を返します。

const myObject = {};
Error.captureStackTrace(myObject);
myObject.stack;  // Similar to `new Error().stack`

トレースの最初の行は ${myObject.name}: ${myObject.message}で接頭辞付きになります。

オプションの constructorOpt 引数は関数を受け入れます。 もし与えられた場合、 constructorOpt以上のフレーム( constructorOptを含む)は生成されたスタックトレースから除外されます。

constructorOptの議論は、エラー発生の実装詳細をユーザーから隠すのに役立ちます。 次に例を示します。

function a() {
  b();
}

function b() {
  c();
}

function c() {
  // Create an error without stack trace to avoid calculating the stack trace twice.
  const { stackTraceLimit } = Error;
  Error.stackTraceLimit = 0;
  const error = new Error();
  Error.stackTraceLimit = stackTraceLimit;

  // Capture the stack trace above function b
  Error.captureStackTrace(error, b); // Neither function c, nor b is included in the stack trace
  throw error;
}

a();
static function captureStackTrace(targetObject: object, constructorOpt?: Function)

パラメーター

targetObject

object

constructorOpt

Function

AuthError.captureStackTraceから継承

prepareStackTrace(Error, CallSite[])

https://v8.dev/docs/stack-trace-api#customizing-stack-traces」を参照してください。

static function prepareStackTrace(err: Error, stackTraces: CallSite[]): any

パラメーター

err

Error

stackTraces

CallSite[]

返品

any

AuthError.prepareStackTraceから継承

setCorrelationId(string)

function setCorrelationId(correlationId: string)

パラメーター

correlationId

string

AuthError.setCorrelationIdから継承