You are here

class ChartService in Charts 5.0.x

Same name and namespace in other branches
  1. 8.4 src/Services/ChartService.php \Drupal\charts\Services\ChartService
  2. 8 src/Services/ChartService.php \Drupal\charts\Services\ChartService
  3. 8.3 src/Services/ChartService.php \Drupal\charts\Services\ChartService

Service class for getting and setting the currently selected library's state.

@package Drupal\charts\Services

Hierarchy

Expanded class hierarchy of ChartService

1 file declares its use of ChartService
ChartServiceTest.php in tests/src/Unit/Services/ChartServiceTest.php
1 string reference to 'ChartService'
charts.services.yml in ./charts.services.yml
charts.services.yml
1 service uses ChartService
charts.charts_service in ./charts.services.yml
Drupal\charts\Services\ChartService

File

src/Services/ChartService.php, line 10

Namespace

Drupal\charts\Services
View source
class ChartService implements ChartServiceInterface {

  /**
   * The selected library.
   *
   * @var string
   */
  private $librarySelected;

  /**
   * {@inheritdoc}
   */
  public function getLibrarySelected() {
    return $this->librarySelected;
  }

  /**
   * {@inheritdoc}
   */
  public function setLibrarySelected($librarySelected = '') {
    $this->librarySelected = $librarySelected;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
ChartService::$librarySelected private property The selected library.
ChartService::getLibrarySelected public function Gets the currently selected Library. Overrides ChartServiceInterface::getLibrarySelected
ChartService::setLibrarySelected public function Sets the previously set Library with the newly selected library value. Overrides ChartServiceInterface::setLibrarySelected