2017-07-20 11:21:28 +02:00
|
|
|
|
using System;
|
2016-06-30 18:35:43 +02:00
|
|
|
|
using System.Collections.Generic;
|
|
|
|
|
|
using System.Xml.XPath;
|
2017-09-08 19:39:13 +02:00
|
|
|
|
using Umbraco.Core;
|
2016-06-30 18:35:43 +02:00
|
|
|
|
using Umbraco.Core.Models.PublishedContent;
|
|
|
|
|
|
using Umbraco.Core.Xml;
|
|
|
|
|
|
|
|
|
|
|
|
namespace Umbraco.Web
|
|
|
|
|
|
{
|
2017-07-27 12:01:38 +02:00
|
|
|
|
using Examine = global::Examine;
|
|
|
|
|
|
|
2016-06-30 18:35:43 +02:00
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Query methods used for accessing strongly typed content in templates
|
|
|
|
|
|
/// </summary>
|
|
|
|
|
|
public interface IPublishedContentQuery
|
|
|
|
|
|
{
|
|
|
|
|
|
IPublishedContent Content(int id);
|
2016-11-03 10:31:44 +01:00
|
|
|
|
IPublishedContent Content(Guid id);
|
2017-09-08 19:39:13 +02:00
|
|
|
|
IPublishedContent Content(Udi id);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
IPublishedContent ContentSingleAtXPath(string xpath, params XPathVariable[] vars);
|
|
|
|
|
|
IEnumerable<IPublishedContent> Content(IEnumerable<int> ids);
|
2016-11-03 10:31:44 +01:00
|
|
|
|
IEnumerable<IPublishedContent> Content(IEnumerable<Guid> ids);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
IEnumerable<IPublishedContent> ContentAtXPath(string xpath, params XPathVariable[] vars);
|
|
|
|
|
|
IEnumerable<IPublishedContent> ContentAtXPath(XPathExpression xpath, params XPathVariable[] vars);
|
|
|
|
|
|
IEnumerable<IPublishedContent> ContentAtRoot();
|
|
|
|
|
|
|
|
|
|
|
|
IPublishedContent Media(int id);
|
2016-11-05 12:22:57 +01:00
|
|
|
|
IPublishedContent Media(Guid id);
|
2017-09-08 19:39:13 +02:00
|
|
|
|
IPublishedContent Media(Udi id);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
IEnumerable<IPublishedContent> Media(IEnumerable<int> ids);
|
2016-11-05 12:22:57 +01:00
|
|
|
|
IEnumerable<IPublishedContent> Media(IEnumerable<Guid> ids);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
IEnumerable<IPublishedContent> MediaAtRoot();
|
|
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
2018-03-27 10:04:07 +02:00
|
|
|
|
/// Searches content.
|
2016-06-30 18:35:43 +02:00
|
|
|
|
/// </summary>
|
2018-03-27 18:14:21 +11:00
|
|
|
|
IEnumerable<PublishedSearchResult> Search(string term, bool useWildCards = true, string indexName = null);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
2018-03-27 10:04:07 +02:00
|
|
|
|
/// Searches content.
|
|
|
|
|
|
/// </summary>
|
2018-03-29 15:39:48 +11:00
|
|
|
|
IEnumerable<PublishedSearchResult> Search(int skip, int take, out int totalRecords, string term, bool useWildCards = true, string indexName = null);
|
2018-03-27 10:04:07 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Searches content.
|
2016-06-30 18:35:43 +02:00
|
|
|
|
/// </summary>
|
2018-03-27 18:14:21 +11:00
|
|
|
|
IEnumerable<PublishedSearchResult> Search(Examine.SearchCriteria.ISearchCriteria criteria, Examine.ISearcher searchProvider = null);
|
2018-03-27 10:04:07 +02:00
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
|
/// Searches content.
|
|
|
|
|
|
/// </summary>
|
2018-03-29 15:39:48 +11:00
|
|
|
|
IEnumerable<PublishedSearchResult> Search(int skip, int take, out int totalRecords, Examine.SearchCriteria.ISearchCriteria criteria, Examine.ISearcher searchProvider = null);
|
2016-06-30 18:35:43 +02:00
|
|
|
|
}
|
2017-07-20 11:21:28 +02:00
|
|
|
|
}
|