public function InstagramMedia::__construct in Drupagram 6
Same name and namespace in other branches
- 7 drupagram.lib.php \InstagramMedia::__construct()
Constructor for InstagramMedia
File
- ./
drupagram.lib.php, line 545 - Classes to implement the full Instagram API
Class
- InstagramMedia
- Class for containing an individual Instagram posts.
Code
public function __construct($values = array()) {
$values = array_filter($values);
foreach ($values as $key => $value) {
switch ($key) {
case 'user':
$this->user = new InstagramUser($values['user']);
break;
default:
$this->{$key} = $value;
break;
}
}
}