MediaWiki REL1_31
OATHUser.php
Go to the documentation of this file.
1<?php
24class OATHUser {
26 private $user;
27
29 private $key;
30
36 public function __construct( User $user, OATHAuthKey $key = null ) {
37 $this->user = $user;
38 $this->key = $key;
39 }
40
44 public function getUser() {
45 return $this->user;
46 }
47
51 public function getIssuer() {
52 global $wgSitename, $wgOATHAuthAccountPrefix;
53 if ( $wgOATHAuthAccountPrefix !== false ) {
54 return $wgOATHAuthAccountPrefix;
55 }
56 return $wgSitename;
57 }
58
62 public function getAccount() {
63 return $this->user->getName();
64 }
65
71 public function getKey() {
72 return $this->key;
73 }
74
80 public function setKey( OATHAuthKey $key = null ) {
81 $this->key = $key;
82 }
83}
$wgSitename
Name of the site.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU Ge...
This program is free software; you can redistribute it and/or modify it under the terms of the GNU Ge...
Definition OATHUser.php:24
User $user
Definition OATHUser.php:26
getAccount()
Definition OATHUser.php:62
getKey()
Get the key associated with this user.
Definition OATHUser.php:71
__construct(User $user, OATHAuthKey $key=null)
Constructor.
Definition OATHUser.php:36
OATHAuthKey null $key
Definition OATHUser.php:29
getIssuer()
Definition OATHUser.php:51
setKey(OATHAuthKey $key=null)
Set the key associated with this user.
Definition OATHUser.php:80
The User object encapsulates all of the user-specific settings (user_id, name, rights,...
Definition User.php:53
design txt This is a brief overview of the new design More thorough and up to date information is available on the documentation wiki at etc Handles the details of getting and saving to the user table of the and dealing with sessions and cookies OutputPage Encapsulates the entire HTML page that will be sent in response to any server request It is used by calling its functions to add in any and then calling but I prefer the flexibility This should also do the output encoding The system allocates a global one in $wgOut Title Represents the title of an and does all the work of translating among various forms such as plain database key
Definition design.txt:26