ILIAS
Release_4_0_x_branch Revision 61816
|
Content Object Parser. More...
Public Member Functions | |
ilContObjParser (&$a_content_object, $a_xml_file, $a_subdir) | |
Constructor. | |
setHandlers ($a_xml_parser) | |
set event handlers | |
startParsing () | |
start parser | |
storeTree () | |
insert StructureObjects and PageObjects into tree | |
processPagesToParse () | |
parse pages that contain files, mobs and/or internal links | |
copyMobFiles () | |
copy multimedia object files from import zip file to mob directory | |
copyFileItems () | |
copy files of file items | |
setQuestionMapping ($a_map) | |
set question import ident to pool/test question id mapping | |
beginElement ($a_name) | |
endElement ($a_name) | |
getCurrentElement () | |
getOpenCount ($a_name) | |
buildTag ($type, $name, $attr="") | |
generate a tag with given name and attributes | |
handlerBeginTag ($a_xml_parser, $a_name, $a_attribs) | |
handler for begin of element | |
processMeta () | |
check whether meta data should be processed | |
handlerEndTag ($a_xml_parser, $a_name) | |
handler for end of element | |
handlerCharacterData ($a_xml_parser, $a_data) | |
handler for character data | |
emptyMediaMetaCache (&$a_xml_parser) | |
send all cached tags to the meta data parser and clear the cache | |
Public Member Functions inherited from ilMDSaxParser | |
ilMDSaxParser ($a_xml_file= '') | |
Constructor. | |
enableMDParsing ($a_status) | |
getMDParsingStatus () | |
setMDObject (&$md) | |
& | getMDObject () |
inMetaData () | |
__getCharacterData () | |
__pushParent (&$md_obj) | |
& | __popParent () |
& | __getParent () |
ilMDSaxParser ($a_xml_file= '') | |
Constructor. | |
setMDObject (&$md) | |
inMetaData () | |
__getCharacterData () | |
__pushParent (&$md_obj) | |
& | __popParent () |
& | __getParent () |
Public Member Functions inherited from ilSaxParser | |
ilSaxParser ($a_xml_file= '', $throwException=false) | |
Constructor setup ILIAS global object public. | |
setXMLContent ($a_xml_content) | |
getXMLContent () | |
getInputType () | |
createParser () | |
create parser | |
setOptions ($a_xml_parser) | |
set parser options | |
openXMLFile () | |
open xml file | |
parse ($a_xml_parser, $a_fp=null) | |
parse xml file | |
freeParser ($a_xml_parser) | |
free xml parser handle | |
setThrowException ($throwException) | |
set error handling | |
Public Member Functions inherited from PEAR | |
PEAR ($error_class=null) | |
Constructor. | |
_PEAR () | |
Destructor (the emulated type of...). | |
& | getStaticProperty ($class, $var) |
If you have a class that's mostly/entirely static, and you need static properties, you can use this method to simulate them. | |
registerShutdownFunc ($func, $args=array()) | |
Use this function to register a shutdown method for static classes. | |
isError ($data, $code=null) | |
Tell whether a value is a PEAR error. | |
setErrorHandling ($mode=null, $options=null) | |
Sets how errors generated by this object should be handled. | |
expectError ($code= '*') | |
This method is used to tell which errors you expect to get. | |
popExpect () | |
This method pops one element off the expected error codes stack. | |
_checkDelExpect ($error_code) | |
This method checks unsets an error code if available. | |
delExpect ($error_code) | |
This method deletes all occurences of the specified element from the expected error codes stack. | |
& | raiseError ($message=null, $code=null, $mode=null, $options=null, $userinfo=null, $error_class=null, $skipmsg=false) |
This method is a wrapper that returns an instance of the configured error class with this object's default error handling applied. | |
& | throwError ($message=null, $code=null, $userinfo=null) |
Simpler form of raiseError with fewer options. | |
staticPushErrorHandling ($mode, $options=null) | |
staticPopErrorHandling () | |
pushErrorHandling ($mode, $options=null) | |
Push a new error handler on top of the error handler options stack. | |
popErrorHandling () | |
Pop the last error handler used. | |
loadExtension ($ext) | |
OS independant PHP extension load. |
Additional Inherited Members | |
Protected Member Functions inherited from ilSaxParser | |
handleError ($message, $code) | |
use given error handler to handle error message or internal ilias error message handle |
Definition at line 32 of file class.ilContObjParser.php.
ilContObjParser::beginElement | ( | $a_name | ) |
Definition at line 385 of file class.ilContObjParser.php.
Referenced by handlerBeginTag().
ilContObjParser::buildTag | ( | $type, | |
$name, | |||
$attr = "" |
|||
) |
generate a tag with given name and attributes
string | "start" | "end" for starting or ending tag |
string | element/tag name |
array | array of attributes |
Definition at line 442 of file class.ilContObjParser.php.
Referenced by handlerBeginTag(), and handlerEndTag().
ilContObjParser::copyFileItems | ( | ) |
copy files of file items
Definition at line 340 of file class.ilContObjParser.php.
References $test, ilUtil\makeDir(), and ilUtil\rCopy().
Referenced by startParsing().
ilContObjParser::copyMobFiles | ( | ) |
copy multimedia object files from import zip file to mob directory
Definition at line 296 of file class.ilContObjParser.php.
References ilUtil\getWebspaceDir(), ilUtil\makeDir(), and ilUtil\rCopy().
Referenced by startParsing().
ilContObjParser::emptyMediaMetaCache | ( | & | $a_xml_parser | ) |
send all cached tags to the meta data parser and clear the cache
Definition at line 1540 of file class.ilContObjParser.php.
References handlerBeginTag(), handlerCharacterData(), and handlerEndTag().
Referenced by handlerBeginTag().
ilContObjParser::endElement | ( | $a_name | ) |
Definition at line 403 of file class.ilContObjParser.php.
Referenced by handlerEndTag().
ilContObjParser::getCurrentElement | ( | ) |
Definition at line 412 of file class.ilContObjParser.php.
Referenced by handlerCharacterData().
ilContObjParser::getOpenCount | ( | $a_name | ) |
Definition at line 422 of file class.ilContObjParser.php.
ilContObjParser::handlerBeginTag | ( | $a_xml_parser, | |
$a_name, | |||
$a_attribs | |||
) |
handler for begin of element
resource | $a_xml_parser | xml parser |
string | $a_name | element name |
array | $a_attribs | element attributes array |
Meta Data Section /////////////////////////////////////////////
Reimplemented from ilMDSaxParser.
Definition at line 469 of file class.ilContObjParser.php.
References $_GET, $content_object, $glossary_object, $lm_page_object, beginElement(), buildTag(), emptyMediaMetaCache(), ilMDSaxParser\enableMDParsing(), IL_EXT_LINK, IL_INT_LINK, processMeta(), and ilUtil\yn2tf().
Referenced by emptyMediaMetaCache().
ilContObjParser::handlerCharacterData | ( | $a_xml_parser, | |
$a_data | |||
) |
handler for character data
resource | $a_xml_parser | xml parser |
string | $a_data | character data |
Reimplemented from ilMDSaxParser.
Definition at line 1462 of file class.ilContObjParser.php.
References getCurrentElement(), and processMeta().
Referenced by emptyMediaMetaCache().
ilContObjParser::handlerEndTag | ( | $a_xml_parser, | |
$a_name | |||
) |
handler for end of element
resource | $a_xml_parser | xml parser |
string | $a_name | element name |
Reimplemented from ilMDSaxParser.
Definition at line 959 of file class.ilContObjParser.php.
References $cnt, $dir, $file, $in_glossary, $in_media_object, ilLMObject\_writeImportId(), buildTag(), ilMDSaxParser\enableMDParsing(), endElement(), IL_MODE_ALIAS, and processMeta().
Referenced by emptyMediaMetaCache().
ilContObjParser::ilContObjParser | ( | & | $a_content_object, |
$a_xml_file, | |||
$a_subdir | |||
) |
Constructor.
object | $a_content_object | must be of type ilObjContentObject ilObjTest or ilObjQuestionPool |
string | $a_xml_file | xml file |
string | $a_subdir | subdirectory in import directory public |
Definition at line 84 of file class.ilContObjParser.php.
References $lng, $tree, ilMDSaxParser\ilMDSaxParser(), and ilTree\setTreeTablePK().
ilContObjParser::processMeta | ( | ) |
check whether meta data should be processed
Definition at line 938 of file class.ilContObjParser.php.
Referenced by handlerBeginTag(), handlerCharacterData(), and handlerEndTag().
ilContObjParser::processPagesToParse | ( | ) |
parse pages that contain files, mobs and/or internal links
Definition at line 201 of file class.ilContObjParser.php.
References $key, $page_object, $target_id, $target_type, ilInternalLink\_getSourcesOfTarget(), SurveyQuestion\_resolveIntLinks(), assQuestion\_resolveIntLinks(), and ilMediaItem\_resolveMapAreaLinks().
Referenced by startParsing().
ilContObjParser::setHandlers | ( | $a_xml_parser | ) |
set event handlers
resource | reference to the xml parser private |
Reimplemented from ilMDSaxParser.
Definition at line 126 of file class.ilContObjParser.php.
ilContObjParser::setQuestionMapping | ( | $a_map | ) |
set question import ident to pool/test question id mapping
Definition at line 376 of file class.ilContObjParser.php.
ilContObjParser::startParsing | ( | ) |
start parser
Reimplemented from ilSaxParser.
Definition at line 137 of file class.ilContObjParser.php.
References copyFileItems(), copyMobFiles(), processPagesToParse(), and storeTree().
ilContObjParser::storeTree | ( | ) |
insert StructureObjects and PageObjects into tree
Definition at line 155 of file class.ilContObjParser.php.
References $ilLog.
Referenced by startParsing().
ilContObjParser::$bib_item |
Definition at line 67 of file class.ilContObjParser.php.
ilContObjParser::$cnt |
Definition at line 36 of file class.ilContObjParser.php.
Referenced by handlerEndTag().
ilContObjParser::$container |
Definition at line 50 of file class.ilContObjParser.php.
ilContObjParser::$content_object |
Definition at line 57 of file class.ilContObjParser.php.
Referenced by handlerBeginTag().
ilContObjParser::$current_element |
Definition at line 37 of file class.ilContObjParser.php.
ilContObjParser::$current_object |
Definition at line 43 of file class.ilContObjParser.php.
ilContObjParser::$file_item |
Definition at line 59 of file class.ilContObjParser.php.
ilContObjParser::$file_item_mapping |
Definition at line 63 of file class.ilContObjParser.php.
ilContObjParser::$glossary_object |
Definition at line 58 of file class.ilContObjParser.php.
Referenced by handlerBeginTag().
ilContObjParser::$in_bib_item |
Definition at line 69 of file class.ilContObjParser.php.
ilContObjParser::$in_file_item |
Definition at line 54 of file class.ilContObjParser.php.
ilContObjParser::$in_glossary |
Definition at line 55 of file class.ilContObjParser.php.
Referenced by handlerEndTag().
ilContObjParser::$in_map_area |
Definition at line 56 of file class.ilContObjParser.php.
ilContObjParser::$in_media_object |
Definition at line 53 of file class.ilContObjParser.php.
Referenced by handlerEndTag().
ilContObjParser::$in_meta_data |
Definition at line 52 of file class.ilContObjParser.php.
ilContObjParser::$in_meta_meta_data = false |
Definition at line 73 of file class.ilContObjParser.php.
ilContObjParser::$in_page_object |
Definition at line 51 of file class.ilContObjParser.php.
ilContObjParser::$keyword_language |
Definition at line 60 of file class.ilContObjParser.php.
ilContObjParser::$learning_module |
Definition at line 38 of file class.ilContObjParser.php.
ilContObjParser::$link_targets |
Definition at line 70 of file class.ilContObjParser.php.
ilContObjParser::$lm_page_object |
Definition at line 40 of file class.ilContObjParser.php.
Referenced by handlerBeginTag().
ilContObjParser::$lm_tree |
Definition at line 47 of file class.ilContObjParser.php.
ilContObjParser::$lng |
Definition at line 34 of file class.ilContObjParser.php.
Referenced by ilContObjParser().
ilContObjParser::$loc_type |
Definition at line 66 of file class.ilContObjParser.php.
ilContObjParser::$map_area |
Definition at line 68 of file class.ilContObjParser.php.
ilContObjParser::$media_item |
Definition at line 65 of file class.ilContObjParser.php.
ilContObjParser::$media_object |
Definition at line 42 of file class.ilContObjParser.php.
ilContObjParser::$meta_data |
Definition at line 44 of file class.ilContObjParser.php.
ilContObjParser::$metadata_parsing_disabled |
Definition at line 72 of file class.ilContObjParser.php.
ilContObjParser::$mob_mapping |
Definition at line 62 of file class.ilContObjParser.php.
ilContObjParser::$page_object |
Definition at line 39 of file class.ilContObjParser.php.
Referenced by processPagesToParse().
ilContObjParser::$pages_to_parse |
Definition at line 61 of file class.ilContObjParser.php.
ilContObjParser::$paragraph |
Definition at line 45 of file class.ilContObjParser.php.
ilContObjParser::$pg_into_tree |
Definition at line 48 of file class.ilContObjParser.php.
ilContObjParser::$qst_mapping |
Definition at line 71 of file class.ilContObjParser.php.
ilContObjParser::$st_into_tree |
Definition at line 49 of file class.ilContObjParser.php.
ilContObjParser::$structure_objects |
Definition at line 41 of file class.ilContObjParser.php.
ilContObjParser::$subdir |
Definition at line 64 of file class.ilContObjParser.php.
ilContObjParser::$table |
Definition at line 46 of file class.ilContObjParser.php.
ilContObjParser::$tree |
Definition at line 35 of file class.ilContObjParser.php.
Referenced by ilContObjParser().