Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F6067555
ContributeCardAction.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
2 KB
Referenced Files
None
Subscribers
None
ContributeCardAction.php
View Options
<?php
/**
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License along
* with this program; if not, write to the Free Software Foundation, Inc.,
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
* http://www.gnu.org/copyleft/gpl.html
*
* @file
*/
namespace
MediaWiki\Specials\Contribute\Card
;
class
ContributeCardAction
{
private
string
$action
;
private
string
$actionText
;
private
string
$actionType
;
/**
* @param string $action the action's url or command to be attached to card element
* @param string $actionText the action's text to be shown on the bottom of the card element
* @param string $actionType the action's type, specifying if it is a url or a function, ...
*/
public
function
__construct
(
string
$action
,
string
$actionText
,
string
$actionType
)
{
$this
->
action
=
$action
;
$this
->
actionText
=
$actionText
;
$this
->
actionType
=
$actionType
;
}
/**
* @return string
*/
public
function
getActionType
():
string
{
return
$this
->
actionType
;
}
/**
* @return string
*/
public
function
getAction
():
string
{
return
$this
->
action
;
}
/**
* @return string
*/
public
function
getActionText
():
string
{
return
$this
->
actionText
;
}
/**
* @param string $action
*/
public
function
setAction
(
string
$action
):
void
{
$this
->
action
=
$action
;
}
/**
* @param string $actionText
*/
public
function
setActionText
(
string
$actionText
):
void
{
$this
->
actionText
=
$actionText
;
}
/**
* @return array
*/
public
function
toArray
():
array
{
return
[
'action'
=>
$this
->
action
,
'actionText'
=>
$this
->
actionText
,
'actionType'
=>
$this
->
actionType
,
];
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Oct 5 2026, 05:16 (6 w, 9 h ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
b1/0f/73ba2994d6a462c69194c65152ce
Default Alt Text
ContributeCardAction.php (2 KB)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment