<?php
/**
 * @copyright (c) Kufer Software GmbH, Loisachstrasse 4, D-84453 Mühldorf
 */

namespace Kufer\KuferTools\Utils\StatusMessages;

class StatusMessage
{
  
  protected $msgBoxType;
  protected $message;

  public function __construct($pMsgBoxType, $pMessage)
  {
    $this->msgBoxType = $pMsgBoxType;
    $this->message = $pMessage;
  }

  public function getMessageBoxType()
  {
    return $this->msgBoxType;
  }

  public function getStatusMessage()
  {
    return $this->message;
  }

  
  public static function getErrorMessageObj($pMessage)
  {
    return new StatusMessage(MSG_BOX_ERROR, $pMessage);
  }

  public static function getSuccessMessageObj($pMessage)
  {
    return new StatusMessage(MSG_BOX_SUCCESS, $pMessage);
  }

  public static function getWarningMessageObj($pMessage)
  {
    return new StatusMessage(MSG_BOX_WARNING, $pMessage);
  }

  public static function getInfoMessageObj($pMessage)
  {
    return new StatusMessage(MSG_BOX_INFO, $pMessage);
  }
}