[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] phpgwapi/inc class.Services_JSON.inc.php class....
From: |
Dave Hall |
Subject: |
[Phpgroupware-cvs] phpgwapi/inc class.Services_JSON.inc.php class.... |
Date: |
Sun, 03 Sep 2006 11:14:42 +0000 |
CVSROOT: /cvsroot/phpgwapi
Module name: phpgwapi
Changes by: Dave Hall <skwashd> 06/09/03 11:14:42
Modified files:
inc : class.Services_JSON.inc.php
class.Template.inc.php
class.custom_fields.inc.php
class.data_cleaner.inc.php
class.html2text.inc.php
class.mailer_smtp.inc.php
class.nextmatchs.inc.php class.pdf.inc.php
class.preferences.inc.php
class.richtext.inc.php class.shm.inc.php
common_functions.inc.php
Log message:
more phpdoc fixes
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.Services_JSON.inc.php?cvsroot=phpgwapi&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.Template.inc.php?cvsroot=phpgwapi&r1=1.41&r2=1.42
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.custom_fields.inc.php?cvsroot=phpgwapi&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.data_cleaner.inc.php?cvsroot=phpgwapi&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.html2text.inc.php?cvsroot=phpgwapi&r1=1.2&r2=1.3
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.mailer_smtp.inc.php?cvsroot=phpgwapi&r1=1.4&r2=1.5
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.nextmatchs.inc.php?cvsroot=phpgwapi&r1=1.75&r2=1.76
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.pdf.inc.php?cvsroot=phpgwapi&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.preferences.inc.php?cvsroot=phpgwapi&r1=1.62&r2=1.63
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.richtext.inc.php?cvsroot=phpgwapi&r1=1.3&r2=1.4
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/class.shm.inc.php?cvsroot=phpgwapi&r1=1.6&r2=1.7
http://cvs.savannah.gnu.org/viewcvs/phpgwapi/inc/common_functions.inc.php?cvsroot=phpgwapi&r1=1.23&r2=1.24
Patches:
Index: class.Services_JSON.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.Services_JSON.inc.php,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- class.Services_JSON.inc.php 3 Sep 2006 04:07:00 -0000 1.2
+++ class.Services_JSON.inc.php 3 Sep 2006 11:14:42 -0000 1.3
@@ -111,6 +111,8 @@
* $input = file_get_contents('php://input', 1000000);
* $value = $json->decode($input);
* </code>
+ * @package phpgwapi
+ * @subpackage Services_JSON
*/
class Services_JSON
{
@@ -764,6 +766,12 @@
if (class_exists('pear_error')) {
+ /**
+ * Error Handler for Services_JSON
+ *
+ * @package phpgwapi
+ * @subpackage Services_JSON
+ */
class Services_JSON_Error extends PEAR_Error
{
function Services_JSON_Error($message = 'unknown error', $code = null,
@@ -777,6 +785,7 @@
/**
* @todo Ultimately, this class shall be descended from PEAR_Error
+ * @ignore
*/
class Services_JSON_Error
{
Index: class.Template.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.Template.inc.php,v
retrieving revision 1.41
retrieving revision 1.42
diff -u -b -r1.41 -r1.42
--- class.Template.inc.php 6 Aug 2006 04:51:25 -0000 1.41
+++ class.Template.inc.php 3 Sep 2006 11:14:42 -0000 1.42
@@ -8,7 +8,7 @@
* @license http://www.fsf.org/licenses/lgpl.html GNU Lesser General Public
License
* @package phpgwapi
* @subpackage gui
- * @version $Id: class.Template.inc.php,v 1.41 2006/08/06 04:51:25 skwashd Exp
$
+ * @version $Id: class.Template.inc.php,v 1.42 2006/09/03 11:14:42 skwashd Exp
$
* @internal Based on phplib
*
*/
@@ -21,6 +21,8 @@
*
* Note: If you think that this is like FastTemplates, read carefully. It
isn't.
*
+ * @package phpgwapi
+ * @subpackage gui
*/
class Template
Index: class.custom_fields.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.custom_fields.inc.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- class.custom_fields.inc.php 3 Sep 2006 06:15:27 -0000 1.3
+++ class.custom_fields.inc.php 3 Sep 2006 11:14:42 -0000 1.4
@@ -8,7 +8,7 @@
* @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package phpgwapi
- * @version $Id: class.custom_fields.inc.php,v 1.3 2006/09/03 06:15:27
skwashd Exp $
+ * @version $Id: class.custom_fields.inc.php,v 1.4 2006/09/03 11:14:42
skwashd Exp $
*/
/**
@@ -66,7 +66,7 @@
);
/**
- * @constructor
+ * Constructor
*/
function custom_fields($appname='', $location='')
{
Index: class.data_cleaner.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.data_cleaner.inc.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- class.data_cleaner.inc.php 3 Sep 2006 04:07:00 -0000 1.3
+++ class.data_cleaner.inc.php 3 Sep 2006 11:14:42 -0000 1.4
@@ -1,7 +1,7 @@
<?php
/**
* HTML Sanitizer, attemtpts to make variables safe for users.
- * $Id: class.data_cleaner.inc.php,v 1.3 2006/09/03 04:07:00 skwashd Exp $
+ * $Id: class.data_cleaner.inc.php,v 1.4 2006/09/03 11:14:42 skwashd Exp $
*
* Taken from the horde project by Dave Hall for use in phpGroupWare
*
@@ -29,7 +29,7 @@
var $data;
/**
- * @constructor
+ * Constructor
*
* @param string $data the data to be cleaned
*/
Index: class.html2text.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.html2text.inc.php,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -b -r1.2 -r1.3
--- class.html2text.inc.php 3 Sep 2006 06:15:27 -0000 1.2
+++ class.html2text.inc.php 3 Sep 2006 11:14:42 -0000 1.3
@@ -28,7 +28,9 @@
* *
* Last modified: 04/06/05 *
* *
- *************************************************************************/
+ * @package phpgwapi *
+ * @subpackage utilities *
+ ************************************************************************/
/**
@@ -70,6 +72,8 @@
* @author Jon Abernathy <address@hidden>
* @version 0.6.1
* @since PHP 4.0.2
+ * @package phpgwapi
+ * @subpackage utilities
*/
class html2text
{
Index: class.mailer_smtp.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.mailer_smtp.inc.php,v
retrieving revision 1.4
retrieving revision 1.5
diff -u -b -r1.4 -r1.5
--- class.mailer_smtp.inc.php 3 Sep 2006 04:07:00 -0000 1.4
+++ class.mailer_smtp.inc.php 3 Sep 2006 11:14:42 -0000 1.5
@@ -6,16 +6,20 @@
* @license http://www.gnu.org/licenses/gpl.html GNU General Public
License
* @package phpgwapi
* @subpackage communication
- * @version $Id: class.mailer_smtp.inc.php,v 1.4 2006/09/03 04:07:00
skwashd Exp $
+ * @version $Id: class.mailer_smtp.inc.php,v 1.5 2006/09/03 11:14:42
skwashd Exp $
*/
/**
- address@hidden phpmailer
+ * @see phpmailer
*/
include_once(PHPGW_INCLUDE_ROOT .
'/phpgwapi/inc/phpmailer/class.phpmailer.php');
/**
* Send email messages via SMTP
+ *
+ * @internal this is really just a phpgw friendly wrapper for phpmailer
+ * @package phpgwapi
+ * @subpackage communication
*/
class mailer_smtp extends PHPMailer
{
Index: class.nextmatchs.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.nextmatchs.inc.php,v
retrieving revision 1.75
retrieving revision 1.76
diff -u -b -r1.75 -r1.76
--- class.nextmatchs.inc.php 1 Sep 2006 14:39:44 -0000 1.75
+++ class.nextmatchs.inc.php 3 Sep 2006 11:14:42 -0000 1.76
@@ -3,15 +3,18 @@
* Handles limiting number of rows displayed
* @author Joseph Engo <address@hidden>
* @author Bettina Gille <address@hidden>
- * @copyright Copyright (C) 2000-2005 Free Software Foundation, Inc.
http://www.fsf.org/
+ * @author Dave Hall skwashd phpgroupware.org
+ * @copyright Copyright (C) 2000-2006 Free Software Foundation, Inc.
http://www.fsf.org/
* @license http://www.fsf.org/licenses/lgpl.html GNU Lesser General
Public License
* @package phpgwapi
* @subpackage gui
- * @version $Id: class.nextmatchs.inc.php,v 1.75 2006/09/01 14:39:44
skwashd Exp $
+ * @version $Id: class.nextmatchs.inc.php,v 1.76 2006/09/03 11:14:42
skwashd Exp $
*/
/**
* Include nextmatchs XSLT
+ * @see nextmatchs_xslt
+ * @todo make a generic abstract base class which both classes extend,
not this wacky relationship
*/
include_once(PHPGW_API_INC . '/class.nextmatchs_xslt.inc.php');
@@ -23,15 +26,32 @@
*/
class nextmatchs extends nextmatchs_xslt
{
+ /**
+ * @var int $maxmatches the maximum number of records to return
+ */
var $maxmatches;
+
+ /**
+ * @var ??? $action ???
+ */
var $action;
+
+ /**
+ * @var object $template template class
+ */
var $template;
+
+ /**
+ * @var array $extra_filters ???
+ */
var $extra_filters = array();
/**
- * @constructor
+ * Constructor
+ *
+ * @param bool $website ???
*/
- function nextmatchs($website=False)
+ function nextmatchs($website = False)
{
if(!$website)
{
@@ -50,14 +70,11 @@
$this->template->set_block('_nextmatchs','cats_search_filter');
}
+ $this->maxmatches = 15;
if(isset($GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'])
&&
intval($GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs']) >
0)
{
- $this->maxmatches =
intval($GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs']);
- }
- else
- {
- $this->maxmatches = 15;
+ $this->maxmatches =&
$GLOBALS['phpgw_info']['user']['preferences']['common']['maxmatchs'];
}
if(isset($GLOBALS['phpgw_info']['menuaction']))
@@ -871,7 +888,7 @@
* prev_page
* next_page
* last_page
- * @author: jengo, some changes by Angles
+ * @internal author: jengo, some changes by Angles
*/
function nav_left_right_imap($feed_vars)
{
Index: class.pdf.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.pdf.inc.php,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- class.pdf.inc.php 3 Sep 2006 06:15:27 -0000 1.6
+++ class.pdf.inc.php 3 Sep 2006 11:14:42 -0000 1.7
@@ -8,7 +8,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package phpgwapi
* @subpackage utilities
- * @version $Id: class.pdf.inc.php,v 1.6 2006/09/03 06:15:27 skwashd Exp
$
+ * @version $Id: class.pdf.inc.php,v 1.7 2006/09/03 11:14:42 skwashd Exp
$
*
* Example
* <code>
@@ -21,7 +21,7 @@
*
* $pdf = createObject('phpgwapi.pdf');
*
- * @set_time_limit(1800); //allows for generation of complex
documents
+ * set_time_limit(1800); //allows for generation of complex
documents
* $pdf -> ezSetMargins(50,70,50,50);
* $pdf->selectFont(PHPGW_API_INC . '/pdf/fonts/Helvetica.afm');
*
@@ -33,7 +33,10 @@
*/
/**
- * Docuemnt me!
+ * Document me!
+ *
+ * @package phpgwapi
+ * @subpackage utilities
*/
class pdf__
{
Index: class.preferences.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.preferences.inc.php,v
retrieving revision 1.62
retrieving revision 1.63
diff -u -b -r1.62 -r1.63
--- class.preferences.inc.php 3 Sep 2006 07:09:28 -0000 1.62
+++ class.preferences.inc.php 3 Sep 2006 11:14:42 -0000 1.63
@@ -7,7 +7,7 @@
* @license http://www.fsf.org/licenses/lgpl.html GNU Lesser General
Public License
* @package phpgwapi
* @subpackage application
- * @version $Id: class.preferences.inc.php,v 1.62 2006/09/03 07:09:28
Caeies Exp $
+ * @version $Id: class.preferences.inc.php,v 1.63 2006/09/03 11:14:42
skwashd Exp $
*/
/**
@@ -63,7 +63,7 @@
/**
* Standard constructor for setting $this->account_id
*
- * @constructor
+ * Constructor
* @param int $account_id the user id for which preferences are
sought - 0 == current user
*/
function preferences($account_id = 0)
@@ -341,7 +341,6 @@
/**
* add preference to $app_name a particular app
*
- * @discussion
* @param $app_name name of the app
* @param $var name of preference to be stored
* @param $value value of the preference
@@ -389,7 +388,6 @@
/**
* delete preference from $app_name
*
- * @discussion
* @param $app_name name of app
* @param $var variable to be deleted
* @param $type of preference to set: forced, default, user
@@ -608,7 +606,6 @@
/**
* insert a copy of the default preferences for use by real
account_id
*
- * @discussion
* @param $account_id numerical id of account for which to
create the prefs
*/
function create_defaults($account_id)
@@ -667,9 +664,8 @@
\**************************************************************************/
/**
- * verify basic settings
+ * verify basic settings for a user
*
- * @discussion
*/
function verify_basic_settings()
{
@@ -828,7 +824,7 @@
part is generated elsewhere.
In the absence of a custom ['email']['address'], this function
should be used to set it.
* @param $accountid - as determined in and/or passed to
"create_email_preferences"
- * @access Public now
+ * @access public
*/
function email_address($account_id='')
{
Index: class.richtext.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.richtext.inc.php,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- class.richtext.inc.php 28 Aug 2006 09:42:01 -0000 1.3
+++ class.richtext.inc.php 3 Sep 2006 11:14:42 -0000 1.4
@@ -9,7 +9,7 @@
* @license http://www.fsf.org/licenses/gpl.html GNU General Public
License
* @package phpgwapi
* @subpackage gui
- * @version $Id: class.richtext.inc.php,v 1.3 2006/08/28 09:42:01
skwashd Exp $
+ * @version $Id: class.richtext.inc.php,v 1.4 2006/09/03 11:14:42
skwashd Exp $
*/
/**
@@ -36,7 +36,7 @@
var $targets = array();
/**
- * @constructor
+ * Constructor
*/
function richtext()
{
Index: class.shm.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/class.shm.inc.php,v
retrieving revision 1.6
retrieving revision 1.7
diff -u -b -r1.6 -r1.7
--- class.shm.inc.php 3 Sep 2006 06:15:27 -0000 1.6
+++ class.shm.inc.php 3 Sep 2006 11:14:42 -0000 1.7
@@ -63,7 +63,7 @@
* @internal Development of this application was funded by
http://www.bergen.kommune.no/bbb_/ekstern/
* @package phpgwapi
* @subpackage application
- * @version $Id: class.shm.inc.php,v 1.6 2006/09/03 06:15:27 skwashd Exp
$
+ * @version $Id: class.shm.inc.php,v 1.7 2006/09/03 11:14:42 skwashd Exp
$
*/
class shm
@@ -325,7 +325,7 @@
/**
* Delete an entry from the cache
*
- * @
+ * @param int $key the entry to delete from the cache
*/
function delete_key($key)
{
Index: common_functions.inc.php
===================================================================
RCS file: /cvsroot/phpgwapi/phpgwapi/inc/common_functions.inc.php,v
retrieving revision 1.23
retrieving revision 1.24
diff -u -b -r1.23 -r1.24
--- common_functions.inc.php 3 Sep 2006 06:15:27 -0000 1.23
+++ common_functions.inc.php 3 Sep 2006 11:14:42 -0000 1.24
@@ -1,21 +1,17 @@
<?php
- /**
+/**
* Has a few functions, but primary role is to load the phpgwapi
* @author Dan Kuykendall <address@hidden>
* @author Joseph Engo <address@hidden>
+ * @author Dave Hall skwashd phpgroupware.org
* @copyright Copyright (C) 2000-2004 Free Software Foundation, Inc.
http://www.fsf.org/
* @license http://www.fsf.org/licenses/lgpl.html GNU Lesser General
Public License
* @package phpgwapi
* @subpackage utilities
- * @version $Id: common_functions.inc.php,v 1.23 2006/09/03 06:15:27
skwashd Exp $
+ * @version $Id: common_functions.inc.php,v 1.24 2006/09/03 11:14:42 skwashd
Exp $
*/
-
/****************************************************************************\
- * Direct functions which are not part of the API classes
*
- * because they are required to be available at the lowest level.
*
-
\***************************************************************************/
- /**
- * @collection_start direct functions
+ /*
* Direct functions which are not part of the API classes because they
are required to be available at the lowest level.
*
*/
@@ -23,40 +19,42 @@
/**
* Allows for array and direct function params as well as sanatization.
*
- * @author seek3r
* This function is used to validate param data as well as offer
flexible function usage.
*
- function somefunc()
- {
- $expected_args[0] =
Array('name'=>'fname','default'=>'joe', 'type'=>'string');
- $expected_args[1] =
Array('name'=>'mname','default'=>'hick', 'type'=>'string');
- $expected_args[2] =
Array('name'=>'lname','default'=>'bob', 'type'=>'string');
- $recieved_args = func_get_args();
- $args = safe_args($expected_args,
$recieved_args,__LINE__,__FILE__);
- echo 'Full name: '.$args['fname'].' '.$args['fname'].'
'.$args['lname'].'<br>';
- //default result would be:
- // Full name: joe hick bob<br>
- }
-
- Using this it is possible to use the function in any of the
following ways
- somefunc('jack','city','brown');
- or
-
somefunc(array('fname'=>'jack','mname'=>'city','lname'=>'brown'));
- or
-
somefunc(array('lname'=>'brown','fname'=>'jack','mname'=>'city'));
-
- For the last one, when using named params in an array you dont
have to follow any order
- All three would result in - Full name: jack city brown<br>
-
- When you use this method of handling params you can secure your
functions as well offer
- flexibility needed for both normal use and web services use.
- If you have params that are required just set the default as
##REQUIRED##
- Users of your functions can also use ##DEFAULT## to use your
default value for a param
- when using the standard format like this:
- somefunc('jack','##DEFAULT##','brown');
- This would result in - Full name: jack hick brown<br>
- Its using the default value for the second param.
- Of course if you have the second param as a required field it
will fail to work.
+ * @example
+ * <code>
+ * function somefunc()
+ * {
+ * $expected_args[0] =
Array('name'=>'fname','default'=>'joe', 'type'=>'string');
+ * $expected_args[1] =
Array('name'=>'mname','default'=>'hick', 'type'=>'string');
+ * $expected_args[2] =
Array('name'=>'lname','default'=>'bob', 'type'=>'string');
+ * $recieved_args = func_get_args();
+ * $args = safe_args($expected_args,
$recieved_args,__LINE__,__FILE__);
+ * echo 'Full name: '.$args['fname'].'
'.$args['fname'].' '.$args['lname'].'<br>';
+ * //default result would be:
+ * // Full name: joe hick bob<br>
+ * }
+ * </code>
+ *
+ * Using this it is possible to use the function in any of the
following ways
+ * somefunc('jack','city','brown');
+ * or
+ *
somefunc(array('fname'=>'jack','mname'=>'city','lname'=>'brown'));
+ * or
+ *
somefunc(array('lname'=>'brown','fname'=>'jack','mname'=>'city'));
+ *
+ * For the last one, when using named params in an array you dont
have to follow any order
+ * All three would result in - Full name: jack city brown<br>
+ *
+ * When you use this method of handling params you can secure your
functions as well offer
+ * flexibility needed for both normal use and web services use.
+ * If you have params that are required just set the default as
##REQUIRED##
+ * Users of your functions can also use ##DEFAULT## to use your
default value for a param
+ * when using the standard format like this:
+ * somefunc('jack','##DEFAULT##','brown');
+ * This would result in - Full name: jack hick brown<br>
+ * Its using the default value for the second param.
+ * Of course if you have the second param as a required field it
will fail to work.
*/
function safe_args($expected, $recieved, $line='??', $file='??')
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] phpgwapi/inc class.Services_JSON.inc.php class....,
Dave Hall <=