MBTemplatingClass


@interface MBTemplatingClass : NSObject

Class that represents a specific class of documents when used within Templating API.

  • Sets processor groups that will be executed before classification

    Declaration

    Objective-C

    - (void)setClassificationProcessorGroups:
        (nonnull NSArray<__kindof MBProcessorGroup *> *)processorGroups;

    Swift

    func setClassificationProcessorGroups(_ processorGroups: [MBProcessorGroup])

    Parameters

    processorGroups

    processor groups that will be executed before classification

  • Returns the currently set array of classification processor groups.

    Declaration

    Objective-C

    - (nullable NSArray<__kindof MBProcessorGroup *> *)
        getClassificationProcessorGroups;

    Swift

    func getClassificationProcessorGroups() -> [MBProcessorGroup]?

    Return Value

    the currently set array of classification processor groups.

  • Sets processor groups that will be executed if MBTemplatingClassifier’s classify returns YES.

    Declaration

    Objective-C

    - (void)setNonClassificationProcessorGroups:
        (nonnull NSArray<__kindof MBProcessorGroup *> *)processorGroups;

    Swift

    func setNonClassificationProcessorGroups(_ processorGroups: [MBProcessorGroup])

    Parameters

    processorGroups

    processor groups that will be executed after classification, if classification is positive

  • Returns the currently set array of non-classification processor groups.

    Declaration

    Objective-C

    - (nullable NSArray<__kindof MBProcessorGroup *> *)
        getNonClassificationProcessorGroups;

    Swift

    func getNonClassificationProcessorGroups() -> [MBProcessorGroup]?

    Return Value

    the currently set array of non-classification processor groups.

  • Sets the classifier which will tell whether currently processed document belongs to this class. If set to nil, existing classifier (if exists) will be cleared and non-classification processor groups will not be executed.

    Declaration

    Objective-C

    - (void)setTemplatingClassifier:
        (nullable id<MBTemplatingClassifier>)templatingClassifier;

    Swift

    func setTemplatingClassifier(_ templatingClassifier: MBTemplatingClassifier?)

    Parameters

    templatingClassifier

    Classifier which will tell whether currently processed document belongs to this class.