Panda3D

Public Member Functions | Static Public Member Functions | Public Attributes | Friends | List of all members
NotifyCategory Class Reference

A particular category of error messages. More...

`#include "notifyCategory.h"`

Inheritance diagram for NotifyCategory:

## Public Member Functions
std::ostream & | debug (bool prefix=true) const
| A shorthand way to write out(NS_debug). More...
std::ostream & | error (bool prefix=true) const
| A shorthand way to write out(NS_error). More...
std::ostream & | fatal (bool prefix=true) const
| A shorthand way to write out(NS_fatal). More...
std::string | get_basename () const
NotifyCategory * | get_child (size_t i) const
std::string | get_fullname () const
size_t | get_num_children () const
NotifySeverity | get_severity () const
std::ostream & | info (bool prefix=true) const
| A shorthand way to write out(NS_info). More...
bool | is_debug () const
| A shorthand way to write is_on(NS_debug). More...
bool | is_error () const
| A shorthand way to write is_on(NS_error). More...
bool | is_fatal () const
| A shorthand way to write is_on(NS_fatal). More...
bool | is_info () const
| A shorthand way to write is_on(NS_info). More...
bool | is_on (NotifySeverity severity) const
| Returns true if messages of the indicated severity level ought to be reported for this Category. More...
bool | is_spam () const
| A shorthand way to write is_on(NS_spam). More...
bool | is_warning () const
| A shorthand way to write is_on(NS_warning). More...
std::ostream & | out (NotifySeverity severity, bool prefix=true) const
| Begins a new message to this Category at the indicated severity level. More...
void | set_severity (NotifySeverity severity)
std::ostream & | spam (bool prefix=true) const
| A shorthand way to write out(NS_spam). More...
std::ostream & | warning (bool prefix=true) const
| A shorthand way to write out(NS_warning). More...
Public Member Functions inherited from MemoryBase
void | operator delete (void *, void *)
void | operator delete (void *ptr)
void | operator delete[] (void *, void *)
void | operator delete[] (void *ptr)
void * | operator new (size_t size)
void * | operator new (size_t size, void *ptr)
void * | operator new[] (size_t size)
void * | operator new[] (size_t size, void *ptr)

## Static Public Member Functions
static void | set_server_delta (long delta)
| Sets a global delta (in seconds) between the local time and the server's time, for the purpose of synchronizing the time stamps in the log messages of the client with that of a known server. More...

## Public Attributes
| get_basename
| get_child
| Returns the nth child Category of this particular Category. More...
| get_fullname
| get_num_children
| Returns the number of child Categories of this particular Category. More...
| get_severity
| set_severity
| Sets the severity level of messages that will be reported from this Category. More...

## Friends
class | Notify

## Additional Inherited Members
Public Types inherited from ConfigFlags
enum | ValueType { VT_undefined , VT_list , VT_string , VT_filename , VT_bool , VT_int , VT_double , VT_enum , VT_search_path , VT_int64 , VT_color }
enum | VariableFlags { F_trust_level_mask = 0x00000fff , F_open = 0x00001000 , F_closed = 0x00002000 , F_dynamic = 0x00004000 , F_dconfig = 0x00008000 }

## Detailed Description

A particular category of error messages.

Typically there will be one of these per package, so that we can turn on or off error messages at least at a package level; further nested categories can be created within a package if a finer grain of control is required.

Definition at line 32 of file notifyCategory.h.

## Member Function Documentation

## ◆ debug()

std::ostream & NotifyCategory::debug | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_debug).

Definition at line 140 of file notifyCategory.I.

## ◆ error()

std::ostream & NotifyCategory::error | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_error).

Definition at line 168 of file notifyCategory.I.

Referenced by Shader::cp_report_error().

## ◆ fatal()

std::ostream & NotifyCategory::fatal | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_fatal).

Definition at line 176 of file notifyCategory.I.

## ◆ info()

std::ostream & NotifyCategory::info | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_info).

Definition at line 152 of file notifyCategory.I.

## ◆ is_debug()

bool NotifyCategory::is_debug | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_debug).

Definition at line 83 of file notifyCategory.I.

## ◆ is_error()

bool NotifyCategory::is_error | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_error).

Definition at line 112 of file notifyCategory.I.

## ◆ is_fatal()

bool NotifyCategory::is_fatal | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_fatal).

Definition at line 120 of file notifyCategory.I.

## ◆ is_info()

bool NotifyCategory::is_info | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_info).

Definition at line 96 of file notifyCategory.I.

## ◆ is_on()

bool NotifyCategory::is_on | ( | NotifySeverity | severity | ) | const
| inline

Returns true if messages of the indicated severity level ought to be reported for this Category.

Definition at line 61 of file notifyCategory.I.

Referenced by out().

## ◆ is_spam()

bool NotifyCategory::is_spam | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_spam).

Definition at line 70 of file notifyCategory.I.

## ◆ is_warning()

bool NotifyCategory::is_warning | ( |  | ) | const
| inline

A shorthand way to write is_on(NS_warning).

Definition at line 104 of file notifyCategory.I.

## ◆ out()

std::ostream & NotifyCategory::out | ( | NotifySeverity | severity,
|  | bool | prefix = `true`
| ) |  | const

Begins a new message to this Category at the indicated severity level.

If the indicated severity level is enabled, this writes a prefixing string to the Notify::out() stream and returns that. If the severity level is disabled, this returns Notify::null().

Definition at line 58 of file notifyCategory.cxx.

References is_on().

## ◆ set_server_delta()

void NotifyCategory::set_server_delta | ( | long | delta | ) |
| static

Sets a global delta (in seconds) between the local time and the server's time, for the purpose of synchronizing the time stamps in the log messages of the client with that of a known server.

Definition at line 145 of file notifyCategory.cxx.

## ◆ spam()

std::ostream & NotifyCategory::spam | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_spam).

Definition at line 128 of file notifyCategory.I.

## ◆ warning()

std::ostream & NotifyCategory::warning | ( | bool | prefix = `true` | ) | const
| inline

A shorthand way to write out(NS_warning).

Definition at line 160 of file notifyCategory.I.

## Member Data Documentation

## ◆ get_child

NotifyCategory * NotifyCategory::get_child

Returns the nth child Category of this particular Category.

Definition at line 71 of file notifyCategory.h.

## ◆ get_num_children

size_t NotifyCategory::get_num_children

Returns the number of child Categories of this particular Category.

Definition at line 71 of file notifyCategory.h.

## ◆ set_severity

void NotifyCategory::set_severity
| inline

Sets the severity level of messages that will be reported from this Category.

This allows any message of this severity level or higher.

Definition at line 44 of file notifyCategory.h.

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

- dtool/src/prc/notifyCategory.h
- dtool/src/prc/notifyCategory.cxx
- dtool/src/prc/notifyCategory.I