1 entity_test.entity.inc public TestEntity::uri()
1 field_test.class.inc TestEntity::uri()

Returns the URI elements of the entity.

Return value

array: An array containing the 'path' and 'options' keys used to build the URI of the entity, and matching the signature of url(). An empty array if the entity has no URI of its own.

Overrides EntityInterface::uri

File

core/modules/field/tests/field_test/field_test.class.inc, line 71

Class

TestEntity
Test class for the test_entity entity type.

Code

function uri() {
  return array(
    'path' => 'test/' . $this->id,
  );
}