Skip to content

DataTypeSamplingSchemeMap

A set of DataTypeSamplingSchemes mapped to their data type as String.

Returned by DeviceConfiguration.dataTypeSamplingSchemes to list what a device can collect.

Constructors

DataTypeSamplingSchemeMap.from

DataTypeSamplingSchemeMap.from(
  1. List<DataTypeSamplingScheme> schemes
)

Creates a DataTypeSamplingSchemeMap from the list of schemes.

DataTypeSamplingSchemeMap

DataTypeSamplingSchemeMap()

Creates an empty DataTypeSamplingSchemeMap.

Properties

configurations

Map<String, SamplingConfiguration> get configurations

The map of all SamplingConfiguration entries in this scheme.

dataTypes

List<DataTypeMetaData> get dataTypes

The list of data types as DataTypeMetaData supported by this sampling schema.

types

Set<String> get types

The set of data types as String supported by this sampling schema.

Methods

add

void add(
  1. DataTypeSamplingScheme scheme
)

Add scheme to this map of schemes.

addSamplingSchema

void addSamplingSchema(
  1. DataTypeSamplingSchemeMap schema
)

Adds all sampling configurations from another schema to this schema. If a configuration in schema is already in this schema, its value is overwritten.

clear

void clear()

Removes all data schemes from this map.

contains

bool contains(
  1. String type
)

Whether the schema contains the data type type.

remove

DataTypeSamplingScheme? remove(
  1. String type
)

Removes type and its associated value, if present, from the map.

Returns the configuration associated with type before it was removed. Returns null if type was not in the map.

toMap

This sampling schema as a native Map. Changes to it change this map.

toString

String toString()
override

A string representation of this object.

Some classes have a default textual representation, often paired with a static parse function (like int.parse). These classes will provide the textual representation as their string representation.

Other classes have no meaningful textual representation that a program will care about. Such classes will typically override toString to provide useful information when inspecting the object, mainly for debugging or logging.

Operators

operator []

DataTypeSamplingScheme? operator [](
  1. String? type
)

The configuration for the data type type, or null if type is not in the map.

operator []=

void operator []=(
  1. String type,
  2. DataTypeSamplingScheme schema
)

Associates the type with the given schema.