Ginkgo  Generated from tags/v1.0.0^0 branch based on master. Ginkgo version 1.0.0
A numerical linear algebra library targeting many-core architectures
Public Member Functions | List of all members
gko::log::Loggable Class Referenceabstract

Loggable class is an interface which should be implemented by classes wanting to support logging. More...

#include <ginkgo/core/log/logger.hpp>

Public Member Functions

virtual void add_logger (std::shared_ptr< const Logger > logger)=0
 Adds a new logger to the list of subscribed loggers. More...
 
virtual void remove_logger (const Logger *logger)=0
 Removes a logger from the list of subscribed loggers. More...
 

Detailed Description

Loggable class is an interface which should be implemented by classes wanting to support logging.

For most cases, one can rely on the EnableLogging mixin which provides a default implementation of this interface.

Member Function Documentation

◆ add_logger()

virtual void gko::log::Loggable::add_logger ( std::shared_ptr< const Logger logger)
pure virtual

Adds a new logger to the list of subscribed loggers.

Parameters
loggerthe logger to add

Implemented in gko::log::EnableLogging< ConcreteLoggable, PolymorphicBase >, gko::log::EnableLogging< PolymorphicObject >, and gko::log::EnableLogging< Executor >.

◆ remove_logger()

virtual void gko::log::Loggable::remove_logger ( const Logger logger)
pure virtual

Removes a logger from the list of subscribed loggers.

Parameters
loggerthe logger to remove
Note
The comparison is done using the logger's object unique identity. Thus, two loggers constructed in the same way are not considered equal.

Implemented in gko::log::EnableLogging< ConcreteLoggable, PolymorphicBase >, gko::log::EnableLogging< PolymorphicObject >, and gko::log::EnableLogging< Executor >.


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