1 /** 2 The purpose of package, is to provide common interface for locating, storing, 3 aliasing of object. It does provide interface for objects that are implementing 4 service locator pattern. 5 6 There is a basic implementation of such object ObjectStorage. 7 8 Example: 9 --------------- 10 auto storage = new ObjectStorage!()(); 11 storage.set(new Object, "some object id"); 12 storage.get("some object id"); 13 storage.remove("some object id"); 14 --------------- 15 16 It does provide an interface for compositing multiple locators into one 17 composited locator. An object implementing it is AggregateLocatorImpl!(). 18 19 Example: 20 ---------------- 21 auto locator = new AggregateLocatorImpl!()(); 22 locator.set(new ObjectStorage!(), "first"); 23 locator.set(new ObjectStorage!(), "second"); 24 locator.get("some object id"); 25 ---------------- 26 27 It does provide an interface for aliasing an object identifier to another 28 identifier, and resolving the alias of it. 29 30 Example: 31 ---------------- 32 auto storage = new ObjectStorage!()(); 33 storage.set(new Object, "some object"); 34 storage.link("some object", "an alias"); 35 assert(storage.resolve("an alias") == "some object"); 36 assert(storage.get("an alias") == storage.get("some object"); 37 ---------------- 38 39 See: 40 $(UL 41 $(LI storage.d -> module that contains the object storage interface. 42 It is used in library to declare containers as able to save Factory 43 for objects that are registered in containers.) 44 $(LI locator.d -> module that contains the object locator interface. 45 It is used in library to decliare containers as able to locate 46 objects required by your application, or other objects that depend on 47 required object. It provides an interface for aggregate locator, as well 48 as a convenient function for automatic cast of objects from Locators to 49 desired type. ) 50 $(LI alias_aware.d -> module that declares interface for aliasing capabilities. ) 51 ) 52 53 License: 54 Boost Software License - Version 1.0 - August 17th, 2003 55 56 Permission is hereby granted, free of charge, to any person or organization 57 obtaining a copy of the software and accompanying documentation covered by 58 this license (the "Software") to use, reproduce, display, distribute, 59 execute, and transmit the Software, and to prepare derivative works of the 60 Software, and to permit third-parties to whom the Software is furnished to 61 do so, all subject to the following: 62 63 The copyright notices in the Software and this entire statement, including 64 the above license grant, this restriction and the following disclaimer, 65 must be included in all copies of the Software, in whole or in part, and 66 all derivative works of the Software, unless such copies or derivative 67 works are solely in the form of machine-executable object code generated by 68 a source language processor. 69 70 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 71 IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 72 FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT 73 SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE 74 FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, 75 ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 76 DEALINGS IN THE SOFTWARE. 77 78 Authors: 79 Alexandru Ermicioi 80 **/ 81 module aermicioi.aedi.storage; 82 83 public import aermicioi.aedi.storage.aggregate_locator; 84 public import aermicioi.aedi.storage.alias_aware; 85 public import aermicioi.aedi.storage.allocator_aware; 86 public import aermicioi.aedi.storage.decorator; 87 public import aermicioi.aedi.storage.locator; 88 public import aermicioi.aedi.storage.locator_aware; 89 public import aermicioi.aedi.storage.object_storage; 90 public import aermicioi.aedi.storage.storage; 91 public import aermicioi.aedi.storage.wrapper;