Options
All
  • Public
  • Public/Protected
  • All
Menu

Index

Variables

base64keyStr

base64keyStr: string

Functions

addEventListener

  • addEventListener(obj: any, type: any, listener: any): void
  • Add an event listener to an object.

    Parameters

    • obj: any

      The object to add the event listener to.

    • type: any

      The type of event to listen for.

    • listener: any

      The object that receives a notification when an event occurs.

    Returns void

alphaNumericToken

  • alphaNumericToken(length?: number): string
  • Generates a random alphanumeric token, given a length.

    Parameters

    • Optional length: number

      The length of the token to generate. If no length is provided, a default length of 8 characters is used.

    Returns string

base64Decode

  • base64Decode(input: string): string
  • Decodes a Base-64 string.

    Parameters

    • input: string

      The text input to decode.

    Returns string

base64Encode

  • base64Encode(input: string): string
  • Base-64 encodes a chunk of UTF-8 data.

    Parameters

    • input: string

      The text input to encode.

    Returns string

clamp

  • clamp(value: number, min: number, max: number): number
  • Restricts a value to be within a specified range.

    Parameters

    • value: number

      The value to clamp

    • min: number

      The minimum value. If value is less than min, min will be returned

    • max: number

      The maximum value. If value is greater than max, max will be returned

    Returns number

isDefined

  • isDefined(value: any): boolean
  • Parameters

    • value: any

    Returns boolean

isNullOrUndefined

  • isNullOrUndefined(value: any): boolean
  • Parameters

    • value: any

    Returns boolean

isPercentage

  • isPercentage(value: string): boolean
  • Returns true if a value is a percentage value, false otherwise.

    Parameters

    • value: string

      The value being evaluated.

    Returns boolean

isUrl

  • isUrl(value: string): boolean
  • Checks whether the supplied string represents a URL.

    Parameters

    • value: string

      The value to check.

    Returns boolean

makeUrlAbsolute

  • makeUrlAbsolute(url: string): string
  • Makes a relative URL absolute.

    Parameters

    • url: string

      The URL to make absolute.

    Returns string

utf8Decode

  • utf8Decode(input: string): string
  • Decodes a UTF-8 value into its string representation.

    Parameters

    • input: string

    Returns string

utf8Encode

  • utf8Encode(s: string): string
  • Encodes a string into its UTF-8 representation.

    Parameters

    • s: string

      The string to encode.

    Returns string