You are here

AutocompleteController.php in Zircon Profile 8.0

Namespace

Drupal\form_test

File

core/modules/system/tests/modules/form_test/src/AutocompleteController.php
View source
<?php

/**
 * @file
 * Contains \Drupal\form_test\AutocompleteController.
 */
namespace Drupal\form_test;

use Symfony\Component\HttpFoundation\JsonResponse;

/**
 * Defines a controller class with methods for autocompletion.
 */
class AutocompleteController {

  /**
   * Returns some autocompletion content.
   *
   * @return \Symfony\Component\HttpFoundation\JsonResponse
   *   A JSON response.
   */
  public function autocomplete1() {
    return new JsonResponse(array(
      'key' => 'value',
    ));
  }

}

Classes

Namesort descending Description
AutocompleteController Defines a controller class with methods for autocompletion.