1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18/**
19 * Service definition for CloudNaturalLanguageAPI (v1beta1).
20 *
21 * <p>
22 * Google Cloud Natural Language API provides natural language understanding
23 * technologies to developers. Examples include sentiment analysis, entity
24 * recognition, and text annotations.</p>
25 *
26 * <p>
27 * For more information about this service, see the API
28 * <a href="https://cloud.google.com/natural-language/" target="_blank">Documentation</a>
29 * </p>
30 *
31 * @author Google, Inc.
32 */
33class Google_Service_CloudNaturalLanguageAPI extends Google_Service
34{
35  /** View and manage your data across Google Cloud Platform services. */
36  const CLOUD_PLATFORM =
37      "https://www.googleapis.com/auth/cloud-platform";
38
39  public $documents;
40
41  /**
42   * Constructs the internal representation of the CloudNaturalLanguageAPI
43   * service.
44   *
45   * @param Google_Client $client
46   */
47  public function __construct(Google_Client $client)
48  {
49    parent::__construct($client);
50    $this->rootUrl = 'https://language.googleapis.com/';
51    $this->servicePath = '';
52    $this->version = 'v1beta1';
53    $this->serviceName = 'language';
54
55    $this->documents = new Google_Service_CloudNaturalLanguageAPI_Resource_Documents(
56        $this,
57        $this->serviceName,
58        'documents',
59        array(
60          'methods' => array(
61            'analyzeEntities' => array(
62              'path' => 'v1beta1/documents:analyzeEntities',
63              'httpMethod' => 'POST',
64              'parameters' => array(),
65            ),'analyzeSentiment' => array(
66              'path' => 'v1beta1/documents:analyzeSentiment',
67              'httpMethod' => 'POST',
68              'parameters' => array(),
69            ),'annotateText' => array(
70              'path' => 'v1beta1/documents:annotateText',
71              'httpMethod' => 'POST',
72              'parameters' => array(),
73            ),
74          )
75        )
76    );
77  }
78}
79