/*
 * This is one of the header files of Dynamsoft Capture Vision SDK - Barcode Reader module.
 *
 * Copyright © Dynamsoft Corporation. All rights reserved.
 */

#import <Foundation/Foundation.h>

NS_ASSUME_NONNULL_BEGIN

/**
 * Represents the Extended Channel Interpretation (ECI) information within a barcode.
 *
 * Each ECI segment specifies the character encoding used for a portion of the decoded bytes.
 * The charset names follow the IANA character set registry (e.g. "UTF-8", "ISO-8859-1").
 */
NS_SWIFT_NAME(ECISegment)
@interface DSECISegment : NSObject

/**
 * ECI assignment number as defined by ISO/IEC 15424.
 */
@property (nonatomic, readonly, assign) NSInteger eciValue;
/**
 * Charset encoding name defined by IANA (e.g. "UTF-8", "ISO-8859-1").
 */
@property (nonatomic, readonly, copy) NSString *charsetEncoding;
/**
 * Start index of this ECI segment in the decoded barcode bytes.
 */
@property (nonatomic, readonly, assign) NSInteger startIndex;
/**
 * Length (in bytes) of this segment within the decoded barcode bytes.
 */
@property (nonatomic, readonly, assign) NSInteger length;

+ (instancetype)new NS_UNAVAILABLE;
- (instancetype)init NS_UNAVAILABLE;

@end

NS_ASSUME_NONNULL_END
