Moodle PHP Documentation 4.2
Moodle 4.2.8 (Build: 20240610) (2d41ac46f45)
moodlecore

Classes

class  activity_backup_setting
 Abstract class containing all the common stuff for activity backup settings. More...
 
interface  annotable
 Interface to apply to all the classes we want to be annotable in the backup/restore process. More...
 
class  auth_plugin_base
 Abstract authentication plugin. More...
 
class  backup
 Abstract class defining common stuff to be used by the backup stuff. More...
 
class  backup_anonymizer_helper
 Helper class for anonymization of data. More...
 
class  backup_array_iterator
 Implementation of iterator interface to work with common arrays. More...
 
class  backup_attribute
 Instantiable class representing one attribute atom (name/value) piece of information on backup. More...
 
class  backup_check
 Non instantiable helper class providing different backup checks. More...
 
class  backup_controller_dbops
 Non instantiable helper class providing DB support to the @backup_controller. More...
 
class  backup_dbops
 Base abstract class for all the helper classes providing DB operations. More...
 
class  backup_dbops_exception
 
class  backup_exception
 
class  backup_execution_step
 Abstract class defining the needed stuff to execute code on backup. More...
 
class  backup_factory
 Non instantiable factory class providing different backup object instances. More...
 
class  backup_file_manager
 Collection of helper functions to handle files. More...
 
class  backup_files_edit_form
 
class  backup_final_element
 Instantiable class representing one final element atom (name/value/parent) piece of information on backup. More...
 
class  backup_general_helper
 Non instantiable helper class providing general helper methods for backup/restore. More...
 
class  backup_helper
 Base abstract class for all the helper classes providing various operations. More...
 
class  backup_helper_exception
 
class  backup_nested_element
 Instantiable class representing one nestable element (non final) piece of information on backup. More...
 
class  backup_null_iterator
 Implementation of iterator interface to work without information. More...
 
class  backup_optigroup
 Instantiable class representing one optigroup element for conditional branching. More...
 
class  backup_optigroup_element
 Instantiable class representing one optigroup element for conditional branching. More...
 
class  backup_plan
 Implementable class defining the needed stuf for one backup plan. More...
 
class  backup_plan_dbops
 Non instantiable helper class providing DB support to the @backup_plan class. More...
 
class  backup_plan_exception
 
class  backup_processor_exception
 backup_processor exception to control all the errors while working with backup_processors More...
 
class  backup_qtype_calculated_plugin
 Provides the information to backup calculated questions. More...
 
class  backup_qtype_calculatedmulti_plugin
 Provides the information to backup calculatedmulti questions. More...
 
class  backup_qtype_calculatedsimple_plugin
 Provides the information to backup calculatedsimple questions. More...
 
class  backup_qtype_essay_plugin
 Provides the information to backup essay questions. More...
 
class  backup_qtype_match_plugin
 Provides the information to backup match questions. More...
 
class  backup_qtype_multianswer_plugin
 Provides the information to backup multianswer questions. More...
 
class  backup_qtype_multichoice_plugin
 Provides the information to backup multichoice questions. More...
 
class  backup_qtype_numerical_plugin
 Provides the information to backup numerical questions. More...
 
class  backup_qtype_randomsamatch_plugin
 Provides the information to backup randomsamatch questions. More...
 
class  backup_qtype_shortanswer_plugin
 Provides the information to backup shortanswer questions. More...
 
class  backup_qtype_truefalse_plugin
 Provides the information to backup truefalse questions. More...
 
class  backup_question_dbops
 Non instantiable helper class providing DB support to the questions backup stuff. More...
 
class  backup_step
 Abstract class defining the needed stuf for one backup step. More...
 
class  backup_step_exception
 
class  backup_structure_dbops
 Non instantiable helper class providing DB support to the backup_structure stuff. More...
 
class  backup_structure_processor
 Instantiable class defining the process of backup structures. More...
 
class  backup_structure_step
 Abstract class defining the needed stuff to backup one @backup_structure. More...
 
class  backup_task
 Abstract class defining the needed stuf for one backup task (a collection of steps) More...
 
class  backup_task_exception
 
class  base_atom
 Abstract class representing one atom (name/value) piece of information. More...
 
class  base_atom_content_exception
 base_atom exception to control all the errors while setting the values More...
 
class  base_atom_exception
 base_atom abstract exception class More...
 
class  base_atom_struct_exception
 base_atom exception to control all the errors while creating the objects More...
 
class  base_attribute
 Abstract class representing one attribute atom (name/value) piece of information. More...
 
class  base_element_attribute_exception
 base_element exception to control all the errors related with attributes handling More...
 
class  base_element_parent_exception
 base_element exception to control all the errors related with parents handling More...
 
class  base_element_struct_exception
 base_element exception to control all the errors while building the nested tree More...
 
class  base_final_element
 Abstract class representing one final element atom (name/value/parent) piece of information. More...
 
class  base_logger
 Base abstract class for all the loggers to be used in backup/restore. More...
 
class  base_logger_exception
 
class  base_nested_element
 Abstract class representing one nestable element (non final) piece of information. More...
 
class  base_optigroup
 Abstract class representing one optigroup for conditional branching. More...
 
class  base_optigroup_exception
 base_optigroup_exception to control all the errors while building the optigroups More...
 
class  base_plan
 Abstract class defining the basis for one execution (backup/restore) plan. More...
 
class  base_plan_exception
 
class  base_processor
 Abstract class representing the required implementation for classes able to process structure classes. More...
 
class  base_processor_exception
 base_processor abstract exception class More...
 
class  base_setting
 This abstract class defines one basic setting. More...
 
class  base_setting_exception
 
class  base_step
 Abstract class defining the basis for one execution (backup/restore) step. More...
 
class  base_step_exception
 
class  base_task
 Abstract class defining the basis for one execution (backup/restore) task. More...
 
class  base_task_exception
 
class  blog_edit_external_form
 
class  blog_entry
 Blog_entry class. More...
 
class  blog_entry_attachment
 Renderable class to represent an entry attachment. More...
 
class  blog_filter
 Abstract class for blog_filter objects. More...
 
class  blog_filter_context
 This filter defines the context level of the blog entries being searched: site, course, module. More...
 
class  blog_filter_entry
 This filter defines a specific blog entry id. More...
 
class  blog_filter_search
 Filter used to perform full-text search on an entry's subject, summary and content. More...
 
class  blog_filter_since
 This filter restricts the results to a time interval in seconds up to time() More...
 
class  blog_filter_tag
 This filter defines a tag by which blog entries should be searched. More...
 
class  blog_filter_user
 This filter defines the user level of the blog entries being searched: a userid or a groupid. More...
 
class  blog_listing
 Abstract Blog_Listing class: used to gather blog entries and output them as listings. More...
 
class  blog_preferences_form
 
class  calc_formula
 This class abstracts evaluation of spreadsheet formulas. More...
 
class  cc112moodle
 
class  cc11_basiclti
 
class  cc11_forum
 
class  cc11_lti
 
class  cc11_quiz
 
class  cc11_resource
 
class  cc2moodle
 
class  cc_forum
 
class  cc_label
 
class  cc_quiz
 
class  cc_resource
 Resource Class. More...
 
interface  checksumable
 Interface to apply to all the classes we want to calculate their checksum. More...
 
class  component_installer
 This class is used to check, download and install items from download.moodle.org to the moodledata directory. More...
 
class  core_course_renderer
 The core course renderer. More...
 
class  core_question_renderer
 This renderer controls the overall output of questions. More...
 
class  course_backup_setting
 Abstract class containing all the common stuff for course backup settings. More...
 
class  course_restore_form
 
class  coursecat_helper
 Class storing display options and functions to help display course category and/or courses lists. More...
 
class  csv_import_reader
 Utitily class for importing of CSV files. More...
 
class  data_loading_method_test_base
 Helper base class for tests that need to simulate records loaded from the database. More...
 
class  database_logger
 Logger implementation that sends messages to database. More...
 
class  dummy_question_engine_assumption_logger
 Subclass of question_engine_assumption_logger that does nothing, for testing. More...
 
class  entities
 
class  entities11
 
class  environment_results
 Helper Class to return results to caller. More...
 
class  error_log_logger
 Logger implementation that sends messages to error_log() More...
 
interface  executable
 Interface to apply to all the classes we want to be executable (plan/part/task) More...
 
class  file_logger
 Logger implementation that sends indented messages (depth option) to one file. More...
 
class  file_xml_output
 This class implements one @xml_output able to send contents to one OS file. More...
 
class  findpaths_parser_processor
 Find paths progressive_parser_processor that will search for all the paths present in the chunks being returned. More...
 
class  flexible_table
 
class  graph
 
class  grouped_parser_processor
 Abstract xml parser processor able to group chunks as configured and dispatch them to other arbitrary methods. More...
 
class  key_form
 
class  Lexer
 Accepts text and breaks it into tokens. More...
 
class  list_item
 
interface  loggable
 Interface to apply to all the classes we want to be able to write to logs. More...
 
class  memory_xml_output
 This class implements one @xml_output able to store and return output in memory. More...
 
class  moodle_list
 Clues to reading this code: More...
 
class  MoodleExcelFormat
 Define and operate over one Format. More...
 
class  MoodleExcelWorkbook
 Define and operate over one Moodle Workbook. More...
 
class  my_syspage_block_manager
 
class  null_parser_processor
 Null progressive_parser_processor that won't process chunks at all. More...
 
class  oauth2_client
 OAuth 2.0 Client for using web access tokens. More...
 
class  oauth_helper
 
class  output_controller
 This class decides, based in environment/backup controller settings about the best way to send information to output, independently of the process and the loggers. More...
 
class  output_indented_logger
 Logger implementation that sends indented messages (depth option) to output. More...
 
class  output_text_logger
 Logger implementation that sends text messages to output. More...
 
class  pdf
 Wrapper class that extends TCPDF (lib/tcpdf/tcpdf.php). More...
 
class  portfolio_plugin_mahara
 
interface  processable
 Interface to apply to all the classes we want to be processable by one @base_processor. More...
 
class  progressive_parser
 Class implementing one SAX progressive push parser. More...
 
class  progressive_parser_exception
 
class  progressive_parser_processor
 This abstract class implements one progressive_parser_processor. More...
 
class  qbehaviour_adaptive_converter
 
class  qbehaviour_adaptivenopenalty_converter
 
class  qbehaviour_deferredfeedback_converter
 
class  qbehaviour_informationitem_converter
 
class  qbehaviour_manualgraded_converter
 
class  qbehaviour_renderer
 Renderer base class for question behaviours. More...
 
class  qbehaviour_walkthrough_test_base
 Helper base class for question walk-through tests. More...
 
class  qformat_based_on_xml
 Since the lesson module tries to re-use the question bank import classes in a crazy way, this is necessary to stop things breaking. More...
 
class  qformat_default
 Base class for question import and export formats. More...
 
class  qtype_renderer
 Renderer base classes for question types. More...
 
class  qtype_with_combined_feedback_renderer
 Renderer base classes for question types. More...
 
class  question_answer
 Class to represent a question answer, loaded from the question_answers table in the database. More...
 
class  question_attempt
 Tracks an attempt at one particular question in a question_usage_by_activity. More...
 
class  question_attempt_iterator
 A class abstracting access to the question_usage_by_activity::$questionattempts array. More...
 
