Panda3D
Public Member Functions
ConfigVariableInt Class Reference

This is a convenience class to specialize ConfigVariable as an integer type. More...

#include "configVariableInt.h"

Inheritance diagram for ConfigVariableInt:
ConfigVariable ConfigVariableBase ConfigFlags

List of all members.

Public Member Functions

 ConfigVariableInt (const string &name)
 ConfigVariableInt (const string &name, int default_value, const string &description=string(), int flags=0)
 ConfigVariableInt (const string &name, const string &default_value, const string &description=string(), int flags=0)
int get_default_value () const
 Returns the variable's default value.
int get_value () const
 Returns the variable's value.
int get_word (int n) const
 Returns the variable's nth value.
 operator int () const
 Returns the variable's value.
void operator= (int value)
 Reassigns the variable's local value.
int operator[] (int n) const
 Returns the value of the variable's nth word.
void set_value (int value)
 Reassigns the variable's local value.
void set_word (int n, int value)
 Reassigns the variable's nth value.
int size () const
 Returns the number of unique words in the variable.

Detailed Description

This is a convenience class to specialize ConfigVariable as an integer type.

Definition at line 26 of file configVariableInt.h.


Member Function Documentation

int ConfigVariableInt::get_default_value ( ) const [inline]

Returns the variable's default value.

Reimplemented from ConfigVariable.

Definition at line 139 of file configVariableInt.I.

References ConfigDeclaration::get_int_word().

int ConfigVariableInt::get_value ( ) const [inline]
int ConfigVariableInt::get_word ( int  n) const [inline]

Returns the variable's nth value.

Definition at line 153 of file configVariableInt.I.

References ConfigVariable::get_int_word().

Referenced by Texture::generate_simple_ram_image(), and operator[]().

ConfigVariableInt::operator int ( ) const [inline]

Returns the variable's value.

Definition at line 83 of file configVariableInt.I.

References get_value().

void ConfigVariableInt::operator= ( int  value) [inline]

Reassigns the variable's local value.

Definition at line 73 of file configVariableInt.I.

References set_value().

int ConfigVariableInt::operator[] ( int  n) const [inline]

Returns the value of the variable's nth word.

Definition at line 103 of file configVariableInt.I.

References get_word().

void ConfigVariableInt::set_value ( int  value) [inline]

Reassigns the variable's local value.

Definition at line 113 of file configVariableInt.I.

References ConfigVariable::set_int_word(), and ConfigVariable::set_string_value().

Referenced by operator=().

void ConfigVariableInt::set_word ( int  n,
int  value 
) [inline]

Reassigns the variable's nth value.

This makes a local copy of the variable's overall value.

Definition at line 164 of file configVariableInt.I.

References ConfigVariable::set_int_word().

int ConfigVariableInt::size ( ) const [inline]

Returns the number of unique words in the variable.

Definition at line 93 of file configVariableInt.I.

References ConfigVariable::get_num_words().


The documentation for this class was generated from the following files:
 All Classes Functions Variables Enumerations