Unit Price Text Builder

Defined under the namespace Scandit.Datacapture.Label

UnitPriceTextBuilder
class UnitPriceTextBuilder : TextFieldBuilder<UnitPriceTextBuilder, UnitPriceText>

Added in version 7.2.0

Builder class for creating UnitPriceText field definitions. Provides a fluent interface for configuring unit price text field properties including validation patterns and data type patterns.

setDataTypePatterns(dataTypePatterns)
setDataTypePatterns(dataTypePatterns: string[]): this

Added in version 7.4.0

Sets the identifying text patterns (data type patterns) from a list of strings.

setDataTypePattern(dataTypePattern)
setDataTypePattern(dataTypePattern: string): this

Added in version 7.4.0

Used to specify keywords or phrases that help identify the context of the field. This is particularly useful when the label contains multiple fields that could match the same pattern (e.g., when both packaging and expiry dates are present).

resetDataTypePatterns()
resetDataTypePatterns(): this

Added in version 7.4.0

All pre-built fields come with default patterns and dataTypePatterns that are suitable for most use cases. Using either method is optional and will override the defaults.

This method can be used to remove the default dataTypePattern, allowing you to rely solely on the patterns for detection.

build(name)
build(name: string): Promise<UnitPriceText>

Added in version 7.2.0

Creates a UnitPriceText field definition with the specified name and all configured properties.