Class MultyDecodeType

Class MultyDecodeType

Namespace: Aspose.BarCode.BarCodeRecognition
Assembly: Aspose.BarCode.dll (25.1.0)

复合解码类型。

public class MultyDecodeType : BaseDecodeType, IEquatable<basedecodetype>, IEquatable<multydecodetype>

继承

objectBaseDecodeTypeMultyDecodeType

实现

IEquatable<basedecodetype>, IEquatable<multydecodetype>

继承成员

BaseDecodeType.ContainsAny(params BaseDecodeType[]), BaseDecodeType.Equals(SingleDecodeType), BaseDecodeType.Equals(MultyDecodeType), BaseDecodeType.Equals(BaseDecodeType), BaseDecodeType.Equals(object), BaseDecodeType.GetHashCode(), BaseDecodeType.TryParse(string, out SingleDecodeType), BaseDecodeType.TryParse(string, out MultyDecodeType), BaseDecodeType.TryParse(string, out BaseDecodeType), object.GetType(), object.MemberwiseClone(), object.ToString(), object.Equals(object?), object.Equals(object?, object?), object.ReferenceEquals(object?, object?), object.GetHashCode()

示例

此示例演示如何创建复合的 MultyDecode 类型,该类型结合了 SingleDecodeType 和 MultiDecode 类型。

MultyDecodeType types1 = new MultyDecodeType(DecodeType.QR, DecodeType.DataMatrix);
MultyDecodeType types2 = new MultyDecodeType(types1, DecodeType.Code128, DecodeType.Code39);
Dim multyType1 As MultyDecodeType 
multyType1 = New MultyDecodeType(DecodeType.QR, DecodeType.DataMatrix)
Dim multyType2 As MultyDecodeType
multyType2 = New MultyDecodeType(multyType1, DecodeType.Code128, DecodeType.Code39)

构造函数

MultyDecodeType(params SingleDecodeType[])

初始化 Aspose.BarCode.BarCodeRecognition.MultyDecodeType 类的新实例。

public MultyDecodeType(params SingleDecodeType[] barcodeTypes)

参数

barcodeTypes SingleDecodeType[]

单解码类型数组

MultyDecodeType(params BaseDecodeType[])

初始化 Aspose.BarCode.BarCodeRecognition.MultyDecodeType 类的新实例。

public MultyDecodeType(params BaseDecodeType[] barcodeTypes)

参数

barcodeTypes BaseDecodeType[]

多解码和单解码类型数组

属性

GetSingleTypesCount

返回单类型的数量。

public int GetSingleTypesCount { get; }

属性值

int

方法

Add(SingleDecodeType)

向 MultyDecodeType 添加一个 Aspose.BarCode.BarCodeRecognition.SingleDecodeType。

public void Add(SingleDecodeType singleType)

参数

singleType SingleDecodeType

要添加到列表中的单解码类型

ContainsAll(params BaseDecodeType[])

检查是否包含所有条形码类型。

public bool ContainsAll(params BaseDecodeType[] barcodeTypes)

参数

barcodeTypes BaseDecodeType[]

输入的单条形码或多条形码类型

返回

bool

如果所有类型都包含在内,则值为真

ContainsAny(params BaseDecodeType[])

是否包含任何类型

public override bool ContainsAny(params BaseDecodeType[] decodeTypes)

参数

decodeTypes BaseDecodeType[]

解码类型

返回

bool

如果包含任何类型,则值为真

Equals(MultyDecodeType)

返回一个值,指示此实例是否等于指定的 Aspose.BarCode.BarCodeRecognition.MultyDecodeType 值。

public override bool Equals(MultyDecodeType other)

参数

other MultyDecodeType

要与此实例进行比较的 Aspose.BarCode.BarCodeRecognition.MultyDecodeType 值。

返回

bool

如果 obj 的值与此实例相同,则返回true;否则返回false

Equals(object)

返回一个值,指示此实例是否等于指定的 Aspose.BarCode.BarCodeRecognition.MultyDecodeType 值。

public override bool Equals(object obj)

参数

obj object

要与此实例进行比较的 System.Object 值。

返回

bool

如果 obj 的值与此实例相同,则返回true;否则返回false

Exclude(SingleDecodeType)

从 MultyDecodeType 中排除 Aspose.BarCode.BarCodeRecognition.SingleDecodeType 并返回新的 MultyDecodeType 实例。

public MultyDecodeType Exclude(SingleDecodeType singleType)

参数

singleType SingleDecodeType

要排除的单解码类型。

返回

MultyDecodeType

具有排除的 SingleDecodeType 的新 MultyDecodeType 实例。

GetHashCode()

返回此实例的哈希代码。

public override int GetHashCode()

返回

int

一个 32 位有符号整数哈希代码。

GetSingleTypes()

表示单类型的列表。

public List<singledecodetype> GetSingleTypes()

返回

List<SingleDecodeType&gt;

单类型列表

ToString()

重写方法,将 MultyDecodeType 表示为字符串。

public override string ToString()

返回

string

表示 MultyDecodeType 实例的字符串,格式为 “singleDecodeType1, singleDecodeType2, …”

"AllSupportedTypes" 当所有类型都包含时返回。

TryParse(string, out MultyDecodeType)

将 MultyDecodeType 的字符串表示形式转换为其实例。返回值指示转换是否成功。

public static bool TryParse(string parsingType, out MultyDecodeType result)

参数

parsingType string

格式为 “AllSupportedTypes” 或 “EAN8,EAN13,CodaBar” 的字符串进行转换。

result MultyDecodeType

成功完成转换时返回的实际 MultyDecodeType;

否则返回不确定类型 Aspose.BarCode.BarCodeRecognition.DecodeType.None 或 MultyDecodeType ("None")。

返回

bool

如果 s 成功转换,则返回true;否则返回false

 中文