ameliabooking
/
vendor
/
microsoft
/
microsoft-graph
/
src
/
ExternalConnectors
/
Model
/
External.php
ameliabooking
/
vendor
/
microsoft
/
microsoft-graph
/
src
/
ExternalConnectors
/
Model
Last commit date
AccessType.php
1 year ago
Acl.php
1 year ago
AclType.php
1 year ago
Configuration.php
1 year ago
ConnectionOperation.php
1 year ago
ConnectionOperationStatus.php
1 year ago
ConnectionState.php
1 year ago
External.php
1 year ago
ExternalConnection.php
1 year ago
ExternalGroup.php
1 year ago
ExternalItem.php
1 year ago
ExternalItemContent.php
1 year ago
ExternalItemContentType.php
1 year ago
Identity.php
1 year ago
IdentityType.php
1 year ago
Label.php
1 year ago
Properties.php
1 year ago
Property.php
1 year ago
PropertyType.php
1 year ago
Schema.php
1 year ago
External.php
133 lines
| 1 | <?php |
| 2 | /** |
| 3 | * Copyright (c) Microsoft Corporation. All Rights Reserved. Licensed under the MIT License. See License in the project root for license information. |
| 4 | * |
| 5 | * External File |
| 6 | * PHP version 7 |
| 7 | * |
| 8 | * @category Library |
| 9 | * @package Microsoft.Graph |
| 10 | * @copyright (c) Microsoft Corporation. All rights reserved. |
| 11 | * @license https://opensource.org/licenses/MIT MIT License |
| 12 | * @link https://graph.microsoft.com |
| 13 | */ |
| 14 | namespace Microsoft\Graph\ExternalConnectors\Model; |
| 15 | |
| 16 | /** |
| 17 | * External class |
| 18 | * |
| 19 | * @category Model |
| 20 | * @package Microsoft.Graph |
| 21 | * @copyright (c) Microsoft Corporation. All rights reserved. |
| 22 | * @license https://opensource.org/licenses/MIT MIT License |
| 23 | * @link https://graph.microsoft.com |
| 24 | */ |
| 25 | class External implements \JsonSerializable |
| 26 | { |
| 27 | /** |
| 28 | * The array of properties available |
| 29 | * to the model |
| 30 | * |
| 31 | * @var array $_propDict |
| 32 | */ |
| 33 | protected $_propDict; |
| 34 | |
| 35 | /** |
| 36 | * Construct a new External |
| 37 | * |
| 38 | * @param array $propDict A list of properties to set |
| 39 | */ |
| 40 | function __construct($propDict = array()) |
| 41 | { |
| 42 | if (!is_array($propDict)) { |
| 43 | $propDict = array(); |
| 44 | } |
| 45 | $this->_propDict = $propDict; |
| 46 | } |
| 47 | |
| 48 | /** |
| 49 | * Gets the property dictionary of the External |
| 50 | * |
| 51 | * @return array The list of properties |
| 52 | */ |
| 53 | public function getProperties() |
| 54 | { |
| 55 | return $this->_propDict; |
| 56 | } |
| 57 | |
| 58 | |
| 59 | /** |
| 60 | * Gets the connections |
| 61 | * |
| 62 | * @return array|null The connections |
| 63 | */ |
| 64 | public function getConnections() |
| 65 | { |
| 66 | if (array_key_exists("connections", $this->_propDict)) { |
| 67 | return $this->_propDict["connections"]; |
| 68 | } else { |
| 69 | return null; |
| 70 | } |
| 71 | } |
| 72 | |
| 73 | /** |
| 74 | * Sets the connections |
| 75 | * |
| 76 | * @param ExternalConnection[] $val The connections |
| 77 | * |
| 78 | * @return External |
| 79 | */ |
| 80 | public function setConnections($val) |
| 81 | { |
| 82 | $this->_propDict["connections"] = $val; |
| 83 | return $this; |
| 84 | } |
| 85 | |
| 86 | /** |
| 87 | * Gets the ODataType |
| 88 | * |
| 89 | * @return string|null The ODataType |
| 90 | */ |
| 91 | public function getODataType() |
| 92 | { |
| 93 | if (array_key_exists('@odata.type', $this->_propDict)) { |
| 94 | return $this->_propDict["@odata.type"]; |
| 95 | } |
| 96 | return null; |
| 97 | } |
| 98 | |
| 99 | /** |
| 100 | * Sets the ODataType |
| 101 | * |
| 102 | * @param string $val The ODataType |
| 103 | * |
| 104 | * @return External |
| 105 | */ |
| 106 | public function setODataType($val) |
| 107 | { |
| 108 | $this->_propDict["@odata.type"] = $val; |
| 109 | return $this; |
| 110 | } |
| 111 | |
| 112 | /** |
| 113 | * Serializes the object by property array |
| 114 | * Manually serialize DateTime into RFC3339 format |
| 115 | * |
| 116 | * @return array The list of properties |
| 117 | */ |
| 118 | public function jsonSerialize() |
| 119 | { |
| 120 | $serializableProperties = $this->getProperties(); |
| 121 | foreach ($serializableProperties as $property => $val) { |
| 122 | if (is_a($val, "\DateTime")) { |
| 123 | $serializableProperties[$property] = $val->format(\DateTime::RFC3339); |
| 124 | } else if (is_a($val, "\Microsoft\Graph\Core\Enum")) { |
| 125 | $serializableProperties[$property] = $val->value(); |
| 126 | } else if (is_a($val, "\Entity")) { |
| 127 | $serializableProperties[$property] = $val->jsonSerialize(); |
| 128 | } |
| 129 | } |
| 130 | return $serializableProperties; |
| 131 | } |
| 132 | } |
| 133 |