/usr/share/php/google-api-php-client/src/contrib/Google_AuditService.php is in php-google-api-php-client 0.6.2-1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 | <?php
/*
* Copyright 2010 Google Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License"); you may not
* use this file except in compliance with the License. You may obtain a copy of
* the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License 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.
*/
/**
* The "activities" collection of methods.
* Typical usage is:
* <code>
* $auditService = new Google_AuditService(...);
* $activities = $auditService->activities;
* </code>
*/
class Google_ActivitiesServiceResource extends Google_ServiceResource {
/**
* Retrieves a list of activities for a specific customer and application. (activities.list)
*
* @param string $customerId Represents the customer who is the owner of target object on which action was performed.
* @param string $applicationId Application ID of the application on which the event was performed.
* @param array $optParams Optional parameters.
*
* @opt_param string actorEmail Email address of the user who performed the action.
* @opt_param string actorApplicationId Application ID of the application which interacted on behalf of the user while performing the event.
* @opt_param string actorIpAddress IP Address of host where the event was performed. Supports both IPv4 and IPv6 addresses.
* @opt_param string caller Type of the caller.
* @opt_param int maxResults Number of activity records to be shown in each page.
* @opt_param string eventName Name of the event being queried.
* @opt_param string startTime Return events which occured at or after this time.
* @opt_param string endTime Return events which occured at or before this time.
* @opt_param string continuationToken Next page URL.
* @return Google_Activities
*/
public function listActivities($customerId, $applicationId, $optParams = array()) {
$params = array('customerId' => $customerId, 'applicationId' => $applicationId);
$params = array_merge($params, $optParams);
$data = $this->__call('list', array($params));
if ($this->useObjects()) {
return new Google_Activities($data);
} else {
return $data;
}
}
}
/**
* Service definition for Google_Audit (v1).
*
* <p>
* Lets you access user activities in your enterprise made through various applications.
* </p>
*
* <p>
* For more information about this service, see the
* <a href="https://developers.google.com/google-apps/admin-audit/get_started" target="_blank">API Documentation</a>
* </p>
*
* @author Google, Inc.
*/
class Google_AuditService extends Google_Service {
public $activities;
/**
* Constructs the internal representation of the Audit service.
*
* @param Google_Client $client
*/
public function __construct(Google_Client $client) {
$this->servicePath = 'apps/reporting/audit/v1/';
$this->version = 'v1';
$this->serviceName = 'audit';
$client->addService($this->serviceName, $this->version);
$this->activities = new Google_ActivitiesServiceResource($this, $this->serviceName, 'activities', json_decode('{"methods": {"list": {"parameters": {"actorEmail": {"type": "string", "location": "query"}, "actorApplicationId": {"location": "query", "type": "string", "format": "int64"}, "actorIpAddress": {"type": "string", "location": "query"}, "caller": {"enum": ["application_owner", "customer"], "type": "string", "location": "query"}, "maxResults": {"format": "int32", "maximum": "1000", "minimum": "1", "location": "query", "type": "integer"}, "customerId": {"required": true, "type": "string", "location": "path"}, "eventName": {"type": "string", "location": "query"}, "startTime": {"type": "string", "location": "query"}, "endTime": {"type": "string", "location": "query"}, "applicationId": {"location": "path", "required": true, "type": "string", "format": "int64"}, "continuationToken": {"type": "string", "location": "query"}}, "response": {"$ref": "Activities"}, "httpMethod": "GET", "path": "{customerId}/{applicationId}", "id": "audit.activities.list"}}}', true));
}
}
class Google_Activities extends Google_Model {
protected $__itemsType = 'Google_Activity';
protected $__itemsDataType = 'array';
public $items;
public $kind;
public $next;
public function setItems(/* array(Google_Activity) */ $items) {
$this->assertIsArray($items, 'Google_Activity', __METHOD__);
$this->items = $items;
}
public function getItems() {
return $this->items;
}
public function setKind($kind) {
$this->kind = $kind;
}
public function getKind() {
return $this->kind;
}
public function setNext($next) {
$this->next = $next;
}
public function getNext() {
return $this->next;
}
}
class Google_Activity extends Google_Model {
protected $__actorType = 'Google_ActivityActor';
protected $__actorDataType = '';
public $actor;
protected $__eventsType = 'Google_ActivityEvents';
protected $__eventsDataType = 'array';
public $events;
protected $__idType = 'Google_ActivityId';
protected $__idDataType = '';
public $id;
public $ipAddress;
public $kind;
public $ownerDomain;
public function setActor(Google_ActivityActor $actor) {
$this->actor = $actor;
}
public function getActor() {
return $this->actor;
}
public function setEvents(/* array(Google_ActivityEvents) */ $events) {
$this->assertIsArray($events, 'Google_ActivityEvents', __METHOD__);
$this->events = $events;
}
public function getEvents() {
return $this->events;
}
public function setId(Google_ActivityId $id) {
$this->id = $id;
}
public function getId() {
return $this->id;
}
public function setIpAddress($ipAddress) {
$this->ipAddress = $ipAddress;
}
public function getIpAddress() {
return $this->ipAddress;
}
public function setKind($kind) {
$this->kind = $kind;
}
public function getKind() {
return $this->kind;
}
public function setOwnerDomain($ownerDomain) {
$this->ownerDomain = $ownerDomain;
}
public function getOwnerDomain() {
return $this->ownerDomain;
}
}
class Google_ActivityActor extends Google_Model {
public $applicationId;
public $callerType;
public $email;
public $key;
public function setApplicationId($applicationId) {
$this->applicationId = $applicationId;
}
public function getApplicationId() {
return $this->applicationId;
}
public function setCallerType($callerType) {
$this->callerType = $callerType;
}
public function getCallerType() {
return $this->callerType;
}
public function setEmail($email) {
$this->email = $email;
}
public function getEmail() {
return $this->email;
}
public function setKey($key) {
$this->key = $key;
}
public function getKey() {
return $this->key;
}
}
class Google_ActivityEvents extends Google_Model {
public $eventType;
public $name;
protected $__parametersType = 'Google_ActivityEventsParameters';
protected $__parametersDataType = 'array';
public $parameters;
public function setEventType($eventType) {
$this->eventType = $eventType;
}
public function getEventType() {
return $this->eventType;
}
public function setName($name) {
$this->name = $name;
}
public function getName() {
return $this->name;
}
public function setParameters(/* array(Google_ActivityEventsParameters) */ $parameters) {
$this->assertIsArray($parameters, 'Google_ActivityEventsParameters', __METHOD__);
$this->parameters = $parameters;
}
public function getParameters() {
return $this->parameters;
}
}
class Google_ActivityEventsParameters extends Google_Model {
public $name;
public $value;
public function setName($name) {
$this->name = $name;
}
public function getName() {
return $this->name;
}
public function setValue($value) {
$this->value = $value;
}
public function getValue() {
return $this->value;
}
}
class Google_ActivityId extends Google_Model {
public $applicationId;
public $customerId;
public $time;
public $uniqQualifier;
public function setApplicationId($applicationId) {
$this->applicationId = $applicationId;
}
public function getApplicationId() {
return $this->applicationId;
}
public function setCustomerId($customerId) {
$this->customerId = $customerId;
}
public function getCustomerId() {
return $this->customerId;
}
public function setTime($time) {
$this->time = $time;
}
public function getTime() {
return $this->time;
}
public function setUniqQualifier($uniqQualifier) {
$this->uniqQualifier = $uniqQualifier;
}
public function getUniqQualifier() {
return $this->uniqQualifier;
}
}
|