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

#import <Foundation/Foundation.h>
#import <DynamsoftCaptureVisionBundle/DSIntermediateResultUnit.h>

@class DSLineSegment;

NS_ASSUME_NONNULL_BEGIN

/**
 * DSLongLinesUnit class represents an intermediate result unit whose type is long lines. Line segments that are located in the same line are extended and merged to form a long line.
 */
NS_SWIFT_NAME(LongLinesUnit)
@interface DSLongLinesUnit : DSIntermediateResultUnit
/**
 * An array of DSLineSegments as the long lines.
 */
- (nullable NSArray<DSLineSegment *> *)getLongLines;

- (NSInteger)getCount;

- (nullable DSLineSegment *)getLongLine:(NSInteger)index;

- (void)removeAllLongLines;

- (NSInteger)removeLongLine:(NSInteger)index;

- (NSInteger)addLongLine:(DSLineSegment *)line
   matrixToOriginalImage:(CGAffineTransform)matrixToOriginalImage;

- (NSInteger)setLongLine:(NSInteger)index
                    line:(DSLineSegment *)line
   matrixToOriginalImage:(CGAffineTransform)matrixToOriginalImage;

@end

NS_ASSUME_NONNULL_END
