Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

On this site, all the security filters that only work for the IRole DB Entity are listedare built to check the security of IRoles.

Filter

RoleAttributeValueFilter

This security filter checks if a role attribute value exists that match the filter and then gives you access to a role entity.

Code Block
languagec#
/// <typeparam name="TFilterPropertyType">The filter type you want to find the correct attribute values</typeparam>
/// <param name="subPropertyChain">Path to the property to filter the possible attribute values</param>
/// <param name="filterValue">The filter to search the attribute values to check</param>
/// <param name="attributeValueFilterBehaviour">Behaviour how to filter the attribute values based on attributeValueFilterValue</param>
/// <param name="attributeValueFilterValue">The filter value you want to apply to the attribute values</param>
/// <param name="attributeValueType">The type how the attribute value is serialized into the database</param>
RoleAttributeValueFilter<TFilterPropertyType> (Expression<Func<IRoleAttributeValue, TFilterPropertyType>> subPropertyChain, TFilterPropertyType filterValue, StringFilterBehaviour attributeValueFilterBehaviour, string attributeValueFilterValue, string attributeValueType) : base(c => c.RoleAttributeValues, subPropertyChain)

Possible filter behaviors:

Code Block
languagec#
  Equals,
  StartsWith,
  EndsWith,
  Contains

Example:

Code Block
languagec#
new RoleAttributeValueFilter<uint>(c => c.Attribute.Id, 1, StringFilterBehaviour.EndsWith, "li", "string")

...