OpenMS
Loading...
Searching...
No Matches
hash< OpenMS::MassAnalyzer > Struct Reference

Hash function for OpenMS::MassAnalyzer. More...

#include <OpenMS/METADATA/MassAnalyzer.h>

Public Member Functions

std::size_t operator() (const OpenMS::MassAnalyzer &ma) const noexcept
 

Detailed Description

Hash function for OpenMS::MassAnalyzer.

Computes a hash based on all fields compared in operator==:

  • All enum fields (type, resolution_method, resolution_type, scan_direction, scan_law, reflectron_state)
  • All double fields (resolution, accuracy, scan_rate, scan_time, TOF_total_path_length, isolation_width, magnetic_field_strength)
  • All integer fields (final_MS_exponent, order)
Note
MetaInfoInterface is included in operator== but excluded from hash computation since meta info is typically auxiliary data that varies frequently. This satisfies the hash contract: if hash(a) != hash(b), then a != b. The reverse implication (equal hashes imply equal objects) is not required for hash functions.

Member Function Documentation

◆ operator()()

std::size_t operator() ( const OpenMS::MassAnalyzer ma) const
inlinenoexcept