This repository was archived by the owner on Mar 9, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathArrayIterationCallback.cs
More file actions
40 lines (34 loc) · 1.62 KB
/
ArrayIterationCallback.cs
File metadata and controls
40 lines (34 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
// ArrayIterationCallback.cs
// Script#/Libraries/jQuery/Core
// This source code is subject to terms and conditions of the Apache License, Version 2.0.
//
using System;
using System.Runtime.CompilerServices;
namespace jQueryApi {
/// <summary>
/// A callback to be invoked for each item in an array being iterated.
/// </summary>
/// <param name="index">The index of the item.</param>
/// <param name="value">The item within the array.</param>
public delegate void ArrayIterationCallback(int index, object value);
/// <summary>
/// A callback to be invoked for each item in an array being iterated.
/// </summary>
/// <param name="index">The index of the item.</param>
/// <param name="value">The item within the array.</param>
public delegate void ArrayIterationCallback<T>(int index, T value);
/// <summary>
/// A callback to be invoked for each item in an array being iterated.
/// </summary>
/// <param name="index">The index of the item.</param>
/// <param name="value">The item within the array.</param>
/// <returns>false if the iteration is to be stopped; true otherwise.</returns>
public delegate bool ArrayInterruptableIterationCallback(int index, object value);
/// <summary>
/// A callback to be invoked for each item in an array being iterated.
/// </summary>
/// <param name="index">The index of the item.</param>
/// <param name="value">The item within the array.</param>
/// <returns>false if the iteration is to be stopped; true otherwise.</returns>
public delegate bool ArrayInterruptableIterationCallback<T>(int index, T value);
}