/** * Class implements all the work with consistency states. * invalidate() and markConsistent() are used to change states. * isConsistent() and hasInvalidationState() are used to check states. * @constructor * @name anychart.core.Base */ anychart.core.Base;
/** * Special event for changes in dirty states. * @param {anychart.core.Base} target Event target. * @param {number} invalidatedStates Changes effectively happened with the target. * @constructor */ anychart.SignalEvent;
/** * If target needs redraw. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetNeedsRedraw;
/** * If target signalled bounds change. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetBoundsChanged;
/** * If target signalled data change. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetDataChanged;
/** * If target signalled meta change. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetMetaChanged;
/** * If target needs to be reapplied. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetNeedsReapplication;
/** * If target needs to be recalculated. * @return {boolean} Boolean flag. */ anychart.SignalEvent.prototype.targetNeedsRecalculation;
/** * Adds an event listener to an implementing object. * @detailed The listener can be added to an object once, and if it is added one more time, its key will be returned.<br/> * <b>Note</b> Notice that if the existing listener is one-off (added using listenOnce), * it will cease to be such after calling the listen() method. * @shortDescription Adds an event listener * @category Events * @example anychart.core.Base.listen * @param {string} type The event type id. * @param {ListenCallback} listener * Callback method. Function that looks like: <pre>function(event){ * // event.actualTarget - actual event target * // event.currentTarget - current event target * // event.iterator - event iterator * // event.originalEvent - original event * // event.point - event point * // event.pointIndex - event point index * }</pre> * @param {boolean=} opt_useCapture [false] Whether to fire in capture phase. Learn more about capturing {@link https://javascript.info/bubbling-and-capturing} * @param {Object=} opt_listenerScope Object in whose scope to call the listener. * @return {{key: number}} Unique key for the listener. */ anychart.core.Base.prototype.listen;
/** * Adds an event listener to an implementing object. * @detailed <b>After the event is called, its handler will be deleted.</b><br> * If the event handler being added already exists, listenOnce will do nothing. <br/> * <b>Note</b> In particular, if the handler is already registered using listen(), listenOnce() * <b>will not</b> make it one-off. Similarly, if a one-off listener already exists, listenOnce will not change it * (it wil remain one-off). * @shortDescription Adds a single time event listener * @category Events * @example anychart.core.Base.listenOnce * @param {string} type The event type id. * @param {ListenCallback} listener Callback method. * @param {boolean=} opt_useCapture [false] Whether to fire in capture phase. Learn more about capturing {@link https://javascript.info/bubbling-and-capturing} * @param {Object=} opt_listenerScope Object in whose scope to call the listener. * @return {{key: number}} Unique key for the listener. * @template SCOPE,EVENTOBJ */ anychart.core.Base.prototype.listenOnce;
/** * Removes a listener added using listen() or listenOnce() methods. * @shortDescription Removes the listener * @category Events * @example anychart.core.Base.unlisten * @param {string} type The event type id. * @param {Callback} listener Callback method. * @param {boolean=} opt_useCapture [false] Whether to fire in capture phase. Learn more about capturing {@link https://javascript.info/bubbling-and-capturing} * @param {Object=} opt_listenerScope Object in whose scope to call the listener. * @return {boolean} Whether any listener was removed. * @template SCOPE,EVENTOBJ */ anychart.core.Base.prototype.unlisten;
/** * Removes an event listener which was added with listen() by the key returned by listen() or listenOnce(). * @shortDescription Removes the listener by the key * @category Events * @example anychart.core.Base.unlistenByKey * @param {{key: number}} key The key returned by listen() or listenOnce(). * @return {boolean} Whether any listener was removed. */ anychart.core.Base.prototype.unlistenByKey;
/** * Removes all listeners from an object. You can also optionally remove listeners of some particular type. * @shortDescription Removes all listeners * @category Events * @example anychart.core.Base.removeAllListeners * @param {string=} opt_type Type of event to remove, default is to remove all types. * @return {number} Number of listeners removed. */ anychart.core.Base.prototype.removeAllListeners;