Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. SpanConverter.php

function SpanConverter::convertStatusCode

1 call to SpanConverter::convertStatusCode()
SpanConverter::convertSpan in vendor/open-telemetry/exporter-otlp/SpanConverter.php

File

vendor/open-telemetry/exporter-otlp/SpanConverter.php, line 136

Class

SpanConverter

Namespace

OpenTelemetry\Contrib\Otlp

Code

private function convertStatusCode(string $status) : int {
    switch ($status) {
        case API\StatusCode::STATUS_UNSET:
            return StatusCode::STATUS_CODE_UNSET;
        case API\StatusCode::STATUS_OK:
            return StatusCode::STATUS_CODE_OK;
        case API\StatusCode::STATUS_ERROR:
            return StatusCode::STATUS_CODE_ERROR;
    }
    return StatusCode::STATUS_CODE_UNSET;
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal