# Class ReplicationValue

Namespace
  Npgsql.Replication.PgOutput

Assembly
  Npgsql.dll

Represents a column value in a logical replication session.

    public class ReplicationValue

Inheritance
  object
  ReplicationValue

Inherited Members
  object.Equals(object)
  object.Equals(object, object)
  object.GetHashCode()
  object.GetType()
  object.MemberwiseClone()
  object.ReferenceEquals(object, object)
  object.ToString()

## Properties

### IsDBNull

Gets a value that indicates whether the column contains nonexistent or missing values.

    public bool IsDBNull { get; }

#### Property Value

bool

  true if the specified column is equivalent to DBNull; otherwise false.

### IsUnchangedToastedValue

Gets a value that indicates whether the column contains an unchanged TOASTed value (the actual value is not sent).

    public bool IsUnchangedToastedValue { get; }

#### Property Value

bool

  Whether the specified column is an unchanged TOASTed value.

### Kind

The kind of data transmitted for a tuple in a Logical Replication Protocol message.

    public TupleDataKind Kind { get; }

#### Property Value

TupleDataKind

### Length

The length of the value in bytes.

    public int Length { get; }

#### Property Value

int

## Methods

### Get(CancellationToken)

Gets the value of the specified column as an instance of object.

    public ValueTask<object> Get(CancellationToken cancellationToken = default)

#### Parameters

`cancellationToken` CancellationToken

  An optional token to cancel the asynchronous operation. The default value is None.

#### Returns

ValueTask<object>

### GetDataTypeName()

Gets the data type information for the specified field. This is be the PostgreSQL type name (e.g. double precision), not the .NET type (see GetFieldType() for that).

    public string GetDataTypeName()

#### Returns

string

### GetFieldName()

Gets the name of the specified column.

    public string GetFieldName()

#### Returns

string

  The name of the specified column.

### GetFieldType()

Gets the data type of the specified column.

    public Type GetFieldType()

#### Returns

Type

  The data type of the specified column.

### GetPostgresType()

Gets a representation of the PostgreSQL data type for the specified field. The returned representation can be used to access various information about the field.

    public PostgresType GetPostgresType()

#### Returns

PostgresType

### GetStream()

Retrieves data as a Stream.

    public Stream GetStream()

#### Returns

Stream

### GetTextReader()

Retrieves data as a TextReader.

    public TextReader GetTextReader()

#### Returns

TextReader

### Get<T>(CancellationToken)

Gets the value of the specified column as a type.

    public ValueTask<T> Get<T>(CancellationToken cancellationToken = default)

#### Parameters

`cancellationToken` CancellationToken

  An optional token to cancel the asynchronous operation. The default value is None.

#### Returns

ValueTask<T>

#### Type Parameters

`T`

  The type of the value to be returned.