Skip to content

Instantly share code, notes, and snippets.

@aohorodnyk
Created July 5, 2015 11:14
Show Gist options
  • Save aohorodnyk/b89d1c9dcef438617a53 to your computer and use it in GitHub Desktop.
Save aohorodnyk/b89d1c9dcef438617a53 to your computer and use it in GitHub Desktop.
<?php
/**
* Copyright © 2015 Magento. All rights reserved.
* See COPYING.txt for license details.
*/
namespace Magento\CatalogSearch\Model;
use Magento\CatalogSearch\Api\Data\DocumentInterface;
use Magento\Framework\Api\AbstractSimpleObject;
class Document extends AbstractSimpleObject implements DocumentInterface
{
/**
* {@inheritdoc}
*/
public function getId()
{
return $this->_get(self::ID);
}
/**
* {@inheritdoc}
*/
public function setId($id)
{
return $this->_set(self::ID, $id);
}
/**
* {@inheritdoc}
*/
public function getData()
{
$this->_get(self::DATA);
}
/**
* {@inheritdoc}
*/
public function setData($data)
{
return $this->_set(self::DATA, $data);
}
/**
* Set value for the given key
*
* @param string $key
* @param mixed $value
* @return $this
*/
protected function _set($key, $value)
{
return parent::setData($key, $value);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment