My Project: dht::Where Class Reference

My Project 3.7.7 C++ Distributed Hash Table

Loading...
Searching...
No Matches
Public Member Functions | Friends | List of all members
dht::Where Class Reference

Serializable dht::Value filter. More...

`#include <value.h>`

## Public Member Functions
| Where (std::string_view q_str)
bool | isSatisfiedBy (const Where &where) const
Where && | id (Value::Id id)
Where && | valueType (ValueType::Id type)
Where && | owner (InfoHash owner_pk_hash)
Where && | seq (uint16_t seq_no)
Where && | userType (std::string_view user_type)
Value::Filter | getFilter () const
template<typename Packer>
void | msgpack_pack (Packer &pk) const
void | msgpack_unpack (const msgpack::object &o)
std::string | toString () const
bool | empty () const

## Friends
OPENDHT_PUBLIC friend std::ostream & | operator<< (std::ostream &s, const dht::Where &q)

## Detailed Description

Serializable dht::Value filter.

This is container for a list of FieldValue instances. It describes a complete WHERE query for dht::Value.

Definition at line 849 of file value.h.

## Constructor & Destructor Documentation

## ◆ Where()

dht::Where::Where | ( |  | ) |
| inline

Definition at line 851 of file value.h.

## Member Function Documentation

## ◆ empty()

bool dht::Where::empty | ( |  | ) | const
| inline

Definition at line 971 of file value.h.

## ◆ getFilter()

Value::Filter dht::Where::getFilter | ( |  | ) | const
| inline

Computes the Value::Filter based on the list of field value set.

Returns
  the resulting Value::Filter.

Definition at line 938 of file value.h.

## ◆ id()

Where && dht::Where::id | ( | Value::Id | id | ) |
| inline

Adds restriction on Value::Id based on the id argument.

Parameters

  id | the id.

Returns
  the resulting Where instance.

Definition at line 863 of file value.h.

## ◆ msgpack_pack()

template<typename Packer>

void dht::Where::msgpack_pack | ( | Packer & | pk | ) | const
| inline

Definition at line 954 of file value.h.

## ◆ msgpack_unpack()

void dht::Where::msgpack_unpack | ( | const msgpack::object & | o | ) |
| inline

Definition at line 958 of file value.h.

## ◆ owner()

Where && dht::Where::owner | ( | InfoHash | owner_pk_hash | ) |
| inline

Adds restriction on Value::OwnerPk based on the owner_pk_hash argument.

Parameters

  owner_pk_hash | the owner public key fingerprint.

Returns
  the resulting Where instance.

Definition at line 893 of file value.h.

## ◆ seq()

Where && dht::Where::seq | ( | uint16_t | seq_no | ) |
| inline

Adds restriction on Value::OwnerPk based on the owner_pk_hash argument.

Parameters

  owner_pk_hash | the owner public key fingerprint.

Returns
  the resulting Where instance.

Definition at line 908 of file value.h.

## ◆ toString()

std::string dht::Where::toString | ( |  | ) | const
| inline

Definition at line 964 of file value.h.

## ◆ userType()

Where && dht::Where::userType | ( | std::string_view | user_type | ) |
| inline

Adds restriction on Value::UserType based on the user_type argument.

Parameters

  user_type | the user type.

Returns
  the resulting Where instance.

Definition at line 923 of file value.h.

## ◆ valueType()

Where && dht::Where::valueType | ( | ValueType::Id | type | ) |
| inline

Adds restriction on Value::ValueType based on the type argument.

Parameters

  type | the value type.

Returns
  the resulting Where instance.

Definition at line 878 of file value.h.

The documentation for this class was generated from the following file:

- /home/noptrix/ba/blackarch/packages/opendht-c/src/opendht/include/opendht/value.h