Class HIBCPASCodetext
ชื่อพื้นที่: Aspose.BarCode.ComplexBarcode การประกอบ: Aspose.BarCode.dll (25.4.0)
ประเภทการเข้ารหัสและ decoding the text embedded in the HIBC PAS code
public class HIBCPASCodetext : IComplexCodetext
Inheritance
Implements
อนุญาโตตุลาการ
object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()
Examples
ตัวอย่างนี้แสดงให้เห็นวิธีการเข้ารหัสและ decode HIBC PAS โดยใช้ HIBCPASCodetext
HIBCPASComplexCodetext complexCodetext = new HIBCPASComplexCodetext();
complexCodetext.DataLocation = HIBCPASDataLocation.Patient;
complexCodetext.AddRecord(HIBCPASDataType.LabelerIdentificationCode, "A123");
complexCodetext.AddRecord(HIBCPASDataType.ManufacturerSerialNumber, "SERIAL123");
complexCodetext.BarcodeType = EncodeTypes.HIBCDataMatrixPAS;
using (ComplexBarcodeGenerator generator = new ComplexBarcodeGenerator(complexCodetext))
{
using (BarCodeReader reader = new BarCodeReader(generator.GenerateBarCodeImage(), DecodeType.HIBCDataMatrixPAS))
{
reader.ReadBarCodes();
string codetext = reader.FoundBarCodes[0].CodeText;
HIBCPASComplexCodetext readCodetext = ComplexCodetextReader.TryDecodeHIBCPAS(codetext);
Console.WriteLine("Data location: {0}", readCodetext.DataLocation);
Console.Write("Data type: {0}. ", readCodetext.GetRecords()[0].DataType);
Console.WriteLine("Data: {0}", readCodetext.GetRecords()[0].Data);
Console.Write("Data type: {0}. ", readCodetext.GetRecords()[1].DataType);
Console.WriteLine("Data: {0}", readCodetext.GetRecords()[1].Data);
}
}
Constructors
ไฮบีคโปสโค้ด()
public HIBCPASCodetext()
Properties
BarcodeType
รับหรือตั้งค่าประเภทรหัสรหัส HIBC PAS สามารถเข้ารหัสได้โดยใช้ HIBCCode39PAS, HIBCCode128PAS, HIBCAztec:PAS, HIBCDataMatrixPAS และ HIBCQRPAS ประเภทรหัสค่าเริ่มต้น: HIBCCode39PAS
public BaseEncodeType BarcodeType { get; set; }
คุณสมบัติมูลค่า
DataLocation
การระบุตําแหน่งข้อมูล
public HIBCPASDataLocation DataLocation { get; set; }
คุณสมบัติมูลค่า
Methods
AddRecord(HIBCPASDataType, string)
เพิ่มรายชื่อใหม่
public void AddRecord(HIBCPASDataType dataType, string data)
Parameters
dataType
HIBCPASDataType
ประเภทข้อมูล
data
string
รั้วข้อมูล
AddRecord(บันทึก)
เพิ่มรายชื่อใหม่
public void AddRecord(HIBCPASRecord record)
Parameters
record
HIBCPASRecord
บันทึกที่จะเพิ่ม
Clear()
เคลือบรายการบันทึก
public void Clear()
Equals(วัตถุ)
กลับค่าแสดงให้เห็นว่าตัวอย่างนี้เท่ากับค่า Aspose.BarCode.ComplexBarcode.HIBCPASCodetext ที่ระบุไว้
public override bool Equals(object obj)
Parameters
obj
object
คะแนน Aspose.BarCode.ComplexBarcode.HIBCPASCodetext เพื่อเปรียบเทียบกับตัวอย่างนี้
Returns
จริง ถ้า obj มีมูลค่าเดียวกันกับตัวอย่างนี้ อย่างไรก็ตาม The translation of “false” to Thai is “เท็จ”..
GetBarcodeType()
รับประเภทรหัสบาร์
public BaseEncodeType GetBarcodeType()
Returns
บาร์โค้ดประเภท
GetConstructedCodetext()
สร้าง codetext
public string GetConstructedCodetext()
Returns
โครงสร้างโค้ด
GetHashCode()
กลับรหัส hash สําหรับตัวอย่างนี้
public override int GetHashCode()
Returns
32 บิตลงชื่อรหัส hash ทั้งหมด
GetRecords()
รับรายการบันทึก
public List<hibcpasrecord> GetRecords()
Returns
List < HIBCPASRecord >
รายการบันทึก
InitFromString(รั้ว)
เริ่มต้นตัวอย่างจากโค้ดข้อความที่สร้างขึ้น
public void InitFromString(string constructedCodetext)
Parameters
constructedCodetext
string
โครงสร้างโค้ด