FilterBase Class

NOTE: This API is now obsolete.

Provides an abstract base class for filters in the Business Data Catalog.

Inheritance Hierarchy

System.Object
  Microsoft.Office.Server.ApplicationRegistry.Runtime.FilterBase
    Microsoft.Office.Server.ApplicationRegistry.Runtime.SystemFilter
    Microsoft.Office.Server.ApplicationRegistry.Runtime.UserInputFilter

Namespace:  Microsoft.Office.Server.ApplicationRegistry.Runtime
Assembly:  Microsoft.SharePoint.Portal (in Microsoft.SharePoint.Portal.dll)

Syntax

'Declaration
<SerializableAttribute> _
<ObsoleteAttribute("O12 Application Registry API is deprecated. Please use BusinessData.",  _
    False)> _
<SharePointPermissionAttribute(SecurityAction.LinkDemand, ObjectModel := True)> _
<SharePointPermissionAttribute(SecurityAction.InheritanceDemand, ObjectModel := True)> _
Public MustInherit Class FilterBase
'Usage
Dim instance As FilterBase
[SerializableAttribute]
[ObsoleteAttribute("O12 Application Registry API is deprecated. Please use BusinessData.", 
    false)]
[SharePointPermissionAttribute(SecurityAction.LinkDemand, ObjectModel = true)]
[SharePointPermissionAttribute(SecurityAction.InheritanceDemand, ObjectModel = true)]
public abstract class FilterBase

Remarks

Filters are annotations on methods that capture the parameters users or the system provides to restrict the instances that are returned. The metadata author 'tags' a particular 'slot' or field in an input parameter to a back-end API with the filterdescriptor and then when the user or system sets the value on the filter, that value is written into the field when the method is executed, overriding the default value for that field. A method can support zero or more filters.

Line-of-business (LOB) systems provide various filtering mechanisms. The Business Data Catalog abstracts common patterns so that it can provide users with the same filtering semantics, regardless of the data source. The Business Data Catalog supports the following filters and filtering patterns:

  • Comparison filter   Limits the instances returned to those where the specified condition is met.

  • Wildcard filter   Limits the instances returned to those where field like value, where value may contain the asterisk (*) wildcard character. Users can use this filter type to present more user-friendly filters such as "starts with" and "contains".

  • Limit filter   Limits the number of instances returned to n. SQL supports this filter with the SELECT TOP clause. By using a Limit filter, you can prevent long waits and time outs, and also prevent users from issuing bad queries that request a large amount of data.

  • UserContext filter   Limits the instances by the current user's context. This filter tells the Business Data Catalog to append the current Microsoft Windows user's domain\username to the method call. In Forms authentication, the Business Data Catalog appends the forms authentication user name.

  • Username filter   Limits the instances by a single sign-on (SSO) username. This filter tells the Business Data Catalog to pass the username from SSO as part of a parameter to the method call.

  • Password filter   Works with the Username filter. This filter tells the Business Data Catalog to pass the password from SSO as part of a parameter to the method call.

    Note

    The back-end method definition should support the filters. Only then can you, in a context-sensitive manner, use filters to reflect in the front-end Web server the functionality that is available in the back-end application. The metadata simply declares which filters a method supports.

  • UserProfile filter   Specified in the FilterDescriptor definition. To use this simple filter, declare a filter of the type UserProfile" and add a System.String property with the name "UserProfilePropertyName", whose value is the name of a User Profile property. The Business Data Catalog looks up the current user's profile, reads the value of the property with this name, and plumbs that through to the back-end method that is invoked.

  • SSOTicket filter   Tells the Business Data Catalog to pass the SSO ticket from SSO as part of a parameter to the method call.

  • LastIdSeen filter   Enables chunking for IDEnumerator objects. For Web services and other non-streaming back-end applications, use the LastIdSeen filter in your IDEnumerator object, as shown in the following code example, to improve performance:

    SELECT TOP 100 Id FROM Customers WHERE Id>=@LastIdSeen
    ORDER BY Id
    

Thread Safety

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

See Also

Reference

FilterBase Members

Microsoft.Office.Server.ApplicationRegistry.Runtime Namespace