Table of Contents

Class SortOption

Namespace
PnP.Core.Model.SharePoint
Assembly
PnP.Core.dll

Defines a field to be used for sorting search query results

public class SortOption
Inheritance
SortOption
Inherited Members

Constructors

SortOption(string)

Creates SortOption class, defaults to ascending sort order

public SortOption(string property)

Parameters

property string

Property to sort on

SortOption(string, SortDirection)

Creates SortOption class

public SortOption(string property, SortDirection sort)

Parameters

property string

Property to sort on

sort SortDirection

Sort order to use

Properties

Property

Property to sort on

public string Property { get; }

Property Value

string

Sort

Sort order to use

public SortDirection Sort { get; }

Property Value

SortDirection

Methods

ToString()

Returns the sort option so it can be used in a search query

public override string ToString()

Returns

string

Sort option to use in a query