From 2b42893fa9e8d564abf47d495558295d2979c0de Mon Sep 17 00:00:00 2001 From: Georg Ehrke Date: Sat, 8 Sep 2012 16:18:47 +0200 Subject: [PATCH] style fixes for public util api --- lib/public/util.php | 33 +++++++++------------------------ 1 file changed, 9 insertions(+), 24 deletions(-) diff --git a/lib/public/util.php b/lib/public/util.php index ed23521b040..747448e62eb 100644 --- a/lib/public/util.php +++ b/lib/public/util.php @@ -34,8 +34,6 @@ namespace OCP; * This class provides different helper functions to make the life of a developer easier */ class Util { - - // consts for Logging const DEBUG=0; const INFO=1; @@ -43,7 +41,6 @@ class Util { const ERROR=3; const FATAL=4; - /** * @brief get the current installed version of ownCloud * @return array @@ -52,7 +49,6 @@ class Util { return(\OC_Util::getVersion()); } - /** * @brief send an email * @param string $toaddress @@ -68,18 +64,16 @@ class Util { \OC_MAIL::send( $toaddress, $toname, $subject, $mailtext, $fromaddress, $fromname, $html=0, $altbody='', $ccaddress='', $ccname='', $bcc=''); } - - /** + /** * @brief write a message in the log * @param string $app * @param string $message * @param int level - */ - public static function writeLog( $app, $message, $level ) { - // call the internal log class - \OC_LOG::write( $app, $message, $level ); - } - + */ + public static function writeLog( $app, $message, $level ) { + // call the internal log class + \OC_LOG::write( $app, $message, $level ); + } /** * @brief add a css file @@ -87,8 +81,7 @@ class Util { */ public static function addStyle( $application, $file = null ) { \OC_Util::addStyle( $application, $file ); - } - + } /** * @brief add a javascript file @@ -97,7 +90,7 @@ class Util { */ public static function addScript( $application, $file = null ) { \OC_Util::addScript( $application, $file ); - } + } /** * @brief Add a custom element to the header @@ -118,8 +111,6 @@ class Util { return(\OC_Util::formatDate( $timestamp,$dateOnly )); } - - /** * @brief Creates an absolute url * @param $app app @@ -133,7 +124,6 @@ class Util { return(\OC_Helper::linkToAbsolute( $app, $file, $args )); } - /** * @brief Creates an absolute url for remote use * @param $service id @@ -156,7 +146,6 @@ class Util { return \OC_Helper::linkToPublic($service); } - /** * @brief Creates an url * @param $app app @@ -199,11 +188,10 @@ class Util { * * Returns the path to the image. */ - public static function imagePath( $app, $image ) { + public static function imagePath( $app, $image ) { return(\OC_Helper::imagePath( $app, $image )); } - /** * @brief Make a human file size * @param $bytes file size in bytes @@ -244,7 +232,6 @@ class Util { return(\OC_Hook::connect( $signalclass, $signalname, $slotclass, $slotname )); } - /** * @brief emitts a signal * @param $signalclass class name of emitter @@ -260,7 +247,6 @@ class Util { return(\OC_Hook::emit( $signalclass, $signalname, $params )); } - /** * Register an get/post call. This is important to prevent CSRF attacks * TODO: write example @@ -269,7 +255,6 @@ class Util { return(\OC_Util::callRegister()); } - /** * Check an ajax get/post call if the request token is valid. exit if not. * Todo: Write howto -- 2.39.5