from utils import *


class Label:
    def __init__(self,
                 imageName,
                 classId,
                 labelType,
                 classConfidence=None):
        if labelType == LabelType.Detected and classConfidence is None:
            raise IOError(
                'For labelType=\'Detection\', it is necessary to inform the classConfidence value.')

        self._imageName = imageName
        self._classId = classId
        self._labelType = labelType
        self._classConfidence = classConfidence

    def getImageName(self):
        return self._imageName

    def getConfidence(self):
        return self._classConfidence

    def getClassId(self):
        return self._classId

    def getLabelType(self):
        return self._labelType