Page Menu
Home
Phabricator (Chris)
Search
Configure Global Search
Log In
Files
F621103
Command.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
Unknown
Size
1 KB
Referenced Files
None
Subscribers
None
Command.php
View Options
<?php
/*
* This file is part of the TelegramBot package.
*
* (c) Avtandil Kikabidze aka LONGMAN <akalongman@gmail.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace
Longman
\
TelegramBot
;
use
Longman
\
TelegramBot
\
Entities
\
Update
;
abstract
class
Command
{
protected
$telegram
;
protected
$update
;
protected
$message
;
protected
$command
;
protected
$description
=
'Command help'
;
protected
$usage
=
'Command usage'
;
protected
$version
=
'1.0.0'
;
protected
$enabled
=
true
;
protected
$name
=
''
;
public
function
__construct
(
Telegram
$telegram
)
{
$this
->
telegram
=
$telegram
;
}
public
function
setUpdate
(
Update
$update
)
{
$this
->
update
=
$update
;
$this
->
message
=
$this
->
update
->
getMessage
(
)
;
return
$this
;
}
public
abstract
function
execute
(
)
;
public
function
getUpdate
(
)
{
return
$this
->
update
;
}
public
function
getMessage
(
)
{
return
$this
->
message
;
}
public
function
getTelegram
(
)
{
return
$this
->
telegram
;
}
public
function
setCommand
(
$command
)
{
$this
->
command
=
$command
;
return
$this
;
}
public
function
getUsage
(
)
{
return
$this
->
usage
;
}
public
function
getVersion
(
)
{
return
$this
->
version
;
}
public
function
getDescription
(
)
{
return
$this
->
description
;
}
public
function
getName
(
)
{
return
$this
->
name
;
}
public
function
isEnabled
(
)
{
return
$this
->
enabled
;
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Sat, Nov 14, 6:45 PM (18 h, 5 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
132336
Default Alt Text
Command.php (1 KB)
Attached To
Mode
R123 php-telegram-bot
Attached
Detach File
Event Timeline