Methods
-
append(subjects, erroropt, successopt)
-
Add records to the end of this watchlist.
Parameters:
Name Type Attributes Description subjects
Array.<string> the array of subjects of the records to add. error
function <optional>
function to be called if the operation fails. success
function <optional>
function to be called when the operation completes successfully. -
contains(subject) → {boolean}
-
Whether or not this watchlist contains a given record.
Parameters:
Name Type Description subject
string The subject of the record to verify. Returns:
true
if the given subject is in this watchlist, otherwisefalse
.- Type
- boolean
-
destroy()
-
This method should be called when this
module:caplin/watchlist/WatchlistContentsManager
will no longer be used, signifying to the watchlist that it can free up resources. -
insert(subjects, index, erroropt, successopt)
-
Insert records into this watchlist at a given index.
Parameters:
Name Type Attributes Description subjects
Array.<string> the array of subjects of the records to add. index
Integer the insertion index. error
function <optional>
function to be called if the operation fails. success
function <optional>
function to be called when the operation completes successfully. -
isPaused() → {boolean}
-
Is this
module:caplin/watchlist/WatchlistContentsManager
's subscription paused.Returns:
true if the contents manager subscription is paused, otherwise false.- Type
- boolean
-
pause()
-
Signify to the
module:caplin/watchlist/Watchlist
that the user of this contents manager is not actively using the watchlist. -
remove(subjects, erroropt, successopt)
-
Remove records from this watchlist.
Parameters:
Name Type Attributes Description subjects
Array.<string> the array of subjects to be removed. error
function <optional>
function to be called if the operation fails. success
function <optional>
function to be called when the operation completes successfully. -
resume()
-
Signify to the
module:caplin/watchlist/Watchlist
that the user of this contents manager is once again actively using the watchlist.