Class MultiDecodeType
Namespace: Aspose.BarCode.BarCodeRecognition
Assembly: Aspose.BarCode.dll (25.12.0)
Composite decode type.
public class MultiDecodeType : BaseDecodeType, IEquatable<BaseDecodeType>, IEquatable<MultiDecodeType>Inheritance
object ← BaseDecodeType ← MultiDecodeType
Derived
Implements
IEquatable<BaseDecodeType> , IEquatable<MultiDecodeType>
Inherited Members
BaseDecodeType.ContainsAny(params BaseDecodeType[]) , BaseDecodeType.Equals(SingleDecodeType) , BaseDecodeType.Equals(MultiDecodeType) , BaseDecodeType.Equals(BaseDecodeType) , BaseDecodeType.Equals(object) , BaseDecodeType.TryParse(string, out SingleDecodeType) , BaseDecodeType.TryParse(string, out MultiDecodeType) , BaseDecodeType.TryParse(string, out BaseDecodeType) , object.GetType() , object.MemberwiseClone() , object.ToString() , object.Equals(object?) , object.Equals(object?, object?) , object.ReferenceEquals(object?, object?) , object.GetHashCode()
Examples
This sample shows how to create compound MultiDecode types that combine SingleDecodeType and MultiDecode types.
MultiDecodeType types1 = new MultiDecodeType(DecodeType.QR, DecodeType.DataMatrix);
MultiDecodeType types2 = new MultiDecodeType(types1, DecodeType.Code128, DecodeType.Code39);
Dim multiType1 As MultiDecodeType
multiType1 = New MultiDecodeType(DecodeType.QR, DecodeType.DataMatrix)
Dim multiType2 As MultiDecodeType
multiType2 = New MultiDecodeType(multiType1, DecodeType.Code128, DecodeType.Code39)Constructors
MultiDecodeType(params SingleDecodeType[])
Initializes a new instance of the Aspose.BarCode.BarCodeRecognition.MultiDecodeType class.
public MultiDecodeType(params SingleDecodeType[] barcodeTypes)Parameters
barcodeTypes SingleDecodeType
[]
Array of single decode types
MultiDecodeType(params BaseDecodeType[])
Initializes a new instance of the Aspose.BarCode.BarCodeRecognition.MultiDecodeType class.
public MultiDecodeType(params BaseDecodeType[] barcodeTypes)Parameters
barcodeTypes BaseDecodeType
[]
Array of multi and single decode types
Properties
GetSingleTypesCount
Returns a number of single types.
public int GetSingleTypesCount { get; }Property Value
Methods
Add(SingleDecodeType)
Adds one more Aspose.BarCode.BarCodeRecognition.SingleDecodeType to the MultiDecodeType.
public void Add(SingleDecodeType singleType)Parameters
singleType SingleDecodeType
A Single DecodeType to be added to the list
ContainsAll(params BaseDecodeType[])
Check if this contains all types from barcode types.
public bool ContainsAll(params BaseDecodeType[] barcodeTypes)Parameters
barcodeTypes BaseDecodeType
[]
Input single or multi barcode types
Returns
Value is a true if all types are included into
ContainsAny(params BaseDecodeType[])
Is contain any of types
public override bool ContainsAny(params BaseDecodeType[] decodeTypes)Parameters
decodeTypes BaseDecodeType
[]
Decode types
Returns
Value is a true if any types are included into
Equals(MultiDecodeType)
Returns a value indicating whether this instance is equal to a specified Aspose.BarCode.BarCodeRecognition.MultiDecodeType value.
public override bool Equals(MultiDecodeType other)Parameters
other MultiDecodeType
An Aspose.BarCode.BarCodeRecognition.MultiDecodeType value to compare to this instance.
Returns
true if obj has the same value as this instance; otherwise, false.
Equals(SingleDecodeType)
Returns a value indicating whether this decode types collection contains only specified Aspose.BarCode.BarCodeRecognition.SingleDecodeType value.
public override bool Equals(SingleDecodeType other)Parameters
other SingleDecodeType
An Aspose.BarCode.BarCodeRecognition.SingleDecodeType value to compare to this decode types collection.
Returns
true if this collection contains only specified decode type; otherwise, false.
Equals(object)
Returns a value indicating whether this instance is equal to a specified Aspose.BarCode.BarCodeRecognition.MultiDecodeType value.
public override bool Equals(object obj)Parameters
obj object
An System.Object value to compare to this instance.
Returns
true if obj has the same value as this instance; otherwise, false.
Exclude(SingleDecodeType)
Excludes Aspose.BarCode.BarCodeRecognition.SingleDecodeType from the MultiDecodeType and returns new MultiDecodeType instance.
public MultiDecodeType Exclude(SingleDecodeType singleType)Parameters
singleType SingleDecodeType
A Single DecodeType to be excluded.
Returns
New MultiDecodeType instance with excluded SingleDecodeType.
GetHashCode()
Returns the hash code for this instance.
public override int GetHashCode()Returns
A 32-bit signed integer hash code.
GetSingleTypes()
Represents a list of single types.
public List<SingleDecodeType> GetSingleTypes()Returns
List < SingleDecodeType >
List of single types
ToString()
Overridden method representing MultiDecodeType as a string.
public override string ToString()Returns
A string representing MultiDecodeType instance as “singleDecodeType1, singleDecodeType2, …”
"AllSupportedTypes" returns when all types are included.
TryParse(string, out MultiDecodeType)
Converts the string representation of a MultiDecodeType to its instance. A return value indicates whether the conversion succeeded or failed.
public static bool TryParse(string parsingType, out MultiDecodeType result)Parameters
parsingType string
A string in the format as either “AllSupportedTypes” or “EAN8,EAN13,CodaBar” to convert.
result MultiDecodeType
An actual MultiDecodeType is returned, when conversion has completed successfully;
otherwise it returns indefinite type. Aspose.BarCode.BarCodeRecognition.DecodeType.None or MultiDecodeType (“None”).
Returns
true if s was converted successfully; otherwise, false.