# OnnxRuntime: OrtApiBase Struct Reference

Loading...
Searching...
No Matches
OrtApiBase Struct Reference
Global

The helper interface to get the right version of OrtApi. More...

`#include <onnxruntime_c_api.h>`

## Public Attributes

const OrtApi *(* | GetApi )(uint32_t version)
| Get a pointer to the requested version of the OrtApi.
const char *(* | GetVersionString )(void)
| Returns a null terminated string of the version of the Onnxruntime library (eg: "1.8.1")

## Detailed Description

The helper interface to get the right version of OrtApi.

Get a pointer to this structure through OrtGetApiBase

## Member Data Documentation

## GetApi

const OrtApi *( * OrtApiBase::GetApi) (uint32_t version)

Get a pointer to the requested version of the OrtApi.

Parameters

  [in] | version | Must be ORT_API_VERSION

Returns
  The OrtApi for the version requested, nullptr will be returned if this version is unsupported, for example when using a runtime older than the version created with this header file.

## GetVersionString

const char *( * OrtApiBase::GetVersionString) (void)

Returns a null terminated string of the version of the Onnxruntime library (eg: "1.8.1")