One Logo Pool Ball
Accelerate · IOS API REFERENCE

BNNSGraph.Builder.SliceRange

struct · iOS 26.0+ · SDK 27.1

struct SliceRange

A structure that represents a range. You can use standard Swift range operators to specify the range in slice operation. However, the `BNNSGraph.Builder.SliceRange` structure provides additional functionality: * You can specify a `stop` that's less that the `start` value. * You can supply negative `startIndex` and `endIndex` values to indicate the index is relative to the end of sequence * You can specify the stride. * You can specify an `UnboundedRange` with the `fillAll` constant. For example, the following code shows a slice operation that selects dimensions using a `SliceRange`, a Swift range, and an integer. ``` let slice = src[BNNSGraph.Builder.SliceRange(startIndex: 1, endIndex: -1), 5 ... 20, 3] ```

Members (4)

init · iOS 26.0+

init

TypeScript
static init(startIndex: number, endIndex: number): BNNSGraph_Builder_SliceRange
Swift declaration
init(startIndex: Int = 0, endIndex: Int)

Returns a new slice range structure.

get · iOS 26.0+

startIndex

TypeScript
get startIndex(): number
Swift declaration
let startIndex: Int
get · iOS 26.0+

fillAll

TypeScript
static get fillAll(): BNNSGraph_Builder_SliceRange
Swift declaration
static let fillAll: BNNSGraph.Builder.SliceRange

The same as the ellipsis literal `...` used to indicate unspecified dimensions of the tensor.

get · iOS 26.0+

endIndex

TypeScript
get endIndex(): number
Swift declaration
let endIndex: Int

Skipped declarations

No declarations were skipped in this snapshot.

All Accelerate types →