Moodle PHP Documentation 4.3
Moodle 4.3.5 (Build: 20240610) (7dcfaa79f78)
gradereport_singleview\local\ui\checkbox_attribute Class Reference

A checkbox ui element. More...

Inheritance diagram for gradereport_singleview\local\ui\checkbox_attribute:
gradereport_singleview\local\ui\element

Public Member Functions

 __construct (string $name, string $label, bool $ischecked=false, int $locked=0, bool $isreadonly=false)
 Constructor.
 
 html ()
 Generate the HTML.
 
 is_checkbox ()
 Nasty function allowing checkbox logic to escape the class.
 
 is_dropdown ()
 Nasty function used for spreading dropdown logic all around.
 
 is_textbox ()
 Nasty function used for spreading textbox logic all around.
 

Public Attributes

string $label
 The form label for this input.
 
string $name
 The first bit of the name for this input.
 
string $value
 The value for this input.
 

Protected Attributes

int int $locked
 Is this element locked either 0 or a time.
 

Detailed Description

A checkbox ui element.

License
http://www.gnu.org/copyleft/gpl.html GNU GPL v3 or later

Constructor & Destructor Documentation

◆ __construct()

gradereport_singleview\local\ui\checkbox_attribute::__construct ( string $name,
string $label,
bool $ischecked = false,
int $locked = 0,
bool $isreadonly = false )

Constructor.

Parameters
string$nameThe element name
string$labelThe label for the form element
bool$ischeckedIs this thing on?
int$lockedIs this element locked either 0 or a time.
bool$isreadonlyIf this is a read-only input.

Member Function Documentation

◆ html()

gradereport_singleview\local\ui\checkbox_attribute::html ( )

Generate the HTML.

Return values
string

Reimplemented from gradereport_singleview\local\ui\element.

◆ is_checkbox()

gradereport_singleview\local\ui\checkbox_attribute::is_checkbox ( )

Nasty function allowing checkbox logic to escape the class.

Return values
bool

Reimplemented from gradereport_singleview\local\ui\element.

◆ is_dropdown()

gradereport_singleview\local\ui\element::is_dropdown ( )
inherited

Nasty function used for spreading dropdown logic all around.

Return values
bool

Reimplemented in gradereport_singleview\local\ui\dropdown_attribute.

◆ is_textbox()

gradereport_singleview\local\ui\element::is_textbox ( )
inherited

Nasty function used for spreading textbox logic all around.

Return values
bool

Reimplemented in gradereport_singleview\local\ui\text_attribute.

Member Data Documentation

◆ $label

string gradereport_singleview\local\ui\element::$label
inherited

The form label for this input.

$label

◆ $name

string gradereport_singleview\local\ui\element::$name
inherited

The first bit of the name for this input.

$name

◆ $value

string gradereport_singleview\local\ui\element::$value
inherited

The value for this input.

$value


The documentation for this class was generated from the following file: