Example: Entity

Example creating a core Entity API entity.

Note that this example does not use or demonstrate the contrib Entity API, which you can find here: http://drupal.org/project/entity

Parent topics

File

entity_example/entity_example.module, line 20

Functions

Title Sort descending File name Summary
entity_example_basic_add entity_example/entity_example.module Provides a wrapper on the edit form to add a new entity.
entity_example_basic_delete entity_example/entity_example.module Use the controller to delete the entity.
entity_example_basic_edit_delete entity_example/entity_example.module Form deletion handler.
entity_example_basic_form entity_example/entity_example.module Form function to create an entity_example_basic entity.
entity_example_basic_form_submit entity_example/entity_example.module Form submit handler: Submits basic_add_form information.
entity_example_basic_form_validate entity_example/entity_example.module Validation handler for entity_example_basic_add_form form.
entity_example_basic_list_entities entity_example/entity_example.module Returns a render array with all entity_example_basic entities.
entity_example_basic_load entity_example/entity_example.module Fetch a basic object.
entity_example_basic_load_multiple entity_example/entity_example.module Loads multiple basic entities.
entity_example_basic_save entity_example/entity_example.module We save the entity by calling the controller.
entity_example_basic_title entity_example/entity_example.module Callback for a page title when this entity is displayed.
entity_example_basic_uri entity_example/entity_example.module Implements the uri callback.
entity_example_basic_view entity_example/entity_example.module Menu callback to display an entity.
entity_example_entity_info entity_example/entity_example.module Implements hook_entity_info().
entity_example_field_extra_fields entity_example/entity_example.module Implements hook_field_extra_fields().
entity_example_info_page entity_example/entity_example.module Basic information for the page.
entity_example_menu entity_example/entity_example.module Implements hook_menu().
entity_example_permission entity_example/entity_example.module Implements hook_permission().
entity_example_schema entity_example/entity_example.install Implements hook_schema().
entity_example_uninstall entity_example/entity_example.install Implements hook_uninstall().

Classes

Title Sort descending File name Summary
EntityExampleBasicController entity_example/entity_example.module EntityExampleBasicController extends DrupalDefaultEntityController.
EntityExampleTestCase entity_example/entity_example.test Functionality tests for entity example module.

Interfaces

Title Sort descending File name Summary
EntityExampleBasicControllerInterface entity_example/entity_example.module EntityExampleBasicControllerInterface definition.