<?php
class GeneralShort implements iTransQR
{
	protected $data;

	function __construct(array $trans = [])
	{
		$this->set_data($trans);
	}

	public function set_data(array $trans = [])
	{
		if (empty($trans))
		{
			return $this;
		}

		$CI =& get_instance();
		$this->data = $CI->load->view("view.php", $trans, TRUE, dirname(__FILE__) . DS . "view.php");

        return $this;
	}

	public function get_content(array $trans = [])
	{
		if (empty($trans))
		{
			return $this->data;
		}

		return $this->set_data($trans)->data;
	}

	public function __toString()
	{
		return $this->get_content();
	}
}
