diff options
author | lloyd <[email protected]> | 2006-06-26 13:30:05 +0000 |
---|---|---|
committer | lloyd <[email protected]> | 2006-06-26 13:30:05 +0000 |
commit | 864dcbc7b49d8e57b57af594b88f3853523b74da (patch) | |
tree | 29e6ff17688c9b5266ecce25320cf13f25711a22 /include | |
parent | ec036e15f63507286d54df7a02a6e5e28aeaff03 (diff) |
Various changes to how library initialization occurs, though I'm still
not completely happy with it.
Diffstat (limited to 'include')
-rw-r--r-- | include/libstate.h | 2 | ||||
-rw-r--r-- | include/modules.h | 19 |
2 files changed, 9 insertions, 12 deletions
diff --git a/include/libstate.h b/include/libstate.h index b2879c7d9..6b4c2cac1 100644 --- a/include/libstate.h +++ b/include/libstate.h @@ -31,7 +31,7 @@ class Library_State friend class Engine_Iterator; Allocator* get_allocator(const std::string& = "") const; - void add_allocator(Allocator*); + void add_allocator(Allocator*, bool = false); void set_prng(RandomNumberGenerator*); void randomize(byte[], u32bit); diff --git a/include/modules.h b/include/modules.h index 7441134d1..48aeb11fb 100644 --- a/include/modules.h +++ b/include/modules.h @@ -6,9 +6,6 @@ #ifndef BOTAN_MODULE_FACTORIES_H__ #define BOTAN_MODULE_FACTORIES_H__ -#include <string> -#include <vector> - namespace Botan { /************************************************* @@ -19,12 +16,12 @@ class Modules public: void load(class Library_State&) const; - virtual class Mutex_Factory* mutex_factory() const; - virtual class Timer* timer() const; + virtual class Mutex_Factory* mutex_factory() const { return 0; } + virtual class Timer* timer() const { return 0; } - virtual std::vector<class Allocator*> allocators() const; - virtual std::vector<class EntropySource*> entropy_sources() const; - virtual std::vector<class Engine*> engines() const; + virtual void set_allocators(class Library_State&, bool) const {} + virtual void set_entropy_sources(class Library_State&) const {} + virtual void set_engines(class Library_State&, bool) const {} virtual ~Modules() {} }; @@ -38,9 +35,9 @@ class Builtin_Modules : public Modules class Mutex_Factory* mutex_factory() const; class Timer* timer() const; - std::vector<class Allocator*> allocators() const; - std::vector<class EntropySource*> entropy_sources() const; - std::vector<class Engine*> engines() const; + void set_allocators(class Library_State&, bool) const; + void set_entropy_sources(class Library_State&) const; + void set_engines(class Library_State&, bool) const; }; } |