freebox_api_php/freebox/api/v3/Model.php

22 lines
469 B
PHP
Raw Normal View History

2016-02-03 21:36:45 +01:00
<?php
namespace alphayax\freebox\api\v3;
/**
* Class Model
* @package alphayax\freebox\api\v3
*/
abstract class Model {
/**
* Model constructor.
* @param array $properties_x mapping of properties
*/
public function __construct( $properties_x = []){
foreach( $properties_x as $property => $value){
if( property_exists( static::class, $property)){
$this->$property = $value;
}
}
}
}