• InfluxDB3.Client API
Show / Hide Table of Contents
  • InfluxDB3.Client
    • IInfluxDBClient
    • InfluxDBApiException
    • InfluxDBClient
  • InfluxDB3.Client.Config
    • ClientConfig
    • QueryOptions
    • WriteOptions
  • InfluxDB3.Client.Internal
    • TypeCasting
  • InfluxDB3.Client.Query
    • QueryType
  • InfluxDB3.Client.Write
    • PointData
    • PointDataValues
    • WritePrecision

Class PointData

Point defines the values that will be written to the database. See Go Implementation.

Inheritance
object
PointData
Implements
IEquatable<PointData>
Inherited Members
object.Equals(object, object)
object.GetType()
object.MemberwiseClone()
object.ReferenceEquals(object, object)
object.ToString()
Namespace: InfluxDB3.Client.Write
Assembly: InfluxDB3.Client.dll
Syntax
public class PointData : IEquatable<PointData>

Constructors

PointData(PointDataValues)

Declaration
public PointData(PointDataValues values)
Parameters
Type Name Description
PointDataValues values

Methods

Copy()

Creates a deep copy of this object.

Declaration
public PointData Copy()
Returns
Type Description
PointData

A new instance with copied values.

Equals(PointData?)

Indicates whether the current object is equal to another object of the same type.

Declaration
public bool Equals(PointData? other)
Parameters
Type Name Description
PointData other

An object to compare with this object.

Returns
Type Description
bool

true if the current object is equal to the other parameter; otherwise, false.

Equals(object?)

Determines whether the specified object, is equal to this instance.

Declaration
public override bool Equals(object? obj)
Parameters
Type Name Description
object obj

The object to compare with this instance.

Returns
Type Description
bool

true if the specified object is equal to this instance; otherwise, false.

Overrides
object.Equals(object)

FromValues(PointDataValues)

Create a new Point with given values.

Declaration
public static PointData FromValues(PointDataValues values)
Parameters
Type Name Description
PointDataValues values

the point values

Returns
Type Description
PointData

the new Point

GetBooleanField(string)

Gets the bool field value associated with the specified name. If the field is not present, returns null.

