You are here

public static function LingotekApi::instance in Lingotek Translation 7.4

Same name and namespace in other branches
  1. 7.7 lib/Drupal/lingotek/LingotekApi.php \LingotekApi::instance()
  2. 7.2 lib/Drupal/lingotek/LingotekApi.php \LingotekApi::instance()
  3. 7.3 lib/Drupal/lingotek/LingotekApi.php \LingotekApi::instance()
  4. 7.5 lib/Drupal/lingotek/LingotekApi.php \LingotekApi::instance()
  5. 7.6 lib/Drupal/lingotek/LingotekApi.php \LingotekApi::instance()

Gets the singleton instance of the API class.

Return value

LingotekApi An instantiated LingotekApi object.

42 calls to LingotekApi::instance()
LingotekComment::load in lib/Drupal/lingotek/LingotekComment.php
Factory method for getting a loaded LingotekComment object.
LingotekComment::loadById in lib/Drupal/lingotek/LingotekComment.php
Factory method for getting a loaded LingotekComment object.
LingotekComment::updateLocalContent in lib/Drupal/lingotek/LingotekComment.php
Updates the local content with data from a Lingotek Document.
LingotekComment::updateLocalContentByTarget in lib/Drupal/lingotek/LingotekComment.php
Updates the local content of $target_code with data from a Lingotek Document
LingotekConfigChunk::loadById in lib/Drupal/lingotek/LingotekConfigChunk.php
Factory method for getting a loaded LingotekConfigChunk object.

... See full list

File

lib/Drupal/lingotek/LingotekApi.php, line 51
Defines Drupal\lingotek\LingotekApi

Class

LingotekApi
@file Defines Drupal\lingotek\LingotekApi

Code

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