类 OcrClient

    • 构造器详细资料

      • OcrClient

        public OcrClient​(BceClientConfiguration ocrConfig)
        Constructs a new client using the client configuration.
        参数:
        ocrConfig - The client configuration options controlling how this client connects to Ocr services (e.g. proxy settings, retry counts, etc).
    • 方法详细资料

      • bankcardRecognition

        public BankcardRecognitionResponse bankcardRecognition​(String image)
        Gets the bankcard recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        image - The image data which needs to be base64
        返回:
        The bankcard recognition properties of the image resource
      • bankcardRecognition

        public BankcardRecognitionResponse bankcardRecognition​(BankcardRecognitionRequest request)
        Gets the bankcard recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        request - The request wrapper object containing all options.
        返回:
        The bankcard recognition properties of the image resource
      • idcardRecognition

        public IdcardRecognitionResponse idcardRecognition​(String image,
                                                           String side)
        Gets the idcard recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        image - The image data which needs to be base64
        side - The side of idcard image. (front/back)
        返回:
        The idcard recognition properties of the image resource
      • idcardRecognition

        public IdcardRecognitionResponse idcardRecognition​(String image,
                                                           String side,
                                                           Boolean direction)
        Gets the idcard recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        image - The image data which needs to be base64
        side - The side of idcard image. (front/back)
        direction - Decide if the image has been rotated (true/false)
        返回:
        The idcard recognition properties of the image resource
      • idcardRecognition

        public IdcardRecognitionResponse idcardRecognition​(IdcardRecognitionRequest request)
        Gets the idcard recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        request - The request wrapper object containing all options.
        返回:
        The idcard recognition properties of the image resource
      • generalRecognition

        public GeneralRecognitionResponse generalRecognition​(String image)
        Gets the general recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        image - The image data which needs to be base64
        返回:
        The general recognition properties of the image resource
      • generalRecognition

        public GeneralRecognitionResponse generalRecognition​(String image,
                                                             String granularity,
                                                             String mask,
                                                             String langType,
                                                             Boolean direction)
        Gets the general recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        image - The image data which needs to be base64
        granularity - Decide if recognize single character (big/small)
        mask - Represent the gray/white/black shade image area (base64 data)
        langType - Language type, detail to be CHN_ENG (ENG/POR/FRE/GER/ITA/SPA/RUS/JAP)
        direction - Decide if the image has been rotated (true/false)
        返回:
        The general recognition properties of the image resource
      • generalRecognition

        public GeneralRecognitionResponse generalRecognition​(GeneralRecognitionRequest request)
        Gets the general recognition properties of specific image resource.

        The caller must authenticate with a valid BCE Access Key / Private Key pair.

        参数:
        request - The request wrapper object containing all options.
        返回:
        The general recognition properties of the image resource