Declaration
public bool? GetBooleanField(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
bool?

The bool field value or null

GetDoubleField(string)

Gets the double field value associated with the specified name. If the field is not present, returns null.

Declaration
public double? GetDoubleField(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
double?

The double field value or null

GetField(string)

Get field of given name. Can be null if field doesn't exist.

Declaration
public object? GetField(string name)
Parameters
Type Name Description
string name
Returns
Type Description
object

Field as object

GetFieldNames()

Gets an array of field names associated with this object.

Declaration
public string[] GetFieldNames()
Returns
Type Description
string[]

An array of field names.

GetFieldType(string)

Gets the type of field with given name, if it exists. If the field is not present, returns null.

Declaration
public Type? GetFieldType(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
Type

The field type or null.

GetField<T>(string)

Get field of given name as type. Can be null if field doesn't exist.

Declaration
public T? GetField<T>(string name) where T : struct
Parameters
Type Name Description
string name
Returns
Type Description
T?

Field as given type

Type Parameters
Name Description
T
Exceptions
Type Condition
InvalidCastException

Field doesn't match given type

GetHashCode()

Returns a hash code for this instance.

Declaration
public override int GetHashCode()
Returns
Type Description
int

A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.

Overrides
object.GetHashCode()

GetIntegerField(string)

Gets the integer field value associated with the specified name. If the field is not present, returns null.

Declaration
public long? GetIntegerField(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
long?

The integer field value or null

GetMeasurement()

Get measurement name.

Declaration
public string GetMeasurement()
Returns
Type Description
string

Measurement name

GetStringField(string)

Gets the string field value associated with the specified name. If the field is not present, returns null.

Declaration
public string? GetStringField(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
string

The string field value or null

GetTag(string)

Gets value of tag with given name. Returns null if tag not found.

Declaration
public string? GetTag(string name)
Parameters
Type Name Description
string name

the tag name

Returns
Type Description
string

tag value or null

GetTagNames()

Gets an array of tag names.

Declaration
public string[] GetTagNames()
Returns
Type Description
string[]

An array of tag names

GetTimestamp()

Get timestamp. Can be null if not set.

Declaration
public BigInteger? GetTimestamp()
Returns
Type Description
BigInteger?

timestamp or null

GetUintegerField(string)

Gets the uinteger field value associated with the specified name. If the field is not present, returns null.

Declaration
public ulong? GetUintegerField(string name)
Parameters
Type Name Description
string name

the field name

Returns
Type Description
ulong?

The uinteger field value or null

HasFields()

Has point any fields?

Declaration
public bool HasFields()
Returns
Type Description
bool

true, if the point contains any fields, false otherwise.

Measurement(string)

Create a new Point with specified a measurement name.

Declaration
public static PointData Measurement(string measurementName)
Parameters
Type Name Description
string measurementName

the measurement name

Returns
Type Description
PointData

the new Point

RemoveField(string)

Removes a field with the specified name if it exists; otherwise, it does nothing.

Declaration
public PointData RemoveField(string name)
Parameters
Type Name Description
string name

The name of the field to be removed.

Returns
Type Description
PointData

this

RemoveTag(string)

Removes a tag with the specified name if it exists; otherwise, it does nothing.

Declaration
public PointData RemoveTag(string name)
Parameters
Type Name Description
string name

the tag name

Returns
Type Description
PointData

this

SetBooleanField(string, bool)

Adds or replaces a bool field.

Declaration
public PointData SetBooleanField(string name, bool value)
Parameters
Type Name Description
string name

the field name

bool value

the field value

Returns
Type Description
PointData

this

SetDoubleField(string, double)

Adds or replaces a double field.

Declaration
public PointData SetDoubleField(string name, double value)
Parameters
Type Name Description
string name

the field name

double value

the field value

Returns
Type Description
PointData

this

SetField(string, bool)

Adds or replaces a field with a bool value.

Declaration
public PointData SetField(string name, bool value)
Parameters
Type Name Description
string name

the field name

bool value

the field value

Returns
Type Description
PointData

this

SetField(string, double)

Adds or replaces a field with a double value.

Declaration
public PointData SetField(string name, double value)
Parameters
Type Name Description
string name

the field name

double value

the field value

Returns
Type Description
PointData

this

SetField(string, long)

Adds or replaces a field with a long value.

Declaration
public PointData SetField(string name, long value)
Parameters
Type Name Description
string name

the field name

long value

the field value

Returns
Type Description
PointData

this

SetField(string, object)

Adds or replaces a field with an object value.

Declaration
public PointData SetField(string name, object value)
Parameters
Type Name Description
string name

the field name

object value

the field value

Returns
Type Description
PointData

this

SetField(string, string)

Adds or replaces a field with a string value.

Declaration
public PointData SetField(string name, string value)
Parameters
Type Name Description
string name

the field name

string value

the field value

Returns
Type Description
PointData

this

SetField(string, ulong)

Adds or replaces a field with a ulong value.

Declaration
public PointData SetField(string name, ulong value)
Parameters
Type Name Description
string name

the field name

ulong value

the field value

Returns
Type Description
PointData

this

SetFields(Dictionary<string, object>)

Add fields according to their type.

Declaration
public PointData SetFields(Dictionary<string, object> fields)
Parameters
Type Name Description
Dictionary<string, object> fields

the name-value dictionary

Returns
Type Description
PointData

this

SetIntegerField(string, long)

Adds or replaces a integer field.

Declaration
public PointData SetIntegerField(string name, long value)
Parameters
Type Name Description
string name

the field name

long value

the field value

Returns
Type Description
PointData

this

SetMeasurement(string)

Create new Point with this values and provided measurement.

Declaration
public PointData SetMeasurement(string measurementName)
Parameters
Type Name Description
string measurementName

the measurement name

Returns
Type Description
PointData

copy of this Point with given measurement name

SetStringField(string, string)

Adds or replaces a string field.

Declaration
public PointData SetStringField(string name, string value)
Parameters
Type Name Description
string name

the field name

string value

the field value

Returns
Type Description
PointData

this

SetTag(string, string)

Adds or replaces a tag value for a point.

Declaration
public PointData SetTag(string name, string value)
Parameters
Type Name Description
string name

the tag name

string value

the tag value

Returns
Type Description
PointData

this

SetTimestamp(DateTime)

Updates the timestamp for the point represented by DateTime.

Declaration
public PointData SetTimestamp(DateTime timestamp)
Parameters
Type Name Description
DateTime timestamp

the timestamp

Returns
Type Description
PointData

SetTimestamp(DateTimeOffset)

Updates the timestamp for the point represented by DateTime.

Declaration
public PointData SetTimestamp(DateTimeOffset timestamp)
Parameters
Type Name Description
DateTimeOffset timestamp

the timestamp

Returns
Type Description
PointData

SetTimestamp(long, WritePrecision?)

Updates the timestamp for the point.

Declaration
public PointData SetTimestamp(long timestamp, WritePrecision? timeUnit = null)
Parameters
Type Name Description
long timestamp

the timestamp

WritePrecision? timeUnit

the timestamp precision. Default is 'nanoseconds'.

Returns
Type Description
PointData

SetTimestamp(TimeSpan)

Updates the timestamp for the point represented by TimeSpan.

Declaration
public PointData SetTimestamp(TimeSpan timestamp)
Parameters
Type Name Description
TimeSpan timestamp

the timestamp

Returns
Type Description
PointData

SetUintegerField(string, ulong)

Adds or replaces a uinteger field.

Declaration
public PointData SetUintegerField(string name, ulong value)
Parameters
Type Name Description
string name

the field name

ulong value

the field value

Returns
Type Description
PointData

this

ToLineProtocol(WritePrecision?, Dictionary<string, string>?)

Transform to Line Protocol.

Declaration
public string ToLineProtocol(WritePrecision? timeUnit = null, Dictionary<string, string>? defaultTags = null)
Parameters
Type Name Description
WritePrecision? timeUnit

the timestamp precision

Dictionary<string, string> defaultTags

Tags added to point

Returns
Type Description
string

Line Protocol

Operators

operator ==(PointData?, PointData?)

Implements the operator ==.

Declaration
public static bool operator ==(PointData? left, PointData? right)
Parameters
Type Name Description
PointData left

The left.

PointData right

The right.

Returns
Type Description
bool

The result of the operator.

operator !=(PointData, PointData)

Implements the operator !=.

Declaration
public static bool operator !=(PointData left, PointData right)
Parameters
Type Name Description
PointData left

The left.

PointData right

The right.

Returns
Type Description
bool

The result of the operator.

Implements

IEquatable<T>
In this article
Back to top Generated by DocFX