Open Badges Assertions specification 1.0 https://github.com/mozilla/openbadges/wiki/Assertions
More...
Open Badges Assertions specification 1.0 https://github.com/mozilla/openbadges/wiki/Assertions
Badge asserion is defined by three parts:
- Badge Assertion (information regarding a specific badge that was awarded to a badge earner)
- Badge Class (general information about a badge and what it is intended to represent)
- Issuer Class (general information of an issuing organisation) Class that represents badge assertion.
◆ __construct()
core_badges_assertion::__construct |
( |
|
$hash, |
|
|
|
$obversion = OPEN_BADGES_V1 |
|
) |
| |
Constructs with issued badge unique hash.
- Parameters
-
string | $hash | Badge unique hash from badge_issued table. |
int | $obversion | to control version JSON-LD. |
◆ embed_data_badge_version2()
core_badges_assertion::embed_data_badge_version2 |
( |
& |
$json, |
|
|
|
$type = OPEN_BADGES_V2_TYPE_ASSERTION |
|
) |
| |
|
protected |
Embed data of Open Badges Specification Version 2.0 to json.
- Parameters
-
array | $json | for assertion, badges, issuer. |
string | $type | Content type. |
◆ get_alignments()
core_badges_assertion::get_alignments |
( |
| ) |
|
Get alignment of the badge.
- Return values
-
◆ get_assertion_hash()
core_badges_assertion::get_assertion_hash |
( |
| ) |
|
Get the local id for this badge assertion.
- Return values
-
◆ get_badge_assertion()
core_badges_assertion::get_badge_assertion |
( |
|
$issued = true , |
|
|
|
$usesalt = true |
|
) |
| |
Get badge assertion.
- Parameters
-
boolean | $issued | Include the nested badge issued information. |
boolean | $usesalt | Hash the identity and include the salt information for the hash. |
- Return values
-
◆ get_badge_class()
core_badges_assertion::get_badge_class |
( |
|
$issued = true | ) |
|
Get badge class information.
- Parameters
-
boolean | $issued | Include the nested badge issuer information. |
- Return values
-
array | Badge Class information. |
◆ get_badge_id()
core_badges_assertion::get_badge_id |
( |
| ) |
|
Get the local id for this badge.
- Return values
-
◆ get_criteria_badge_class()
core_badges_assertion::get_criteria_badge_class |
( |
| ) |
|
Get criteria of badge class.
- Return values
-
array|string | Criteria information. |
◆ get_endorsement()
core_badges_assertion::get_endorsement |
( |
| ) |
|
Get endorsement of the badge.
- Return values
-
false|stdClass | Endorsement information. |
◆ get_issuer()
core_badges_assertion::get_issuer |
( |
| ) |
|
Get badge issuer information.
- Return values
-
◆ get_related_badges()
core_badges_assertion::get_related_badges |
( |
badge |
$badge | ) |
|
Get related badges of the badge.
- Parameters
-
- Return values
-
array|bool | List related badges. |
The documentation for this class was generated from the following file: