ModelMemberCollection<TItemType, TFindType>.Find Method (TFindType, Boolean)
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Searches the collection for the given key and returns it if it is found. If the key is not found, this method throws an exception or returns nulla null reference (Nothing in Visual Basic), depending on the value passed to throwOnError.
Namespace: System.Activities.Design.Model
Assembly: System.Activities.Design.Base (in System.Activities.Design.Base.dll)
Syntax
'Declaration
Protected MustOverride Function Find ( _
value As TFindType, _
throwOnError As Boolean _
) As TItemType
'Usage
Dim value As TFindType
Dim throwOnError As Boolean
Dim returnValue As TItemType
returnValue = Me.Find(value, throwOnError)
protected abstract TItemType Find(
TFindType value,
bool throwOnError
)
protected:
virtual TItemType Find(
TFindType value,
bool throwOnError
) abstract
protected abstract function Find(
value : TFindType,
throwOnError : boolean
) : TItemType
abstract Find :
value:'TFindType *
throwOnError:bool -> 'TItemType
Parameters
- value
Type: TFindType
The type of the given key.
- throwOnError
Type: System.Boolean
true to throw an exception if the given key is not found; otherwise, false.
Return Value
Type: TItemType
Returns [{0}] .
Exceptions
Exception | Condition |
---|---|
ArgumentException | Throws if value is not found and throwOnError is true. |
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.
Platforms
Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008, Windows Server 2003
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
Version Information
.NET Framework
Supported in: 4
See Also
Reference
ModelMemberCollection<TItemType, TFindType> Class