mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
50 lines
900 B
PHP
50 lines
900 B
PHP
<?php
|
|
/**
|
|
* @author Stephen "TheCodeAssassin" Hoogendijk
|
|
*/
|
|
|
|
namespace InfluxDB\Driver;
|
|
|
|
/**
|
|
* Interface DriverInterface
|
|
*
|
|
* @package InfluxDB\Driver
|
|
*/
|
|
interface DriverInterface
|
|
{
|
|
|
|
/**
|
|
* Called by the client write() method, will pass an array of required parameters such as db name
|
|
*
|
|
* will contain the following parameters:
|
|
*
|
|
* [
|
|
* 'database' => 'name of the database',
|
|
* 'url' => 'URL to the resource',
|
|
* 'method' => 'HTTP method used'
|
|
* ]
|
|
*
|
|
* @param array $parameters
|
|
*
|
|
* @return mixed
|
|
*/
|
|
public function setParameters(array $parameters);
|
|
|
|
/**
|
|
* Send the data
|
|
*
|
|
* @param $data
|
|
*
|
|
* @return mixed
|
|
*/
|
|
public function write($data = null);
|
|
|
|
/**
|
|
* Should return if sending the data was successful
|
|
*
|
|
* @return bool
|
|
*/
|
|
public function isSuccess();
|
|
|
|
}
|