summaryrefslogtreecommitdiff
path: root/includes/install.inc
diff options
context:
space:
mode:
authorJennifer Hodgdon <yahgrp@poplarware.com>2012-10-04 09:04:02 -0700
committerJennifer Hodgdon <yahgrp@poplarware.com>2012-10-04 09:04:02 -0700
commit0a1b3116cae3577f966a8c86233c321d98c699e4 (patch)
tree4b81c649dd5793c35684dc8ce23acd78bb4c5327 /includes/install.inc
parentdb5bfb425a0571c2bc6fe164bc2fea4df60065e4 (diff)
downloadbrdo-0a1b3116cae3577f966a8c86233c321d98c699e4.tar.gz
brdo-0a1b3116cae3577f966a8c86233c321d98c699e4.tar.bz2
Issue #1317626 by Albert Volkman, xjm: Clean up API docs for include files H-M
Diffstat (limited to 'includes/install.inc')
-rw-r--r--includes/install.inc49
1 files changed, 31 insertions, 18 deletions
diff --git a/includes/install.inc b/includes/install.inc
index 6411f8f19..2f50c857c 100644
--- a/includes/install.inc
+++ b/includes/install.inc
@@ -1,6 +1,11 @@
<?php
/**
+* @file
+* API functions for installing modules and themes.
+*/
+
+/**
* Indicates that a module has not been installed yet.
*/
define('SCHEMA_UNINSTALLED', -1);
@@ -71,7 +76,7 @@ define('FILE_NOT_WRITABLE', 64);
define('FILE_NOT_EXECUTABLE', 128);
/**
- * Initialize the update system by loading all installed module's .install files.
+ * Loads .install files for installed modules to initialize the update system.
*/
function drupal_load_updates() {
foreach (drupal_get_installed_schema_version(NULL, FALSE, TRUE) as $module => $schema_version) {
@@ -204,11 +209,12 @@ function drupal_install_profile_distribution_name() {
}
/**
- * Auto detect the base_url with PHP predefined variables.
+ * Detects the base URL using the PHP $_SERVER variables.
*
* @param $file
* The name of the file calling this function so we can strip it out of
* the URI when generating the base_url.
+ *
* @return
* The auto-detected $base_url that should be configured in settings.php
*/
@@ -223,7 +229,7 @@ function drupal_detect_baseurl($file = 'install.php') {
}
/**
- * Detect all supported databases that are compiled into PHP.
+ * Detects all supported databases that are compiled into PHP.
*
* @return
* An array of database types compiled into PHP.
@@ -239,7 +245,7 @@ function drupal_detect_database_types() {
}
/**
- * Return all supported database installer objects that are compiled into PHP.
+ * Returns all supported database installer objects that are compiled into PHP.
*
* @return
* An array of database installer objects compiled into PHP.
@@ -576,7 +582,7 @@ class DatabaseTaskException extends Exception {
}
/**
- * Replace values in settings.php with values in the submitted array.
+ * Replaces values in settings.php with values in the submitted array.
*
* @param $settings
* An array of settings that need to be updated.
@@ -654,10 +660,11 @@ function drupal_rewrite_settings($settings = array(), $prefix = '') {
}
/**
- * Verify an install profile for installation.
+ * Verifies an install profile for installation.
*
* @param $install_state
* An array of information about the current installation state.
+ *
* @return
* The list of modules to install.
*/
@@ -706,7 +713,7 @@ function drupal_verify_profile($install_state) {
}
/**
- * Callback to install the system module.
+ * Installs the system module.
*
* Separated from the installation of other modules so core system
* functions can be made available while other modules are installed.
@@ -800,7 +807,7 @@ function drupal_uninstall_modules($module_list = array(), $uninstall_dependents
}
/**
- * Verify the state of the specified file.
+ * Verifies the state of the specified file.
*
* @param $file
* The file to check for.
@@ -808,6 +815,7 @@ function drupal_uninstall_modules($module_list = array(), $uninstall_dependents
* An optional bitmask created from various FILE_* constants.
* @param $type
* The type of file. Can be file (default), dir, or link.
+ *
* @return
* TRUE on success or FALSE on failure. A message is set for the latter.
*/
@@ -879,7 +887,7 @@ function drupal_verify_install_file($file, $mask = NULL, $type = 'file') {
}
/**
- * Create a directory with specified permissions.
+ * Creates a directory with the specified permissions.
*
* @param $file
* The name of the directory to create;
@@ -887,6 +895,7 @@ function drupal_verify_install_file($file, $mask = NULL, $type = 'file') {
* The permissions of the directory to create.
* @param $message
* (optional) Whether to output messages. Defaults to TRUE.
+ *
* @return
* TRUE/FALSE whether or not the directory was successfully created.
*/
@@ -918,7 +927,7 @@ function drupal_install_mkdir($file, $mask, $message = TRUE) {
}
/**
- * Attempt to fix file permissions.
+ * Attempts to fix file permissions.
*
* The general approach here is that, because we do not know the security
* setup of the webserver, we apply our permission changes to all three
@@ -935,6 +944,7 @@ function drupal_install_mkdir($file, $mask, $message = TRUE) {
* The desired permissions for the file.
* @param $message
* (optional) Whether to output messages. Defaults to TRUE.
+ *
* @return
* TRUE/FALSE whether or not we were able to fix the file's permissions.
*/
@@ -1000,7 +1010,7 @@ function drupal_install_fix_file($file, $mask, $message = TRUE) {
}
/**
- * Send the user to a different installer page.
+ * Sends the user to a different installer page.
*
* This issues an on-site HTTP redirect. Messages (and errors) are erased.
*
@@ -1078,7 +1088,7 @@ function drupal_requirements_url($severity) {
}
/**
- * Functional equivalent of t(), used when some systems are not available.
+ * Translates a string when some systems are not available.
*
* Used during the install process, when database, theme, and localization
* system is possibly not yet available.
@@ -1138,7 +1148,7 @@ function st($string, array $args = array(), array $options = array()) {
}
/**
- * Check an install profile's requirements.
+ * Checks an install profile's requirements.
*
* @param $profile
* Name of install profile to check.
@@ -1169,11 +1179,12 @@ function drupal_check_profile($profile) {
}
/**
- * Extract highest severity from requirements array.
+ * Extracts the highest severity from the requirements array.
*
* @param $requirements
* An array of requirements, in the same format as is returned by
* hook_requirements().
+ *
* @return
* The highest severity in the array.
*/
@@ -1188,12 +1199,13 @@ function drupal_requirements_severity(&$requirements) {
}
/**
- * Check a module's requirements.
+ * Checks a module's requirements.
*
* @param $module
* Machine name of module to check.
+ *
* @return
- * TRUE/FALSE depending on the requirements are in place.
+ * TRUE or FALSE, depending on whether the requirements are met.
*/
function drupal_check_module($module) {
module_load_install($module);
@@ -1218,13 +1230,14 @@ function drupal_check_module($module) {
}
/**
- * Retrieve info about an install profile from its .info file.
+ * Retrieves information about an install profile from its .info file.
*
* The information stored in a profile .info file is similar to that stored in
* a normal Drupal module .info file. For example:
* - name: The real name of the install profile for display purposes.
* - description: A brief description of the profile.
- * - dependencies: An array of shortnames of other modules this install profile requires.
+ * - dependencies: An array of shortnames of other modules that this install
+ * profile requires.
*
* Additional, less commonly-used information that can appear in a profile.info
* file but not in a normal Drupal module .info file includes: