ILIAS
release_5-2 Revision v5.2.25-18-g3f80b828510
|
Explorer base GUI class. More...
Public Member Functions | |
__construct ($a_expl_id, $a_parent_obj, $a_parent_cmd) | |
Constructor. More... | |
getRootNode () | |
Get root node. More... | |
getChildsOfNode ($a_parent_node_id) | |
Get childs of node. More... | |
getNodeContent ($a_node) | |
Get content of a node. More... | |
getNodeId ($a_node) | |
Get id of a node. More... | |
getNodeHref ($a_node) | |
Get href for node. More... | |
nodeHasVisibleChilds ($a_node) | |
Node has childs? More... | |
sortChilds ($a_childs, $a_parent_node_id) | |
Sort childs. More... | |
getNodeIcon ($a_node) | |
Get node icon path. More... | |
getNodeIconAlt ($a_node) | |
Get node icon alt attribute. More... | |
getNodeTarget ($a_node) | |
Get node target (frame) attribute. More... | |
getNodeOnClick ($a_node) | |
Get node onclick attribute. More... | |
isNodeVisible ($a_node) | |
Is node visible? More... | |
isNodeHighlighted ($a_node) | |
Is node highlighted? More... | |
isNodeClickable ($a_node) | |
Is node clickable? More... | |
getId () | |
Get id of explorer element. More... | |
setSkipRootNode ($a_val) | |
Set skip root node. More... | |
getSkipRootNode () | |
Get skip root node. More... | |
setAjax ($a_val) | |
Set ajax. More... | |
getAjax () | |
Get ajax. More... | |
setSecondaryHighlightedNodes ($a_val) | |
Set secondary (background) highlighted nodes. More... | |
getSecondaryHighlightedNodes () | |
Get secondary (background) highlighted nodes. More... | |
setNodeOpen ($a_id) | |
Set node to be opened (additional custom opened node, not standard expand behaviour) More... | |
setSelectMode ($a_postvar, $a_multi=false) | |
Set select mode (to deactivate, pass an empty string as postvar) More... | |
setNodeSelected ($a_id) | |
Set node to be opened (additional custom opened node, not standard expand behaviour) More... | |
setOfflineMode ($a_val) | |
Set offline mode. More... | |
getOfflineMode () | |
Get offline mode. More... | |
handleCommand () | |
Handle explorer internal command. More... | |
getContainerId () | |
Get container id. More... | |
openNode () | |
Open node. More... | |
closeNode () | |
Close node. More... | |
getNodeAsync () | |
Get node asynchronously. More... | |
beforeRendering () | |
Before rendering. More... | |
getOnLoadCode () | |
Get on load code. More... | |
getHTML () | |
Get HTML. More... | |
renderNode ($a_node, $tpl) | |
Render node. More... | |
renderChilds ($a_node_id, $tpl) | |
Render childs. More... | |
getDomNodeIdForNodeId ($a_node_id) | |
Get DOM node id for node id. More... | |
getNodeIdForDomNodeId ($a_dom_node_id) | |
Get node id for dom node id. More... | |
listItemStart ($tpl, $a_node) | |
List item start. More... | |
listItemEnd ($tpl) | |
List item end. More... | |
listStart ($tpl) | |
List start. More... | |
listEnd ($tpl) | |
List end. More... | |
isNodeOnclickEnabled () | |
setNodeOnclickEnabled ($nodeOnclickEnabled) | |
isEnableDnd () | |
setEnableDnd ($enable_dnd) | |
Enable Drag & Drop functionality. More... | |
Static Public Member Functions | |
static | getLocalExplorerJsPath () |
Get local path of explorer js. More... | |
static | getLocalJsTreeJsPath () |
Get local path of jsTree js. More... | |
static | createHTMLExportDirs ($a_target_dir) |
Create html export directories. More... | |
static | init () |
Init JS. More... | |
Protected Member Functions | |
isNodeSelectable ($a_node) | |
Is node selectable? More... | |
getNodeToggleOnClick ($a_node) | |
Get onclick attribute for node toggling. More... | |
getSelectOnClick ($a_node) | |
Get onclick attribute for selecting radio/checkbox. More... | |
getJSTreePlugins () | |
Protected Attributes | |
$skip_root_node = false | |
$ajax = false | |
$custom_open_nodes = array() | |
$selected_nodes = array() | |
$select_postvar = "" | |
$offline_mode = false | |
$sec_highl_nodes = array() | |
$enable_dnd = false | |
Static Protected Attributes | |
static | $js_tree_path = "./Services/UIComponent/Explorer2/lib/jstree-v.pre1.0/jquery.jstree.js" |
static | $js_expl_path = "./Services/UIComponent/Explorer2/js/Explorer2.js" |
Private Attributes | |
$nodeOnclickEnabled | |
Explorer base GUI class.
The class is supposed to work on a hierarchie of nodes that are identified by IDs. Whether nodes are represented by associative arrays or objects is not defined by this abstract class.
Definition at line 16 of file class.ilExplorerBaseGUI.php.
ilExplorerBaseGUI::__construct | ( | $a_expl_id, | |
$a_parent_obj, | |||
$a_parent_cmd | |||
) |
ilExplorerBaseGUI::beforeRendering | ( | ) |
Before rendering.
Definition at line 521 of file class.ilExplorerBaseGUI.php.
Referenced by getHTML(), and getNodeAsync().
ilExplorerBaseGUI::closeNode | ( | ) |
Close node.
Definition at line 482 of file class.ilExplorerBaseGUI.php.
References $_GET, $ilLog, exit, and getNodeIdForDomNodeId().
|
static |
Create html export directories.
string | $a_target_dir | target directory |
Definition at line 74 of file class.ilExplorerBaseGUI.php.
References getChildsOfNode(), getNodeContent(), getNodeId(), getRootNode(), and ilUtil\makeDirParents().
Referenced by ilObjContentObject\exportHTML().
ilExplorerBaseGUI::getAjax | ( | ) |
Get ajax.
Definition at line 316 of file class.ilExplorerBaseGUI.php.
References $ajax.
Referenced by getOnLoadCode(), ilObjStudyProgrammeTreeExplorerGUI\listItemStart(), listItemStart(), and renderNode().
|
abstract |
Get childs of node.
string | $a_parent_id | parent node id |
Referenced by createHTMLExportDirs(), getHTML(), ilKSDocumentationExplorerGUI\getRootNode(), nodeHasVisibleChilds(), and renderChilds().
ilExplorerBaseGUI::getContainerId | ( | ) |
Get container id.
Definition at line 458 of file class.ilExplorerBaseGUI.php.
Referenced by ilForumExplorerGUI\getHTML(), ilObjStudyProgrammeTreeExplorerGUI\getHTML(), getHTML(), getOnLoadCode(), and handleCommand().
ilExplorerBaseGUI::getDomNodeIdForNodeId | ( | $a_node_id | ) |
Get DOM node id for node id.
Definition at line 816 of file class.ilExplorerBaseGUI.php.
Referenced by getNodeToggleOnClick(), getOnLoadCode(), getSelectOnClick(), ilObjStudyProgrammeTreeExplorerGUI\listItemStart(), and listItemStart().
ilExplorerBaseGUI::getHTML | ( | ) |
Get HTML.
Definition at line 627 of file class.ilExplorerBaseGUI.php.
References $ilCtrl, $tpl, beforeRendering(), getChildsOfNode(), getContainerId(), getNodeId(), getOnLoadCode(), getRootNode(), getSkipRootNode(), isNodeVisible(), listEnd(), listStart(), renderNode(), and sortChilds().
ilExplorerBaseGUI::getId | ( | ) |
Get id of explorer element.
Definition at line 274 of file class.ilExplorerBaseGUI.php.
Referenced by getNodeIdForDomNodeId().
|
protected |
Definition at line 599 of file class.ilExplorerBaseGUI.php.
References array, and isEnableDnd().
Referenced by getOnLoadCode().
|
static |
Get local path of explorer js.
Definition at line 56 of file class.ilExplorerBaseGUI.php.
Referenced by ilObjContentObject\getSupplyingExportFiles().
|
static |
Get local path of jsTree js.
Definition at line 64 of file class.ilExplorerBaseGUI.php.
Referenced by ilObjContentObject\getSupplyingExportFiles().
ilExplorerBaseGUI::getNodeAsync | ( | ) |
Get node asynchronously.
Definition at line 499 of file class.ilExplorerBaseGUI.php.
References $_GET, beforeRendering(), exit, getNodeId(), getNodeIdForDomNodeId(), getRootNode(), and renderChilds().
|
abstract |
Get content of a node.
mixed | $a_node | node array or object |
Referenced by createHTMLExportDirs(), and renderNode().
ilExplorerBaseGUI::getNodeHref | ( | $a_node | ) |
Get href for node.
mixed | $a_node | node object/array |
Definition at line 131 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
ilExplorerBaseGUI::getNodeIcon | ( | $a_node | ) |
Get node icon path.
mixed | $a_node | node object/array |
Definition at line 178 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
ilExplorerBaseGUI::getNodeIconAlt | ( | $a_node | ) |
Get node icon alt attribute.
mixed | $a_node | node object/array |
Definition at line 189 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
|
abstract |
Get id of a node.
mixed | $a_node | node array or object |
Referenced by createHTMLExportDirs(), getHTML(), getNodeAsync(), getNodeToggleOnClick(), getOnLoadCode(), getSelectOnClick(), listItemStart(), nodeHasVisibleChilds(), and renderNode().
ilExplorerBaseGUI::getNodeIdForDomNodeId | ( | $a_dom_node_id | ) |
Get node id for dom node id.
Definition at line 827 of file class.ilExplorerBaseGUI.php.
References getId().
Referenced by closeNode(), getNodeAsync(), ilObjStudyProgrammeTreeExplorerGUI\openCertainNode(), and openNode().
ilExplorerBaseGUI::getNodeOnClick | ( | $a_node | ) |
Get node onclick attribute.
mixed | $a_node | node object/array |
Definition at line 211 of file class.ilExplorerBaseGUI.php.
References getSelectOnClick().
Referenced by renderNode().
ilExplorerBaseGUI::getNodeTarget | ( | $a_node | ) |
Get node target (frame) attribute.
mixed | $a_node | node object/array |
Definition at line 200 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
|
finalprotected |
Get onclick attribute for node toggling.
Definition at line 361 of file class.ilExplorerBaseGUI.php.
References getDomNodeIdForNodeId(), and getNodeId().
Referenced by ilBookmarkBlockExplorerGUI\getNodeOnClick().
ilExplorerBaseGUI::getOfflineMode | ( | ) |
Get offline mode.
Definition at line 422 of file class.ilExplorerBaseGUI.php.
References $offline_mode.
Referenced by ilLMExplorerGUI\__construct(), ilLMTOCExplorerGUI\__construct(), ilLMExplorerGUI\beforeRendering(), ilLMTOCExplorerGUI\getNodeHref(), ilLMTOCExplorerGUI\getNodeIcon(), getOnLoadCode(), and ilLMTOCExplorerGUI\isNodeClickable().
ilExplorerBaseGUI::getOnLoadCode | ( | ) |
Get on load code.
Definition at line 532 of file class.ilExplorerBaseGUI.php.
References $config, $ilCtrl, $url, array, getAjax(), getContainerId(), getDomNodeIdForNodeId(), getJSTreePlugins(), getNodeId(), getOfflineMode(), and getRootNode().
Referenced by getHTML().
|
abstract |
Get root node.
Please note that the class does not make any requirements how nodes are represented (array or object)
Referenced by createHTMLExportDirs(), getHTML(), getNodeAsync(), and getOnLoadCode().
ilExplorerBaseGUI::getSecondaryHighlightedNodes | ( | ) |
Get secondary (background) highlighted nodes.
Definition at line 336 of file class.ilExplorerBaseGUI.php.
References $sec_highl_nodes.
|
finalprotected |
Get onclick attribute for selecting radio/checkbox.
Definition at line 373 of file class.ilExplorerBaseGUI.php.
References getDomNodeIdForNodeId(), and getNodeId().
Referenced by getNodeOnClick().
ilExplorerBaseGUI::getSkipRootNode | ( | ) |
Get skip root node.
Definition at line 296 of file class.ilExplorerBaseGUI.php.
References $skip_root_node.
Referenced by getHTML().
ilExplorerBaseGUI::handleCommand | ( | ) |
Handle explorer internal command.
Definition at line 436 of file class.ilExplorerBaseGUI.php.
References $_GET, $cmd, array, and getContainerId().
|
static |
Init JS.
Definition at line 612 of file class.ilExplorerBaseGUI.php.
References $tpl, and iljQueryUtil\initjQuery().
Referenced by ilInternalLinkGUI\getInitHTML().
ilExplorerBaseGUI::isEnableDnd | ( | ) |
Definition at line 904 of file class.ilExplorerBaseGUI.php.
References $enable_dnd.
Referenced by getJSTreePlugins().
ilExplorerBaseGUI::isNodeClickable | ( | $a_node | ) |
Is node clickable?
mixed | $a_node | node object/array |
Definition at line 248 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
ilExplorerBaseGUI::isNodeHighlighted | ( | $a_node | ) |
Is node highlighted?
mixed | $a_node | node object/array |
Definition at line 237 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
ilExplorerBaseGUI::isNodeOnclickEnabled | ( | ) |
Definition at line 891 of file class.ilExplorerBaseGUI.php.
References $nodeOnclickEnabled.
Referenced by renderNode().
|
protected |
Is node selectable?
mixed | $a_node | node object/array |
Definition at line 259 of file class.ilExplorerBaseGUI.php.
Referenced by renderNode().
ilExplorerBaseGUI::isNodeVisible | ( | $a_node | ) |
Is node visible?
mixed | $a_node | node object/array |
Definition at line 226 of file class.ilExplorerBaseGUI.php.
Referenced by getHTML(), nodeHasVisibleChilds(), and renderChilds().
ilExplorerBaseGUI::listEnd | ( | $tpl | ) |
List end.
Definition at line 882 of file class.ilExplorerBaseGUI.php.
References $tpl.
Referenced by getHTML(), and renderChilds().
ilExplorerBaseGUI::listItemEnd | ( | $tpl | ) |
List item end.
Definition at line 858 of file class.ilExplorerBaseGUI.php.
References $tpl.
Referenced by renderNode().
ilExplorerBaseGUI::listItemStart | ( | $tpl, | |
$a_node | |||
) |
List item start.
Definition at line 839 of file class.ilExplorerBaseGUI.php.
References $tpl, getAjax(), getDomNodeIdForNodeId(), getNodeId(), and nodeHasVisibleChilds().
Referenced by renderNode().
ilExplorerBaseGUI::listStart | ( | $tpl | ) |
List start.
Definition at line 870 of file class.ilExplorerBaseGUI.php.
References $tpl.
Referenced by getHTML(), and renderChilds().
ilExplorerBaseGUI::nodeHasVisibleChilds | ( | $a_node | ) |
Node has childs?
Please note that this standard method may not be optimal depending on what a derived class does in isNodeVisible.
Definition at line 145 of file class.ilExplorerBaseGUI.php.
References getChildsOfNode(), getNodeId(), and isNodeVisible().
Referenced by ilObjStudyProgrammeTreeExplorerGUI\listItemStart(), and listItemStart().
ilExplorerBaseGUI::openNode | ( | ) |
Open node.
Definition at line 466 of file class.ilExplorerBaseGUI.php.
References $_GET, $ilLog, exit, and getNodeIdForDomNodeId().
|
final |
Render childs.
Definition at line 783 of file class.ilExplorerBaseGUI.php.
References $tpl, getChildsOfNode(), isNodeVisible(), listEnd(), listStart(), renderNode(), and sortChilds().
Referenced by getNodeAsync(), and renderNode().
ilExplorerBaseGUI::renderNode | ( | $a_node, | |
$tpl | |||
) |
Render node.
Definition at line 695 of file class.ilExplorerBaseGUI.php.
References $target, $tpl, array, getAjax(), getNodeContent(), getNodeHref(), getNodeIcon(), getNodeIconAlt(), getNodeId(), getNodeOnClick(), getNodeTarget(), ilUtil\img(), isNodeClickable(), isNodeHighlighted(), isNodeOnclickEnabled(), isNodeSelectable(), listItemEnd(), listItemStart(), and renderChilds().
Referenced by getHTML(), and renderChilds().
ilExplorerBaseGUI::setAjax | ( | $a_val | ) |
Set ajax.
boolean | $a_val | ajax |
Definition at line 306 of file class.ilExplorerBaseGUI.php.
Referenced by ilMailExplorer\__construct(), ilSCORM2004EditorExplorerGUI\__construct(), ilSkillTreeExplorerGUI\__construct(), ilBookmarkExplorerGUI\__construct(), ilMediaPoolExplorerGUI\__construct(), ilVirtualSkillTreeExplorerGUI\__construct(), ilSkillTemplateTreeExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), ilRepositoryExplorerGUI\__construct(), ilLMExplorerGUI\__construct(), ilConditionSelector\__construct(), ilPoolSelectorGUI\__construct(), ilOrgUnitExplorerGUI\__construct(), ilMaterialExplorer\__construct(), ilRepositorySelectorExplorerGUI\__construct(), ilObjStudyProgrammeTreeExplorerGUI\__construct(), and ilLMExplorerGUI\beforeRendering().
ilExplorerBaseGUI::setEnableDnd | ( | $enable_dnd | ) |
Enable Drag & Drop functionality.
boolean | $enable_dnd |
Definition at line 912 of file class.ilExplorerBaseGUI.php.
References $enable_dnd.
Referenced by ilObjStudyProgrammeTreeExplorerGUI\__construct().
ilExplorerBaseGUI::setNodeOnclickEnabled | ( | $nodeOnclickEnabled | ) |
boolean | $nodeOnclickEnabled |
Definition at line 899 of file class.ilExplorerBaseGUI.php.
References $nodeOnclickEnabled.
ilExplorerBaseGUI::setNodeOpen | ( | $a_id | ) |
Set node to be opened (additional custom opened node, not standard expand behaviour)
Definition at line 347 of file class.ilExplorerBaseGUI.php.
Referenced by ilLMTableOfContentsExplorerGUI\__construct(), ilPublicSectionExplorerGUI\beforeRendering(), ilForumExplorerGUI\getHTML(), ilKSDocumentationExplorerGUI\openNodesRecursively(), and ilTreeExplorerGUI\setPathOpen().
ilExplorerBaseGUI::setNodeSelected | ( | $a_id | ) |
Set node to be opened (additional custom opened node, not standard expand behaviour)
Definition at line 399 of file class.ilExplorerBaseGUI.php.
Referenced by ilPublicSectionExplorerGUI\beforeRendering(), and ilSkillSelectorGUI\setSkillSelected().
ilExplorerBaseGUI::setOfflineMode | ( | $a_val | ) |
Set offline mode.
bool | $a_val | offline mode |
Definition at line 412 of file class.ilExplorerBaseGUI.php.
Referenced by ilKSDocumentationExplorerGUI\__construct().
ilExplorerBaseGUI::setSecondaryHighlightedNodes | ( | $a_val | ) |
Set secondary (background) highlighted nodes.
array | $a_val | array of node ids |
Definition at line 326 of file class.ilExplorerBaseGUI.php.
Referenced by ilLMTOCExplorerGUI\__construct().
ilExplorerBaseGUI::setSelectMode | ( | $a_postvar, | |
$a_multi = false |
|||
) |
Set select mode (to deactivate, pass an empty string as postvar)
string | $a_postvar | variable used for post, a "[]" is added automatically |
boolean | $a_multi | multi select (checkboxes) or not (radio) |
Definition at line 387 of file class.ilExplorerBaseGUI.php.
Referenced by ilForumMoveTopicsExplorer\__construct().
ilExplorerBaseGUI::setSkipRootNode | ( | $a_val | ) |
Set skip root node.
If set to false, the top node will not be displayed.
boolean | $a_val | skip root node |
Definition at line 286 of file class.ilExplorerBaseGUI.php.
Referenced by ilMailExplorer\__construct(), ilMediaPoolExplorerGUI\__construct(), ilSkillTreeExplorerGUI\__construct(), ilSCORM2004EditorExplorerGUI\__construct(), ilSkillSelectorGUI\__construct(), ilBookmarkExplorerGUI\__construct(), ilBookmarkBlockExplorerGUI\__construct(), ilVirtualSkillTreeExplorerGUI\__construct(), ilSkillTemplateTreeExplorerGUI\__construct(), ilRepositoryExplorerGUI\__construct(), ilAdministrationExplorerGUI\__construct(), ilPersonalSkillExplorerGUI\__construct(), ilLMExplorerGUI\__construct(), ilMaterialExplorer\__construct(), and ilRepositorySelectorExplorerGUI\__construct().
ilExplorerBaseGUI::sortChilds | ( | $a_childs, | |
$a_parent_node_id | |||
) |
Sort childs.
array | $a_childs | array of child nodes |
mixed | $a_parent_node | parent node |
Definition at line 167 of file class.ilExplorerBaseGUI.php.
Referenced by getHTML(), and renderChilds().
|
protected |
Definition at line 21 of file class.ilExplorerBaseGUI.php.
Referenced by getAjax().
|
protected |
Definition at line 22 of file class.ilExplorerBaseGUI.php.
|
protected |
Definition at line 27 of file class.ilExplorerBaseGUI.php.
Referenced by isEnableDnd(), and setEnableDnd().
|
staticprotected |
Definition at line 19 of file class.ilExplorerBaseGUI.php.
|
staticprotected |
Definition at line 18 of file class.ilExplorerBaseGUI.php.
|
private |
Definition at line 29 of file class.ilExplorerBaseGUI.php.
Referenced by isNodeOnclickEnabled(), and setNodeOnclickEnabled().
|
protected |
Definition at line 25 of file class.ilExplorerBaseGUI.php.
Referenced by getOfflineMode().
|
protected |
Definition at line 26 of file class.ilExplorerBaseGUI.php.
Referenced by getSecondaryHighlightedNodes().
|
protected |
Definition at line 24 of file class.ilExplorerBaseGUI.php.
Referenced by ilSkillSelectorGUI\getSelectedSkills().
|
protected |
Definition at line 23 of file class.ilExplorerBaseGUI.php.
|
protected |
Definition at line 20 of file class.ilExplorerBaseGUI.php.
Referenced by getSkipRootNode().