You are here

function mongodb_block_ui_load in MongoDB 7

Loads a block object.

Parameters

string $delta: Unique ID of the block.

Return value

array|null A document for the block of null if none was found.

Throws

\MongoConnectionException

\MongoException

\MongoWriteConcernException

3 calls to mongodb_block_ui_load()
mongodb_block_ui_admin_configure in mongodb_block_ui/mongodb_block_ui.admin.inc
Menu callback; displays the mongodb_block_ui configuration form.
mongodb_block_ui_block_view in mongodb_block_ui/mongodb_block_ui.module
Implements hook_block_view().
mongodb_block_ui_custom_block_delete in mongodb_block_ui/mongodb_block_ui.admin.inc
Menu callback; confirm deletion of custom block.

File

mongodb_block_ui/mongodb_block_ui.module, line 207
Controls the visual building mongodb_block_uis a page is constructed with.

Code

function mongodb_block_ui_load($delta) {
  return mongodb_collection('block_custom')
    ->findOne(array(
    '_id' => (string) $delta,
  ));
}