Share via


SPWorkflowTemplate.IComparer.Compare method

Compares two specified SPWorkflowTemplate objects and returns a value that indicates whether one object is less than, equal to, or greater than the other.

Namespace:  Microsoft.SharePoint.Workflow
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Private Function Compare ( _
    o1 As Object, _
    o2 As Object _
) As Integer Implements IComparer.Compare
'Usage
Dim instance As SPWorkflowTemplate
Dim o1 As Object
Dim o2 As Object
Dim returnValue As Integer

returnValue = CType(instance, IComparer).Compare(o1, _
    o2)
intIComparer.Compare(
    Object o1,
    Object o2
)

Parameters

Return value

Type: System.Int32
The relative difference between two specified SPWorkflowTemplate objects, as shown in the following table:

Value

Condition

-1

o1 is less than o2.

0

o1 is equal to o2.

1

o1 is greater than o2.

Implements

IComparer.Compare(Object, Object)

Remarks

One or both comparands can be a null reference. By definition, any object compares greater than a null reference; and two null references are equal to each other.

This member is an explicit interface implementation. It can be used only when the SPWorkflowTemplate instance is cast to an IComparer interface.

See also

Reference

SPWorkflowTemplate class

SPWorkflowTemplate members

Microsoft.SharePoint.Workflow namespace