Moodle APIs 4.3
Moodle 4.3.6 (Build: 20240812)
core_badges

Topics

 external
 
 

Namespaces

namespace  core_badges
 Communicate with backpacks.
 
namespace  core_badges\external
 Contains alignment class for displaying a badge alignment.
 
namespace  core_badges\form
 Form class for mybackpack.php.
 
namespace  core_badges\oauth2
 This file to proccess Oauth2 connects for backpack.
 
namespace  core_badges\output
 Issued badge renderable.
 
namespace  core_badges\privacy
 Data provider.
 
namespace  core_badges\reportbuilder\datasource
  
 
namespace  core_badges\reportbuilder\local\entities
  
 
namespace  core_badges\reportbuilder\local\systemreports
  
 

Classes

class  behat_core_badges_generator
 Badges test generator for Behat. More...
 
class  core_badges\backpack_api
 Class for communicating with backpacks. More...
 
class  core_badges\backpack_api2p1
 To process badges with backpack and control api request and this class using for Open Badge API v2.1 methods. More...
 
class  core_badges\backpack_api2p1_mapping
 Represent a single method for the remote api and this class using for Open Badge API v2.1 methods. More...
 
class  core_badges\backpack_api_mapping
 Represent a single method for the remote api. More...
 
class  core_badges\external\alignment_exporter
 Class for displaying a badge alignment. More...
 
class  core_badges\external\assertion_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\backpack_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\badgeclass_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\collection_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\endorsement_exporter
 Class for displaying a badge endorsement. More...
 
class  core_badges\external\issuer_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\recipient_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\external\related_info_exporter
 Class for displaying information of a related badge. More...
 
class  core_badges\external\user_badge_exporter
 Class for displaying a badge issued to a user. More...
 
class  core_badges\external\verification_exporter
 Class for displaying a badge competency. More...
 
class  core_badges\form\external_backpack
 Backpack form class. More...
 
class  core_badges\oauth2\auth
 Proccess Oauth2 connects to backpack site. More...
 
class  core_badges\oauth2\badge_backpack_oauth2
 Class badge_backpack_oauth2 for backpack is connected. More...
 
class  core_badges\oauth2\client
 Configurable OAuth2 client to request authorization and store token. More...
 
class  core_badges\output\badgeclass
 Page to display badge information, such as name, description or criteria. More...
 
class  core_badges\output\base_action_bar
 Abstract class for the badges tertiary navigation. More...
 
class  core_badges\output\external_backpacks_page
 Manage enabled backpacks renderable. More...
 
class  core_badges\output\external_backpacks_table
 Backpacks table class. More...
 
class  core_badges\output\manage_badge_action_bar
 Class manage_badge_action_bar - Display the action bar. More...
 
class  core_badges\output\recipients_action_bar
 Class recipients_action_bar - Display the action bar. More...
 
class  core_badges\output\standard_action_bar
 Class standard_action_bar - Display the action bar. More...
 
class  core_badges\privacy\provider
 Data provider class. More...
 
class  core_badges\reportbuilder\datasource\badges
 Badges datasource. More...
 
class  core_badges\reportbuilder\datasource\users
 User badges datasource. More...
 
class  core_badges\reportbuilder\local\entities\badge
 Badge entity. More...
 
class  core_badges\reportbuilder\local\entities\badge_issued
 Badge issued entity. More...
 
class  core_badges\reportbuilder\local\systemreports\badges
 Badges system report class implementation. More...
 
class  core_badges_generator
 Badges test generator. More...
 
class  core_badges_observer
 Event observer for badges. More...
 

Functions

 badge_get_tagged_badges (object $tag, bool $exclusivemode=false, null|int $fromctx=0, null|int $ctx=0, bool $rec=true, int $page=0)
 Returns badges tagged with a specified tag.
 
 badges_install_default_backpacks ()
 Called on install or upgrade to create default list of backpacks a user can connect to.
 
 core_badges_myprofile_navigation (\core_user\output\myprofile\tree $tree, $user, $iscurrentuser, $course)
 Add nodes to myprofile page.
 

Variables

global $CFG
 
global core_badges::$CFG
 
global core_badges\reportbuilder\local\entities::$CFG
 
global core_badges\reportbuilder\local\systemreports::$CFG
 
const core_badges\oauth2::BACKPACK_CHALLENGE_METHOD 'S256'
 
const core_badges\oauth2::BACKPACK_CODE_VERIFIER_TIME 60
 
const core_badges::BADGE_ACCESS_TOKEN 'access'
 
const core_badges::BADGE_BACKPACK_ID_TOKEN 'backpack_id'
 
const core_badges::BADGE_EXPIRES_TOKEN 'expires'
 
const core_badges::BADGE_REFRESH_TOKEN 'refresh'
 
const core_badges::BADGE_USER_ID_TOKEN 'user_id'
 

Detailed Description

Function Documentation

◆ badge_get_tagged_badges()

badge_get_tagged_badges ( object $tag,
bool $exclusivemode = false,
null|int $fromctx = 0,
null|int $ctx = 0,
bool $rec = true,
int $page = 0 )

Returns badges tagged with a specified tag.

Parameters
object$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
null | int$fromctxcontext id where the link was displayed, may be used by callbacks to display items in the same context first
null | 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

◆ badges_install_default_backpacks()

badges_install_default_backpacks ( )

Called on install or upgrade to create default list of backpacks a user can connect to.

Don't use the global defines from badgeslib because this is for install/upgrade.

Return values
void

◆ core_badges_myprofile_navigation()

core_badges_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