MinimalECIInput

Class that converts a character string into a sequence of ECIs and bytes

The implementation uses the Dijkstra algorithm to produce minimal encodings

Inheritors

Constructors

Link copied to clipboard
constructor(stringToEncode: String, priorityCharset: KiteCharset?, fnc1: Int)

Constructs a minimal input

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun charAt(index: Int): Char

Returns the byte value at the specified index. An index ranges from zero to length() - 1. The first byte value of the sequence is at index zero, the next at index one, and so on, as for array indexing.

Link copied to clipboard
open override fun getECIValue(index: Int): Int

Returns the int ECI value at the specified index. An index ranges from zero to length() - 1. The first byte value of the sequence is at index zero, the next at index one, and so on, as for array indexing.

Link copied to clipboard
Link copied to clipboard
open override fun haveNCharacters(index: Int, n: Int): Boolean
Link copied to clipboard
open override fun isECI(index: Int): Boolean

Determines if a value is an ECI

Link copied to clipboard
fun isFNC1(index: Int): Boolean

Determines if a value is the FNC1 character

Link copied to clipboard
open override fun length(): Int

Returns the length of this input. The length is the number of bytes, FNC1 characters or ECIs in the sequence.

Link copied to clipboard
open override fun subSequence(start: Int, end: Int): CharSequence

Returns a CharSequence that is a subsequence of this sequence. The subsequence starts with the char value at the specified index and ends with the char value at index end - 1. The length (in chars) of the returned sequence is end - start, so if start == end then an empty sequence is returned.

Link copied to clipboard
open override fun toString(): String