MCPcopy
hub / github.com/zxing-js/library / encode

Method encode

src/core/Writer.ts:55–55  ·  view source on GitHub ↗

* @param contents The contents to encode in the barcode * @param format The barcode format to generate * @param width The preferred width in pixels * @param height The preferred height in pixels * @param hints Additional parameters to supply to the encoder * @return {@link B

(
        contents: string,
        format: BarcodeFormat,
        width: number /*int*/,
        height: number /*int*/,
        hints: Map<EncodeHintType, any>
    )

Source from the content-addressed store, hash-verified

53 * @throws WriterException if contents cannot be encoded legally in a format
54 */
55 encode(
56 contents: string,
57 format: BarcodeFormat,
58 width: number /*int*/,

Callers 13

writeFunction · 0.65
encodeFunction · 0.65
writeMethod · 0.65
encodeMethod · 0.65
Encoder.spec.tsFile · 0.65
testEncodeFunction · 0.65
testEncodeDecodeFunction · 0.65
testWriterFunction · 0.65

Implementers 15

MultiFormatWritersrc/core/MultiFormatWriter.ts
DataMatrixWritersrc/core/datamatrix/DataMatrixWriter.t
QRCodeWritersrc/core/qrcode/QRCodeWriter.ts
AztecWritersrc/core/aztec/AztecWriter.ts
C40Encodersrc/core/datamatrix/encoder/C40Encoder
MinimalEncodersrc/core/datamatrix/encoder/MinimalEnc
ASCIIEncodersrc/core/datamatrix/encoder/ASCIIEncod
EdifactEncodersrc/core/datamatrix/encoder/EdifactEnc
Base256Encodersrc/core/datamatrix/encoder/Base256Enc
X12Encodersrc/core/datamatrix/encoder/X12Encoder
ECIEncoderSetsrc/core/common/ECIEncoderSet.ts
ReedSolomonEncodersrc/core/common/reedsolomon/ReedSolomo

Calls

no outgoing calls

Tested by 5

testEncodeFunction · 0.52
testEncodeDecodeFunction · 0.52
testWriterFunction · 0.52