codemelted.js Module
    Preparing search index...

    Class CWorkerProtocol

    Constructs a dedicated background worker off the JavaScript runtime main thread via the async_worker function.

    Hierarchy (View Summary)

    Index

    post_message

    • post_message(data?: any): void

      Sends a message, which can be of any kind of Object, to the background worker for processing based on how it was setup to be processed.

      Parameters

      • Optionaldata: any

        The data to post. The data is serialized using the structured clone algorithm. This means you can pass a broad variety of data objects safely to the background for processing without having to serialize them yourself.

      Returns void

    • Identifies the number of background threads are available to the worker.

      Returns number