Class SearchCriteriaCollection
Represents a collection of SearchCriteria objects.
Inheritance
Namespace: DotNetNuke.Services.Search
Assembly: DotNetNuke.dll
Syntax
public class SearchCriteriaCollection : CollectionBase
Constructors
| Improve this Doc View SourceSearchCriteriaCollection()
Initializes a new instance of the SearchCriteriaCollection class.
Declaration
public SearchCriteriaCollection()
SearchCriteriaCollection(SearchCriteria[])
Initializes a new instance of the SearchCriteriaCollection class containing the specified array of SearchCriteria objects.
Declaration
public SearchCriteriaCollection(SearchCriteria[] value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria[] | value | An array of SearchCriteria objects with which to initialize the collection. |
SearchCriteriaCollection(SearchCriteriaCollection)
Initializes a new instance of the SearchCriteriaCollection class containing the elements of the specified source collection.
Declaration
public SearchCriteriaCollection(SearchCriteriaCollection value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteriaCollection | value | A SearchCriteriaCollection with which to initialize the collection. |
SearchCriteriaCollection(String)
Initializes a new instance of the SearchCriteriaCollection class containing the elements of the specified source collection.
Declaration
public SearchCriteriaCollection(string value)
Parameters
Type | Name | Description |
---|---|---|
System.String | value | A criteria string with which to initialize the collection. |
Properties
| Improve this Doc View SourceItem[Int32]
Gets the SearchCriteriaCollection at the specified index in the collection.
In VB.Net, this property is the indexer for the SearchCriteriaCollection class.
Declaration
public SearchCriteria this[int index] { get; set; }
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index |
Property Value
Type | Description |
---|---|
SearchCriteria |
Methods
| Improve this Doc View SourceAdd(SearchCriteria)
Add an element of the specified SearchCriteria to the end of the collection.
Declaration
public int Add(SearchCriteria value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria | value | An object of type SearchCriteria to add to the collection. |
Returns
Type | Description |
---|---|
System.Int32 | The position into which the new element was inserted, or -1 to indicate that the item was not inserted into the collection. |
AddRange(SearchCriteria[])
Copies the elements of the specified SearchCriteria array to the end of the collection.
Declaration
public void AddRange(SearchCriteria[] value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria[] | value | An array of type SearchCriteria containing the objects to add to the collection. |
AddRange(SearchCriteriaCollection)
Adds the contents of another SearchCriteriaCollection to the end of the collection.
Declaration
public void AddRange(SearchCriteriaCollection value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteriaCollection | value | A SearchCriteriaCollection containing the objects to add to the collection. |
Contains(SearchCriteria)
Gets a value indicating whether the collection contains the specified SearchCriteriaCollection.
Declaration
public bool Contains(SearchCriteria value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria | value | The SearchCriteriaCollection to search for in the collection. |
Returns
Type | Description |
---|---|
System.Boolean | true if the collection contains the specified object; otherwise, false. |
CopyTo(SearchCriteria[], Int32)
Copies the collection objects to a one-dimensional System.Array instance beginning at the specified index.
Declaration
public void CopyTo(SearchCriteria[] array, int index)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria[] | array | The one-dimensional System.Array that is the destination of the values copied from the collection. |
System.Int32 | index | The index of the array at which to begin inserting. |
IndexOf(SearchCriteria)
Gets the index in the collection of the specified SearchCriteriaCollection, if it exists in the collection.
Declaration
public int IndexOf(SearchCriteria value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria | value | The SearchCriteriaCollection to locate in the collection. |
Returns
Type | Description |
---|---|
System.Int32 | The index in the collection of the specified object, if found; otherwise, -1. |
Insert(Int32, SearchCriteria)
Add an element of the specified SearchCriteria to the collection at the designated index.
Declaration
public void Insert(int index, SearchCriteria value)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | index | An |
SearchCriteria | value | An object of type SearchCriteria to add to the collection. |
Remove(SearchCriteria)
Remove the specified object of type SearchCriteria from the collection.
Declaration
public void Remove(SearchCriteria value)
Parameters
Type | Name | Description |
---|---|---|
SearchCriteria | value | An object of type SearchCriteria to remove to the collection. |
ToArray()
Creates a one-dimensional System.Array instance containing the collection items.
Declaration
public SearchCriteria[] ToArray()
Returns
Type | Description |
---|---|
SearchCriteria[] | Array of type SearchCriteria. |