Public Member Functions | List of all members
PLMD::WithCmd Class Reference

Base for classes with cmd() method. More...

#include <WithCmd.h>

Inheritance diagram for PLMD::WithCmd:
Inheritance graph
[legend]

Public Member Functions

virtual ~WithCmd ()
 
void cmd (const char *key, const TypesafePtr &val=nullptr)
 This is needed to avoid ambiguities. More...
 
virtual void cmd (const std::string &key, const TypesafePtr &val=nullptr)
 This is the legacy method we used in older plumed versions, so it is still possible. More...
 
void cmd (std::string_view key, const TypesafePtr &val, const std::size_t *shape)
 
void cmd (std::string_view key, const TypesafePtr &val, std::size_t nelem, const std::size_t *shape=nullptr)
 
virtual void cmd (std::string_view key, const TypesafePtr &val=nullptr)
 This is the preferred method as it avoid allocations of temporaries. More...
 

Detailed Description

Base for classes with cmd() method.

This is an abstract base class for classes with cmd() method.

Constructor & Destructor Documentation

◆ ~WithCmd()

PLMD::WithCmd::~WithCmd ( )
inlinevirtual

Member Function Documentation

◆ cmd() [1/5]

void PLMD::WithCmd::cmd ( const char *  key,
const TypesafePtr val = nullptr 
)
inline

This is needed to avoid ambiguities.

◆ cmd() [2/5]

virtual void PLMD::WithCmd::cmd ( const std::string &  key,
const TypesafePtr val = nullptr 
)
inlinevirtual

This is the legacy method we used in older plumed versions, so it is still possible.

If this is not overridden, it will call the preferred method

◆ cmd() [3/5]

void PLMD::WithCmd::cmd ( std::string_view  key,
const TypesafePtr val,
const std::size_t *  shape 
)
inline

◆ cmd() [4/5]

void PLMD::WithCmd::cmd ( std::string_view  key,
const TypesafePtr val,
std::size_t  nelem,
const std::size_t *  shape = nullptr 
)
inline

◆ cmd() [5/5]

virtual void PLMD::WithCmd::cmd ( std::string_view  key,
const TypesafePtr val = nullptr 
)
inlinevirtual

This is the preferred method as it avoid allocations of temporaries.

If this is not overridded, it will call the legacy method.

Reimplemented in PLMD::PlumedMain, PLMD::CLToolMain, PLMD::GREX, and PLMD::PlumedHandle.


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