GSKTextLayoutToTextConverterResult
Objective-C
@interface GSKTextLayoutToTextConverterResult : NSObject
- (nonnull instancetype)initWithStatus:(GSKTextLayoutToTextConverterStatus)status
text:(nonnull NSString *)text
averageWordConfidence:(int32_t)averageWordConfidence
wordCount:(int32_t)wordCount;
+ (nonnull instancetype)textLayoutToTextConverterResultWithStatus:(GSKTextLayoutToTextConverterStatus)status
text:(nonnull NSString *)text
averageWordConfidence:(int32_t)averageWordConfidence
wordCount:(int32_t)wordCount;
/** The status of the conversion. If failure, the other values in the result must not be used. */
@property (nonatomic, readonly) GSKTextLayoutToTextConverterStatus status;
/** The text reconstructed from the text layout. */
@property (nonatomic, readonly, nonnull) NSString * text;
/**
* The average word confidence of the recognized text.
* A value between 0 and 100
*/
@property (nonatomic, readonly) int32_t averageWordConfidence;
/**
* The number of words in the recognized text.
* This is the number of words on which the average word confidence has been computed.
*/
@property (nonatomic, readonly) int32_t wordCount;
@end
Swift
class GSKTextLayoutToTextConverterResult : NSObject
Undocumented
-
Undocumented
Declaration
Objective-C
- (nonnull instancetype)initWithStatus:(GSKTextLayoutToTextConverterStatus)status text:(nonnull NSString *)text averageWordConfidence:(int32_t)averageWordConfidence wordCount:(int32_t)wordCount;
Swift
init(status: GSKTextLayoutToTextConverterStatus, text: String, averageWordConfidence: Int32, wordCount: Int32)
-
Undocumented
Declaration
Objective-C
+ (nonnull instancetype)textLayoutToTextConverterResultWithStatus:(GSKTextLayoutToTextConverterStatus)status text:(nonnull NSString *)text averageWordConfidence:(int32_t)averageWordConfidence wordCount:(int32_t)wordCount;
Swift
class func textLayoutToTextConverterResult(with status: GSKTextLayoutToTextConverterStatus, text: String, averageWordConfidence: Int32, wordCount: Int32) -> Self
-
The status of the conversion. If failure, the other values in the result must not be used.
Declaration
Objective-C
@property (nonatomic, readonly) GSKTextLayoutToTextConverterStatus status;
Swift
var status: GSKTextLayoutToTextConverterStatus { get }
-
The text reconstructed from the text layout.
Declaration
Objective-C
@property (nonatomic, readonly, nonnull) NSString *text;
Swift
var text: String { get }
-
The average word confidence of the recognized text. A value between 0 and 100
Declaration
Objective-C
@property (nonatomic, readonly) int32_t averageWordConfidence;
Swift
var averageWordConfidence: Int32 { get }
-
The number of words in the recognized text. This is the number of words on which the average word confidence has been computed.
Declaration
Objective-C
@property (nonatomic, readonly) int32_t wordCount;
Swift
var wordCount: Int32 { get }