Свойство | Тип | Описание | |
---|---|---|---|
$client | |||
$name | string | The name of the Database |
Метод | Описание | |
---|---|---|
__construct ( string $name, |
Construct a database object | |
alterRetentionPolicy ( InfluxDB\Database\RetentionPolicy $retentionPolicy ) | ||
create ( InfluxDB\Database\RetentionPolicy $retentionPolicy = null, boolean $createIfNotExists = true ) : influxdb\ResultSet | Create this database | |
createRetentionPolicy ( InfluxDB\Database\RetentionPolicy $retentionPolicy ) : influxdb\ResultSet | ||
drop ( ) | Drop this database | |
exists ( ) : boolean | ||
getClient ( ) : |
||
getName ( ) : string | ||
getQueryBuilder ( ) : InfluxDB\Query\Builder | Retrieve the query builder | |
listRetentionPolicies ( ) : array | ||
query ( string $query, array $params = [] ) : influxdb\ResultSet | Query influxDB | |
writePayload ( string | array $payload, string $precision = self::PRECISION_NANOSECONDS, string | null $retentionPolicy = null ) : boolean | Write a payload into InfluxDB using the current driver. This method is similar to writePoints(), except it takes a string payload instead of an array of Points. This is useful in the following situations: | |
writePoints ( array $points, string $precision = self::PRECISION_NANOSECONDS, string | null $retentionPolicy = null ) : boolean | Write points into InfluxDB using the current driver. This is the recommended method for inserting data into InfluxDB. |
Метод | Описание | |
---|---|---|
getRetentionPolicyQuery ( string $method, InfluxDB\Database\RetentionPolicy $retentionPolicy ) : string |
public __construct ( string $name, |
||
$name | string | |
$client |
public alterRetentionPolicy ( InfluxDB\Database\RetentionPolicy $retentionPolicy ) | ||
$retentionPolicy | InfluxDB\Database\RetentionPolicy |
public createRetentionPolicy ( InfluxDB\Database\RetentionPolicy $retentionPolicy ) : influxdb\ResultSet | ||
$retentionPolicy | InfluxDB\Database\RetentionPolicy | |
Результат | influxdb\ResultSet |
public getQueryBuilder ( ) : InfluxDB\Query\Builder | ||
Результат | InfluxDB\Query\Builder |
protected getRetentionPolicyQuery ( string $method, InfluxDB\Database\RetentionPolicy $retentionPolicy ) : string | ||
$method | string | |
$retentionPolicy | InfluxDB\Database\RetentionPolicy | |
Результат | string |
public writePayload ( string | array $payload, string $precision = self::PRECISION_NANOSECONDS, string | null $retentionPolicy = null ) : boolean | ||
$payload | string | array | InfluxDB payload (Or array of payloads) that conform to the Line syntax. |
$precision | string | The timestamp precision (defaults to nanoseconds). |
$retentionPolicy | string | null | Specifies an explicit retention policy to use when writing all points. If not set, the default retention period will be used. This is only applicable for the Guzzle driver. The UDP driver utilizes the endpoint configuration defined in the server's influxdb configuration file. |
Результат | boolean |
public writePoints ( array $points, string $precision = self::PRECISION_NANOSECONDS, string | null $retentionPolicy = null ) : boolean | ||
$points | array | Array of Point objects |
$precision | string | The timestamp precision (defaults to nanoseconds). |
$retentionPolicy | string | null | Specifies an explicit retention policy to use when writing all points. If not set, the default retention period will be used. This is only applicable for the Guzzle driver. The UDP driver utilizes the endpoint configuration defined in the server's influxdb configuration file. |
Результат | boolean |