IMP logo
IMP Reference Guide  2.12.0
The Integrative Modeling Platform
showable_macros.h File Reference

Various general useful macros for IMP. More...

#include <IMP/kernel_config.h>
#include "Showable.h"
#include "warning_macros.h"
+ Include dependency graph for showable_macros.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Showable

Declare the methods needed by an object that can be printed, both from C++ and Python. Each value-type class should have an IMP_SHOWABLE() call internal to it and an IMP_OUTPUT_OPERATOR() call external to it.

The suffixes are the number of template arguments that the object has (eg _1 means one template argument). _D means one integer template argument.

#define IMP_SHOWABLE(Name)   void show(std::ostream &out = std::cout) const
 
#define IMP_SHOWABLE_INLINE(Name, how_to_show)   void show(std::ostream &out = std::cout) const
 Declare the methods needed by an object that can be printed. More...
 

Detailed Description

Various general useful macros for IMP.

Copyright 2007-2019 IMP Inventors. All rights reserved.

Definition in file showable_macros.h.

Macro Definition Documentation

#define IMP_SHOWABLE (   Name)    void show(std::ostream &out = std::cout) const

This macro declares the method

  • void show(std::ostream &out) const It also makes it so that the object can be printed in Python.

The ostream and sstream headers must be included.

See Also
IMP_SHOWABLE_INLINE().

Do not use with IMP::Object objects as they have their own show mechanism.

Definition at line 40 of file showable_macros.h.

#define IMP_SHOWABLE_INLINE (   Name,
  how_to_show 
)    void show(std::ostream &out = std::cout) const

Declare the methods needed by an object that can be printed.

This macro declares the method

  • void show(std::ostream &out) const It also makes it so that the object can be printed in Python.

The ostream and sstream headers must be included.

Definition at line 50 of file showable_macros.h.