Class HIBCLICCombinedCodetext
A név: Aspose.BarCode.ComplexBarcode Összefoglaló: Aspose.BarCode.dll (25.5.0)
A HIBC LIC kódba beágyazott szöveg kódolására és dekódolására szolgáló osztály, amely elsődleges és másodlagos adatokat tárol.
public class HIBCLICCombinedCodetext : HIBCLICComplexCodetext, IComplexCodetextInheritance
object ← HIBCLICComplexCodetext ← HIBCLICCombinedCodetext
Implements
Örökletes tagok
HIBCLICComplexCodetext.GetConstructedCodetext() , HIBCLICComplexCodetext.InitFromString(string) , HIBCLICComplexCodetext.GetBarcodeType() , HIBCLICComplexCodetext.BarcodeType , object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()
Examples
Ez a minta azt mutatja, hogyan kell kódolni és dekódolni HIBC LIC használatával HIBCLICCombinedCodetext.
HIBCLICCombinedCodetext combinedCodetext = new HIBCLICCombinedCodetext();
combinedCodetext.BarcodeType = EncodeTypes.HIBCQRLIC;
combinedCodetext.PrimaryData = new PrimaryData();
combinedCodetext.PrimaryData.ProductOrCatalogNumber = "12345";
combinedCodetext.PrimaryData.LabelerIdentificationCode = "A999";
combinedCodetext.PrimaryData.UnitOfMeasureID = 1;
combinedCodetext.SecondaryAndAdditionalData = new SecondaryAndAdditionalData();
combinedCodetext.SecondaryAndAdditionalData.ExpiryDate = DateTime.Now;
combinedCodetext.SecondaryAndAdditionalData.ExpiryDateFormat = HIBCLICDateFormat.MMDDYY;
combinedCodetext.SecondaryAndAdditionalData.Quantity = 30;
combinedCodetext.SecondaryAndAdditionalData.LotNumber = "LOT123";
combinedCodetext.SecondaryAndAdditionalData.SerialNumber = "SERIAL123";
combinedCodetext.SecondaryAndAdditionalData.DateOfManufacture = DateTime.Now;
using (ComplexBarcodeGenerator generator = new ComplexBarcodeGenerator(combinedCodetext))
{
    Bitmap image = generator.GenerateBarCodeImage();
    using (BarCodeReader reader = new BarCodeReader(image, DecodeType.HIBCQRLIC))
    {
        reader.ReadBarCodes();
        string codetext = reader.FoundBarCodes[0].CodeText;
        HIBCLICCombinedCodetext result = (HIBCLICCombinedCodetext)ComplexCodetextReader.TryDecodeHIBCLIC(codetext);
        Console.WriteLine("Product or catalog number: " + result.PrimaryData.ProductOrCatalogNumber);
        Console.WriteLine("Labeler identification code: " + result.PrimaryData.LabelerIdentificationCode);
        Console.WriteLine("Unit of measure ID: " + result.PrimaryData.UnitOfMeasureID);
        Console.WriteLine("Expiry date: " + result.SecondaryAndAdditionalData.ExpiryDate);
        Console.WriteLine("Quantity: " + result.SecondaryAndAdditionalData.Quantity);
        Console.WriteLine("Lot number: " + result.SecondaryAndAdditionalData.LotNumber);
        Console.WriteLine("Serial number: " + result.SecondaryAndAdditionalData.SerialNumber);
        Console.WriteLine("Date of manufacture: " + result.SecondaryAndAdditionalData.DateOfManufacture);
    }
}Constructors
CsehországCombinedCodetext()
public HIBCLICCombinedCodetext()Properties
PrimaryData
Az elsődleges adatok azonosítása.
public PrimaryData PrimaryData { get; set; }ingatlan értéke
SecondaryAndAdditionalData
Másodlagos és kiegészítő adatok azonosítása.
public SecondaryAndAdditionalData SecondaryAndAdditionalData { get; set; }ingatlan értéke
Methods
Equals(objektum)
Visszatér egy értéket, amely azt jelzi, hogy ez az eset egyenlő-e egy meghatározott Aspose.BarCode.ComplexBarcode.HIBCLICCombinedCodetext értéket.
public override bool Equals(object obj)Parameters
obj object
Egy Aspose.BarCode.ComplexBarcode.HIBCLICCombinedCodetext érték összehasonlítani ezt a példát.
Returns
Igazság ha az obj-nak ugyanolyan értéke van, mint a jelen esetben; egyébként, hamis.
GetConstructedCodetext()
Kódszöveg készítése
public override string GetConstructedCodetext()Returns
épített kódszöveg
GetHashCode()
Visszaadja a hash kódot erre az esetre.
public override int GetHashCode()Returns
Egy 32 bites hash kódot írt alá.
InitFromString(A string)
Elindítja a példát az épített kódszövegből.
public override void InitFromString(string constructedCodetext)Parameters
constructedCodetext string
Az épített kódszöveg.