[This is preliminary documentation and is subject to change.]
Returns the count of items in work segment along with the start index of the first item to be processed
by a particular worker in the worker set
Namespace: NFXAssembly: NFX (in NFX.dll) Version: 3.0.0.1 (3.0.0.1)
public static int AssignWorkSegment(
int totalItemCount,
int totalWorkerCount,
int thisWorkerIndex,
out int startIndex
)
public static int AssignWorkSegment(
int totalItemCount,
int totalWorkerCount,
int thisWorkerIndex,
out int startIndex
)
Public Shared Function AssignWorkSegment (
totalItemCount As Integer,
totalWorkerCount As Integer,
thisWorkerIndex As Integer,
<OutAttribute> ByRef startIndex As Integer
) As Integer
Public Shared Function AssignWorkSegment (
totalItemCount As Integer,
totalWorkerCount As Integer,
thisWorkerIndex As Integer,
<OutAttribute> ByRef startIndex As Integer
) As Integer
public:
static int AssignWorkSegment(
int totalItemCount,
int totalWorkerCount,
int thisWorkerIndex,
[OutAttribute] int% startIndex
)
public:
static int AssignWorkSegment(
int totalItemCount,
int totalWorkerCount,
int thisWorkerIndex,
[OutAttribute] int% startIndex
)
static member AssignWorkSegment :
totalItemCount : int *
totalWorkerCount : int *
thisWorkerIndex : int *
startIndex : int byref -> int
static member AssignWorkSegment :
totalItemCount : int *
totalWorkerCount : int *
thisWorkerIndex : int *
startIndex : int byref -> int
Parameters
- totalItemCount
- Type:
System Int32
Total item count in the set processed by all workers
- totalWorkerCount
- Type:
System Int32
Total number of workers int the set operating over the totalItemCount
- thisWorkerIndex
- Type:
System Int32
The index of THIS worker in the whole worker set
- startIndex
- Type:
System Int32
Returns the index of the first item in the assigned segment
Return Value
Type:
Int32The count of items in the assigned segment