/** * Base class for instrumenting a feature. * @extends FeatureBase */ export class InstrumentBase extends FeatureBase { /** * Instantiate InstrumentBase. * @param {Object} agentRef - The agent reference object. * @param {string} featureName - The name of the feature module (used to construct file path). */ constructor(agentRef: Object, featureName: string); /** @type {Function | undefined} This should be set by any derived Instrument class if it has things to do when feature fails or is killed. */ abortHandler: Function | undefined; /** * @type {import('./aggregate-base').AggregateBase} Holds the reference to the feature's aggregate module counterpart, if and after it has been initialized. This may not be assigned until after page loads! * The only purpose of this for now is to expose it to the NREUM interface, as the feature's instrument instance is already exposed. */ featAggregate: import("./aggregate-base").AggregateBase; /** * @type {Promise} Assigned immediately after @see importAggregator runs. Serves as a signal for when the inner async fn finishes execution. Useful for features to await * one another if there are inter-features dependencies. */ loadedSuccessfully: Promise; onAggregateImported: Promise; /** * used in conjunction with newrelic.start() to defer harvesting in features * @type {Promise} Resolves when the feature is ready to import its aggregator, either immediately or after the start API has been called if the feature is autoStart: false. */ deferred: Promise; /** * Lazy-load the latter part of the feature: its aggregator. This method is called by the first part of the feature * (the instrumentation) when instrumentation is complete. * @param {Object} agentRef - reference to the base agent ancestor that this feature belongs to * @param {Function} fetchAggregator - a function that returns a promise that resolves to the aggregate module * @param {Object} [argsObjFromInstrument] - any values or references to pass down to aggregate * @returns */ importAggregator(agentRef: Object, fetchAggregator: Function, argsObjFromInstrument?: Object): void; #private; } import { FeatureBase } from './feature-base'; //# sourceMappingURL=instrument-base.d.ts.map