2017 © Pedro Peláez
 

library text-kernel

image

eoko/text-kernel

  • Monday, November 27, 2017
  • by iam_merlin
  • Repository
  • 2 Watchers
  • 1 Stars
  • 354 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 1 Open issues
  • 3 Versions
  • 298 % Grown

The README.md

TextKernel API

This is a small implementation of the sourcebox extract API
Contributions are welcome., (*1)

Usage with Symfony

Configuration

In your service.yml, (*2)

    textkernel.factory:
        class: Eoko\TextKernel\Factory\TextKernelFactory

    textkernel.api.servicebox:
        class: Eoko\TextKernel\Api\SourceboxApi
        factory: [ '@textkernel.factory', createSourceboxApi ]
        arguments:
            - '%textkernel_account%'
            - '%textkernel_username%'
            - '%textkernel_password%'

In your parameters.yml, (*3)

parameters:
    textkernel_account: change_me
    textkernel_username: change_me
    textkernel_password: ######

Usage

In a container aware class, (*4)

    $api = $this->get('textkernel.api.servicebox');

    try {
        /** @param \Eoko\TextKernel\Model\CvModel $cv */
        $cv = $api->extractFromFile($filepath);
        // or
        $cv = $api->extract($cvBuffer);
    } catch(\Exception $e) {
        //handle errors
    }

Raw usage

    use Eoko\TextKernel\Factory\TextKernelFactory;

    $account = 'change_me';
    $username = 'change_me';
    $password = '########';

    $factory = new TextKernelFactory();
    $api = $factory->createSourceboxApi($account, $username, $password);

    try {
        /** @param \Eoko\TextKernel\Model\CvModel $cv */
        $cv = $api->extractFromFile($filepath);
        // or
        $cv = $api->extract($cvBuffer);
    } catch(\Exception $e) {
        //handle errors
    }

The Versions

27/11 2017

dev-master

9999999-dev

  Sources   Download

The Requires

 

by GASPARINI Nicolas

27/11 2017

1.0.1

1.0.1.0

  Sources   Download

The Requires

 

by GASPARINI Nicolas

02/10 2017

1.0.0

1.0.0.0

  Sources   Download

The Requires

 

by GASPARINI Nicolas