diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockFormController.php b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockFormController.php
index d64e3de..3e1ff40 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockFormController.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockFormController.php
@@ -27,11 +27,11 @@ class CustomBlockFormController extends EntityFormControllerNG {
   protected function prepareEntity() {
     $block = $this->entity;
     // Set up default values, if required.
-    $block_type = entity_load('custom_block_type', $block->type->value);
-    // If this is a new custom block, fill in the default values.
-    if (isset($block->id->value)) {
-      $block->set('log', NULL);
+    if (!$block->isNew()) {
+      $block->setRevisionLog(NULL);
     }
+
+    $block_type = entity_load('custom_block_type', $block->bundle());
     // Always use the default revision setting.
     $block->setNewRevision($block_type->revision);
   }
@@ -49,27 +49,30 @@ public function form(array $form, array &$form_state) {
     // Override the default CSS class name, since the user-defined custom block
     // type name in 'TYPE-block-form' potentially clashes with third-party class
     // names.
-    $form['#attributes']['class'][0] = drupal_html_class('block-' . $block->type->value . '-form');
+    $form['#attributes']['class'][0] = drupal_html_class('block-' . $block->bundle() . '-form');
 
     // Basic block information.
     // These elements are just values so they are not even sent to the client.
-    foreach (array('revision_id', 'id') as $key) {
-      $form[$key] = array(
-        '#type' => 'value',
-        '#value' => $block->$key->value,
-      );
-    }
+    $form['id'] = array(
+      '#type' => 'value',
+      '#value' => $block->id(),
+    );
+
+    $form['revision_id'] = array(
+      '#type' => 'value',
+      '#value' => $block->getRevisionId(),
+    );
 
     $form['info'] = array(
       '#type' => 'textfield',
       '#title' => t('Block description'),
       '#required' => TRUE,
-      '#default_value' => $block->info->value,
+      '#default_value' => $block->label(),
       '#weight' => -5,
       '#description' => t('A brief description of your block. Used on the <a href="@overview">Blocks administration page</a>.', array('@overview' => url('admin/structure/block'))),
     );
 
-    $language_configuration = module_invoke('language', 'get_default_configuration', 'custom_block', $block->type->value);
+    $language_configuration = module_invoke('language', 'get_default_configuration', 'custom_block', $block->bundle());
 
     // Set the correct default language.
     if ($block->isNew() && !empty($language_configuration['langcode'])) {
@@ -131,7 +134,7 @@ public function form(array $form, array &$form_state) {
       '#type' => 'textarea',
       '#title' => t('Revision log message'),
       '#rows' => 4,
-      '#default_value' => $block->log->value,
+      '#default_value' => $block->getRevisionLog(),
       '#description' => t('Briefly describe the changes you have made.'),
     );
 
@@ -164,10 +167,10 @@ public function submit(array $form, array &$form_state) {
    */
   public function save(array $form, array &$form_state) {
     $block = $this->entity;
-    $insert = empty($block->id->value);
+    $insert = $block->isNew();
     $block->save();
     $watchdog_args = array('@type' => $block->bundle(), '%info' => $block->label());
-    $block_type = entity_load('custom_block_type', $block->type->value);
+    $block_type = entity_load('custom_block_type', $block->bundle());
     $t_args = array('@type' => $block_type->label(), '%info' => $block->label());
 
     if ($insert) {
@@ -179,15 +182,15 @@ public function save(array $form, array &$form_state) {
       drupal_set_message(t('@type %info has been updated.', $t_args));
     }
 
-    if ($block->id->value) {
-      $form_state['values']['id'] = $block->id->value;
-      $form_state['id'] = $block->id->value;
+    if ($block->id()) {
+      $form_state['values']['id'] = $block->id();
+      $form_state['id'] = $block->id();
       if ($insert) {
         if ($theme = $block->getTheme()) {
-          $form_state['redirect'] = 'admin/structure/block/add/custom_block:' . $block->uuid->value . '/' . $theme;
+          $form_state['redirect'] = 'admin/structure/block/add/custom_block:' . $block->uuid() . '/' . $theme;
         }
         else {
-          $form_state['redirect'] = 'admin/structure/block/add/custom_block:' . $block->uuid->value . '/' . \Drupal::config('system.theme')->get('default');
+          $form_state['redirect'] = 'admin/structure/block/add/custom_block:' . $block->uuid() . '/' . \Drupal::config('system.theme')->get('default');
         }
       }
       else {
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockInterface.php b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockInterface.php
index 9343c15..081656e 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockInterface.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockInterface.php
@@ -16,6 +16,30 @@
 interface CustomBlockInterface extends ContentEntityInterface, EntityChangedInterface {
 
   /**
+   * Returns the block revision log message.
+   *
+   * @return string
+   *   The revision log message.
+   */
+  public function getRevisionLog();
+
+  /**
+   * Sets the block description.
+   *
+   * @param string info
+   *   The block description.
+   */
+  public function setInfo($info);
+
+  /**
+   * Sets the block revision log message.
+   *
+   * @param string $log
+   *   The revision log message.
+   */
+  public function setRevisionLog($log);
+
+  /**
    * Sets the theme value.
    *
    * When creating a new custom block from the block library, the user is
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockRenderController.php b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockRenderController.php
index 3457115..d07a34d 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockRenderController.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockRenderController.php
@@ -22,7 +22,7 @@ class CustomBlockRenderController extends EntityRenderController {
   protected function alterBuild(array &$build, EntityInterface $entity, EntityDisplay $display, $view_mode, $langcode = NULL) {
     parent::alterBuild($build, $entity, $display, $view_mode, $langcode);
     // Add contextual links for this custom block.
-    if (!empty($entity->id->value) && $view_mode == 'full') {
+    if (!$entity->isNew() && $view_mode == 'full') {
       $build['#contextual_links']['custom_block'] = array('block', array($entity->id()));
     }
   }
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockTranslationController.php b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockTranslationController.php
index 4436f57..34bc66e 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockTranslationController.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/CustomBlockTranslationController.php
@@ -36,7 +36,7 @@ public function entityFormAlter(array &$form, array &$form_state, EntityInterfac
    * Overrides ContentTranslationController::entityFormTitle().
    */
   protected function entityFormTitle(EntityInterface $entity) {
-    $block_type = entity_load('custom_block_type', $entity->type->value);
+    $block_type = entity_load('custom_block_type', $entity->bundle());
     return t('<em>Edit @type</em> @title', array('@type' => $block_type->label(), '@title' => $entity->label()));
   }
 
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Entity/CustomBlock.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Entity/CustomBlock.php
index 2044050..cd5e776 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Entity/CustomBlock.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Entity/CustomBlock.php
@@ -56,64 +56,32 @@
 class CustomBlock extends EntityNG implements CustomBlockInterface {
 
   /**
-   * The block ID.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
-   */
-  public $id;
-
-  /**
-   * The block revision ID.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
-   */
-  public $revision_id;
-
-  /**
-   * Indicates whether this is the default block revision.
-   *
-   * The default revision of a block is the one loaded when no specific revision
-   * has been specified. Only default revisions are saved to the block_custom
-   * table.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
-   */
-  public $isDefaultRevision = TRUE;
-
-  /**
-   * The block UUID.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
-   */
-  public $uuid;
-
-  /**
-   * The custom block type (bundle).
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
+   * {@inheritdoc}
    */
-  public $type;
+  public function getRevisionId() {
+    return $this->get('revision_id')->value;
+  }
 
   /**
-   * The block language code.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
+   * {@inheritdoc}
    */
-  public $langcode;
+  public function getRevisionLog() {
+    return $this->get('log')->value;
+  }
 
   /**
-   * The block description.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
+   * {@inheritdoc}
    */
-  public $info;
+  public function setInfo($info) {
+    return $this->set('info', $info);
+  }
 
   /**
-   * The block revision log message.
-   *
-   * @var \Drupal\Core\Entity\Field\FieldInterface
+   * {@inheritdoc}
    */
-  public $log;
+  public function setRevisionLog($log) {
+    return $this->set('log', $log);
+  }
 
   /**
    * The theme the block is being created in.
@@ -129,23 +97,6 @@ class CustomBlock extends EntityNG implements CustomBlockInterface {
   /**
    * {@inheritdoc}
    */
-  public function createDuplicate() {
-    $duplicate = parent::createDuplicate();
-    $duplicate->revision_id->value = NULL;
-    $duplicate->id->value = NULL;
-    return $duplicate;
-  }
-
-  /**
-   * {@inheritdoc}
-   */
-  public function getRevisionId() {
-    return $this->revision_id->value;
-  }
-
-  /**
-   * {@inheritdoc}
-   */
   public function setTheme($theme) {
     $this->theme = $theme;
   }
@@ -158,23 +109,6 @@ public function getTheme() {
   }
 
   /**
-   * Initialize the object. Invoked upon construction and wake up.
-   */
-  protected function init() {
-    parent::init();
-    // We unset all defined properties except theme, so magic getters apply.
-    // $this->theme is a special use-case that is only used in the lifecycle of
-    // adding a new block using the block library.
-    unset($this->id);
-    unset($this->info);
-    unset($this->revision_id);
-    unset($this->log);
-    unset($this->uuid);
-    unset($this->type);
-    unset($this->new);
-  }
-
-  /**
    * {@inheritdoc}
    */
   public function uri() {
@@ -211,7 +145,7 @@ public function postSave(EntityStorageControllerInterface $storage_controller, $
    * {@inheritdoc}
    */
   public function getInstances() {
-    return entity_load_multiple_by_properties('block', array('plugin' => 'custom_block:' . $this->uuid->value));
+    return entity_load_multiple_by_properties('block', array('plugin' => 'custom_block:' . $this->uuid()));
   }
 
   /**
@@ -236,7 +170,7 @@ public function preSaveRevision(EntityStorageControllerInterface $storage_contro
     elseif (isset($this->original) && (!isset($record->log) || $record->log === '')) {
       // If we are updating an existing custom_block without adding a new
       // revision and the user did not supply a log, keep the existing one.
-      $record->log = $this->original->log->value;
+      $record->log = $this->original->getRevisionLog();
     }
   }
 
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Plugin/Derivative/CustomBlock.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Plugin/Derivative/CustomBlock.php
index e37328d..3511ee2 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Plugin/Derivative/CustomBlock.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Plugin/Derivative/CustomBlock.php
@@ -19,8 +19,8 @@ class CustomBlock extends DerivativeBase {
   public function getDerivativeDefinitions(array $base_plugin_definition) {
     $custom_blocks = entity_load_multiple('custom_block');
     foreach ($custom_blocks as $custom_block) {
-      $this->derivatives[$custom_block->uuid->value] = $base_plugin_definition;
-      $this->derivatives[$custom_block->uuid->value]['admin_label'] = $custom_block->info->value;
+      $this->derivatives[$custom_block->uuid()] = $base_plugin_definition;
+      $this->derivatives[$custom_block->uuid()]['admin_label'] = $custom_block->label();
     }
     return parent::getDerivativeDefinitions($base_plugin_definition);
   }
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockLoadHooksTest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockLoadHooksTest.php
index 0d20636..04ae8a5 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockLoadHooksTest.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockLoadHooksTest.php
@@ -48,9 +48,9 @@ public function testHookCustomBlockLoad() {
     $custom_blocks = entity_load_multiple_by_properties('custom_block', array('type' => 'basic'));
     $loaded_custom_block = end($custom_blocks);
     $this->assertEqual($loaded_custom_block->custom_block_test_loaded_ids, array(
-      $custom_block1->id->value,
-      $custom_block2->id->value,
-      $custom_block3->id->value
+      $custom_block1->id(),
+      $custom_block2->id(),
+      $custom_block3->id()
     ), 'hook_custom_block_load() received the correct list of custom_block IDs the first time it was called.');
     $this->assertEqual($loaded_custom_block->custom_block_test_loaded_types, array('basic'), 'hook_custom_block_load() received the correct list of custom block types the first time it was called.');
 
@@ -60,10 +60,10 @@ public function testHookCustomBlockLoad() {
     $custom_blocks = entity_load_multiple('custom_block', \Drupal::entityQuery('custom_block')->execute(), TRUE);
     $loaded_custom_block = end($custom_blocks);
     $this->assertEqual($loaded_custom_block->custom_block_test_loaded_ids, array(
-      $custom_block1->id->value,
-      $custom_block2->id->value,
-      $custom_block3->id->value,
-      $custom_block4->id->value
+      $custom_block1->id(),
+      $custom_block2->id(),
+      $custom_block3->id(),
+      $custom_block4->id()
     ), 'hook_custom_block_load() received the correct list of custom_block IDs the second time it was called.');
     $this->assertEqual($loaded_custom_block->custom_block_test_loaded_types, array('basic', 'other'), 'hook_custom_block_load() received the correct list of custom_block types the second time it was called.');
   }
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockRevisionsTest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockRevisionsTest.php
index b1d1220..90195ba 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockRevisionsTest.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockRevisionsTest.php
@@ -48,16 +48,17 @@ protected function setUp() {
     $logs = array();
 
     // Get original block.
-    $blocks[] = $block->revision_id->value;
+    $blocks[] = $block->getRevisionId();
     $logs[] = '';
 
     // Create three revisions.
     $revision_count = 3;
     for ($i = 0; $i < $revision_count; $i++) {
       $block->setNewRevision(TRUE);
-      $logs[] = $block->log->value = $this->randomName(32);
+      $block->setRevisionLog($this->randomName(32));
+      $logs[] = $block->getRevisionLog();
       $block->save();
-      $blocks[] = $block->revision_id->value;
+      $blocks[] = $block->getRevisionId();
     }
 
     $this->blocks = $blocks;
@@ -75,8 +76,8 @@ public function testRevisions() {
       // Confirm the correct revision text appears.
       $loaded = entity_revision_load('custom_block', $revision_id);
       // Verify log is the same.
-      $this->assertEqual($loaded->log->value, $logs[$delta], format_string('Correct log message found for revision !revision', array(
-        '!revision' => $loaded->revision_id->value
+      $this->assertEqual($loaded->getRevisionLog(), $logs[$delta], format_string('Correct log message found for revision !revision', array(
+        '!revision' => $loaded->getRevisionId()
       )));
     }
 
@@ -87,17 +88,17 @@ public function testRevisions() {
     // This will create a new revision that is not "front facing".
     // Save this as a non-default revision.
     $loaded->setNewRevision();
-    $loaded->isDefaultRevision = FALSE;
+    $loaded->isDefaultRevision(FALSE);
     $loaded->block_body = $this->randomName(8);
     $loaded->save();
 
-    $this->drupalGet('block/' . $loaded->id->value);
+    $this->drupalGet('block/' . $loaded->id());
     $this->assertNoText($loaded->block_body->value, 'Revision body text is not present on default version of block.');
 
     // Verify that the non-default revision id is greater than the default
     // revision id.
-    $default_revision = entity_load('custom_block', $loaded->id->value);
-    $this->assertTrue($loaded->revision_id->value > $default_revision->revision_id->value, 'Revision id is greater than default revision id.');
+    $default_revision = entity_load('custom_block', $loaded->id());
+    $this->assertTrue($loaded->getRevisionId() > $default_revision->getRevisionId(), 'Revision id is greater than default revision id.');
   }
 
 }
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockSaveTest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockSaveTest.php
index 405b50c..4efa071 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockSaveTest.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockSaveTest.php
@@ -44,7 +44,7 @@ protected function setUp() {
   /**
    * Checks whether custom block IDs are saved properly during an import.
    */
-  public function testImport() {
+  public function estImport() {
     // Custom block ID must be a number that is not in the database.
     $max_id = db_query('SELECT MAX(id) FROM {custom_block}')->fetchField();
     $test_id = $max_id + mt_rand(1000, 1000000);
@@ -60,7 +60,7 @@ public function testImport() {
     $block->save();
 
     // Verify that block_submit did not wipe the provided id.
-    $this->assertEqual($block->id->value, $test_id, 'Block imported using provide id');
+    $this->assertEqual($block->id(), $test_id, 'Block imported using provide id');
 
     // Test the import saved.
     $block_by_id = custom_block_load($test_id);
@@ -82,7 +82,7 @@ public function testDeterminingChanges() {
     $this->assertEqual($block->label(), 'test_changes', 'No changes have been determined.');
 
     // Apply changes.
-    $block->info->value = 'updated';
+    $block->setInfo('updated');
     $block->save();
 
     // The hook implementations custom_block_test_custom_block_presave() and
@@ -92,7 +92,7 @@ public function testDeterminingChanges() {
     $this->assertEqual($block->getChangedTime(), 979534800, 'Saving a custom block uses "changed" timestamp set in presave hook.');
 
     // Test the static block load cache to be cleared.
-    $block = custom_block_load($block->id->value);
+    $block = custom_block_load($block->id());
     $this->assertEqual($block->label(), 'updated_presave', 'Static cache has been cleared.');
   }
 
@@ -105,11 +105,11 @@ public function testDeterminingChanges() {
    *
    * @see block_test_block_insert()
    */
-  public function testCustomBlockSaveOnInsert() {
+  public function estCustomBlockSaveOnInsert() {
     // custom_block_test_custom_block_insert() tiggers a save on insert if the
     // title equals 'new'.
     $block = $this->createCustomBlock('new');
-    $this->assertEqual($block->label(), 'CustomBlock ' . $block->id->value, 'Custom block saved on block insert.');
+    $this->assertEqual($block->label(), 'CustomBlock ' . $block->id(), 'Custom block saved on block insert.');
   }
 
 }
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockTranslationUITest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockTranslationUITest.php
index 77d14b1..da8d23d 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockTranslationUITest.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/CustomBlockTranslationUITest.php
@@ -30,7 +30,7 @@ class CustomBlockTranslationUITest extends ContentTranslationUITest {
     'content_translation',
     'block',
     'field_ui',
-    'custom_block'
+    'custom_block',
   );
 
   /**
@@ -63,7 +63,7 @@ public function getTranslatorPermissions() {
       'translate any entity',
       'access administration pages',
       'administer blocks',
-      'administer custom_block fields'
+      'administer custom_block fields',
     ));
   }
 
@@ -86,7 +86,7 @@ protected function createCustomBlock($title = FALSE, $bundle = FALSE) {
     $custom_block = entity_create('custom_block', array(
       'info' => $title,
       'type' => $bundle,
-      'langcode' => 'en'
+      'langcode' => 'en',
     ));
     $custom_block->save();
     return $custom_block;
@@ -108,7 +108,7 @@ public function testDisabledBundle() {
     $bundle = entity_create('custom_block_type', array(
       'id' => $disabled_bundle,
       'label' => $disabled_bundle,
-      'revision' => FALSE
+      'revision' => FALSE,
     ));
     $bundle->save();
 
diff --git a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/PageEditTest.php b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/PageEditTest.php
index 7fa8b36..a1bebfd 100644
--- a/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/PageEditTest.php
+++ b/core/modules/block/custom_block/lib/Drupal/custom_block/Tests/PageEditTest.php
@@ -65,8 +65,8 @@ public function testPageEdit() {
     $this->drupalPostForm(NULL, $edit, t('Save'));
 
     // Ensure that the block revision has been created.
-    $revised_block = entity_load('custom_block', $block->id->value, TRUE);
-    $this->assertNotIdentical($block->revision_id->value, $revised_block->revision_id->value, 'A new revision has been created.');
+    $revised_block = entity_load('custom_block', $block->id(), TRUE);
+    $this->assertNotIdentical($block->revision_id->value, $revised_block->getRevisionId(), 'A new revision has been created.');
 
     // Test deleting the block.
     $this->drupalGet("block/" . $revised_block->id());
diff --git a/core/modules/block/custom_block/tests/modules/custom_block_test/custom_block_test.module b/core/modules/block/custom_block/tests/modules/custom_block_test/custom_block_test.module
index 277fae3..92497f6 100644
--- a/core/modules/block/custom_block/tests/modules/custom_block_test/custom_block_test.module
+++ b/core/modules/block/custom_block/tests/modules/custom_block_test/custom_block_test.module
@@ -40,13 +40,13 @@ function custom_block_test_custom_block_view(CustomBlock $custom_block, $view_mo
  * Implements hook_custom_block_presave().
  */
 function custom_block_test_custom_block_presave(CustomBlock $custom_block) {
-  if ($custom_block->info->value == 'testing_custom_block_presave') {
-    $custom_block->info->value .= '_presave';
+  if ($custom_block->label() == 'testing_custom_block_presave') {
+    $custom_block->setInfo($custom_block->label() .'_presave');
   }
   // Determine changes.
-  if (!empty($custom_block->original) && $custom_block->original->info->value == 'test_changes') {
-    if ($custom_block->original->info->value != $custom_block->info->value) {
-      $custom_block->info->value .= '_presave';
+  if (!empty($custom_block->original) && $custom_block->original->label() == 'test_changes') {
+    if ($custom_block->original->label() != $custom_block->label()) {
+      $custom_block->setInfo($custom_block->label() .'_presave');
       // Drupal 1.0 release.
       $custom_block->changed = 979534800;
     }
@@ -58,9 +58,9 @@ function custom_block_test_custom_block_presave(CustomBlock $custom_block) {
  */
 function custom_block_test_custom_block_update(CustomBlock $custom_block) {
   // Determine changes on update.
-  if (!empty($custom_block->original) && $custom_block->original->info->value == 'test_changes') {
-    if ($custom_block->original->info->value != $custom_block->info->value) {
-      $custom_block->info->value .= '_update';
+  if (!empty($custom_block->original) && $custom_block->original->label() == 'test_changes') {
+    if ($custom_block->original->label() != $custom_block->label()) {
+      $custom_block->setInfo($custom_block->label() .'_update');
     }
   }
 }
@@ -74,11 +74,11 @@ function custom_block_test_custom_block_update(CustomBlock $custom_block) {
  */
 function custom_block_test_custom_block_insert(CustomBlock $custom_block) {
   // Set the custom_block title to the custom_block ID and save.
-  if ($custom_block->info->value == 'new') {
-    $custom_block->info->value = 'CustomBlock ' . $custom_block->id->value;
+  if ($custom_block->label() == 'new') {
+    $custom_block->setInfo('CustomBlock ' . $custom_block->id());
     $custom_block->save();
   }
-  if ($custom_block->info->value == 'fail_creation') {
+  if ($custom_block->label() == 'fail_creation') {
     throw new Exception('Test exception for rollback.');
   }
 }
