Moodle APIs  3.8
Moodle 3.8.6 (Build: 20201109)
Public Member Functions | Public Attributes | List of all members
mnet_peer Class Reference

Public Member Functions

 bootstrap ($wwwroot, $pubkey=null, $application)
 
 check_common_name ($key)
 
 check_credentials ($key)
 
 commit ()
 
 count_live_sessions ()
 
 delete ()
 
 delete_all_sessions ()
 
 delete_expired_sessions ()
 
 get_public_key ()
 
 populate ($hostinfo)
 Several methods can be used to get an 'mnet_host' record. More...
 
 set_applicationid ($applicationid)
 
 set_id ($id)
 
 set_name ($newname)
 
 set_wwwroot ($wwwroot)
 Load information from db about an mnet peer into this object's properties. More...
 
 touch ()
 

Public Attributes

 $applicationid = 1
 
 $bootstrapped = false
 
 $error = array()
 
 $force_theme = 0
 
 $id = 0
 
 $ip_address = ''
 
 $keypair = array()
 
 $last_connect_time = 0
 
 $last_log_id = 0
 
 $name = ''
 
 $public_key = ''
 
 $public_key_expires = 0
 
int $sslverification = self::SSL_HOST_AND_PEER
 $sslverification The level of SSL verification to apply.
 
 $theme = ''
 
 $wwwroot = ''
 
const SSL_HOST = 1
 SSL verification for host.
 
const SSL_HOST_AND_PEER = 2
 SSL verification for host and peer.
 
const SSL_NONE = 0
 No SSL verification.
 

Member Function Documentation

◆ populate()

mnet_peer::populate (   $hostinfo)

Several methods can be used to get an 'mnet_host' record.

They all then send it to this private method to populate this object's attributes.

Parameters
object$hostinfoA database record from the mnet_host table
Return values
void

◆ set_wwwroot()

mnet_peer::set_wwwroot (   $wwwroot)

Load information from db about an mnet peer into this object's properties.

Parameters
string$wwwroot- address of peer whose details we want to load
Return values
bool- indication of success or failure

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