You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@usergrid.apache.org by ro...@apache.org on 2014/11/12 02:15:49 UTC
[44/45] incubator-usergrid git commit: create device Response Model
and changed the service descriptor to return the Device Model instead of the
Entity model . removed used method in usergrid.
create device Response Model and changed the service descriptor to return the Device Model instead of the Entity model .
removed used method in usergrid.
Project: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/commit/8e6df802
Tree: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/tree/8e6df802
Diff: http://git-wip-us.apache.org/repos/asf/incubator-usergrid/diff/8e6df802
Branch: refs/heads/master
Commit: 8e6df802fe9814d24fa25cb2c81871671559f33b
Parents: a9fbc73
Author: Jason Kristian <ja...@apps4u.com.au>
Authored: Tue Nov 11 18:16:15 2014 +1000
Committer: Jason Kristian <ja...@apps4u.com.au>
Committed: Tue Nov 11 18:16:15 2014 +1000
----------------------------------------------------------------------
.../apache-usergrid/src/Api/Models/Device.php | 39 ++++++++++++++++++++
sdks/php5/apache-usergrid/src/Api/Usergrid.php | 8 ----
.../src/Manifests/1.0.1/Devices.php | 12 +++---
.../src/Manifests/1.0.1/Users.php | 2 +-
4 files changed, 46 insertions(+), 15 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/8e6df802/sdks/php5/apache-usergrid/src/Api/Models/Device.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Models/Device.php b/sdks/php5/apache-usergrid/src/Api/Models/Device.php
new file mode 100644
index 0000000..4949ffe
--- /dev/null
+++ b/sdks/php5/apache-usergrid/src/Api/Models/Device.php
@@ -0,0 +1,39 @@
+<?php
+/**
+ * Copyright 2010-2014 baas-platform.com, Pty Ltd. or its affiliates. All Rights Reserved.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License").
+ * You may not use this file except in compliance with the License.
+ * A copy of the License is located at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * or in the "license" file accompanying this file. This file is distributed
+ * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
+ * express or implied. See the License for the specific language governing
+ * permissions and limitations under the License.
+ */
+
+namespace Apache\Usergrid\Api\Models;
+
+
+use Guzzle\Service\Command\ResponseClassInterface;
+
+/**
+ * Class Device
+ *
+ * @package Apache/Usergrid
+ * @version 1.0.0
+ * @author Jason Kristian <ja...@gmail.com>
+ * @license Apache License, Version 2.0
+ * @copyright (c) 2008-2014, Baas Platform Pty. Ltd
+ * @link http://baas-platform.com
+ */
+class Device extends BaseCollection implements ResponseClassInterface
+{
+ use GuzzleCommandTrait;
+
+
+
+
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/8e6df802/sdks/php5/apache-usergrid/src/Api/Usergrid.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Api/Usergrid.php b/sdks/php5/apache-usergrid/src/Api/Usergrid.php
index d12ee11..3353630 100644
--- a/sdks/php5/apache-usergrid/src/Api/Usergrid.php
+++ b/sdks/php5/apache-usergrid/src/Api/Usergrid.php
@@ -442,12 +442,4 @@ class Usergrid
return file_exists($this->getManifestFilePath($file));
}
- /**
- * fetch token from by making api call,
- * and call $this->setToken which will set the bearer token in the
- * http header
- */
- protected function fetchToken(){
-
- }
}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/8e6df802/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
index d544fe3..be1cf13 100644
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
+++ b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Devices.php
@@ -21,7 +21,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
'notes' => 'Get All devices.',
'summary' => 'Get all Device collection limit 10000',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
@@ -98,7 +98,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
'notes' => 'Query Devices.',
'summary' => 'Query the devices collection',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
@@ -173,7 +173,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{uuid}',
'notes' => 'Find Device by uuid.',
'summary' => 'Find device by uuid',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
@@ -255,7 +255,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
'notes' => 'Create new Device. See Usergrid documentation for JSON format of body.',
'summary' => 'Create new Device entity',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
@@ -295,7 +295,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
'notes' => 'Delete a Device entity.',
'summary' => 'Delete a Device entity by name or uuid',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
@@ -337,7 +337,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}/{entity_name_or_uuid}',
'notes' => 'Update a Device entity.',
'summary' => 'Update a Device entity by name or uuid and using JSON data',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Entity',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\Device',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [
http://git-wip-us.apache.org/repos/asf/incubator-usergrid/blob/8e6df802/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
----------------------------------------------------------------------
diff --git a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
index 1e57430..2c68332 100644
--- a/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
+++ b/sdks/php5/apache-usergrid/src/Manifests/1.0.1/Users.php
@@ -21,7 +21,7 @@ return [
'uri' => '/{org_name_or_uuid}/{app_name_or_uuid}/{collection}',
'notes' => 'Query an app collection.',
'summary' => 'Query an app collection',
- 'responseClass' => 'Apache\Usergrid\Api\Models\Collection',
+ 'responseClass' => 'Apache\Usergrid\Api\Models\User',
'responseType' => 'class',
'errorResponses' => $errors,
'parameters' => [