class  question_attempt_pending_step
 A subclass of {. More...
 
class  question_attempt_reverse_step_iterator
 A variant of question_attempt_step_iterator that iterates through the steps in reverse order. More...
 
class  question_attempt_step
 Stores one step in a {. More...
 
class  question_attempt_step_iterator
 A class abstracting access to the question_attempt::$states array. More...
 
class  question_attempt_step_read_only
 A subclass of {. More...
 
class  question_attempt_step_subquestion_adapter
 This is an adapter class that wraps a {. More...
 
class  question_attempt_steps_with_submitted_response_iterator
 A variant of question_attempt_step_iterator that iterates through the steps with submitted tries. More...
 
class  question_attempt_upgrader_test_base
 Base class for tests that thest the upgrade of one particular attempt and one question. More...
 
class  question_attempt_with_restricted_history
 This subclass of question_attempt pretends that only part of the step history exists. More...
 
interface  question_automatically_gradable
 Interface that a question_definition must implement to be usable by the various automatic grading behaviours. More...
 
interface  question_automatically_gradable_with_countback
 Interface that a question_definition must implement to be usable by the interactivecountback behaviour. More...
 
class  question_bank
 This static class provides access to the other question bank. More...
 
class  question_behaviour
 The base class for question behaviours. More...
 
class  question_behaviour_attempt_updater
 Base class for managing the upgrade of a question using a particular behaviour. More...
 
class  question_behaviour_with_multiple_tries
 
class  question_behaviour_with_save
 A subclass of question_behaviour that implements a save action that is suitable for most questions that implement the question_manually_gradable interface. More...
 
class  question_cbm
 This helper class contains the constants and methods required for manipulating scores for certainty based marking. More...
 
class  question_check_specified_fields_expectation
 
class  question_classified_response
 This class is used in the return value from question_manually_gradable::classify_response(). More...
 
class  question_contains_select_expectation
 
class  question_contains_tag_with_attribute
 
class  question_contains_tag_with_attributes
 
class  question_contains_tag_with_contents
 
class  question_definition
 The definition of a question of a particular type. More...
 
class  question_deleted_question_attempt_updater
 
class  question_display_options
 This class contains all the options that controls how a question is displayed. More...
 
class  question_does_not_contain_tag_with_attributes
 
class  question_edit_form
 Form definition base class. More...
 
class  question_engine
 This static class provides access to the other question engine classes. More...
 
class  question_engine_assumption_logger
 This class serves to record all the assumptions that the code had to make during the question engine database database upgrade, to facilitate reviewing them. More...
 
class  question_engine_attempt_upgrader
 This class manages upgrading all the question attempts from the old database structure to the new question engine. More...
 
class  question_engine_upgrade_question_loader
 This class deals with loading (and caching) question definitions during the question engine upgrade. More...
 
class  question_finder
 Class for loading questions according to various criteria. More...
 
class  question_first_matching_answer_grading_strategy
 This grading strategy is used by question types like shortanswer an numerical. More...
 
class  question_flags
 Contains the logic for handling question flags. More...
 
class  question_graded_automatically
 This class represents a question that can be graded automatically. More...
 
class  question_graded_automatically_with_countback
 This class represents a question that can be graded automatically with countback grading in interactive mode. More...
 
class  question_graded_by_strategy
 This class represents a question that can be graded automatically by using a question_grading_strategy. More...
 
interface  question_grading_strategy
 This question_grading_strategy interface. More...
 
class  question_hint
 Class to represent a hint associated with a question. More...
 
class  question_hint_with_parts
 An extension of question_hint for questions like match and multiple choice with multile answers, where there are options for whether to show the number of parts right at each stage, and to reset the wrong parts. More...
 
class  question_information_item
 This class represents a 'question' that actually does not allow the student to respond, like the description 'question' type. More...
 
interface  question_manually_gradable
 Interface that a question_definition must implement to be usable by the manual graded behaviour. More...
 
class  question_no_pattern_expectation
 
class  question_null_step
 A null {. More...
 
class  question_out_of_sequence_exception
 Exception thrown when the system detects that a student has done something out-of-order to a question. More...
 
class  question_pattern_expectation
 
class  question_possible_response
 This class is used in the return value from question_type::get_possible_responses(). More...
 
class  question_qtype_attempt_updater
 Base class for the classes that convert the question-type specific bits of the attempt data. More...
 
interface  question_response_answer_comparer
 This interface defines the methods that a question_definition must implement if it is to be graded by the question_first_matching_answer_grading_strategy. More...
 
class  question_state
 An enumeration representing the states a question can be in after a question_attempt_step. More...
 
class  question_state_complete
 
class  question_state_finished
 
class  question_state_gaveup
 
class  question_state_graded
 
class  question_state_gradedpartial
 
class  question_state_gradedright
 
class  question_state_gradedwrong
 
class  question_state_invalid
 
class  question_state_manfinished
 
class  question_state_mangaveup
 
class  question_state_mangrpartial
 
class  question_state_mangrright
 
class  question_state_mangrwrong
 
class  question_state_manuallygraded
 
class  question_state_needsgrading
 
class  question_state_notstarted
 #+ Specific question_state subclasses. More...
 
class  question_state_todo
 
class  question_state_unprocessed
 
class  question_test_helper
 Base class for question type test helpers. More...
 
class  question_test_recordset
 Simple class that implements the moodle_recordset API based on an array of test data. More...
 
class  question_testcase
 
class  question_type
 This is the base class for Moodle question types. More...
 
class  question_usage_by_activity
 This class keeps track of a group of questions that are being attempted, and which state, and so on, each one is currently in. More...
 
class  question_usage_null_observer
 Null implmentation of the question_usage_watcher interface. More...
 
interface  question_usage_observer
 Interface for things that want to be notified of signficant changes to a question_usage_by_activity. More...
 
class  question_utils
 Useful functions for writing question types and behaviours. More...
 
class  question_variant_forced_choices_selection_strategy
 A question_variant_selection_strategy designed ONLY for testing. More...
 
class  question_variant_pseudorandom_no_repeats_strategy
 A question_variant_selection_strategy that is effectively random for the first attempt, and then after that cycles through the available variants so that the students will not get a repeated variant until they have seen them all. More...
 
class  question_variant_random_strategy
 A question_variant_selection_strategy that is completely random. More...
 
interface  question_variant_selection_strategy
 The interface for strategies for controlling which variant of each question is used. More...
 
class  question_with_responses
 This class represents a real question. More...
 
class  question_wizard_form
 
class  restore_check
 Non instantiable helper class providing different restore checks. More...
 
class  restore_controller
 Class implementing the controller of any restore process. More...
 
class  restore_controller_dbops
 Non instantiable helper class providing DB support to the @restore_controller. More...
 
class  restore_controller_exception
 
class  restore_dbops
 Base abstract class for all the helper classes providing DB operations. More...
 
class  restore_dbops_exception
 
class  restore_decode_content
 Helper class in charge of providing the contents to be processed by restore_decode_rules. More...
 
class  restore_decode_content_exception
 
class  restore_decode_processor
 Helper class that will perform all the necessary decoding tasks on restore. More...
 
class  restore_decode_processor_exception
 
class  restore_decode_rule
 Helper class used to decode links back to their original form. More...
 
class  restore_decode_rule_exception
 
class  restore_execution_step
 Abstract class defining the needed stuff to execute code on restore. More...
 
class  restore_factory
 Non instantiable factory class providing different restore object instances. More...
 
class  restore_inforef_parser_processor
 helper implementation of grouped_parser_processor that will load all the contents of one inforef.xml file to the backup_ids table More...
 
class  restore_log_rule
 Helper class used to restore logs, converting all the information as needed. More...
 
class  restore_logs_processor
 This class is one varying singleton that, for all the logs corresponding to one task, is in charge of storing all its restore_log_rule rules, dispatching to the correct one and insert/log the resulting information. More...
 
class  restore_logs_processor_exception
 
class  restore_moodlexml_parser_processor
 helper implementation of grouped_parser_processor that will return all the information present in the moodle_backup.xml file accumulating it for later generation of controller->info More...
 
class  restore_path_element
 Class representing one path to be restored from XML file. More...
 
class  restore_path_element_exception
 restore_path_element exception class More...
 
class  restore_plan
 Implementable class defining the needed stuf for one restore plan. More...
 
class  restore_plan_exception
 
class  restore_prechecks_helper
 Non instantiable helper class providing support for restore prechecks. More...
 
class  restore_prechecks_helper_exception
 
class  restore_qtype_calculated_plugin
 restore plugin class that provides the necessary information needed to restore one calculated qtype plugin More...
 
class  restore_qtype_calculatedmulti_plugin
 restore plugin class that provides the necessary information needed to restore one calculatedmulti qtype plugin. More...
 
class  restore_qtype_calculatedsimple_plugin
 restore plugin class that provides the necessary information needed to restore one calculatedsimple qtype plugin More...
 
class  restore_qtype_essay_plugin
 restore plugin class that provides the necessary information needed to restore one essay qtype plugin More...
 
class  restore_qtype_match_plugin
 Restore plugin class that provides the necessary information needed to restore one match qtype plugin. More...
 
class  restore_qtype_multianswer_plugin
 restore plugin class that provides the necessary information needed to restore one multianswer qtype plugin More...
 
class  restore_qtype_multichoice_plugin
 restore plugin class that provides the necessary information needed to restore one multichoice qtype plugin More...
 
class  restore_qtype_numerical_plugin
 restore plugin class that provides the necessary information needed to restore one numerical qtype plugin More...
 
class  restore_qtype_random_plugin
 restore plugin class that provides the necessary information needed to restore one random qtype plugin More...
 
class  restore_qtype_randomsamatch_plugin
 restore plugin class that provides the necessary information needed to restore one randomsamatch qtype plugin More...
 
class  restore_qtype_shortanswer_plugin
 Restore plugin class that provides the necessary information needed to restore one shortanswer qtype plugin. More...
 
class  restore_qtype_truefalse_plugin
 restore plugin class that provides the necessary information needed to restore one truefalse qtype plugin More...
 
class  restore_questions_parser_processor
 helper implementation of grouped_parser_processor that will load all the categories and questions (header info only) from the questions.xml file to the backup_ids table storing the whole structure there for later processing. More...
 
class  restore_roles_parser_processor
 helper implementation of grouped_parser_processor that will load all the contents of one roles.xml (roles description) file to the backup_ids table storing the whole structure there for later processing. More...
 
class  restore_step
 Abstract class defining the needed stuf for one restore step. More...
 
class  restore_step_exception
 
class  restore_structure_parser_processor
 helper implementation of grouped_parser_processor that will support the process of all the moodle2 backup files, with complete specs about what to load (grouped or no), dispatching to corresponding methods and basic decoding of contents (NULLs and legacy file.php uses) More...
 
class  restore_structure_step
 Abstract class defining the needed stuff to restore one xml file. More...
 
class  restore_task
 Abstract class defining the needed stuf for one restore task (a collection of steps) More...
 
class  restore_task_exception
 
class  restore_users_parser_processor
 helper implementation of grouped_parser_processor that will load all the contents of one users.xml file to the backup_ids table storing the whole structure there for later processing. More...
 
class  search_lexer
 This class does the heavy lifting of lexing the search string into tokens. More...
 
class  search_parser
 This class takes care of sticking the proper token type/value pairs into the parsed token array. More...
 
class  search_token
 Class to hold token/value pairs after they're parsed. More...
 
class  section_backup_setting
 Abstract class containing all the common stuff for section backup settings. More...
 
class  selective_exact_parser_processor
 Selective progressive_parser_processor that will send chunks straight to output but only for chunks matching (in an exact way) some defined paths. More...
 
class  selective_like_parser_processor
 Selective progressive_parser_processor that will send chunks straight to output but only for chunks matching (in a left padded way - like) some defined paths. More...
 
class  setting_dependency
 Generic abstract dependency class. More...
 
class  setting_dependency_disabledif_checked
 A dependency that disables the secondary element if the primary element is true or checked. More...
 
class  setting_dependency_disabledif_empty
 A dependency that disables the secondary setting if the value of the primary setting is empty. More...
 
class  setting_dependency_disabledif_equals
 A dependency that disables the secondary setting if the primary setting is equal to the provided value. More...
 
class  setting_dependency_disabledif_equals2
 This class is here for backwards compatibility (terrible name). More...
 
class  setting_dependency_disabledif_in_array
 Disable if a value is in a list. More...
 
class  setting_dependency_disabledif_not_checked
 A dependency that disables the secondary element if the primary element is false or not checked. More...
 
class  setting_dependency_disabledif_not_empty
 A dependency that disables the secondary setting if the value of the primary setting is not empty. More...
 
class  setting_dependency_disabledif_not_equals
 A dependency that disables the secondary setting if the primary setting is not equal to the provided value. More...
 
class  simple_parser_processor
 Simple progressive_parser_processor that will send chunks straight to output. More...
 
class  simplified_parser_processor
 Abstract xml parser processor to to simplify and dispatch parsed chunks. More...
 
class  StateStack
 States for a stack machine. More...
 
class  table_default_export_format_parent
 
class  table_sql
 
class  test_question_engine_attempt_upgrader
 Subclass of question_engine_attempt_upgrader to help with testing. More...
 
class  test_question_engine_upgrade_question_loader
 Subclass of question_engine_upgrade_question_loader for unit testing. More...
 
class  test_question_maker
 This class creates questions of various types, which can then be used when testing. More...
 
class  testable_question_attempt
 Makes some protected methods of question_attempt public to facilitate testing. More...
 
class  testable_question_engine_unit_of_work
 Test subclass to allow access to some protected data so that the correct behaviour can be verified. More...
 
class  testing_db_record_builder
 Helper for tests that need to simulate records loaded from the database. More...
 
class  texteditor
 Base abstract text editor class. More...
 
class  upload_manager
 This class handles all aspects of fileuploading. More...
 
class  webdav_client
 
class  WikiToMarkdown
 #- More...
 
class  xml_contenttransformer
 Abstract class to extend in order to transform @xml_writer text contents. More...
 
class  xml_output
 This abstract class outputs XML contents provided by @xml_writer. More...
 
class  xml_output_exception
 
class  xml_writer
 Class implementing one (more or less complete) UTF-8 XML writer. More...
 
class  xml_writer_exception
 

Functions

 Lexer::__construct (&$parser, $start="accept", $case=false)
 Sets up the lexer in case insensitive matching by default.
 
 StateStack::__construct ($start)
 Constructor.
 
 activity_userComments ($per_page=NULL, $page=NULL)
 These functions are the direct implementations of flickr calls.
 
 activity_userPhotos ($timeframe=NULL, $per_page=NULL, $page=NULL)
 
 Lexer::addEntryPattern ($pattern, $mode, $new_mode)
 Adds a pattern that will enter a new parsing mode.
 
 Lexer::addExitPattern ($pattern, $mode)
 Adds a pattern that will exit the current mode and re-enter the previous one.
 
 addPattern ($pattern, $label=true)
 Adds a pattern with an optional label.
 
 Lexer::addPattern ($pattern, $mode="accept")
 Adds a token search pattern for a particular parsing mode.
 
 Lexer::addSpecialPattern ($pattern, $mode, $special)
 Adds a pattern that has a special mode.
 
 auth ($perms="write", $remember_uri=true)
 
 auth_checkToken ()
 Authentication methods.
 
 auth_getFrob ()
 
 auth_getFullToken ($mini_token)
 
 auth_getToken ($frob)
 
 blog_delete_external_entries ($externalblog)
 Given an external blog object, deletes all related blog entries from the post table.
 
 blog_get_all_options (moodle_page $page, stdClass $userid=null)
 This function gets all of the options available for the current user in respect to blogs.
 
 blog_get_associated_count ($courseid, $cmid=null)
 Shortcut function for getting a count of blog entries associated with a course or a module.
 
 blog_get_headers ($courseid=null, $groupid=null, $userid=null, $tagid=null, $tag=null, $modid=null, $entryid=null, $search=null)
 This function encapsulates all the logic behind the complex navigation, titles and headings of the blog listing page, depending on URL params.
 
 blog_get_options_for_course (stdClass $course, stdClass $user=null)
 Get the blog options that relate to the given course for the given user.
 
 blog_get_options_for_module ($module, $user=null)
 Get the blog options relating to the given module for the given user.
 
 blog_get_options_for_user (stdClass $user=null)
 Get all of the blog options that relate to the passed user.
 
 blog_get_tagged_posts ($tag, $exclusivemode=false, $fromctx=0, $ctx=0, $rec=true, $page=0)
 Returns posts tagged with a specified tag.
 
 blog_is_enabled_for_user ()
 This function checks that blogs are enabled, and that the user can see blogs at all.
 
 blog_page_type_list ($pagetype, $parentcontext, $currentcontext)
 Return a list of page types.
 
 blog_remove_associations_for_course ($courseid)
 remove all associations for the blog entries of a particular course
 
 blog_remove_associations_for_module ($modcontextid)
 Remove module associated blogs and blog tag instances.
 
 blog_remove_associations_for_user ($userid)
 remove all associations for the blog entries of a particular user
 
 blog_sync_external_entries ($externalblog)
 Given a record in the {blog_external} table, checks the blog's URL for new entries not yet copied into Moodle.
 
 blog_user_can_edit_entry ($blogentry)
 User can edit a blog entry if this is their own blog entry and they have the capability moodle/blog:create, or if they have the capability moodle/blog:manageentries.
 
 blog_user_can_view_user_entry ($targetuserid, $blogentry=null)
 Checks to see if a user can view the blogs of another user.
 
 blog_validate_access ($courseid, $modid, $groupid, $entryid, $userid)
 Validate the access to a blog.
 
 blogs_getList ()
 Blogs methods.
 
 blogs_postPhoto ($blog_id, $photo_id, $title, $description, $blog_password=NULL)
 
 buildPhotoURL ($photo, $size="Medium")
 These functions are front ends for the flickr calls.
 
 call ($method, $arguments)
 To use the phpFlickr\call method, pass a string containing the API method you want to use and an associative array of arguments.
 
 cc_convert ($dir)
 
 clean_text_nodes ($arr)
 
 contacts_getList ($filter=NULL, $page=NULL, $per_page=NULL)
 Contacts Methods.
 
 contacts_getPublicList ($user_id, $page=NULL, $per_page=NULL)
 
 core_blog_myprofile_navigation (core_user\output\myprofile\tree $tree, $user, $iscurrentuser, $course)
 Add nodes to myprofile page.
 
 create_new_question_button ($categoryid, $params, $caption, $tooltip='', $disabled=false)
 Print a button for creating a new question.
 
 detect_cc_format ($xml_file)
 
 detect_requirements ()
 
 StateStack::enter ($state)
 Adds a state to the stack and sets it to be the current state.
 
 favorites_add ($photo_id)
 Favorites Methods.
 
 favorites_getList ($user_id=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 favorites_getPublicList ($user_id=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 favorites_remove ($photo_id)
 
 get_module_from_cmid ($cmid)
 
 get_questions_category (object $category, bool $noparent, bool $recurse=true, bool $export=true, bool $latestversion=false)
 Function to read all questions for category into big array.
 
 StateStack::getCurrent ()
 Accessor for current state.
 
 getErrorCode ()
 
 getErrorMsg ()
 
 getFriendlyGeodata ($lat, $lon)
 
 groups_browse ($cat_id=NULL)
 Groups Methods.
 
 groups_getInfo ($group_id)
 
 groups_pools_add ($photo_id, $group_id)
 Groups Pools Methods.
 
 groups_pools_getContext ($photo_id, $group_id)
 
 groups_pools_getGroups ($page=NULL, $per_page=NULL)
 
 groups_pools_getPhotos ($group_id, $tags=NULL, $user_id=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 groups_pools_remove ($photo_id, $group_id)
 
 groups_search ($text, $per_page=NULL, $page=NULL)
 
 interestingness_getList ($date=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 Interestingness methods.
 
 StateStack::leave ()
 Leaves the current state and reverts to the previous one.
 
 Lexer::Lexer (&$parser, $start="accept", $case=false)
 Old syntax of class constructor.
 
 Lexer::mapHandler ($mode, $handler)
 Adds a mapping from a mode to another handler.
 
 match ($subject, &$match)
 Attempts to match all patterns at once against a string.
 
 my_copy_page (int $userid, int $private=MY_PAGE_PRIVATE, string $pagetype='my-index', string $pagename=MY_PAGE_DEFAULT)
 This copies a system default page to the current user.
 
 my_get_page (?int $userid, int $private=MY_PAGE_PRIVATE, string $pagename=MY_PAGE_DEFAULT)
 For a given user, this returns the $page information for their My Moodle page.
 
 my_reset_page (int $userid, int $private=MY_PAGE_PRIVATE, string $pagetype='my-index', string $pagename=MY_PAGE_DEFAULT)
 For a given user, this deletes their My Moodle page and returns them to the system default.
 
 my_reset_page_for_all_users (int $private=MY_PAGE_PRIVATE, string $pagetype='my-index', ?progress_bar $progressbar=null, string $pagename=MY_PAGE_DEFAULT)
 Resets the page customisations for all users.
 
 ParallelRegex ($case)
 Old syntax of class constructor.
 
 Lexer::parse ($raw)
 Splits the page text into tokens.
 
 people_findByEmail ($find_email)
 People methods.
 
 people_findByUsername ($username)
 
 people_getInfo ($user_id)
 
 people_getPublicGroups ($user_id)
 
 people_getPublicPhotos ($user_id, $extras=NULL, $per_page=NULL, $page=NULL)
 
 people_getUploadStatus ()
 
 photos_addTags ($photo_id, $tags)
 Photos Methods.
 
 photos_comments_addComment ($photo_id, $comment_text)
 Photos - Comments Methods.
 
 photos_comments_deleteComment ($comment_id)
 
 photos_comments_editComment ($comment_id, $comment_text)
 
 photos_comments_getList ($photo_id)
 
 photos_delete ($photo_id)
 
 photos_geo_getLocation ($photo_id)
 Photos - Geo Methods.
 
 photos_geo_getPerms ($photo_id)
 
 photos_geo_removeLocation ($photo_id)
 
 photos_geo_setLocation ($photo_id, $lat, $lon, $accuracy=NULL)
 
 photos_geo_setPerms ($photo_id, $is_public, $is_contact, $is_friend, $is_family)
 
 photos_getAllContexts ($photo_id)
 
 photos_getContactsPhotos ($count=NULL, $just_friends=NULL, $single_photo=NULL, $include_self=NULL, $extras=NULL)
 
 photos_getContactsPublicPhotos ($user_id, $count=NULL, $just_friends=NULL, $single_photo=NULL, $include_self=NULL, $extras=NULL)
 
 photos_getContext ($photo_id)
 
 photos_getCounts ($dates=NULL, $taken_dates=NULL)
 
 photos_getExif ($photo_id, $secret=NULL)
 
 photos_getFavorites ($photo_id, $page=NULL, $per_page=NULL)
 
 photos_getInfo ($photo_id, $secret=NULL)
 
 photos_getNotInSet ($min_upload_date=NULL, $max_upload_date=NULL, $min_taken_date=NULL, $max_taken_date=NULL, $privacy_filter=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 photos_getPerms ($photo_id)
 
 photos_getRecent ($extras=NULL, $per_page=NULL, $page=NULL)
 
 photos_getSizes ($photo_id)
 
 photos_getUntagged ($min_upload_date=NULL, $max_upload_date=NULL, $min_taken_date=NULL, $max_taken_date=NULL, $privacy_filter=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 photos_getWithGeoData ($args=NULL)
 
 photos_getWithoutGeoData ($args=NULL)
 
 photos_licenses_getInfo ()
 Photos - Licenses Methods.
 
 photos_licenses_setLicense ($photo_id, $license_id)
 
 photos_notes_add ($photo_id, $note_x, $note_y, $note_w, $note_h, $note_text)
 Photos - Notes Methods.
 
 photos_notes_delete ($note_id)
 
 photos_notes_edit ($note_id, $note_x, $note_y, $note_w, $note_h, $note_text)
 
 photos_recentlyUpdated ($min_date=NULL, $extras=NULL, $per_page=NULL, $page=NULL)
 
 photos_removeTag ($tag_id)
 
 photos_search ($args)
 
 photos_setContentType ($photo_id, $content_type)
 
 photos_setDates ($photo_id, $date_posted=NULL, $date_taken=NULL, $date_taken_granularity=NULL)
 
 photos_setMeta ($photo_id, $title, $description)
 
 photos_setPerms ($photo_id, $is_public, $is_friend, $is_family, $perm_comment, $perm_addmeta)
 
 photos_setSafetyLevel ($photo_id, $safety_level, $hidden=null)
 
 photos_setTags ($photo_id, $tags)
 
 photos_transform_rotate ($photo_id, $degrees)
 Photos - Transform Methods.
 
 photos_upload_checkTickets ($tickets)
 Photos - Upload Methods.
 
 photosets_addPhoto ($photoset_id, $photo_id)
 Photosets Methods.
 
 photosets_comments_addComment ($photoset_id, $comment_text)
 Photosets Comments Methods.
 
 photosets_comments_deleteComment ($comment_id)
 
 photosets_comments_editComment ($comment_id, $comment_text)
 
 photosets_comments_getList ($photoset_id)
 
 photosets_create ($title, $description, $primary_photo_id)
 
 photosets_delete ($photoset_id)
 
 photosets_editMeta ($photoset_id, $title, $description=NULL)
 
 photosets_editPhotos ($photoset_id, $primary_photo_id, $photo_ids)
 
 photosets_getContext ($photo_id, $photoset_id)
 
 photosets_getInfo ($photoset_id)
 
 photosets_getList ($user_id=NULL)
 
 photosets_getPhotos ($photoset_id, $extras=NULL, $privacy_filter=NULL, $per_page=NULL, $page=NULL)
 
 photosets_orderSets ($photoset_ids)
 
 photosets_removePhoto ($photoset_id, $photo_id)
 
 places_resolvePlaceId ($place_id)
 Places Methods.
 
 places_resolvePlaceURL ($url)
 
 prefs_getContentType ()
 Prefs Methods.
 
 prefs_getHidden ()
 
 prefs_getPrivacy ()
 
 prefs_getSafetyLevel ()
 
 print_choose_qtype_to_add_form ($hiddenparams, array $allowedqtypes=null, $enablejs=true)
 Print a form to let the user choose which question type to add.
 
 question_build_edit_resources ($edittab, $baseurl, $params, $defaultquestionsperpage=DEFAULT_QUESTIONS_PER_PAGE)
 Common function for building the generic resources required by the editing questions pages.
 
 question_can_delete_cat ($todelete)
 Ensures that this user is allowed to delete this category.
 
 question_edit_setup ($edittab, $baseurl, $requirecmid=false, $unused=null)
 Common setup for all pages for editing questions.
 
 question_fix_random_question_parents ()
 In Moodle, all random questions should have question.parent set to be the same as question.id.
 
 question_get_category_id_from_pagevars (array $pagevars)
 Get the category id from $pagevars.
 
 question_get_display_preference ($param, $default, $type, $thispageurl)
 Get a particular question preference that is also stored as a user preference.
 
 question_is_only_child_of_top_category_in_context ($categoryid)
 Checks whether this is the only child of a top category in a context.
 
 question_is_top_category ($categoryid)
 Checks whether the category is a "Top" category (with no parent).
 
 question_set_or_get_user_preference ($name, $value, $default, $thispageurl)
 Get a user preference by name or set the user preference to a given value.
 
 quiz_attempts_upgraded (environment_results $result)
 This check verifies that all quiz attempts were upgraded since following the question engine upgrade in Moodle 2.1.
 
 reflection_getMethodInfo ($method_name)
 Reflection Methods.
 
 reflection_getMethods ()
 
 request ($command, $args=array())
 
 require_login_in_context ($contextorid=null)
 Make sure user is logged in as required in this context.
 
 setProxy ($server, $port)
 
 setToken ($token)
 
 StateStack::StateStack ($start)
 Old syntax of class constructor.
 
 tags_getHotList ($period=NULL, $count=NULL)
 Tags Methods.
 
 tags_getListPhoto ($photo_id)
 
 tags_getListUser ($user_id=NULL)
 
 tags_getListUserPopular ($user_id=NULL, $count=NULL)
 
 tags_getListUserRaw ($tag)
 
 tags_getRelated ($tag)
 
 tcpdf_init_k_font_path ()
 Init K_PATH_FONTS and PDF_FONT_NAME_MAIN constant.
 
 test_echo ($args=array())
 
 test_login ()
 
 tokenise_expand_cjk ($matches)
 Basic CJK tokeniser.
 
 tokenise_simplify ($text, $overlap_cjk, $join_numbers)
 Simplifies a string according to indexing rules.
 
 tokenise_split ($text, $stop_words, $overlap_cjk, $join_numbers)
 Some helper functions (should be considered private)
 
 tokenise_text ($text, $stop_words=array(), $overlap_cjk=false, $join_numbers=false)
 This function process the text passed at input, extracting all the tokens and scoring each one based in their number of ocurrences and relation with some well-known html tags.
 
 tokenise_truncate_word (&$text)
 Helper function for array_walk in search_index_split.
 
 upload (stored_file $photo, array $meta=array())
 Upload a photo from Moodle file pool to Flickr.
 
 urls_getGroup ($group_id)
 
 urls_getUserPhotos ($user_id=NULL)
 
 urls_getUserProfile ($user_id=NULL)
 
 urls_lookupGroup ($url)
 
 urls_lookupUser ($url)
 
 validateEmailSyntax ( $emailaddr, $options="")
 About ValidateEmailSyntax(): This function uses the ValidateUrlSyntax() function to easily check the syntax of an email address.
 
 validateFtpSyntax ( $ftpaddr, $options="")
 About ValidateFtpSyntax(): This function uses the ValidateUrlSyntax() function to easily check the syntax of an FTP address.
 
 validateUrlSyntax ( $urladdr, $options="")
 BEGINNING OF validateUrlSyntax() function.
 

Variables

 Lexer::$_case
 
 Lexer::$_mode
 
 Lexer::$_mode_handlers
 
 Lexer::$_parser
 
 Lexer::$_regexes
 
 StateStack::$_stack
 
global $CFG
 
global $CFG
 
global $CFG
 
global $CFG
 
global $CFG
 
 $publishes
 
 $subscribes
 
Harry Fuecks and Matt and the project code is in the domain guys **ingroup moodlecore *copyright Markus Harry Fuecks and Matt Mitchell *license Public Domain< a class="el externalurl" href="http: */ define("LEXER_ENTER", 1); define("LEXER_MATCHED", 2); define("LEXER_UNMATCHED", 3); define("LEXER_EXIT", 4); define("LEXER_SPECIAL", 5); class ParallelRegex { var $_patterns; var $_labels; var $_regex; var $_case; public function __construct($case) { $this-> _case = $case
 
$this _labels = array()
 
$this _patterns = array()
 
$this _regex = null
 
Harry Fuecks and Matt and the project code is in the domain guys **ingroup moodlecore *copyright Markus Baker
 
const CC_QUIZ_ESSAY 'cc.essay.v0p1'
 
const CC_QUIZ_FIB 'cc.fib.v0p1'
 
const CC_QUIZ_MULTIPLE_CHOICE 'cc.multiple_choice.v0p1'
 
const CC_QUIZ_MULTIPLE_RESPONSE 'cc.multiple_response.v0p1'
 
const CC_QUIZ_PATTERN_MACHT 'cc.pattern_match.v0p1'
 
const CC_QUIZ_TRUE_FALSE 'cc.true_false.v0p1'
 
const CC_TYPE_ASSOCIATED_CONTENT 'associatedcontent/imscc_xmlv1p0/learning-application-resource'
 
const CC_TYPE_EMPTY ''
 
const CC_TYPE_FORUM 'imsdt_xmlv1p0'
 
const CC_TYPE_QUESTION_BANK 'imsqti_xmlv1p2/imscc_xmlv1p0/question-bank'
 
const CC_TYPE_QUIZ 'imsqti_xmlv1p2/imscc_xmlv1p0/assessment'
 
const CC_TYPE_WEBCONTENT 'webcontent'
 
const CC_TYPE_WEBLINK 'imswl_xmlv1p0'
 
const CENTER_DELIM "\xc3\x91\xce\xa9\xc3\x91"
 
$this curl = new curl(array('cache'=>true, 'module_cache'=>'repository'))
 
const DEFAULT_QUESTIONS_PER_PAGE 100
 
*Sourceforge Project *visit< a class="el externalurl" href="http: * * For installation instructions, open the README.txt file packaged with this * class. If you don't have a copy, you can see it at: * <a class="el externalurl" href="http:**Please submit all problems or questions to the Help Forum on my project page:*< a class="el externalurl" href="http: * * Modified by Dongsheng Cai <dongsheng@moodle.com> * ChangeLog: * 1. Remove PEAR HTTP LIB, use curl.class.php (created by myself) * 2. Remove PEAR DB LIB * 3. Remove all cache code, it will implement in curl class. * 4. Clean up session code * * Modified by David Mudrak <david@moodle.com> * ChangeLog: * 1. upload() method uses Moodle stored_file * 2. upload() method supports all params provided by http: * 3. auth() method shows debugging warning as this library cannot be used any * more for calling Flickr API that requires authentication. * * @ingroup moodlecore * @subpackage 3rd-party */defined('MOODLE_INTERNAL') || die();global $CFG;require_once("{ $CFG->libdir}/flickrclient.php");class phpFlickr { var $api_key; var $secret; var $REST = 'https: var $Upload = 'https: var $Replace = 'https: var $req; var $response; var $parsed_response; var $die_on_error; var $error_code; var $error_msg; var $token; var $php_version; private curl $curl; object function __construct ($api_key, $secret = NULL, $token = '') { global $CFG; $this->api_key = $api_key; $this->secret = $secret; $this-> die_on_error = false
 
const END_DELIM "\xc3\x91\xc3\x91\xce\xa9"
 
const FORMAT_BLACK_BOARD 'BB'
 
const FORMAT_COMMON_CARTRIDGE 'CC'
 
const FORMAT_UNKNOWN 'NA'
 
http
 
 if (!defined( 'MOODLE_INTERNAL'))
 
 if (!defined( 'MOODLE_INTERNAL'))
 
 if (!defined( 'MOODLE_INTERNAL'))
 
 if (!defined( 'MOODLE_INTERNAL'))
 
 if (!defined( 'MOODLE_INTERNAL'))
 
 if (!defined( 'MOODLE_INTERNAL'))
 
const K_BLANK_IMAGE K_PATH_IMAGES . 'pix/spacer.gif'
 blank image
 
const K_CELL_HEIGHT_RATIO 1.25
 height of cell repect font height
 
const K_PATH_CACHE $CFG->cachedir . '/tcpdf/'
 cache directory for temporary files (full path)
 
const K_PATH_IMAGES $CFG->dirroot . '/'
 images directory
 
const K_PATH_MAIN $CFG->dirroot.'/lib/tcpdf/'
 tcpdf installation path
 
const K_PATH_URL $CFG->wwwroot . '/lib/tcpdf/'
 URL path to tcpdf installation folder.
 
const K_SMALL_RATIO 2/3
 reduction factor for small font
 
const K_TCPDF_EXTERNAL_CONFIG (!defined('PDF_DEFAULT_FONT')) 1
 tell tcpdf it is configured here instead of in its own config file
 
const K_TCPDF_THROW_EXCEPTION_ERROR true
 Throw exceptions from errors so they can be caught and recovered from.
 
const MAXIMUM_QUESTIONS_PER_PAGE 4000
 
const MAXIMUM_WORD_SIZE 50
 Minimum word size to index and search.
 
const MINIMUM_WORD_SIZE 3
 Some constants.
 
Harry Fuecks and Matt * Mitchell
 
const MOODLE_QUIZ_ESSAY 'essay'
 
const MOODLE_QUIZ_MACHT 'match'
 
const MOODLE_QUIZ_MULTIANSWER 'multianswer'
 
const MOODLE_QUIZ_MULTIPLE_CHOICE 'multichoice'
 
const MOODLE_QUIZ_MULTIPLE_RESPONSE 'multichoice'
 
const MOODLE_QUIZ_SHORTANSWER 'shortanswer'
 
const MOODLE_QUIZ_TRUE_FALSE 'truefalse'
 
const MOODLE_TYPE_BASICLTI 'basiclti'
 
const MOODLE_TYPE_FORUM 'forum'
 
const MOODLE_TYPE_LABEL 'label'
 
const MOODLE_TYPE_LTI 'lti'
 
const MOODLE_TYPE_QUESTION_BANK 'question_bank'
 
const MOODLE_TYPE_QUIZ 'quiz'
 
const MOODLE_TYPE_RESOURCE 'resource'
 
const MY_PAGE_COURSES '__courses'
 
const MY_PAGE_DEFAULT '__default'
 
const MY_PAGE_PRIVATE 1
 
const MY_PAGE_PUBLIC 0
 
const NS_BLACK_BOARD 'http://www.blackboard.com/content-packaging'
 
const NS_COMMON_CARTRIDGE 'http://www.imsglobal.org/xsd/imscc/imscp_v1p1'
 
*Sourceforge Project Page
 
$this php_version = explode("-", phpversion())
 
const PORTFOLIO_MAHARA_ERR_INVALIDHOST 'err_invalidhost'
 
const PORTFOLIO_MAHARA_ERR_NETWORKING_OFF 'err_networkingoff'
 
const PORTFOLIO_MAHARA_ERR_NOHOSTS 'err_nomnethosts'
 
const PORTFOLIO_MAHARA_ERR_NOMNETAUTH 'err_nomnetauth'
 
const PORTFOLIO_MAHARA_IMMEDIATE PORTFOLIO_TIME_MODERATE
 
const PORTFOLIO_MAHARA_QUEUE PORTFOLIO_TIME_HIGH
 
const PREG_CLASS_CJK '\x{3041}-\x{30ff}\x{31f0}-\x{31ff}\x{3400}-\x{4db5}'. '\x{4e00}-\x{9fbb}\x{f900}-\x{fad9}'
 Matches all CJK characters that are candidates for auto-splitting (Chinese, Japanese, Korean).
 
const PREG_CLASS_NUMBERS '\x{30}-\x{39}\x{b2}\x{b3}\x{b9}\x{bc}-\x{be}\x{660}-\x{669}\x{6f0}-\x{6f9}'. '\x{966}-\x{96f}\x{9e6}-\x{9ef}\x{9f4}-\x{9f9}\x{a66}-\x{a6f}\x{ae6}-\x{aef}'. '\x{b66}-\x{b6f}\x{be7}-\x{bf2}\x{c66}-\x{c6f}\x{ce6}-\x{cef}\x{d66}-\x{d6f}'. '\x{e50}-\x{e59}\x{ed0}-\x{ed9}\x{f20}-\x{f33}\x{1040}-\x{1049}\x{1369}-'. '\x{137c}\x{16ee}-\x{16f0}\x{17e0}-\x{17e9}\x{17f0}-\x{17f9}\x{1810}-\x{1819}'. '\x{1946}-\x{194f}\x{2070}\x{2074}-\x{2079}\x{2080}-\x{2089}\x{2153}-\x{2183}'. '\x{2460}-\x{249b}\x{24ea}-\x{24ff}\x{2776}-\x{2793}\x{3007}\x{3021}-\x{3029}'. '\x{3038}-\x{303a}\x{3192}-\x{3195}\x{3220}-\x{3229}\x{3251}-\x{325f}\x{3280}-'. '\x{3289}\x{32b1}-\x{32bf}\x{ff10}-\x{ff19}'
 Matches all 'N' Unicode character classes (numbers)
 
const PREG_CLASS_PUNCTUATION '\x{21}-\x{23}\x{25}-\x{2a}\x{2c}-\x{2f}\x{3a}\x{3b}\x{3f}\x{40}\x{5b}-\x{5d}'. '\x{5f}\x{7b}\x{7d}\x{a1}\x{ab}\x{b7}\x{bb}\x{bf}\x{37e}\x{387}\x{55a}-\x{55f}'. '\x{589}\x{58a}\x{5be}\x{5c0}\x{5c3}\x{5f3}\x{5f4}\x{60c}\x{60d}\x{61b}\x{61f}'. '\x{66a}-\x{66d}\x{6d4}\x{700}-\x{70d}\x{964}\x{965}\x{970}\x{df4}\x{e4f}'. '\x{e5a}\x{e5b}\x{f04}-\x{f12}\x{f3a}-\x{f3d}\x{f85}\x{104a}-\x{104f}\x{10fb}'. '\x{1361}-\x{1368}\x{166d}\x{166e}\x{169b}\x{169c}\x{16eb}-\x{16ed}\x{1735}'. '\x{1736}\x{17d4}-\x{17d6}\x{17d8}-\x{17da}\x{1800}-\x{180a}\x{1944}\x{1945}'. '\x{2010}-\x{2027}\x{2030}-\x{2043}\x{2045}-\x{2051}\x{2053}\x{2054}\x{2057}'. '\x{207d}\x{207e}\x{208d}\x{208e}\x{2329}\x{232a}\x{23b4}-\x{23b6}\x{2768}-'. '\x{2775}\x{27e6}-\x{27eb}\x{2983}-\x{2998}\x{29d8}-\x{29db}\x{29fc}\x{29fd}'. '\x{3001}-\x{3003}\x{3008}-\x{3011}\x{3014}-\x{301f}\x{3030}\x{303d}\x{30a0}'. '\x{30fb}\x{fd3e}\x{fd3f}\x{fe30}-\x{fe52}\x{fe54}-\x{fe61}\x{fe63}\x{fe68}'. '\x{fe6a}\x{fe6b}\x{ff01}-\x{ff03}\x{ff05}-\x{ff0a}\x{ff0c}-\x{ff0f}\x{ff1a}'. '\x{ff1b}\x{ff1f}\x{ff20}\x{ff3b}-\x{ff3d}\x{ff3f}\x{ff5b}\x{ff5d}\x{ff5f}-'. '\x{ff65}'
 Matches all 'P' Unicode character classes (punctuation)
 
const PREG_CLASS_SEARCH_EXCLUDE '\x{0}-\x{2f}\x{3a}-\x{40}\x{5b}-\x{60}\x{7b}-\x{bf}\x{d7}\x{f7}\x{2b0}-'. '\x{385}\x{387}\x{3f6}\x{482}-\x{489}\x{559}-\x{55f}\x{589}-\x{5c7}\x{5f3}-'. '\x{61f}\x{640}\x{64b}-\x{65e}\x{66a}-\x{66d}\x{670}\x{6d4}\x{6d6}-\x{6ed}'. '\x{6fd}\x{6fe}\x{700}-\x{70f}\x{711}\x{730}-\x{74a}\x{7a6}-\x{7b0}\x{901}-'. '\x{903}\x{93c}\x{93e}-\x{94d}\x{951}-\x{954}\x{962}-\x{965}\x{970}\x{981}-'. '\x{983}\x{9bc}\x{9be}-\x{9cd}\x{9d7}\x{9e2}\x{9e3}\x{9f2}-\x{a03}\x{a3c}-'. '\x{a4d}\x{a70}\x{a71}\x{a81}-\x{a83}\x{abc}\x{abe}-\x{acd}\x{ae2}\x{ae3}'. '\x{af1}-\x{b03}\x{b3c}\x{b3e}-\x{b57}\x{b70}\x{b82}\x{bbe}-\x{bd7}\x{bf0}-'. '\x{c03}\x{c3e}-\x{c56}\x{c82}\x{c83}\x{cbc}\x{cbe}-\x{cd6}\x{d02}\x{d03}'. '\x{d3e}-\x{d57}\x{d82}\x{d83}\x{dca}-\x{df4}\x{e31}\x{e34}-\x{e3f}\x{e46}-'. '\x{e4f}\x{e5a}\x{e5b}\x{eb1}\x{eb4}-\x{ebc}\x{ec6}-\x{ecd}\x{f01}-\x{f1f}'. '\x{f2a}-\x{f3f}\x{f71}-\x{f87}\x{f90}-\x{fd1}\x{102c}-\x{1039}\x{104a}-'. '\x{104f}\x{1056}-\x{1059}\x{10fb}\x{10fc}\x{135f}-\x{137c}\x{1390}-\x{1399}'. '\x{166d}\x{166e}\x{1680}\x{169b}\x{169c}\x{16eb}-\x{16f0}\x{1712}-\x{1714}'. '\x{1732}-\x{1736}\x{1752}\x{1753}\x{1772}\x{1773}\x{17b4}-\x{17db}\x{17dd}'. '\x{17f0}-\x{180e}\x{1843}\x{18a9}\x{1920}-\x{1945}\x{19b0}-\x{19c0}\x{19c8}'. '\x{19c9}\x{19de}-\x{19ff}\x{1a17}-\x{1a1f}\x{1d2c}-\x{1d61}\x{1d78}\x{1d9b}-'. '\x{1dc3}\x{1fbd}\x{1fbf}-\x{1fc1}\x{1fcd}-\x{1fcf}\x{1fdd}-\x{1fdf}\x{1fed}-'. '\x{1fef}\x{1ffd}-\x{2070}\x{2074}-\x{207e}\x{2080}-\x{2101}\x{2103}-\x{2106}'. '\x{2108}\x{2109}\x{2114}\x{2116}-\x{2118}\x{211e}-\x{2123}\x{2125}\x{2127}'. '\x{2129}\x{212e}\x{2132}\x{213a}\x{213b}\x{2140}-\x{2144}\x{214a}-\x{2b13}'. '\x{2ce5}-\x{2cff}\x{2d6f}\x{2e00}-\x{3005}\x{3007}-\x{303b}\x{303d}-\x{303f}'. '\x{3099}-\x{309e}\x{30a0}\x{30fb}-\x{30fe}\x{3190}-\x{319f}\x{31c0}-\x{31cf}'. '\x{3200}-\x{33ff}\x{4dc0}-\x{4dff}\x{a015}\x{a490}-\x{a716}\x{a802}\x{a806}'. '\x{a80b}\x{a823}-\x{a82b}\x{d800}-\x{f8ff}\x{fb1e}\x{fb29}\x{fd3e}\x{fd3f}'. '\x{fdfc}-\x{fe6b}\x{feff}-\x{ff0f}\x{ff1a}-\x{ff20}\x{ff3b}-\x{ff40}\x{ff5b}-'. '\x{ff65}\x{ff70}\x{ff9e}\x{ff9f}\x{ffe0}-\x{fffd}'
 Matches Unicode character classes to exclude from the search index.
 
const ROOT_DEEP 2
 
const SHEET_BASE 'cc/sheets/base.xml'
 
const SHEET_COURSE_BLOCKS_BLOCK 'cc/sheets/course_blocks_block.xml'
 
const SHEET_COURSE_HEADER 'cc/sheets/course_header.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES 'cc/sheets/course_question_categories.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY 'cc/sheets/course_question_categories_question_category.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION 'cc/sheets/course_question_categories_question_category_question.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION_ANSWER 'cc/sheets/course_question_categories_question_category_question_answer.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION_EESAY 'cc/sheets/course_question_categories_question_category_question_eesay.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION_MULTIPLE_CHOICE 'cc/sheets/course_question_categories_question_category_question_multiple_choice.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION_SHORTANSWER 'cc/sheets/course_question_categories_question_category_question_shortanswer.xml'
 
const SHEET_COURSE_QUESTION_CATEGORIES_QUESTION_CATEGORY_QUESTION_TRUE_FALSE 'cc/sheets/course_question_categories_question_category_question_true_false.xml'
 
const SHEET_COURSE_SECTIONS_SECTION 'cc/sheets/course_sections_section.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD 'cc/sheets/course_sections_section_mods_mod.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_BASICLTI 'cc/sheets/course_modules_mod_basiclti.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_FORUM 'cc/sheets/course_modules_mod_forum.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_LABEL 'cc/sheets/course_modules_mod_label.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_LTI 'cc/sheets/course_modules_mod_lti.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_QUIZ 'cc/sheets/course_modules_mod_quiz.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_QUIZ_FEEDBACK 'cc/sheets/course_modules_mod_quiz_feedback.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_QUIZ_QUESTION_INSTANCE 'cc/sheets/course_modules_mod_quiz_question_instance.xml'
 
const SHEET_COURSE_SECTIONS_SECTION_MODS_MOD_RESOURCE 'cc/sheets/course_modules_mod_resource.xml'
 
const SHEET_INFO_DETAILS_MOD 'cc/sheets/info_details_mod.xml'
 
const SHEET_INFO_DETAILS_MOD_INSTANCE 'cc/sheets/info_details_mod_instance.xml'
 
const START_DELIM "\xce\xa9\xc3\x91\xc3\x91"
 Maximum word size to index and search.
 
Harry Fuecks and Matt and the project code is in the domain ** Thanks
 
$this token = $token
 
const TYPE_UNKNOWN '[UNKNOWN]'
 

Detailed Description

Function Documentation

◆ __construct() [1/2]

Lexer::__construct ( & $parser,
$start = "accept",
$case = false )

Sets up the lexer in case insensitive matching by default.

Parameters
object$parserHandling strategy by reference.
string$startStarting handler.
bool$caseTrue for case sensitive.

◆ __construct() [2/2]

StateStack::__construct ( $start)

Constructor.

Starts in named state.

Parameters
string$startStarting state name.

◆ activity_userComments()

activity_userComments ( $per_page = NULL,
$page = NULL )

These functions are the direct implementations of flickr calls.

For method documentation, including arguments, visit the address included in a comment in the function. Activity methods

◆ addEntryPattern()

Lexer::addEntryPattern ( $pattern,
$mode,
$new_mode )

Adds a pattern that will enter a new parsing mode.

Useful for entering parenthesis, strings, tags, etc.

Parameters
string$patternPerl style regex, but ( and ) lose the usual meaning.
string$modeShould only apply this pattern when dealing with this type of input.
string$new_modeChange parsing to this new nested mode.

◆ addExitPattern()

Lexer::addExitPattern ( $pattern,
$mode )

Adds a pattern that will exit the current mode and re-enter the previous one.

Parameters
string$patternPerl style regex, but ( and ) lose the usual meaning.
string$modeMode to leave.

◆ addPattern() [1/2]

addPattern ( $pattern,
$label = true )

Adds a pattern with an optional label.

Parameters
string$patternPerl style regex, but ( and ) lose the usual meaning.
string$labelLabel of regex to be returned on a match.

◆ addPattern() [2/2]

Lexer::addPattern ( $pattern,
$mode = "accept" )

Adds a token search pattern for a particular parsing mode.

The pattern does not change the current mode.

Parameters
string$patternPerl style regex, but ( and ) lose the usual meaning.
string$modeShould only apply this pattern when dealing with this type of input.

◆ addSpecialPattern()

Lexer::addSpecialPattern ( $pattern,
$mode,
$special )

Adds a pattern that has a special mode.

Acts as an entry and exit pattern in one go.

Parameters
string$patternPerl style regex, but ( and ) lose the usual meaning.
string$modeShould only apply this pattern when dealing with this type of input.
string$specialUse this mode for this one token.

◆ blog_delete_external_entries()

blog_delete_external_entries ( $externalblog)

Given an external blog object, deletes all related blog entries from the post table.

NOTE: The external blog's id is saved as post.content, a field that is not oterhwise used by blog entries.

Parameters
object$externablog

◆ blog_get_all_options()

blog_get_all_options ( moodle_page $page,
stdClass $userid = null )

This function gets all of the options available for the current user in respect to blogs.

It loads the following if applicable:

Parameters
moodle_page$pageThe page to load for (normally $PAGE)
stdClass$useridLoad for a specific user
Return values
arrayAn array of options organised by type.

◆ blog_get_associated_count()

blog_get_associated_count ( $courseid,
$cmid = null )

Shortcut function for getting a count of blog entries associated with a course or a module.

Parameters
int$courseidThe ID of the course
int$cmidThe ID of the course_modules
Return values
stringThe number of associated entries

◆ blog_get_headers()

blog_get_headers ( $courseid = null,
$groupid = null,
$userid = null,
$tagid = null,
$tag = null,
$modid = null,
$entryid = null,
$search = null )

This function encapsulates all the logic behind the complex navigation, titles and headings of the blog listing page, depending on URL params.

It looks at URL params and at the current context level. It builds and returns an array containing:

  1. heading: The heading displayed above the blog entries
  2. stradd: The text to be used as the "Add entry" link
  3. strview: The text to be used as the "View entries" link
  4. url: The moodle_url object used as the base for add and view links
  5. filters: An array of parameters used to filter blog listings. Used by index.php and the Recent blogs block

All other variables are set directly in $PAGE

It uses the current URL to build these variables. A number of mutually exclusive use cases are used to structure this function.

Parameters
int$courseidcourse id the the blog is associated to (can be null).
int$groupidgroup id to filter blogs I can see (can be null)
int$useridblog author id (can be null)
int$tagidtag id to filter (can be null)
string$tagtag name to filter (can be null)
int$modidmodule id the blog is associated to (can be null).
int$entryidblog entry id to filter(can be null)
string$searchstring to search (can be null)
Return values
array

◆ blog_get_options_for_course()

blog_get_options_for_course ( stdClass $course,
stdClass $user = null )

Get the blog options that relate to the given course for the given user.

@staticvar array $courseoptions A cache so we can save regenerating multiple times

Parameters
stdClass$courseThe course to load options for
stdClass$userThe user to load options for null == current user
Return values
arrayThe array of options

◆ blog_get_options_for_module()

blog_get_options_for_module ( $module,
$user = null )

Get the blog options relating to the given module for the given user.

@staticvar array $moduleoptions Cache

Parameters
stdClass | cm_info$moduleThe module to get options for
stdClass$userThe user to get options for null == currentuser
Return values
array

◆ blog_get_options_for_user()

blog_get_options_for_user ( stdClass $user = null)

Get all of the blog options that relate to the passed user.

If no user is passed the current user is assumed.

@staticvar array $useroptions Cache so we don't have to regenerate multiple times

Parameters
stdClass$user
Return values
arrayThe array of options for the requested user

◆ blog_get_tagged_posts()

blog_get_tagged_posts ( $tag,
$exclusivemode = false,
$fromctx = 0,
$ctx = 0,
$rec = true,
$page = 0 )

Returns posts tagged with a specified tag.

Parameters
core_tag_tag$tag
bool$exclusivemodeif set to true it means that no other entities tagged with this tag are displayed on the page and the per-page limit may be bigger
int$fromctxcontext id where the link was displayed, may be used by callbacks to display items in the same context first
int$ctxcontext id where to search for records
bool$recsearch in subcontexts as well
int$page0-based number of page being displayed
Return values
core_tag\output\tagindex

◆ blog_is_enabled_for_user()

blog_is_enabled_for_user ( )

This function checks that blogs are enabled, and that the user can see blogs at all.

Return values
bool

◆ blog_page_type_list()

blog_page_type_list ( $pagetype,
$parentcontext,
$currentcontext )

Return a list of page types.

Parameters
string$pagetypecurrent page type
stdClass$parentcontextBlock's parent context
stdClass$currentcontextCurrent context of block

◆ blog_remove_associations_for_course()

blog_remove_associations_for_course ( $courseid)

remove all associations for the blog entries of a particular course

Parameters
intcourseid - id of user whose blog associations will be deleted

◆ blog_remove_associations_for_module()

blog_remove_associations_for_module ( $modcontextid)

Remove module associated blogs and blog tag instances.

Parameters
int$modcontextidModule context ID.

◆ blog_remove_associations_for_user()

blog_remove_associations_for_user ( $userid)

remove all associations for the blog entries of a particular user

Parameters
intuserid - id of user whose blog associations will be deleted

◆ blog_sync_external_entries()

blog_sync_external_entries ( $externalblog)

Given a record in the {blog_external} table, checks the blog's URL for new entries not yet copied into Moodle.

Also attempts to identify and remove deleted blog entries

Parameters
object$externalblog
Return values
booleanFalse if the Feed is invalid

◆ blog_user_can_edit_entry()

blog_user_can_edit_entry ( $blogentry)

User can edit a blog entry if this is their own blog entry and they have the capability moodle/blog:create, or if they have the capability moodle/blog:manageentries.

This also applies to deleting of entries.

◆ blog_user_can_view_user_entry()

blog_user_can_view_user_entry ( $targetuserid,
$blogentry = null )

Checks to see if a user can view the blogs of another user.

Only blog level is checked here, the capabilities are enforced in blog/index.php

◆ blog_validate_access()

blog_validate_access ( $courseid,
$modid,
$groupid,
$entryid,
$userid )

Validate the access to a blog.

Parameters
int$courseidcourse id the the blog is associated to (can be null).
int$modidmodule id the blog is associated to (can be null).
int$groupidgroup id to filter blogs I can see (can be null)
int$entryidblog entry id (can be null)
int$useridblog author id (can be null)
Return values
arraywith the calculated course and id
Since
Moodle 3.6

◆ call()

call ( $method,
$arguments )

To use the phpFlickr\call method, pass a string containing the API method you want to use and an associative array of arguments.

For example: $result = $f->call("flickr.photos.comments.getList", array("photo_id"=>'34952612')); This method will allow you to make calls to arbitrary methods that haven't been implemented in phpFlickr yet.

◆ core_blog_myprofile_navigation()

core_blog_myprofile_navigation ( core_user\output\myprofile\tree $tree,
$user,
$iscurrentuser,
$course )

Add nodes to myprofile page.

Parameters
core_user\output\myprofile\tree$treeTree object
stdClass$useruser object
bool$iscurrentuser
stdClass$courseCourse object
Return values
bool

◆ create_new_question_button()

create_new_question_button ( $categoryid,
$params,
$caption,
$tooltip = '',
$disabled = false )

Print a button for creating a new question.

This will open question/addquestion.php, which in turn goes to question/question.php before getting back to $params['returnurl'] (by default the question bank screen).

Parameters
int$categoryidThe id of the category that the new question should be added to.
array$paramsOther paramters to add to the URL. You need either $params['cmid'] or $params['courseid'], and you should probably set $params['returnurl']
string$captionthe text to display on the button.
string$tooltipa tooltip to add to the button (optional).
bool$disabledif true, the button will be disabled.
Deprecated
since Moodle 4.0
See also
qbank_editquestion\editquestion_helper\create_new_question_button()
Todo
Final deprecation of this class in moodle 4.4 MDL-72438

◆ enter()

StateStack::enter ( $state)

Adds a state to the stack and sets it to be the current state.

Parameters
string$stateNew state.

◆ get_questions_category()

get_questions_category ( object $category,
bool $noparent,
bool $recurse = true,
bool $export = true,
bool $latestversion = false )

Function to read all questions for category into big array.

Parameters
object$categorycategory number
bool$noparentif true only questions with NO parent will be selected
bool$recurseinclude subdirectories
bool$exportset true if this is called by questionbank export
bool$latestversionif only the latest versions needed
Return values
array

◆ getCurrent()

StateStack::getCurrent ( )

Accessor for current state.

Return values
stringState as string.

◆ leave()

StateStack::leave ( )

Leaves the current state and reverts to the previous one.

Return values
boolFalse if we drop off the bottom of the list.

◆ Lexer()

Lexer::Lexer ( & $parser,
$start = "accept",
$case = false )

Old syntax of class constructor.

Deprecated in PHP7.

Deprecated
since Moodle 3.1

◆ mapHandler()

Lexer::mapHandler ( $mode,
$handler )

Adds a mapping from a mode to another handler.

Parameters
string$modeMode to be remapped.
string$handlerNew target handler.

◆ match()

match ( $subject,
& $match )

Attempts to match all patterns at once against a string.

Parameters
string$subjectString to match against.
string$matchFirst matched portion of subject.
Return values
boolTrue on success.

◆ my_copy_page()

my_copy_page ( int $userid,
int $private = MY_PAGE_PRIVATE,
string $pagetype = 'my-index',
string $pagename = MY_PAGE_DEFAULT )

This copies a system default page to the current user.

Parameters
int$useridthe id of the user whose page should be reset
int$privateeither MY_PAGE_PRIVATE or MY_PAGE_PUBLIC
string$pagetypeeither my-index or user-profile
string$pagenameDifferentiate between standard /my or /courses pages.

◆ my_get_page()

my_get_page ( ?int $userid,
int $private = MY_PAGE_PRIVATE,
string $pagename = MY_PAGE_DEFAULT )

For a given user, this returns the $page information for their My Moodle page.

Parameters
int | null$useridthe id of the user whose page should be retrieved
int | null$privateeither MY_PAGE_PRIVATE or MY_PAGE_PUBLIC
string | null$pagenameDifferentiate between standard /my or /courses pages.

◆ my_reset_page()

my_reset_page ( int $userid,
int $private = MY_PAGE_PRIVATE,
string $pagetype = 'my-index',
string $pagename = MY_PAGE_DEFAULT )

For a given user, this deletes their My Moodle page and returns them to the system default.

Parameters
int$useridthe id of the user whose page should be reset
int$privateeither MY_PAGE_PRIVATE or MY_PAGE_PUBLIC
string$pagetypeeither my-index or user-profile
string$pagenameDifferentiate between standard /my or /courses pages.
Return values
mixedsystem page, or false on error

◆ my_reset_page_for_all_users()

my_reset_page_for_all_users ( int $private = MY_PAGE_PRIVATE,
string $pagetype = 'my-index',
?progress_bar $progressbar = null,
string $pagename = MY_PAGE_DEFAULT )

Resets the page customisations for all users.

Parameters
int$privateEither MY_PAGE_PRIVATE or MY_PAGE_PUBLIC.
string$pagetypeEither my-index or user-profile.
progress_bar | null$progressbarA progress bar to update.
string$pagenameDifferentiate between standard /my or /courses pages.
Return values
void

◆ ParallelRegex()

ParallelRegex ( $case)

Old syntax of class constructor.

Deprecated in PHP7.

Deprecated
since Moodle 3.1

◆ parse()

Lexer::parse ( $raw)

Splits the page text into tokens.

Will fail if the handlers report an error or if no content is consumed. If successful then each unparsed and parsed token invokes a call to the held listener.

Parameters
string$rawRaw HTML text.
Return values
boolTrue on success, else false.

◆ print_choose_qtype_to_add_form()

print_choose_qtype_to_add_form ( $hiddenparams,
array $allowedqtypes = null,
$enablejs = true )

Print a form to let the user choose which question type to add.

When the form is submitted, it goes to the question.php script.

Parameters
$hiddenparamshidden parameters to add to the form, in addition to the qtype radio buttons.
$allowedqtypesoptional list of qtypes that are allowed. If given, only those qtypes will be shown. Example value array('description', 'multichoice').
Deprecated
since Moodle 4.0
See also
qbank_editquestion\editquestion_helper\print_choose_qtype_to_add_form()
Todo
Final deprecation of this class in moodle 4.4 MDL-72438

◆ question_build_edit_resources()

question_build_edit_resources ( $edittab,
$baseurl,
$params,
$defaultquestionsperpage = DEFAULT_QUESTIONS_PER_PAGE )

Common function for building the generic resources required by the editing questions pages.

Either a cmid or a course id must be provided as keys in $params or an exception will be thrown. All other params are optional and will have sane default applied if not provided.

The acceptable keys for $params are: [ 'cmid' => PARAM_INT, 'courseid' => PARAM_INT, 'qpage' => PARAM_INT, 'cat' => PARAM_SEQUENCE, 'category' => PARAM_SEQUENCE, 'qperpage' => PARAM_INT, 'recurse' => PARAM_INT, 'showhidden' => PARAM_INT, 'qbshowtext' => PARAM_INT, 'cpage' => PARAM_INT, 'recurse' => PARAM_BOOL, 'showhidden' => PARAM_BOOL, 'qbshowtext' => PARAM_INT, 'qtagids' => [PARAM_INT], (array of integers) 'qbs1' => PARAM_TEXT, 'qbs2' => PARAM_TEXT, 'qbs3' => PARAM_TEXT, ... and more qbs keys up to core_question\local\bank\view\MAX_SORTS ... ];

Parameters
string$edittabCode for this edit tab
string$baseurlThe name of the script calling this funciton. For examle 'qusetion/edit.php'.
array$paramsThe provided parameters to construct the resources with.
int$defaultquestionsperpagenumber of questions per page, if not given in the URL.
Return values
array\$thispageurl,$contexts,$cmid,$cm,$module,$pagevars

◆ question_can_delete_cat()

question_can_delete_cat ( $todelete)

Ensures that this user is allowed to delete this category.

Parameters
int$todeletea category id.
Deprecated
since Moodle 4.0 MDL-71585
See also
qbank_managecategories\helper
Todo
Final deprecation on Moodle 4.4 MDL-72438

◆ question_edit_setup()

question_edit_setup ( $edittab,
$baseurl,
$requirecmid = false,
$unused = null )

Common setup for all pages for editing questions.

Parameters
string$baseurlthe name of the script calling this funciton. For examle 'qusetion/edit.php'.
string$edittabcode for this edit tab
bool$requirecmidrequire cmid? default false
bool$unusedno longer used, do no pass
Return values
array\$thispageurl,$contexts,$cmid,$cm,$module,$pagevars

◆ question_fix_random_question_parents()

question_fix_random_question_parents ( )

In Moodle, all random questions should have question.parent set to be the same as question.id.

One effect of MDL-5482 is that this will not be true for questions that were backed up then restored. The probably does not cause many problems, except occasionally, if the bogus question.parent happens to point to a multianswer question type, or when you try to do a subsequent backup. Anyway, these question.parent values should be fixed, and that is what this update does.

◆ question_get_category_id_from_pagevars()

question_get_category_id_from_pagevars ( array $pagevars)

Get the category id from $pagevars.

Parameters
array$pagevarsfrom question_edit_setup().
Return values
intthe category id.

◆ question_get_display_preference()

question_get_display_preference ( $param,
$default,
$type,
$thispageurl )

Get a particular question preference that is also stored as a user preference.

If the the value is given in the GET/POST request, then that value is used, and the user preference is updated to that value. Otherwise, the last set value of the user preference is used, or if it has never been set the default passed to this function.

Parameters
string$paramthe param name. The URL parameter set, and the GET/POST parameter read. The user_preference name is 'question_bank_' . $param.
mixed$defaultThe default value to use, if not otherwise set.
int$typeone of the PARAM_... constants.
moodle_url$thispageurlif the value has been explicitly set, we add it to this URL.
Return values
mixedthe parameter value to use.

◆ question_is_only_child_of_top_category_in_context()

question_is_only_child_of_top_category_in_context ( $categoryid)

Checks whether this is the only child of a top category in a context.

Parameters
int$categoryida category id.
Return values
bool
Deprecated
since Moodle 4.0 MDL-71585
See also
qbank_managecategories\helper
Todo
Final deprecation on Moodle 4.4 MDL-72438

◆ question_is_top_category()

question_is_top_category ( $categoryid)

Checks whether the category is a "Top" category (with no parent).

Parameters
int$categoryida category id.
Return values
bool
Deprecated
since Moodle 4.0 MDL-71585
See also
qbank_managecategories\helper
Todo
Final deprecation on Moodle 4.4 MDL-72438

◆ question_set_or_get_user_preference()

question_set_or_get_user_preference ( $name,
$value,
$default,
$thispageurl )

Get a user preference by name or set the user preference to a given value.

If $value is null then the function will only attempt to retrieve the user preference requested by $name. If no user preference is found then the $default value will be returned. In this case the user preferences are not modified and nor are the params on $thispageurl.

If $value is anything other than null then the function will set the user preference $name to the provided $value and will also set it as a param on $thispageurl.

Parameters
string$nameThe user_preference name is 'question_bank_' . $name.
mixed$valueThe preference value.
mixed$defaultThe default value to use, if not otherwise set.
moodle_url$thispageurlif the value has been explicitly set, we add it to this URL.
Return values
mixedthe parameter value to use.

◆ quiz_attempts_upgraded()

quiz_attempts_upgraded ( environment_results $result)

This check verifies that all quiz attempts were upgraded since following the question engine upgrade in Moodle 2.1.

Note: This custom check (and its environment.xml declaration) will be safely removed once we raise min required Moodle version to be 2.7 or newer.

Parameters
environment_resultsobject to update, if relevant.
Return values
environment_resultsupdated results object, or null if this test is not relevant.

◆ StateStack()

StateStack::StateStack ( $start)

Old syntax of class constructor.

Deprecated in PHP7.

Deprecated
since Moodle 3.1

◆ tcpdf_init_k_font_path()

tcpdf_init_k_font_path ( )

Init K_PATH_FONTS and PDF_FONT_NAME_MAIN constant.

Unfortunately this hack is necessary because the constants need to be defined before inclusion of the tcpdf.php file.

◆ tokenise_expand_cjk()

tokenise_expand_cjk ( $matches)

Basic CJK tokeniser.

Simply splits a string into consecutive, overlapping sequences of characters (MINIMUM_WORD_SIZE long).

◆ tokenise_split()

tokenise_split ( $text,
$stop_words,
$overlap_cjk,
$join_numbers )

Some helper functions (should be considered private)

Splits a string into tokens

◆ tokenise_text()

tokenise_text ( $text,
$stop_words = array(),
$overlap_cjk = false,
$join_numbers = false )

This function process the text passed at input, extracting all the tokens and scoring each one based in their number of ocurrences and relation with some well-known html tags.

Parameters
string$textthe text to be tokenised.
array$stop_wordsarray of utf-8 words than can be ignored in the text being processed. There are some cool lists of stop words at http://snowball.tartarus.org/
boolean$overlap_cjkoption to split CJK text into some overlapping tokens is order to allow them to be searched. Useful to build indexes and search systems.
boolean$join_numbersoption to join in one unique token sequences of numbers separated by puntuaction chars. Useful to build indexes and search systems.
Return values
arrayone sorted array of tokens, with tokens being the keys and scores in the values.

◆ tokenise_truncate_word()

tokenise_truncate_word ( & $text)

Helper function for array_walk in search_index_split.

Truncates one string (token) to MAXIMUM_WORD_SIZE

◆ upload()

upload ( stored_file $photo,
array $meta = array() )

Upload a photo from Moodle file pool to Flickr.

Optional meta information are title, description, tags, is_public, is_friend, is_family, safety_level, content_type and hidden {

See also
http://www.flickr.com/services/api/upload.api.html}
Parameters
stored_file$photostored in Moodle file pool
array$metaoptional meta information
Return values
boolean

◆ validateEmailSyntax()

validateEmailSyntax ( $emailaddr,
$options = "" )

About ValidateEmailSyntax(): This function uses the ValidateUrlSyntax() function to easily check the syntax of an email address.

It accepts the same options as ValidateURLSyntax but defaults them for email addresses.

Usage: validateEmailSyntax( url_to_check[, options]) url_to_check - string - The url to check

options - string - A optional string of options to set which parts of the url are required, optional, or not allowed. Each option must be followed by a "+" for required, "?" for optional, or "-" for not allowed. See ValidateUrlSyntax() docs for option list.

The default options are changed to: s-H-S-E+F-u+P-a+I-p-f-q-r-

This only allows an address of "name@domain".

Examples: validateEmailSyntax('georg.nosp@m.e@fa.nosp@m.kemai.nosp@m.l.co.nosp@m.m') validateEmailSyntax('georg.nosp@m.e@fa.nosp@m.kemai.nosp@m.l.co.nosp@m.m', 's+') validateEmailSyntax('georg.nosp@m.e@fa.nosp@m.kemai.nosp@m.l.co.nosp@m.m?subject=Hi%20George', 'q?') validateEmailSyntax('georg.nosp@m.e@21.nosp@m.2.198.nosp@m..33..nosp@m.12', 'I?')

Author(s): Rod Apeldoorn - rod(at)canowhoopass(dot)com

Homepage: http://www.canowhoopass.com/

License: Copyright 2004 - Rod Apeldoorn

Released under same license as validateUrlSyntax(). For details, contact me.

◆ validateFtpSyntax()

validateFtpSyntax ( $ftpaddr,
$options = "" )

About ValidateFtpSyntax(): This function uses the ValidateUrlSyntax() function to easily check the syntax of an FTP address.

It accepts the same options as ValidateURLSyntax but defaults them for FTP addresses.

Usage: validateFtpSyntax( url_to_check[, options]) url_to_check - string - The url to check

options - string - A optional string of options to set which parts of the url are required, optional, or not allowed. Each option must be followed by a "+" for required, "?" for optional, or "-" for not allowed. See ValidateUrlSyntax() docs for option list.

The default options are changed to: s?H-S-E-F+u?P?a+I?p?f?q-r-

Examples: validateFtpSyntax('ftp://netscape.com') validateFtpSyntax('moz:iesuc.nosp@m.ks@n.nosp@m.etsca.nosp@m.pe.c.nosp@m.om') validateFtpSyntax('ftp://netscape.com:2121/browsers/ns7/', 'u-')

Author(s): Rod Apeldoorn - rod(at)canowhoopass(dot)com

Homepage: http://www.canowhoopass.com/

License: Copyright 2004 - Rod Apeldoorn

Released under same license as validateUrlSyntax(). For details, contact me.

Variable Documentation

◆ $publishes

$publishes
Initial value:
= array(
'pf' => array(
'apiversion' => 1,
'classname' => 'portfolio_plugin_mahara',
'filename' => 'lib.php',
'methods' => array(
'fetch_file'
),
),
)

◆ $subscribes

$subscribes
Initial value:
= array(
'pf' => array(
'send_content_intent' => 'portfolio/mahara/lib.php/send_content_intent',
'send_content_ready' => 'portfolio/mahara/lib.php/send_content_ready',
),
)

◆ PREG_CLASS_CJK

const PREG_CLASS_CJK '\x{3041}-\x{30ff}\x{31f0}-\x{31ff}\x{3400}-\x{4db5}'. '\x{4e00}-\x{9fbb}\x{f900}-\x{fad9}'

Matches all CJK characters that are candidates for auto-splitting (Chinese, Japanese, Korean).

Contains kana and BMP ideographs.

◆ PREG_CLASS_SEARCH_EXCLUDE

const PREG_CLASS_SEARCH_EXCLUDE '\x{0}-\x{2f}\x{3a}-\x{40}\x{5b}-\x{60}\x{7b}-\x{bf}\x{d7}\x{f7}\x{2b0}-'. '\x{385}\x{387}\x{3f6}\x{482}-\x{489}\x{559}-\x{55f}\x{589}-\x{5c7}\x{5f3}-'. '\x{61f}\x{640}\x{64b}-\x{65e}\x{66a}-\x{66d}\x{670}\x{6d4}\x{6d6}-\x{6ed}'. '\x{6fd}\x{6fe}\x{700}-\x{70f}\x{711}\x{730}-\x{74a}\x{7a6}-\x{7b0}\x{901}-'. '\x{903}\x{93c}\x{93e}-\x{94d}\x{951}-\x{954}\x{962}-\x{965}\x{970}\x{981}-'. '\x{983}\x{9bc}\x{9be}-\x{9cd}\x{9d7}\x{9e2}\x{9e3}\x{9f2}-\x{a03}\x{a3c}-'. '\x{a4d}\x{a70}\x{a71}\x{a81}-\x{a83}\x{abc}\x{abe}-\x{acd}\x{ae2}\x{ae3}'. '\x{af1}-\x{b03}\x{b3c}\x{b3e}-\x{b57}\x{b70}\x{b82}\x{bbe}-\x{bd7}\x{bf0}-'. '\x{c03}\x{c3e}-\x{c56}\x{c82}\x{c83}\x{cbc}\x{cbe}-\x{cd6}\x{d02}\x{d03}'. '\x{d3e}-\x{d57}\x{d82}\x{d83}\x{dca}-\x{df4}\x{e31}\x{e34}-\x{e3f}\x{e46}-'. '\x{e4f}\x{e5a}\x{e5b}\x{eb1}\x{eb4}-\x{ebc}\x{ec6}-\x{ecd}\x{f01}-\x{f1f}'. '\x{f2a}-\x{f3f}\x{f71}-\x{f87}\x{f90}-\x{fd1}\x{102c}-\x{1039}\x{104a}-'. '\x{104f}\x{1056}-\x{1059}\x{10fb}\x{10fc}\x{135f}-\x{137c}\x{1390}-\x{1399}'. '\x{166d}\x{166e}\x{1680}\x{169b}\x{169c}\x{16eb}-\x{16f0}\x{1712}-\x{1714}'. '\x{1732}-\x{1736}\x{1752}\x{1753}\x{1772}\x{1773}\x{17b4}-\x{17db}\x{17dd}'. '\x{17f0}-\x{180e}\x{1843}\x{18a9}\x{1920}-\x{1945}\x{19b0}-\x{19c0}\x{19c8}'. '\x{19c9}\x{19de}-\x{19ff}\x{1a17}-\x{1a1f}\x{1d2c}-\x{1d61}\x{1d78}\x{1d9b}-'. '\x{1dc3}\x{1fbd}\x{1fbf}-\x{1fc1}\x{1fcd}-\x{1fcf}\x{1fdd}-\x{1fdf}\x{1fed}-'. '\x{1fef}\x{1ffd}-\x{2070}\x{2074}-\x{207e}\x{2080}-\x{2101}\x{2103}-\x{2106}'. '\x{2108}\x{2109}\x{2114}\x{2116}-\x{2118}\x{211e}-\x{2123}\x{2125}\x{2127}'. '\x{2129}\x{212e}\x{2132}\x{213a}\x{213b}\x{2140}-\x{2144}\x{214a}-\x{2b13}'. '\x{2ce5}-\x{2cff}\x{2d6f}\x{2e00}-\x{3005}\x{3007}-\x{303b}\x{303d}-\x{303f}'. '\x{3099}-\x{309e}\x{30a0}\x{30fb}-\x{30fe}\x{3190}-\x{319f}\x{31c0}-\x{31cf}'. '\x{3200}-\x{33ff}\x{4dc0}-\x{4dff}\x{a015}\x{a490}-\x{a716}\x{a802}\x{a806}'. '\x{a80b}\x{a823}-\x{a82b}\x{d800}-\x{f8ff}\x{fb1e}\x{fb29}\x{fd3e}\x{fd3f}'. '\x{fdfc}-\x{fe6b}\x{feff}-\x{ff0f}\x{ff1a}-\x{ff20}\x{ff3b}-\x{ff40}\x{ff5b}-'. '\x{ff65}\x{ff70}\x{ff9e}\x{ff9f}\x{ffe0}-\x{fffd}'

Matches Unicode character classes to exclude from the search index.

See: http://www.unicode.org/Public/UNIDATA/UCD.html#General_Category_Values

The index only contains the following character classes: Lu Letter, Uppercase Ll Letter, Lowercase Lt Letter, Titlecase Lo Letter, Other Nd Number, Decimal Digit No Number, Other