You are here

public function ServicesRESTServerFactory::getRESTServer in Services 7.3

File

servers/rest_server/includes/ServicesRESTServerFactory.inc, line 26

Class

ServicesRESTServerFactory
Factory class to build RESTServer object.

Code

public function getRESTServer() {
  $content_type_negotiator = $this
    ->getContentTypeNegotiator();
  $context = $this
    ->getContext();
  $resources = $this
    ->getResources();
  $parsers = $this
    ->getParsers();
  $formatters = $this
    ->getFormatters();
  $class_name = static::$class_name;
  return new $class_name($context, $content_type_negotiator, $resources, $parsers, $formatters);
}