Elgg  Version 2.3
EntityIcon.php
Go to the documentation of this file.
1 <?php
2 namespace Elgg;
3 
7 interface EntityIcon {
16  public function saveIconFromUploadedFile($input_name, $type = 'icon', array $coords = array());
17 
26  public function saveIconFromLocalFile($filename, $type = 'icon', array $coords = array());
27 
36  public function saveIconFromElggFile(\ElggFile $file, $type = 'icon', array $coords = array());
37 
46  public function getIcon($size, $type = 'icon');
47 
54  public function deleteIcon($type = 'icon');
55 
64  public function getIconURL($params);
65 
74  public function getIconLastChange($size, $type = 'icon');
75 
83  public function hasIcon($size, $type = 'icon');
84 }
if(! $owner||!($owner instanceof ElggUser)||! $owner->canEdit()) $coords
Definition: crop.php:15
$params
Definition: login.php:72
$size
Definition: default.php:20
$input_name
Definition: item.php:14
if(! $display_name) $type
Definition: delete.php:27
Entities that support icons should implement this interface.
Definition: EntityIcon.php:7
getIconLastChange($size, $type='icon')
Returns the timestamp of when the icon was changed.
saveIconFromElggFile(\ElggFile $file, $type='icon', array $coords=array())
Saves icons using a file located in the data store as the source.
saveIconFromLocalFile($filename, $type='icon', array $coords=array())
Saves icons using a local file as the source.
getIcon($size, $type='icon')
Returns entity icon as an ElggIcon object The icon file may or may not exist on filestore.
getIconURL($params)
Returns a URL of the icon.
hasIcon($size, $type='icon')
Returns if the entity has an icon of the passed type.
saveIconFromUploadedFile($input_name, $type='icon', array $coords=array())
Saves icons using an uploaded file as the source.
deleteIcon($type='icon')
Removes all icon files and metadata for the passed type of icon.
Save menu items.
$filename
if(!array_key_exists($filename, $text_files)) $file