Stud.IP  4.0
 All Data Structures Namespaces Files Functions Variables Groups
LicenseAvatar Class Reference
Inheritance diagram for LicenseAvatar:
Avatar

Public Member Functions

 getAvatarDirectoryUrl ()
 
 getAvatarDirectoryPath ()
 
 getImageTag ($size=Avatar::MEDIUM, $opt=[])
 
 getDefaultTitle ()
 
- Public Member Functions inherited from Avatar
 getAvatarDirectoryUrl ()
 
 getAvatarDirectoryPath ()
 
 getCustomAvatarUrl ($size, $ext= 'png')
 
 getCustomAvatarPath ($size, $ext= 'png', $retina=false)
 
 getFilename ($size, $ext= 'png')
 
 getURL ($size, $ext= 'png')
 
 is_customized ()
 
 getImageTag ($size=Avatar::MEDIUM, $opt=[])
 
 createFromUpload ($userfile)
 
 createFrom ($filename)
 
 reset ()
 
 getDefaultTitle ()
 

Static Public Member Functions

static getAvatar ($id)
 
static getNobody ()
 
static getDimension ($size)
 
- Static Public Member Functions inherited from Avatar
static getAvatar ($id)
 
static getNobody ()
 
static getDimension ($size)
 
static error_handler ($errno, $errstr, $errfile, $errline)
 

Protected Member Functions

 getCssClass ($size)
 
 checkAvatarVisibility ()
 
- Protected Member Functions inherited from Avatar
 __construct ($user_id, $username=null)
 
 getCssClass ($size)
 
 checkAvatarVisibility ()
 
 sanitizeOrientation ($filename)
 

Additional Inherited Members

- Data Fields inherited from Avatar
const ORIGINAL = 'original'
 
const NORMAL = 'normal'
 
const MEDIUM = 'medium'
 
const SMALL = 'small'
 
const MAX_FILE_SIZE = 10485760
 
const NOBODY = 'nobody'
 
- Protected Attributes inherited from Avatar
 $user_id
 
 $username
 

Detailed Description

This class represents the image-picture of a license.

Member Function Documentation

checkAvatarVisibility ( )
protected

Return if avatar is visible to the current user.

Returns
boolean: true if visible
static getAvatar (   $id)
static

Returns an avatar object of the appropriate class.

Parameters
stringthe course's id
Returns
mixed the course's avatar.
getAvatarDirectoryPath ( )

Returns the file system path to the courses' avatars

Returns
string the file system path to the avatars
getAvatarDirectoryUrl ( )

Returns the URL to the courses' avatars.

Returns
string the URL to the avatars
getCssClass (   $size)
protected

Returns the CSS class to use for this avatar image.

Parameters
stringone of the constants Avatar::(NORMAL|MEDIUM|SMALL)
Returns
string CSS class to use for the avatar
getDefaultTitle ( )

Return the default title of the avatar.

Returns
string the default title
static getDimension (   $size)
static

Return the dimension of a size

Parameters
stringthe dimension of a size
Returns
array a tupel of integers [width, height]
getImageTag (   $size = Avatar::MEDIUM,
  $opt = [] 
)
static getNobody ( )
static

Returns an avatar object for "nobody".

Returns
mixed the course's avatar.

The documentation for this class was generated from the following file: