XOOPS RMCommon Utilities  2.1.8.91RC
 All Classes Namespaces Files Functions Variables
RMImage Class Reference
Inheritance diagram for RMImage:
Inheritance graph

Public Member Functions

 __construct ($id=null)
 
 delete ()
 
 get_all_versions ()
 
 get_sizes_data ()
 
 get_smallest ()
 
 get_version ($name)
 
 getOriginal ()
 
 id ()
 
 load_from_params ($params)
 
 save ()
 
 url ($size=-1)
 
- Public Member Functions inherited from RMObject
 _loadFilters ()
 
 assignVar ($key, $value)
 
 assignVars ($var_arr)
 
 cleanVars ()
 
 errors ($html=true)
 
 getErrors ()
 
 getHtmlErrors ()
 
 getLogger ($ashtml=true)
 
 getValues ($keys=null, $format= 's', $maxDepth=1)
 
 getVar ($key, $format= 's')
 
 getVars ($formated=false, $format= 's')
 
 id ()
 
 initVar ($key, $data_type, $value=null, $required=false, $maxlength=null, $options= '')
 
 isDirty ()
 
 isNew ()
 
 registerFilter ($filtername)
 
 rmClone ()
 
 setDirty ()
 
 setErrors ($err_str)
 
 setFormVars ($var_arr=null, $pref='xo_', $not_gpc=false)
 
 setNew ()
 
 setVar ($key, $value, $not_gpc=false)
 
 setVarLen ($var, $len=null)
 
 setVarRequired ($var, $required)
 
 setVars ($var_arr, $not_gpc=false)
 
 setVarType ($var, $type)
 
 unsetDirty ()
 
 unsetNew ()
 

Private Attributes

 $selected_size = 0
 
 $sizes = array()
 

Additional Inherited Members

- Public Attributes inherited from RMObject
 $cleanVars = array()
 
- Protected Member Functions inherited from RMObject
 addError ($text)
 
 clear_vars ()
 
 clearLogger ()
 
 deleteFromTable ()
 
 getColumns ()
 
 initVarsFromTable ()
 
 loadValues ($id)
 
 loadValuesArray ($values)
 
 loadValuesFiltered ($filter='')
 
 logger ($event, $style='')
 
 saveToTable ()
 
 updateTable ()
 
 varIsset ($var)
 
- Protected Attributes inherited from RMObject
 $_dbtable = ''
 
 $_log = array()
 
 $db = null
 
 $primary = 'id'
 
 $vars = array()
 

Detailed Description

Class to handle images created from Image Manager

Definition at line 15 of file image.php.

Constructor & Destructor Documentation

RMImage::__construct (   $id = null)

Definition at line 28 of file image.php.

References $id, RMObject\initVarsFromTable(), RMObject\loadValues(), RMObject\setNew(), and RMObject\unsetNew().

Here is the call graph for this function:

Member Function Documentation

RMImage::delete ( )

Definition at line 180 of file image.php.

References $path, $sizes, RMObject\deleteFromTable(), get_sizes_data(), and RMObject\getVar().

Here is the call graph for this function:

RMImage::get_all_versions ( )

Get all image versions with url

Returns
array

Definition at line 136 of file image.php.

References $ret, get_sizes_data(), RMObject\isNew(), and url().

Here is the call graph for this function:

RMImage::get_sizes_data ( )

Get all image sizes

Returns
array

Definition at line 72 of file image.php.

References $cat, $sizes, and RMObject\getVar().

Referenced by delete(), get_all_versions(), get_smallest(), get_version(), and url().

Here is the call graph for this function:

Here is the caller graph for this function:

RMImage::get_smallest ( )

Definition at line 111 of file image.php.

References get_sizes_data(), RMObject\isNew(), and url().

Here is the call graph for this function:

RMImage::get_version (   $name)

Definition at line 149 of file image.php.

References $ret, get_sizes_data(), RMObject\isNew(), and url().

Here is the call graph for this function:

RMImage::getOriginal ( )

Definition at line 164 of file image.php.

References $url, and RMObject\getVar().

Here is the call graph for this function:

RMImage::id ( )

Definition at line 42 of file image.php.

References RMObject\getVar().

Here is the call graph for this function:

RMImage::load_from_params (   $params)

Load data from database table according to given parameters

Parameters
stringParams must be passed as string separated by ":" (e.g. 1:3) where second parameter is selected size if any return bool

Definition at line 51 of file image.php.

References $p, RMObject\loadValues(), and RMObject\unsetNew().

Here is the call graph for this function:

RMImage::save ( )

Definition at line 170 of file image.php.

References RMObject\isNew(), RMObject\saveToTable(), and RMObject\updateTable().

Here is the call graph for this function:

RMImage::url (   $size = -1)

Constructs the URL for image according to defined size

Parameters
intSpecific size to construct the url
Returns
string

Definition at line 88 of file image.php.

References $selected_size, $url, get_sizes_data(), RMObject\getVar(), and RMObject\isNew().

Referenced by get_all_versions(), get_smallest(), and get_version().

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

RMImage::$selected_size = 0
private

Definition at line 21 of file image.php.

Referenced by url().

RMImage::$sizes = array()
private

Stores all sizes for category

Parameters
array

Definition at line 26 of file image.php.

Referenced by delete(), and get_sizes_data().


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