@itwin/core-frontend
Version:
iTwin.js frontend components
28 lines • 1.55 kB
TypeScript
/** @packageDocumentation
* @module WebGL
*/
import { GL } from "./GL";
/** Provides facilities for conditionally executing diagnostic/debug code. By default, all facilities are disabled - they must be explicitly enabled.
* @internal
*/
export declare class Debug {
/** Whether [[Debug.print]] will actually produce output. */
static printEnabled: boolean;
/** Whether [[Debug.evaluate]] will actually evaluate an expression. */
static evaluateEnabled: boolean;
/** If [[Debug.printEnabled]] is true, outputs a message using `console.log`.
* @param message A function which returns a string. If [[Debug.printEnabled]] is false, the function is never evaluated.
*/
static print(message: () => string): void;
/** If [[Debug.evaluate]] is true, executes the supplied function and returns its result; otherwise returns the supplied default value.
* @param evaluate The function to execute
* @param defaultValue The value to return if [[Debug.evaluate]] is false
* @returns The return value of `evaluate` if [[Debug.evaluate]] is true; otherwise, the `defaultValue`.
*/
static evaluate<T>(evaluate: () => T, defaultValue: T): T;
/** If [[Debug.evaluateEnabled]] is true, returns whether the currently-bound framebuffer is complete. */
static get isValidFrameBuffer(): boolean;
/** If [[Debug.evaluateEnabled]] is true, returns the status of the currently-bound framebuffer. */
static checkFrameBufferStatus(): GL.FrameBuffer.Status;
}
//# sourceMappingURL=Diagnostics.d.ts.map