Search Results for

    Show / Hide Table of Contents

    Class Query

    Class which represents a CAML query.

    Inheritance
    System.Object
    Query
    Namespace: CamlBuilder
    Assembly: PnP.Framework.dll
    Syntax
    public class Query : object

    Properties

    Statement

    Gets the statement holded by this query.

    Declaration
    public Statement Statement { get; }
    Property Value
    Statement

    Methods

    Build(Statement)

    Instanciates a new Query with the specified inner statement

    Declaration
    public static Query Build(Statement statement)
    Parameters
    Statement statement

    Returns
    Query

    GetCaml()

    Returns query's CAML string representation surrounded by Query element

    Declaration
    public string GetCaml()
    Returns
    System.String

    Query CAML string surrounded by Query element.

    GetCaml(Boolean)

    Returns query's CAML string representation

    Declaration
    public string GetCaml(bool whereClauseOnly)
    Parameters
    System.Boolean whereClauseOnly

    true to return only query's Where; otherwise false

    Returns
    System.String

    Query CAML string surrounded by Query element or only the Where clause

    GroupBy(FieldReference)

    Specify the query's group-by options. Query will be grouped by specified fieldRef.

    Declaration
    public Query GroupBy(FieldReference fieldRef)
    Parameters
    FieldReference fieldRef

    Reference to the field to group by.

    Returns
    Query

    Returns the query itself.

    GroupBy(IEnumerable<FieldReference>)

    Specify the query's group-by options. Query will be grouped by specified fieldRefs.

    Declaration
    public Query GroupBy(IEnumerable<FieldReference> fieldRefs)
    Parameters
    IEnumerable<FieldReference> fieldRefs

    References to the fields to group by.

    Returns
    Query

    Returns the query itself.

    OrderBy(FieldReference)

    Adds a new query sort order relatively to a specified fieldRef.

    Declaration
    public Query OrderBy(FieldReference fieldRef)
    Parameters
    FieldReference fieldRef

    Reference to the field where to perform the ordering on.

    Returns
    Query

    Returns the query itself.

    Remarks

    Use Ascending with false value to specify descending order.

    OrderBy(IEnumerable<FieldReference>)

    Adds a collection of sort orders relatively to specified fieldRefs.

    Declaration
    public Query OrderBy(IEnumerable<FieldReference> fieldRefs)
    Parameters
    IEnumerable<FieldReference> fieldRefs

    References to the fields where to perform the ordering on.

    Returns
    Query

    Returns the query itself.

    Remarks

    Use Ascending with false value to specify descending order.

    Extension Methods

    ValidationExtensions.ValidateNotNullOrEmpty<T>(T, String)
    ObjectExtensions.Set<TObject, T>(TObject, Expression<Func<TObject, T>>, T, Boolean, Boolean)
    ObjectExtensions.GetPublicInstancePropertyValue(Object, String)
    ObjectExtensions.GetPublicInstanceProperty(Object, String)
    ObjectExtensions.SetPublicInstancePropertyValue(Object, String, Object)
    Extensions.ToByteArray(Object)
    Back to top PnP Framework
    Generated by DocFX with Material UI
    spacer