You are here

ScopeIndentUnitTest.inc in Coder 8.2

File

coder_sniffer/Drupal/Test/WhiteSpace/ScopeIndentUnitTest.inc
View source
<?php

// Test correct indenting of trait conflict resolution.
class MyClass {
  use MyTrait {
    myTraitMethod as renamedTraitMethod;
  }

}
setTimeout(function () {
  $timer = parseInt($target, 10);
  if (timer > 0) {
    $target--;
  }
  else {

    // <dt>.
    $kint
      ->toggleChildren(target . parentNode);
    if ($kint->currentPlus !== -1) {
      $kint
        ->fetchVisiblePluses();
    }
  }
}, 300);

/**
 * Implements hook_field_formatter_view().
 */
function example_field_formatter_view($entity_type, $entity, $field, $instance, $langcode, $items, $display) {
  $element = array();
  switch ($display['type']) {
    case 'example_schema_format':
      foreach ($items as $delta => $item) {
        $element[$delta]['#markup'] = theme('example_formatter_default', $item);
      }
      break;
  }
  return $element;
}

Functions

Namesort descending Description
example_field_formatter_view Implements hook_field_formatter_view().

Classes

Namesort descending Description
MyClass