You are here

public static function Loader::instance in Form Builder 7.2

Get a singleton-like class instance.

10 calls to Loader::instance()
AdminTest::testChangingGroupsInElement in tests/AdminTest.php
Test: Elements can change the tabs displayed on their configure form.
ExamplesTest::testOptionsConfiguration in examples/tests/ExamplesTest.php
FormBaseTest::testSaveAndLoad in tests/FormBaseTest.php
@cover \Drupal\form_builder\Loader::fromCache @cover \Drupal\form_builder\FormBase::load @cover \Drupal\form_builder\FormBase::save
FormBaseTest::test_form_builder_add_element in tests/FormBaseTest.php
Integration test _form_builder_add_element().
FormBaseTest::test_render_fieldset in tests/FormBaseTest.php
Integration test: Render textfield inside fieldset.

... See full list

File

src/Loader.php, line 25

Class

Loader
This class is a wrapper around all the hooks used for getting pluigns.

Namespace

Drupal\form_builder

Code

public static function instance() {
  if (!static::$instance) {
    static::$instance = new static();
  }
  return static::$instance;
}