Instance Method

addItem(with:title:previewText:)

Adds an item to the Reading List.

Declaration

func addItem(with URL: URL, title: String?, previewText: String?) throws

Parameters

URL

The URL of the item.

title

The title of the item, or nil.

previewText

A string shown as detail text for the item, or nil.

error

On return, an error object that describes the problem, or nil if the operation succeeded.

Return Value

true if the item was added; otherwise, false.

Discussion

Call this method when the user chooses to add to the Reading List.