Skip to content

Commit d76b092

Browse files
1 parent 15dc6e7 commit d76b092

2 files changed

Lines changed: 112 additions & 0 deletions

File tree

‎src/AnalyticsHub/Compression.php‎

Lines changed: 94 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,94 @@
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+
namespace Google\Service\AnalyticsHub;
19+
20+
class Compression extends \Google\Model
21+
{
22+
/**
23+
* Unspecified algorithm.
24+
*/
25+
public const COMPRESSION_ALGORITHM_COMPRESSION_ALGORITHM_UNSPECIFIED = 'COMPRESSION_ALGORITHM_UNSPECIFIED';
26+
/**
27+
* ZLIB compression.
28+
*/
29+
public const COMPRESSION_ALGORITHM_ZLIB = 'ZLIB';
30+
/**
31+
* Unspecified mode.
32+
*/
33+
public const COMPRESSION_MODE_COMPRESSION_MODE_UNSPECIFIED = 'COMPRESSION_MODE_UNSPECIFIED';
34+
/**
35+
* Compress.
36+
*/
37+
public const COMPRESSION_MODE_COMPRESS = 'COMPRESS';
38+
/**
39+
* Decompress.
40+
*/
41+
public const COMPRESSION_MODE_DECOMPRESS = 'DECOMPRESS';
42+
/**
43+
* Required. Specifies the compression algorithm to use.
44+
*
45+
* @var string
46+
*/
47+
public $compressionAlgorithm;
48+
/**
49+
* Required. Specifies whether to compress or decompress the message.
50+
*
51+
* @var string
52+
*/
53+
public $compressionMode;
54+
55+
/**
56+
* Required. Specifies the compression algorithm to use.
57+
*
58+
* Accepted values: COMPRESSION_ALGORITHM_UNSPECIFIED, ZLIB
59+
*
60+
* @param self::COMPRESSION_ALGORITHM_* $compressionAlgorithm
61+
*/
62+
public function setCompressionAlgorithm($compressionAlgorithm)
63+
{
64+
$this->compressionAlgorithm = $compressionAlgorithm;
65+
}
66+
/**
67+
* @return self::COMPRESSION_ALGORITHM_*
68+
*/
69+
public function getCompressionAlgorithm()
70+
{
71+
return $this->compressionAlgorithm;
72+
}
73+
/**
74+
* Required. Specifies whether to compress or decompress the message.
75+
*
76+
* Accepted values: COMPRESSION_MODE_UNSPECIFIED, COMPRESS, DECOMPRESS
77+
*
78+
* @param self::COMPRESSION_MODE_* $compressionMode
79+
*/
80+
public function setCompressionMode($compressionMode)
81+
{
82+
$this->compressionMode = $compressionMode;
83+
}
84+
/**
85+
* @return self::COMPRESSION_MODE_*
86+
*/
87+
public function getCompressionMode()
88+
{
89+
return $this->compressionMode;
90+
}
91+
}
92+
93+
// Adding a class alias for backwards compatibility with the previous class name.
94+
class_alias(Compression::class, 'Google_Service_AnalyticsHub_Compression');

‎src/AnalyticsHub/MessageTransform.php‎

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@ class MessageTransform extends \Google\Model
2121
{
2222
protected $aiInferenceType = AIInference::class;
2323
protected $aiInferenceDataType = '';
24+
protected $compressionType = Compression::class;
25+
protected $compressionDataType = '';
2426
/**
2527
* Optional. If true, the transform is disabled and will not be applied to
2628
* messages. Defaults to `false`.
@@ -57,6 +59,22 @@ public function getAiInference()
5759
{
5860
return $this->aiInference;
5961
}
62+
/**
63+
* Optional. Compression/Decompression.
64+
*
65+
* @param Compression $compression
66+
*/
67+
public function setCompression(Compression $compression)
68+
{
69+
$this->compression = $compression;
70+
}
71+
/**
72+
* @return Compression
73+
*/
74+
public function getCompression()
75+
{
76+
return $this->compression;
77+
}
6078
/**
6179
* Optional. If true, the transform is disabled and will not be applied to
6280
* messages. Defaults to `false`.

0 commit comments

Comments
 (0)