Class AztecOptions
How Aztec(string, AztecOptions?) makes a symbol; every unset property is chosen automatically.
public sealed record AztecOptions : IEquatable<AztecOptions>
- Inheritance
-
AztecOptions
- Implements
- Inherited Members
Examples
// The smallest compact or full-range symbol with at least 23 % error correction; no quiet zone needed.
Barcode ticket = Barcode.Aztec("EG1234 BER-MUC 2026-10-19 SEAT 12A DOE/JANE");
// More error correction for a ticket that gets folded, or a fixed compact size.
Barcode robust = Barcode.Aztec("EG1234 BER-MUC", new AztecOptions { ErrorCorrectionPercent = 50 });
Barcode compact = Barcode.Aztec("EG1234", new AztecOptions { Compact = true, Layers = 2 });
// A rune: one value from 0 to 255 in an 11 x 11 core.
Barcode rune = Barcode.AztecRune(42);
Properties
Compact
Gets a value indicating whether the symbol is compact (1 to 4 layers, 15 x 15 to 27 x 27 modules) or full-range (up to 32 layers, 151 x 151), or null, the default, for whichever is smallest.
public bool? Compact { get; init; }
Property Value
- bool?
Default
Gets the defaults.
public static AztecOptions Default { get; }
Property Value
ErrorCorrectionPercent
Gets the share of the codewords, in percent, that must at least go to error correction, plus 3 codewords; or null, the default, for the 23 % the standard recommends. Spare room in the symbol goes to error correction too.
public int? ErrorCorrectionPercent { get; init; }
Property Value
- int?
Exceptions
- ArgumentOutOfRangeException
The value is not 5 to 95.
Layers
Gets the number of data layers, 1 to 32 (1 to 4 when compact), or null, the default, for the fewest that fit.
public int? Layers { get; init; }
Property Value
- int?
Exceptions
- ArgumentOutOfRangeException
The value is not 1 to 32.