Harmony
HARMONic stabilitY assessment of PE-penetrated power systems
Loading...
Searching...
No Matches
PnPCertificateLibrary Class Reference

In-memory / JSON-backed library of device gate results. More...

#include <PnP_library.h>

Public Member Functions

void clear ()
 
void add (const PnPDeviceRecord &rec)
 
void addFromGate (const DeviceGateResult &gate, const std::string &device_type="")
 
const std::vector< PnPDeviceRecord > & records () const
 
std::size_t size () const
 
const PnPDeviceRecordfind (const std::string &device_id) const
 Lookup by id; returns nullptr if missing.
 
bool isAllowed (const std::string &device_id) const
 True if id exists and allow==true.
 
void saveJson (const std::string &path) const
 
void loadJson (const std::string &path)
 
void saveCsv (const std::string &path) const
 
void printSummary () const
 Count of allow / block entries.
 

Detailed Description

In-memory / JSON-backed library of device gate results.

Use after running evaluateDeviceGate on candidate converters; persist with saveJson / reload with loadJson for PnP screening.

Member Function Documentation

◆ add()

void PnPCertificateLibrary::add ( const PnPDeviceRecord rec)

References PnPDeviceRecord::device_id.

Referenced by addFromGate().

◆ addFromGate()

◆ clear()

void PnPCertificateLibrary::clear ( )

◆ find()

const PnPDeviceRecord * PnPCertificateLibrary::find ( const std::string &  device_id) const

Lookup by id; returns nullptr if missing.

Referenced by isAllowed().

◆ isAllowed()

bool PnPCertificateLibrary::isAllowed ( const std::string &  device_id) const

True if id exists and allow==true.

References find().

◆ loadJson()

◆ printSummary()

void PnPCertificateLibrary::printSummary ( ) const

Count of allow / block entries.

Referenced by example_certificate_figures().

◆ records()

const std::vector< PnPDeviceRecord > & PnPCertificateLibrary::records ( ) const
inline

◆ saveCsv()

void PnPCertificateLibrary::saveCsv ( const std::string &  path) const

◆ saveJson()

void PnPCertificateLibrary::saveJson ( const std::string &  path) const

◆ size()

std::size_t PnPCertificateLibrary::size ( ) const
inline

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