Show / Hide Table of Contents

Class SortOrderBuilder

Utility class to construct a valid sort order parameter for a query to the Contentful API.

Inheritance
System.Object
SortOrderBuilder
Inherited Members
System.Object.ToString()
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
Namespace:Contentful.Core.Search
Assembly:cs.temp.dll.dll
Syntax
public class SortOrderBuilder

Constructors

SortOrderBuilder(String, SortOrder)

Initializes a new instance of SortOrderBuilder

Declaration
public SortOrderBuilder(string field, SortOrder order = SortOrder.Normal)
Parameters
Type Name Description
System.String field

The field to sort by.

SortOrder order

The order of the sorting. Default is Normal.

Methods

Build()

Declaration
public string Build()
Returns
Type Description
System.String

ThenBy(String, SortOrder)

Adds another field to sort by to the current SortOrderBuilder.

Declaration
public SortOrderBuilder ThenBy(string field, SortOrder order = SortOrder.Normal)
Parameters
Type Name Description
System.String field

The field to sort by.

SortOrder order

The order of the sorting. Default is Normal.

Returns
Type Description
SortOrderBuilder

The SortOrderBuilder instance.

Back to top Copyright © 2015-2016 Contentful
Generated by DocFX