You are here

WSEncoderBase.php in Web Service Data 8

Same filename and directory in other branches
  1. 2.0.x src/Plugin/WSEncoderBase.php

File

src/Plugin/WSEncoderBase.php
View source
<?php

namespace Drupal\wsdata\Plugin;

use Drupal\Component\Plugin\PluginBase;

/**
 * Base class for Web Service Encoder plugins.
 */
abstract class WSEncoderBase extends PluginBase implements WSEncoderInterface {

  /**
   * Encode data into format just sending it off.
   */
  public abstract function encode(&$data, &$replacement, &$url);

  /**
   * Returns whether or not the result on the encoder are cacheable.
   */
  public function isCacheable() {
    return TRUE;
  }

}

Classes

Namesort descending Description
WSEncoderBase Base class for Web Service Encoder plugins.