Class: I2CE FileSearch: Difference between revisions

From IHRIS Wiki
No edit summary
(Redirected page to Class: I2CE FileSearch (4.1.12))
 
(13 intermediate revisions by one other user not shown)
Line 1: Line 1:
This article describes the class ''I2CE_FileSearch''.
#REDIRECT [[Class: I2CE_FileSearch (4.1.12)]]
*Child Classes:
** [[Class: I2CE_FileSearch_Caching | I2CE_FileSearch_Caching]]
*Location: Part of the module [[I2CE Module List#I2CE|I2CE]] in the package [https://launchpad.net/i2ce I2CE]
*Source: Defined in the file [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L27 lib/I2CE_FileSearch.php] on line 27
Class to handle file searching.
==Variables==
===$relative_path===
If not null, it is the file system path that all paths are attempted to resolve to. If null, all resolved paths are absolute @protected static string $relative_path
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L35 i2ce/lib/I2CE_FileSearch.php] on line 35
*Type: static protected $relative_path
 
===$relative_root===
The root drive of the relative path e.g. "C:" on windows or '/' on unix. on windows unix it may or may  not  contains the trailing "\" due to the following maddness: *realpath(C:) is C:\ *realpath(C:\) is C:\ *realpath(C:\\) is C:\ *realpath(C:\some) is C:\some *realpath(C:\some\) is C:\some @protected static string $relative_root
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L48 i2ce/lib/I2CE_FileSearch.php] on line 48
*Type: static protected $relative_root
 
===$relative_parts===
The parts of the relative path.  On windows, it does '''not''' include the drive letter. @protected static array of string $relative_parts
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L55 i2ce/lib/I2CE_FileSearch.php] on line 55
*Type: static protected $relative_parts
 
===$found_locales===
The found locale(s) .  One of: FALSE, a string, or an array.  The former two in the case of a single serach, the later in case of a $find_all search
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L257 i2ce/lib/I2CE_FileSearch.php] on line 257
*Type: protected [http://www.php.net/manual/en/language.pseudo-types.php mixed ] $found_locales
 
===$preferred_locales===
.  Keys are categories. Values are arrrays of string, the preferred locales.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L279 i2ce/lib/I2CE_FileSearch.php] on line 279
*Type: protected [http://www.php.net/manual/en/language.types.array.php array ] $preferred_locales
 
===$ordered_paths===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L287 i2ce/lib/I2CE_FileSearch.php] on line 287
*Type: protected $ordered_paths
 
===$absolut===
protected $var boolean $absolut -- wheter or not to make relative paths absolut based on the directory of the calling file
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L294 i2ce/lib/I2CE_FileSearch.php] on line 294
*Type: protected $absolut
 
===$search_hidden===
protected $var boolean $search_hidden.  Whether or not to search hidden sub-directories
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L301 i2ce/lib/I2CE_FileSearch.php] on line 301
*Type: protected $search_hidden
 
===$search_cwd===
protected @var boolean $search_cwd. Whether or not to seach the current working directory
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L307 i2ce/lib/I2CE_FileSearch.php] on line 307
*Type: protected $search_cwd
 
===$last_order===
protected @var array $last_order values are the order of the last thing added to the category keys are the classes.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L314 i2ce/lib/I2CE_FileSearch.php] on line 314
*Type: protected $last_order
 
===$checked_directories===
protected @var array $checked_directories array with keys directories and values boolean It is true if the directory has already been checked.  Used to avoid recursion,
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L321 i2ce/lib/I2CE_FileSearch.php] on line 321
*Type: protected $checked_directories
 
