newIndex

public static ShardIndex newIndex(int indexValue, int ofTotal)

Creates a new ShardIndex according to the passed shard index

The passed shard index value must be less than the total number of shards specified.

Both passed values must not be negative.

Return

a new instance of the ShardIndex

Parameters

indexValue

the value of the shard index, zero-based

ofTotal

the total number of shard