Panda3D
Public Member Functions | List of all members
WindowsGuid Class Reference

This is an implementation of the Windows GUID object, used everywhere as a world-unique identifier for anything and everything. More...

#include "windowsGuid.h"

Public Member Functions

 WindowsGuid (unsigned long data1, unsigned short data2, unsigned short data3, unsigned char b1, unsigned char b2, unsigned char b3, unsigned char b4, unsigned char b5, unsigned char b6, unsigned char b7, unsigned char b8)
 
 WindowsGuid (const WindowsGuid &copy)
 
int compare_to (const WindowsGuid &other) const
 Returns a number less than zero if this WindowsGuid sorts before the other one, greater than zero if it sorts after, or zero if they are equivalent. More...
 
std::string format_string () const
 Returns a hex representation of the GUID. More...
 
bool operator != (const WindowsGuid &other) const
 
bool operator< (const WindowsGuid &other) const
 
void operator= (const WindowsGuid &copy)
 
bool operator== (const WindowsGuid &other) const
 
void output (std::ostream &out) const
 Outputs a hex representation of the GUID. More...
 
bool parse_string (const std::string &str)
 Parses the hex representation in the indicated string and stores it in the WindowsGuid object. More...
 

Detailed Description

This is an implementation of the Windows GUID object, used everywhere as a world-unique identifier for anything and everything.

In particular, it's used in the X file format to identify standard templates.

Definition at line 26 of file windowsGuid.h.

Member Function Documentation

◆ compare_to()

int WindowsGuid::compare_to ( const WindowsGuid other) const
inline

Returns a number less than zero if this WindowsGuid sorts before the other one, greater than zero if it sorts after, or zero if they are equivalent.

Definition at line 90 of file windowsGuid.I.

◆ format_string()

string WindowsGuid::format_string ( ) const

Returns a hex representation of the GUID.

Definition at line 58 of file windowsGuid.cxx.

Referenced by output().

◆ output()

void WindowsGuid::output ( std::ostream &  out) const

Outputs a hex representation of the GUID.

Definition at line 74 of file windowsGuid.cxx.

References format_string().

◆ parse_string()

bool WindowsGuid::parse_string ( const std::string &  str)

Parses the hex representation in the indicated string and stores it in the WindowsGuid object.

Returns true if successful, false if the string representation is malformed.

Definition at line 27 of file windowsGuid.cxx.


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