Note

The Barcode Count mapping API is still in beta and may change in future versions of Scandit Data Capture SDK.

Barcode Spatial Grid

Defined in package com.scandit.datacapture.barcode.count.capture.map

BarcodeSpatialGrid
class BarcodeSpatialGrid

Added in version 6.17.0

Object that is returned by BarcodeCountSession.getSpatialMap(). Represents the result of mapping the barcodes in a grid. Depending on the scanned barcodes the grid could be incomplete so for some coordinates the returned barcode could be null.

rows()
int rows()

Added in version 6.17.0

Returns the number of rows in the grid.

columns()
int columns()

Added in version 6.17.0

Returns the number of columns in the grid.

barcodeAt(row, column)
@Nullable Barcode barcodeAt(int row,
        int column)

Added in version 6.17.0

Returns the barcode at the specified coordinates. If there is no barcode null is returned.

row(index)
@NonNull List<@NonNull Barcode> row(int index)

Added in version 6.17.0

Returns an array of Barcodes corresponding to the selected row.

Missing barcodes in the row will be represented by null.

column(index)
@NonNull List<@NonNull Barcode> column(int index)

Added in version 6.17.0

Returns an array of barcodes corresponding to the selected column.

Missing barcodes in the row will be represented by null.

coordinatesForBarcode(barcode)
@NonNull List<@NonNull Coordinate2d> coordinatesForBarcode(@NonNull Barcode barcode)

Added in version 6.17.0

Returns the list of coordinates for a specific barcode.

toJson()
@NonNull String toJson()

Added in version 6.19.0

Returns the JSON representation of the spatial grid.