Class FollowedContent

Provides access to followed content items.

Hierarchy

Index

Constructor methods

Methods

Constructor methods

constructor(context: ClientRuntimeContext): FollowedContent

Parameters

Returns

FollowedContent

Methods

public customFromJson(initValue: any): boolean

Parameters

  • initValue: any

Returns

boolean

public findAndUpdateFollowedItem(url: string): FollowedItem

Finds the original item that is being pointed to in the Followed Content list and updates the Title, Url, and IconUrl fields if they have been changed.

Parameters

  • url: string

    The URL of the original item as stored in the Followed Content list.

Returns

FollowedItem

public follow(url: string, data?: FollowedItemData): FollowResult

The Follow method adds the specified document or site to the list of followed content.

Parameters

  • url: string

    URL that identifies the item to follow. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

  • data?: FollowedItemData optional

    Optional parameter that holds application-defined data for the item.

Returns

FollowResult

public followItem(item: FollowedItem): FollowResult

The FollowItem method is reserved for server-to-server use only. The server sets the specified item to be followed by the current user. This method cannot be called from the client.

Parameters

Returns

FollowResult

public fromJson(initValue: any)

Parameters

  • initValue: any

public getFollowedStatus(url: string): IntResult

Retrieves the followed status of the specified document or site. Returns a value of type FollowedStatus, wrapped into a SP.IntResult object.

Parameters

  • url: string

    URL that identifies the followed item. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

Returns

IntResult

public getItem(url: string): FollowedItem

Returns the followed item identified by a given URL or returns null if the item does not exist.

Parameters

  • url: string

    URL that identifies the followed item. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

Returns

FollowedItem

public getItems(options: FollowedContentQueryOptions, subtype: number): FollowedItem[]

Returns an array of zero or more followed items described by the type and subtype parameters.

Parameters

Returns

FollowedItem[]

public get_context(): ClientRuntimeContext

Returns

ClientRuntimeContext

public get_followedDocumentsUrl(): string

Gets the location of the followed sites view

Returns

string

public get_followedSitesUrl(): string

Gets the location of the followed documents view.

Returns

string

public get_objectVersion(): string

Returns

string

public get_path(): ObjectPath

Returns

ObjectPath

public get_serverObjectIsNull(): boolean

Returns

boolean

public get_typedObject(): ClientObject

Returns

ClientObject

public isFollowed(url: string): BooleanResult

Determines if the specified document or site is being followed.

Parameters

  • url: string

    URL that identifies the item that is supposed to be followed. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

Returns

BooleanResult

public isObjectPropertyInstantiated(propertyName: string): boolean

Parameters

  • propertyName: string

Returns

boolean

public isPropertyAvailable(propertyName: string): boolean

Parameters

  • propertyName: string

Returns

boolean

public static newObject(context: ClientRuntimeContext): FollowedContent

Parameters

Returns

FollowedContent

public refreshFollowedItem(item: FollowedItem): FollowedItem

Returns the refreshed item that is being pointed to in the Social list.

Parameters

  • item: FollowedItem

    The original item as stored in the Followed Content list.

Returns

FollowedItem

public refreshLoad()

public retrieve()

public retrieve(propertyNames: Array<string>)

Parameters

  • propertyNames: Array<string>

public set_objectVersion(value: string)

Parameters

  • value: string

public stopFollowing(url: string)

Removes the specified document or site from list of followed content.

Parameters

  • url: string

    URL that identifies the item to stop following. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

public updateData(url: string, data: FollowedItemData)

Updates the properties for followed item with specified URL.

Parameters

  • url: string

    URL that identifies the followed item. The url parameter can identify an existing document or site using the url property of the original item. The url parameter can also identify a document with the following format: http://host/site?listId=&itemId=

  • data: FollowedItemData

    Application-defined data stored with the followed item.