Open Journal Systems  2.4.4
 All Classes Namespaces Functions Variables Groups Pages
HelpTopicDAO Class Reference
Inheritance diagram for HelpTopicDAO:
XMLDAO

Public Member Functions

getTopic ($topicId)
 
getTopicsByKeyword ($keyword)
 
 HelpTopicDAO ()
 
 scanTopic (&$mappingFile, &$matchingTopics, $keyword, $dir, $file)
 
 searchDirectory (&$mappingFile, &$matchingTopics, $keyword, $dir)
 
- Public Member Functions inherited from XMLDAO
parse ($file)
 
parseStruct ($file, $tagsToMatch=array())
 
parseWithHandler ($file, &$handler)
 
 XMLDAO ()
 

Detailed Description

Operations for retrieving HelpTopic objects.

See Also
HelpTopic

Definition at line 21 of file HelpTopicDAO.inc.php.

Member Function Documentation

& HelpTopicDAO::getTopic (   $topicId)

Retrieve a topic by its ID.

Parameters
$topicIdstring
Returns
HelpTopic

Definition at line 87 of file HelpTopicDAO.inc.php.

Referenced by scanTopic().

& HelpTopicDAO::getTopicsByKeyword (   $keyword)

Returns a set of topics matching a specified keyword.

Parameters
$keywordstring
Returns
array matching HelpTopics

Definition at line 130 of file HelpTopicDAO.inc.php.

References PKPHelp\getHelp(), searchDirectory(), and String\strtolower().

HelpTopicDAO::HelpTopicDAO ( )

Constructor

Definition at line 25 of file HelpTopicDAO.inc.php.

HelpTopicDAO::scanTopic ( $mappingFile,
$matchingTopics,
  $keyword,
  $dir,
  $file 
)

Scans topic xml files for keywords

Parameters
$mappingFileobject The responsible mapping file
$matchingTopicsarray stores topics that match the keyword
$keywordstring
$dirstring
$filestring $matchingTopics array by reference

Definition at line 181 of file HelpTopicDAO.inc.php.

References getTopic(), String\strtolower(), and String\substr_count().

Referenced by searchDirectory().

HelpTopicDAO::searchDirectory ( $mappingFile,
$matchingTopics,
  $keyword,
  $dir 
)

Parses deeper into folders if subdirectories exists otherwise scans the topic xml files

Parameters
$mappingFilearray The responsible mapping file
$matchingTopicsarray stores topics that match the keyword
$keywordstring
$dirstring $matchingTopics array by reference by making appropriate calls to functions

Definition at line 159 of file HelpTopicDAO.inc.php.

References scanTopic().

Referenced by getTopicsByKeyword().


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