Cockatrice 2026-04-21-Development-2.11.0-beta.61
A virtual tabletop for multiplayer card games
Loading...
Searching...
No Matches
peg::Trie Class Reference

#include <peglib.h>

Classes

struct  Info

Public Member Functions

 Trie (const std::vector< std::string > &items, bool ignore_case)
size_t match (const char *text, size_t text_len, size_t &id) const
size_t size () const
size_t items_count () const

Private Attributes

std::map< std::string, Info, std::less<> > dic_
bool ignore_case_
size_t items_count_
size_t max_len_ = 0

Friends

struct ComputeFirstSet

Constructor & Destructor Documentation

◆ Trie()

peg::Trie::Trie ( const std::vector< std::string > & items,
bool ignore_case )
inline
Here is the call graph for this function:

Member Function Documentation

◆ items_count()

size_t peg::Trie::items_count ( ) const
inline

◆ match()

size_t peg::Trie::match ( const char * text,
size_t text_len,
size_t & id ) const
inline
Here is the call graph for this function:

◆ size()

size_t peg::Trie::size ( ) const
inline
Here is the caller graph for this function:

◆ ComputeFirstSet

friend struct ComputeFirstSet
friend

Member Data Documentation

◆ dic_

std::map<std::string, Info, std::less<> > peg::Trie::dic_
private

◆ ignore_case_

bool peg::Trie::ignore_case_
private

◆ items_count_

size_t peg::Trie::items_count_
private

◆ max_len_

size_t peg::Trie::max_len_ = 0
private

The documentation for this class was generated from the following file:
  • libcockatrice_utility/libcockatrice/utility/peglib.h