as2js: as2js::Database Class Reference

#include <db.h>

Collaboration diagram for as2js::Database:
Classes class  Element   class  Package   Public Types typedef std::map< String, Element::pointer_telement_map_t   typedef std::vector< Element::pointer_telement_vector_t   typedef std::map< String, Package::pointer_tpackage_map_t   typedef std::vector< Package::pointer_tpackage_vector_t   typedef std::shared_ptr< Databasepointer_t   Public Member Functions Package::pointer_t add_package (String const &package_name)   package_vector_t find_packages (String const &pattern) const   Package::pointer_t get_package (String const &package_name) const   bool load (String const &filename)   void save () const   Static Public Member Functions static bool match_pattern (String const &name, String const &pattern)   Private Attributes String f_filename = String()   JSON::pointer_t f_json = JSON::pointer_t()   package_map_t f_packages = package_map_t()   JSON::JSONValue::pointer_t f_value = JSON::JSONValue::pointer_t()   Detailed Description

Definition at line 60 of file db.h.

Member Typedef Documentation

Definition at line 89 of file db.h.

Definition at line 90 of file db.h.

Definition at line 111 of file db.h.

Definition at line 112 of file db.h.

typedef std::shared_ptr<Database> as2js::Database::pointer_t

Definition at line 63 of file db.h.

Member Function Documentation
Database::Package::pointer_t as2js::Database::add_package ( String const &  package_name)
Database::package_vector_t as2js::Database::find_packages ( String const &  pattern) const

Definition at line 354 of file db.cpp.

References f_packages, and match_pattern().

Database::Package::pointer_t as2js::Database::get_package ( String const &  package_name) const

Definition at line 368 of file db.cpp.

References f_packages.

Referenced by add_package().

bool as2js::Database::match_pattern ( String const &  name, String const &  pattern  ) static

Definition at line 412 of file db.cpp.

Referenced by as2js::Database::Package::find_elements(), and find_packages().

void as2js::Database::save ( ) const

Definition at line 321 of file db.cpp.

References f_filename, and f_json.

Member Data Documentation
String as2js::Database::f_filename = String() private

Definition at line 124 of file db.h.

Referenced by add_package(), load(), and save().

JSON::pointer_t as2js::Database::f_json = JSON::pointer_t() private

Definition at line 125 of file db.h.

Referenced by add_package(), load(), and save().

package_map_t as2js::Database::f_packages = package_map_t() private

Definition at line 128 of file db.h.

Referenced by add_package(), find_packages(), get_package(), and load().

JSON::JSONValue::pointer_t as2js::Database::f_value = JSON::JSONValue::pointer_t() private

Definition at line 126 of file db.h.

Referenced by add_package(), and load().

The documentation for this class was generated from the following files:
  • /home/snapwebsites/snapcpp/contrib/as2js/lib/db.h
  • /home/snapwebsites/snapcpp/contrib/as2js/lib/db.cpp

This document is part of the Snap! Websites Project.

Copyright by Made to Order Software Corp.

Syndicate content

Snap! Websites
An Open Source CMS System in C++

Contact Us Directly