메시지 클래스 새로 작성

This commit is contained in:
2018-04-10 02:38:36 +09:00
parent 50d1c4cd34
commit 2404ab2047
6 changed files with 455 additions and 42 deletions
+28
View File
@@ -0,0 +1,28 @@
<?php
namespace sammo;
class DiplomacticMessage extends Message{
public function __construct(
string $msgType,
MessageTarget $src,
MessageTarget $dest,
string $msg,
\DateTime $date,
\DateTime $validUntil,
array $msgOption
)
{
if ($msgType !== self::MSGTYPE_DIPLOMACY){
throw new \InvalidArgumentException('DiplomaticMessage msgType');
}
parent::__construct(...func_get_args());
//TODO: 누가, 누구에게 보낸 건지 파싱
}
public function send(){
parent::send();
}
}