C# Class Rock.Model.CategoryService

Data access/service class for Rock.Model.Category objects.
Mostrar archivo Open project: NewSpring/Rock Class Usage Examples

Public Methods

Method Description
Get ( int ParentId, int entityTypeId ) : IQueryable

Returns a queryable collection of Rock.Model.Category">Categories by parent Rock.Model.EntityType.

Get ( string name, int entityTypeId, string entityTypeQualifierColumn, string entityTypeQualifierValue ) : IQueryable

Returns a queryable collection of Rock.Model.Category">Categories by Name,

GetAllDescendents ( System.Guid parentCategoryGuid ) : IEnumerable

Returns an enumerable collection of Rock.Model.Category">Category that are descendants of a

GetAllDescendents ( int parentCategoryId ) : IEnumerable

Returns an enumerable collection of Rock.Model.Category">Category that are descendants of a

GetByEntityTypeId ( int entityTypeId ) : IQueryable

Returns a enumerable collection of Rock.Model.Category">Categories by

GetGuid ( int id ) : Guid?

Gets the Guid for the Category that has the specified Id

GetNavigationItems ( int entityTypeId, List selectedCategoryGuids, bool includeAllChildren, Person currentPerson ) : List

Gets all of the categories that were selected and optionally all the child categories of the selected categories

Private Methods

Method Description
GetNavigationChildren ( int parentCategoryId, IEnumerable categories, List selectedCategoryGuids, bool checkSelected, bool includeAllChildren, Person currentPerson ) : List

Gets the navigation children.

Method Details

Get() public method

Returns a queryable collection of Rock.Model.Category">Categories by parent Rock.Model.EntityType.
public Get ( int ParentId, int entityTypeId ) : IQueryable
ParentId int A representing the CategoryID of the parent to search by. To find Categories /// that do not inherit from a parent category, this value will be null.
entityTypeId int A representing the EntityTypeId of the to search by.
return IQueryable

Get() public method

Returns a queryable collection of Rock.Model.Category">Categories by Name,
public Get ( string name, int entityTypeId, string entityTypeQualifierColumn, string entityTypeQualifierValue ) : IQueryable
name string A representing the name to search by.
entityTypeId int A representing the EntityType of the to search by.
entityTypeQualifierColumn string A representing the name of the Qualifier Column to search by.
entityTypeQualifierValue string A representing the name of the Qualifier Value to search by.
return IQueryable

GetAllDescendents() public method

Returns an enumerable collection of Rock.Model.Category">Category that are descendants of a
public GetAllDescendents ( System.Guid parentCategoryGuid ) : IEnumerable
parentCategoryGuid System.Guid The parent category unique identifier.
return IEnumerable

GetAllDescendents() public method

Returns an enumerable collection of Rock.Model.Category">Category that are descendants of a
public GetAllDescendents ( int parentCategoryId ) : IEnumerable
parentCategoryId int A representing the Id of the
return IEnumerable

GetByEntityTypeId() public method

Returns a enumerable collection of Rock.Model.Category">Categories by
public GetByEntityTypeId ( int entityTypeId ) : IQueryable
entityTypeId int A representing the EntityTypeId of the to search by.
return IQueryable

GetGuid() public method

Gets the Guid for the Category that has the specified Id
public GetGuid ( int id ) : Guid?
id int The identifier.
return Guid?

GetNavigationItems() public method

Gets all of the categories that were selected and optionally all the child categories of the selected categories
public GetNavigationItems ( int entityTypeId, List selectedCategoryGuids, bool includeAllChildren, Person currentPerson ) : List
entityTypeId int The entity type identifier.
selectedCategoryGuids List The selected category guids.
includeAllChildren bool if set to true will include all the child categories of any selected category.
currentPerson Person The current person.
return List