Panda3D

- Main Page
- Packages
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions

# ConfigPage Class Reference

A page of ConfigDeclarations that may be loaded or unloaded. More...

List of all members.

## Public Member Functions
| clear ()
bool | deleteDeclaration (ConfigDeclaration decl)
ConfigDeclaration const | getDeclaration (int n)
string | getName ()
| Returns the name of the page.
int | getNumDeclarations ()
int | getPageSeq ()
| Returns the sequence number of the page.
string | getSignature ()
| Returns the raw binary signature that was found in the prc file, if any.
int | getSort ()
| Returns the explicit sort order of this particular ConfigPage.
string | getStringValue (int n)
int | getTrustLevel ()
| Returns the trust level associated with this page.
string | getVariableName (int n)
bool | isImplicit ()
| Returns true if the page was loaded by implicitly searching the config path on startup, or false if it was explicitly loaded by dynamic code after initial startup.
bool | isSpecial ()
| Returns true if this is the special "default" or "local" page, or false if it is an ordinary page, e.g.
bool | isVariableUsed (int n)
ConfigDeclaration | makeDeclaration (ConfigVariableCore variable, string value)
ConfigDeclaration | makeDeclaration (string variable, string value)
ConfigDeclaration | modifyDeclaration (int n)
| output (ostream out)
| outputBriefSignature (ostream out)
bool | readEncryptedPrc (istream in, string password)
bool | readPrc (istream in)
| setSort (int sort)
| setTrustLevel (int trust_level)
| Explicitly sets the trust level on this particular page.
| write (ostream out)
## Static Public Member Functions
static ConfigPage | getDefaultPage ()
static ConfigPage | getLocalPage ()

## Detailed Description

A page of ConfigDeclarations that may be loaded or unloaded.

Typically this represents a single .prc file that is read from disk at runtime, but it may also represent a list of declarations built up by application code and explicitly loaded.

## Member Function Documentation

clear | ( |  | ) |

bool deleteDeclaration | ( | ConfigDeclaration | decl | ) |

ConfigDeclaration const getDeclaration | ( | int | n | ) |

static ConfigPage getDefaultPage | ( |  | ) | `[static]`

static ConfigPage getLocalPage | ( |  | ) | `[static]`

string getName | ( |  | ) |

Returns the name of the page.

If the page was loaded from a .prc file, this is usually the filename.

int getNumDeclarations | ( |  | ) |

int getPageSeq | ( |  | ) |

Returns the sequence number of the page.

Sequence numbers for a particular class (implicit vs. explicit) of pages are assigned as each page is loaded; each page is given a higher sequence number than all the pages loaded before it.

The implicit_load pages, which are discovered in the file system automatically, have a different set of sequence numbers than the explicit pages.

string getSignature | ( |  | ) |

Returns the raw binary signature that was found in the prc file, if any.

This method is probably not terribly useful for most applications.

int getSort | ( |  | ) |

Returns the explicit sort order of this particular ConfigPage.

See set_sort().

string getStringValue | ( | int | n | ) |

int getTrustLevel | ( |  | ) |

Returns the trust level associated with this page.

An untrusted page is trust level 0; if the page was loaded from a signed .prc file, its trust level is the index number of the certificate that signed it. Generally, a higher trust level value represents a greater level of trust.

string getVariableName | ( | int | n | ) |

bool isImplicit | ( |  | ) |

Returns true if the page was loaded by implicitly searching the config path on startup, or false if it was explicitly loaded by dynamic code after initial startup.

bool isSpecial | ( |  | ) |

Returns true if this is the special "default" or "local" page, or false if it is an ordinary page, e.g.

an implicit page loaded from a prc file at startup, or an explicit page created by ConfigPageManager.make_explicit_page().

bool isVariableUsed | ( | int | n | ) |

ConfigDeclaration makeDeclaration | ( | string | variable,
|  | string | value
| ) |  |

ConfigDeclaration makeDeclaration | ( | ConfigVariableCore | variable,
|  | string | value
| ) |  |

ConfigDeclaration modifyDeclaration | ( | int | n | ) |

output | ( | ostream | out | ) |

outputBriefSignature | ( | ostream | out | ) |

bool readEncryptedPrc | ( | istream | in,
|  | string | password
| ) |  |

bool readPrc | ( | istream | in | ) |

setSort | ( | int | sort | ) |

setTrustLevel | ( | int | trust_level | ) |

Explicitly sets the trust level on this particular page.

Note that any subsequent changes to the page, or to any variable declarations on it, will reset the trust level to zero.

write | ( | ostream | out | ) |

All Classes Namespaces Functions Variables Enumerations Enumerator Properties