==Methods==
===__construct()===
Constructor for the FileSearch class
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L334 i2ce/lib/I2CE_FileSearch.php] on line 334
*Signature: public function __construct($hidden,$current_working,$make_absolut)
*Parameters:
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $hidden <br/>Defaults to false.  Whether or not to search hidden sub-directories.  At the moment it does not have meaning on non unix like platforms.
***Default Value: false
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $current_working <br/>Defaults to false. Whether or not to search the current working directory for the file.  If so, it checks there first, before the other paths.
***Default Value: false
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $make_absolut <br/>Defaults to false.  Whether or not to make a relative path absolute when adding it.
***Default Value: false
===_resolve()===
Function to search through a list of paths to find a specified file.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L976 i2ce/lib/I2CE_FileSearch.php] on line 976
*Signature: protected function _resolve($regExps,$paths,$find_all,$dir_prefix,$reset_found_locales)
*Parameters:
** [http://www.php.net/manual/en/language.types.array.php array ] $regExps <br/>If desired_file is null then, then $regExp is a list of regular expression to match file names on.
** [http://www.php.net/manual/en/language.types.array.php array ] $paths <br/>of string.  The keys are the paths we want to search, the values are the locale they are in
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $find_all <br/>If true we find all files, otherwise we return on the first match
** [http://www.php.net/manual/en/language.types.string.php string ] $dir_prefix <br/>any directory we want to prepend onto the file name.
***Default Value: ''
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $reset_found_locales <br/>Defualts to false
***Default Value: false
===absolut()===
Makes a relative file path or file url absolute relative to the directory that the function was called in.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L409 i2ce/lib/I2CE_FileSearch.php] on line 409
*Signature: static public function absolut($path,$indx)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path <br/>a path or URL
** [http://www.php.net/manual/en/language.types.integer.php int ] $indx <br/>the index, from the top level, to consider the calling file defaults to 0 which is the file that is calling this.
***Default Value: 0
*Returns: [http://www.php.net/manual/en/language.types.string.php string ]<br/>the absolute path or URL
===addPath()===
A path to search for a category of files.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L574 i2ce/lib/I2CE_FileSearch.php] on line 574
*Signature: public function addPath($category,$path,$order,$absolut,$path_prefix,$locales)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category <br/>the category of files.
** [http://www.php.net/manual/en/language.types.string.php string ] $path <br/>the parh (or glob pattern for a path) to add.  There a a few modifications to the globbing... A trailing '**' means that the paths should be added recursivley Paths are automatically checked for localized version by the presence of a 'en_US' subdirectory. specifically, if a path is added such as /my/path  and there is a subdir called /my/path/en_US  then all subdirectories which are in the preffered locales (or $locales below) are added. Examples:  /usr/share/fonts/      adds in this directory to the search paths /usr/share/fonts/*  adds in all subdirectories /usr/share/fonts/**  recusively adds in all subdirecties /usr/share/fonts/truetype/ttf*  adds in all directories begining with ttf
** [http://www.php.net/manual/en/language.pseudo-types.php mixed ] $order <br/>If it is a  number, then it indicates the order in which this path is  searched. The lower the number, the higher the priority. If multiple paths share the same order, the order in which they are searched is not specfied The are also special string values of $order (all are relative to the category specified): <ul> <li>'LAST' -- add at the last added order </li> <li>'LOWEST' -- add so it has the lowest order thus far  </li> <li>'HIGHEST' -- add so it has the highest order thus far </li> <li>'EVEN_LOWER' -- add so it has lower order than anything thus far.  This is the default behavior </li> <li>'EVEN_HIGHER' -- add so it has higher  order than anything thus far </li> </ul>
***Default Value: 'EVEN_LOWER'
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $absolut <br/>whether or not to try to make a relative path absolut.  It will overide (but not change) the global behaviour of this instance.
***Default Value: null
** [http://www.php.net/manual/en/language.types.string.php string ] $path_prefix <br/>Defaults to null.  Any prefix to add to a local class path (if we do make absolute)
***Default Value: null
** [http://www.php.net/manual/en/language.pseudo-types.php mixed ] $locales <br/>null(default) , string or array of string.  Used to override the default locale settings when not the defaults of null. It is the list of localized sub-directories to search for, if the given glob is a subdirectory.
***Default Value: null
===changeRelativeToAbsolut()===
Set whether or not to make relative paths absolute
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L374 i2ce/lib/I2CE_FileSearch.php] on line 374
*Signature: public function changeRelativeToAbsolut($absolut)
*Parameters:
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $absolut
===convertUnixToWin()===
Convert a relative windows path with / to  one with \
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L537 i2ce/lib/I2CE_FileSearch.php] on line 537
*Signature: static public function convertUnixToWin($path)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path returns $string
===findByRegularExpression()===
Finds all files with a given extension in the category
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L850 i2ce/lib/I2CE_FileSearch.php] on line 850
*Signature: public function findByRegularExpression($category,$regExps,$find_all,$dir_prefix)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.pseudo-types.php mixed ] $regExps <br/>It may be a string, in which case it is a regular expression to match file names on.  It may be an array of strings, them we attempt a match against each of the regular expressions specified by the strings.
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $find_all <br/>If true we find all files, otherwise we return on the first match
** [http://www.php.net/manual/en/language.types.string.php string ] $dir_prefix <br/>any directory we want to prepend onto the file name.
***Default Value: ''
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]<br/>of string
===findWinShortFileName()===
On windows, convert a given file in a given directory to a 8.3 filename
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L471 i2ce/lib/I2CE_FileSearch.php] on line 471
*Signature: static protected function findWinShortFileName($file,$dir)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $file
**$dir
*Returns: [http://www.php.net/manual/en/language.types.string.php string ]
===findWinShortPathName()===
Attempt to convert a windows long path name to its 8.3 version
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L498 i2ce/lib/I2CE_FileSearch.php] on line 498
*Signature: static public function findWinShortPathName($file)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $file <br/>The absoluate path to a file/directory
*Returns: @string Example:  C:\Program Files\my_long_dir  becomes c:\program~1\my_lon~1
===getCategories()===
Get the categories specified
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L433 i2ce/lib/I2CE_FileSearch.php] on line 433
*Signature: public function getCategories()
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]<br/>of string
===getLastOrder()===
Get the last order set for the specified category.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L425 i2ce/lib/I2CE_FileSearch.php] on line 425
*Signature: public function getLastOrder($category)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
*Returns: [http://www.php.net/manual/en/language.types.integer.php int ]
===getLocaleOfLastSearch()===
Get the locale(s) of the results of the last search.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L827 i2ce/lib/I2CE_FileSearch.php] on line 827
*Signature: public function getLocaleOfLastSearch()
*Returns: mixed.<br/>If the last search has $find_all = false then either false if no file was found or a string, the locale in which the the results was found.  If the $find_all was true, then it is an array of string, the locales of the files found.
===getParts()===
Returns the parts of a path split up according to the directory spearator.  Does _not_ check to see if the given $path is valid
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L136 i2ce/lib/I2CE_FileSearch.php] on line 136
*Signature: static public function getParts($path,$dir_sep,$esc_char,$ignore_empty)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path @param mixed string $dir_sep.  chracter or array of charaterds. Defautls to DIRECTORY_SEPARATOR.  A single character used as the directory sepearator
**$dir_sep
***Default Value: DIRECTORY_SEPARATOR
** [http://www.php.net/manual/en/language.types.string.php string ] $esc_char <br/>Defautls to '\' if $dir_sep is '/' and detaults to none if the $dir_sep is '\'. Set it to false if you don't want any escape characters
***Default Value: null
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $ignore_empty <br/>If true (default), we dont add "empty" parts e.g. C:\some\\path returns array('c:','some','path'). Exmaple: \toolkit\path returns array('toolkit','path')
***Default Value: true
*Returns: $array
===getRelativePath()===
Returns the path which all files are attempted to resolve relative to
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L224 i2ce/lib/I2CE_FileSearch.php] on line 224
*Signature: static public function getRelativePath()
*Returns: [http://www.php.net/manual/en/language.pseudo-types.php mixed ]<br/>string, the path, or null if there is no relative path
===getRootPath()===
Attempts to get the base directory of the given path. On unix (or non-windows) this is always '/' On windows it is the drive with colon and no trailing slash, e.g. 'E:'
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L235 i2ce/lib/I2CE_FileSearch.php] on line 235
*Signature: static public function getRootPath($path)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path <br/>An absolute path
*Returns: mixed.<br/>A string on success, null on failure
===getSearchPath()===
Gets the search path for the specified catgegory
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L449 i2ce/lib/I2CE_FileSearch.php] on line 449
*Signature: public function getSearchPath($category,$localized)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $localized <br/>(FALSE)
***Default Value: FALSE
*Returns: array.<br/>If not localized with keys integers, the orders, and values an array of strings, the paths for that order, if $localized is TRUE, and keys are paths values are locales.
===isAbsolut()===
Checks to see if a path is absolute. All files identified by a URI/L are considered to be absolute
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L384 i2ce/lib/I2CE_FileSearch.php] on line 384
*Signature: static public function isAbsolut($path)
*Parameters:
**$path
*Returns: [http://www.php.net/manual/en/language.types.boolean.php boolean ]
===limitToSubdir()===
Remove sub-directories from a category
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L918 i2ce/lib/I2CE_FileSearch.php] on line 918
*Signature: public function limitToSubdir($category,$limit)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.types.string.php string ] $limit <br/>The subdirectory to limit to.
***Default Value: ""
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]<br/>List of directories
===realPath()===
Gets the real path, realpath(),  of a given path on unix. On windows, if the relative path is not set, then this is just realpath(), otherwise it tries to resolve it as a path relative to the [[#$relative_root | $relative_root]] return mixed. String or false on failure
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L64 i2ce/lib/I2CE_FileSearch.php] on line 64
*Signature: static public function realPath($path)
*Parameters:
**$path
===relativePath()===
Gets the relative real path of a given path on a windows box. If the relative path is not set, then this is just realpath(), otherwise it tries to resolve it as a path relative to the [[#$relative_root | $relative_root]] See windows path conventions.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L85 i2ce/lib/I2CE_FileSearch.php] on line 85
*Signature: static public function relativePath($path)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path return mixed. String or false on failure
===removePath()===
Remove a path in a category
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L717 i2ce/lib/I2CE_FileSearch.php] on line 717
*Signature: public function removePath($category,$path,$absolut,$path_prefix)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.types.string.php string ] $path
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $absolut <br/>whether or not to try to make a relative path absolut.  It will overide (but not change) the global behaviour of this instance.
***Default Value: FALSE
** [http://www.php.net/manual/en/language.types.string.php string ] $path_prefix <br/>Defaults to null.  Any prefix to add to a relative class path (if we do make absolute)
***Default Value: NULL
===removePaths()===
Remove a list of paths from the category path list.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L755 i2ce/lib/I2CE_FileSearch.php] on line 755
*Signature: public function removePaths($category,$path_list)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.types.array.php array ] $path_list <br/>The subdirectory to limit to.
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]<br/>List of directories
===reset()===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L344 i2ce/lib/I2CE_FileSearch.php] on line 344
*Signature: public function reset()
===resetFoundLocales()===
Reset the found locales
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L814 i2ce/lib/I2CE_FileSearch.php] on line 814
*Signature: protected function resetFoundLocales($multiple)
*Parameters:
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $multiple <br/>If true setup so we are returning multiple resutls.  otherwise we return a single result
===resolve()===
Function to search through a list of paths to find a specified file.
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L954 i2ce/lib/I2CE_FileSearch.php] on line 954
*Signature: public function resolve($regExps,$paths,$find_all,$dir_prefix,$reset_found_locales)
*Parameters:
** [http://www.php.net/manual/en/language.types.array.php array ] $regExps <br/>If desired_file is null then, then $regExp is a list of regular expression to match file names on.
** [http://www.php.net/manual/en/language.types.array.php array ] $paths <br/>of string.  The keys are the paths we want to search, the values are the locale they are in
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $find_all <br/>If true we find all files, otherwise we return on the first match
** [http://www.php.net/manual/en/language.types.string.php string ] $dir_prefix <br/>any directory we want to prepend onto the file name.
***Default Value: ''
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $reset_found_locales <br/>Defualts to false
***Default Value: false
===search()===
Find a file (or directory) of a certain category
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L773 i2ce/lib/I2CE_FileSearch.php] on line 773
*Signature: public function search($category,$filename,$find_all)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category <br/>the category of the file
** [http://www.php.net/manual/en/language.types.string.php string ] $filename <br/>the file name of the file we wish to find
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $find_all <br/>Defaults to false
***Default Value: FALSE
*Returns: mixed.<br/>Returns either a string which is the path and file name of the file we found, or null if we did not find the file, or an array of file names if $find_all was set to true
===searchCurrentWorkingDirectory()===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L358 i2ce/lib/I2CE_FileSearch.php] on line 358
*Signature: public function searchCurrentWorkingDirectory($search)
*Parameters:
**$search
===searchHiddenSubdirectories()===
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L366 i2ce/lib/I2CE_FileSearch.php] on line 366
*Signature: public function searchHiddenSubdirectories($search)
*Parameters:
**$search
===searchPaths()===
Search paths for matches to the regular expression
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L888 i2ce/lib/I2CE_FileSearch.php] on line 888
*Signature: public function searchPaths($find_all,$regExps,$paths,$prefix)
*Parameters:
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $find_all <br/>FALSE = return only the first hit.
** [http://www.php.net/manual/en/language.types.array.php array ] $regExps <br/>Regular expressions to match
** [http://www.php.net/manual/en/language.types.array.php array ] $paths <br/>Paths to look in
** [http://www.php.net/manual/en/language.types.string.php string ] $prefix <br/>Directory prefix
*Returns: [http://www.php.net/manual/en/language.types.array.php array ]<br/>List of directories
===setPreferredLocales()===
Set the preferred locale(s) for a category. If not set, defaults the locales default to I2CE::DEFAULT_LOCALE
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L267 i2ce/lib/I2CE_FileSearch.php] on line 267
*Signature: public function setPreferredLocales($category,$locales,$validate)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $category
** [http://www.php.net/manual/en/language.pseudo-types.php mixed ] $locales <br/>string or array of string. The locales.
** [http://www.php.net/manual/en/language.types.boolean.php boolean ] $validate <br/>Defaults to true.
***Default Value: true
===setRelativePath()===
Attempts to set the path for which all files are referenced relative to.  not implemented for unix. This is mainly used for the usb-toolkit on windows:
*Defined in [http://bazaar.launchpad.net/~intrahealth+informatics/i2ce/4.0.2-release/annotate/head:/lib/I2CE_FileSearch.php#L188 i2ce/lib/I2CE_FileSearch.php] on line 188
*Signature: static public function setRelativePath($path)
*Parameters:
** [http://www.php.net/manual/en/language.types.string.php string ] $path
 
 
[[Category:Class Documentation]]

Latest revision as of 10:43, 18 August 2015