Skip to content

Commit

Permalink
Add role to metadata
Browse files Browse the repository at this point in the history
Fix [Autodesk-Forge#32](Autodesk-Forge#32) - tested and passed:
```
[1] => Autodesk\Forge\Client\Model\MetadataMetadata Object
                                        (
                                            [container:protected] => Array
                                                (
                                                    [name] => A100 - FOLHA
                                                    [role] => 2d
                                                    [guid] => d1b21356-f96c-41f3-4cb8-0cc396ade718
                                                )

                                        )
```
```

                                    [8] => Autodesk\Forge\Client\Model\MetadataCollection Object
                                        (
                                            [container:protected] => Array
                                                (
                                                    [objectid] => 9
                                                    [name] => wire_228153184
                                                    [properties] =>
                                                    [externalId] => p7
                                                )
```
  • Loading branch information
dukedhx authored Jul 9, 2019
1 parent 23f69f9 commit 7fcfd6c
Show file tree
Hide file tree
Showing 4 changed files with 54 additions and 0 deletions.
1 change: 1 addition & 0 deletions docs/Model/MetadataCollection.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**objectid** | **int** | Unique ID for the object |
**name** | **string** | Name of the object |
**externalId** | **string** | External Id of the object |
**properties** | **object** | Represents the object’s “properties” | [optional]

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
Expand Down
1 change: 1 addition & 0 deletions docs/Model/MetadataMetadata.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **string** | Name of the model view |
**role** | **string** | Role of the model view |
**guid** | **string** | Unique identifier for the model view |

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
Expand Down
26 changes: 26 additions & 0 deletions lib/Model/MetadataCollection.php
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ class MetadataCollection implements ArrayAccess
protected static $swaggerTypes = [
'objectid' => 'int',
'name' => 'string',
'externalId' => 'string',
'properties' => 'object',
];

Expand All @@ -75,6 +76,7 @@ public static function swaggerTypes()
protected static $attributeMap = [
'objectid' => 'objectid',
'name' => 'name',
'externalId' => 'externalId',
'properties' => 'properties',
];

Expand All @@ -85,6 +87,7 @@ public static function swaggerTypes()
*/
protected static $setters = [
'objectid' => 'setObjectid',
'externalId' => 'setExternalId',
'name' => 'setName',
'properties' => 'setProperties',
];
Expand All @@ -97,6 +100,7 @@ public static function swaggerTypes()
protected static $getters = [
'objectid' => 'getObjectid',
'name' => 'getName',
'name' => 'getExternalId',
'properties' => 'getProperties',
];

Expand Down Expand Up @@ -134,6 +138,7 @@ public function __construct(array $data = null)
$this->container['objectid'] = isset($data['objectid']) ? $data['objectid'] : null;
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['properties'] = isset($data['properties']) ? $data['properties'] : null;
$this->container['externalId'] = isset($data['externalId']) ? $data['externalId'] : null;
}

/**
Expand Down Expand Up @@ -194,6 +199,27 @@ public function setObjectid($objectid)
return $this;
}

/**
* Gets externalId
* @return int
*/
public function getExternalId()
{
return $this->container['externalId'];
}

/**
* Sets externalId
* @param int $objectid Unique ID for the object
* @return $this
*/
public function setExternalId($externalId)
{
$this->container['externalId'] = $externalId;

return $this;
}

/**
* Gets name
* @return string
Expand Down
26 changes: 26 additions & 0 deletions lib/Model/MetadataMetadata.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ class MetadataMetadata implements ArrayAccess
*/
protected static $swaggerTypes = [
'name' => 'string',
'role' => 'string',
'guid' => 'string',
];

Expand All @@ -73,6 +74,7 @@ public static function swaggerTypes()
*/
protected static $attributeMap = [
'name' => 'name',
'role' => 'role',
'guid' => 'guid',
];

Expand All @@ -83,6 +85,7 @@ public static function swaggerTypes()
*/
protected static $setters = [
'name' => 'setName',
'role' => 'setRole',
'guid' => 'setGuid',
];

Expand All @@ -93,6 +96,7 @@ public static function swaggerTypes()
*/
protected static $getters = [
'name' => 'getName',
'role' => 'setRole',
'guid' => 'getGuid',
];

Expand Down Expand Up @@ -128,6 +132,7 @@ public static function getters()
public function __construct(array $data = null)
{
$this->container['name'] = isset($data['name']) ? $data['name'] : null;
$this->container['role'] = isset($data['role']) ? $data['role'] : null;
$this->container['guid'] = isset($data['guid']) ? $data['guid'] : null;
}

Expand Down Expand Up @@ -189,6 +194,27 @@ public function setName($name)
return $this;
}

/**
* Gets role
* @return string
*/
public function getRole()
{
return $this->container['role'];
}

/**
* Sets role
* @param string $name Name of the model view
* @return $this
*/
public function setRole($role)
{
$this->container['role'] = $role;

return $this;
}

/**
* Gets guid
* @return string
Expand Down

0 comments on commit 7fcfd6c

Please sign in to comment.