From 3b2e6e9976bfe1ad09083b0b209978a9fbbd6ba3 Mon Sep 17 00:00:00 2001 From: Michele Caini Date: Sun, 2 Sep 2018 22:50:44 +0200 Subject: [PATCH] API reference v2.7.3 --- CONTRIBUTING_8md_source.html | 2 +- README_8md_source.html | 4 +- actor_8hpp_source.html | 35 +- algorithm_8hpp_source.html | 2 +- annotated.html | 92 +-- attachee_8hpp_source.html | 91 +++ autotoc_md0.html | 2 +- autotoc_md1.html | 110 +++ autotoc_md41.html | 84 +++ autotoc_md44.html | 133 ++++ autotoc_md49.html | 124 ++++ autotoc_md52.html | 84 +++ autotoc_md53.html | 147 ++++ autotoc_md8.html | 461 ++++++++++++ cache_8hpp_source.html | 2 +- classentt_1_1Attachee.html | 94 +++ ...hee_3_01Entity_00_01Type_01_4-members.html | 95 +++ ...1_1Attachee_3_01Entity_00_01Type_01_4.html | 472 +++++++++++++ ...3_01Entity_00_01Type_01_4__coll__graph.map | 3 + ...3_01Entity_00_01Type_01_4__coll__graph.md5 | 1 + ...3_01Entity_00_01Type_01_4__coll__graph.png | Bin 0 -> 4751 bytes ...1Entity_00_01Type_01_4__inherit__graph.map | 3 + ...1Entity_00_01Type_01_4__inherit__graph.md5 | 1 + ...1Entity_00_01Type_01_4__inherit__graph.png | Bin 0 -> 4751 bytes ...t_1_1Attachee_3_01Entity_01_4-members.html | 91 +++ classentt_1_1Attachee_3_01Entity_01_4.html | 324 +++++++++ ...tachee_3_01Entity_01_4__inherit__graph.map | 3 + ...tachee_3_01Entity_01_4__inherit__graph.md5 | 1 + ...tachee_3_01Entity_01_4__inherit__graph.png | Bin 0 -> 4768 bytes classentt_1_1ContinuousLoader-members.html | 2 +- classentt_1_1ContinuousLoader.html | 22 +- classentt_1_1Delegate.html | 2 +- ...ate_3_01Ret_07Args_8_8_8_08_4-members.html | 13 +- ...1_1Delegate_3_01Ret_07Args_8_8_8_08_4.html | 70 +- classentt_1_1Dispatcher-members.html | 2 +- classentt_1_1Dispatcher.html | 2 +- classentt_1_1Emitter-members.html | 2 +- classentt_1_1Emitter.html | 2 +- classentt_1_1Family-members.html | 2 +- classentt_1_1Family.html | 2 +- classentt_1_1HashedString-members.html | 2 +- classentt_1_1HashedString.html | 2 +- classentt_1_1Identifier-members.html | 2 +- classentt_1_1Identifier.html | 4 +- classentt_1_1Meta-members.html | 85 +++ classentt_1_1Meta.html | 111 +++ classentt_1_1MetaCtor-members.html | 89 +++ classentt_1_1MetaCtor.html | 127 ++++ classentt_1_1MetaData-members.html | 91 +++ classentt_1_1MetaData.html | 129 ++++ classentt_1_1MetaDtor-members.html | 85 +++ classentt_1_1MetaDtor.html | 109 +++ classentt_1_1MetaFunc-members.html | 94 +++ classentt_1_1MetaFunc.html | 143 ++++ classentt_1_1MetaProp-members.html | 84 +++ classentt_1_1MetaProp.html | 104 +++ classentt_1_1MetaType-members.html | 95 +++ classentt_1_1MetaType.html | 145 ++++ classentt_1_1PersistentView-members.html | 2 +- classentt_1_1PersistentView.html | 2 +- classentt_1_1Process-members.html | 2 +- classentt_1_1Process.html | 2 +- classentt_1_1Prototype-members.html | 2 +- classentt_1_1Prototype.html | 52 +- classentt_1_1RawView-members.html | 2 +- classentt_1_1RawView.html | 2 +- classentt_1_1Registry-members.html | 2 +- classentt_1_1Registry.html | 140 ++-- classentt_1_1ResourceCache-members.html | 2 +- classentt_1_1ResourceCache.html | 2 +- classentt_1_1ResourceHandle-members.html | 2 +- classentt_1_1ResourceHandle.html | 2 +- classentt_1_1ResourceLoader-members.html | 2 +- classentt_1_1ResourceLoader.html | 2 +- classentt_1_1RuntimeView-members.html | 2 +- classentt_1_1RuntimeView.html | 2 +- classentt_1_1Scheduler-members.html | 2 +- classentt_1_1Scheduler.html | 2 +- classentt_1_1SigH.html | 4 +- ..._8_8_8_08_00_01Collector_01_4-members.html | 2 +- ...t_07Args_8_8_8_08_00_01Collector_01_4.html | 20 +- classentt_1_1Sink.html | 6 +- ...ink_3_01Ret_07Args_8_8_8_08_4-members.html | 6 +- ...ntt_1_1Sink_3_01Ret_07Args_8_8_8_08_4.html | 127 +++- classentt_1_1Snapshot-members.html | 2 +- classentt_1_1Snapshot.html | 12 +- classentt_1_1SnapshotLoader-members.html | 2 +- classentt_1_1SnapshotLoader.html | 14 +- classentt_1_1SparseSet.html | 2 +- ...Set_3_01Entity_00_01Type_01_4-members.html | 2 +- ..._1SparseSet_3_01Entity_00_01Type_01_4.html | 40 +- ..._1_1SparseSet_3_01Entity_01_4-members.html | 2 +- classentt_1_1SparseSet_3_01Entity_01_4.html | 42 +- classentt_1_1View-members.html | 2 +- classentt_1_1View.html | 2 +- ..._01Entity_00_01Component_01_4-members.html | 2 +- ..._1View_3_01Entity_00_01Component_01_4.html | 2 +- classes.html | 13 +- config_8h_source.html | 2 +- core_8md_source.html | 74 ++ delegate_8hpp_source.html | 18 +- dir_66e9674e8206a335795995fa32a03c91.html | 2 +- dir_68267d1309a1af8e8297ef4c3efbcdba.html | 2 +- dir_721f6154dba3c88bcdead5f446bce319.html | 2 +- dir_7929ab29d3f740cf727ccbd263321562.html | 2 +- dir_85dbee8884f1b3a817fa7eff8dff73ec.html | 2 +- dir_a53318306f6ac0f7fe657839abd543ab.html | 2 +- dir_b64489a1e8130d5ebf6d86d282f500f0.html | 2 +- dir_c5715f7ee899854a669b87bbaa642de0.html | 78 +++ dir_de8f4e6ba3f54a2a21309f742e93a373.html | 2 +- dir_e3a7bb56c55e5c2286e2fe96e197d4f5.html | 2 +- dispatcher_8hpp_source.html | 4 +- emitter_8hpp_source.html | 2 +- entity_8hpp_source.html | 7 +- entity_8md_source.html | 74 ++ entt_8hpp_source.html | 4 +- entt__traits_8hpp_source.html | 4 +- factory_8hpp_source.html | 99 +++ family_8hpp_source.html | 2 +- files.html | 51 +- functions.html | 10 +- functions_0x7e.html | 6 +- functions_b.html | 2 +- functions_c.html | 8 +- functions_d.html | 8 +- functions_e.html | 12 +- functions_f.html | 2 +- functions_func.html | 10 +- functions_func_0x7e.html | 6 +- functions_func_b.html | 2 +- functions_func_c.html | 12 +- functions_func_d.html | 10 +- functions_func_e.html | 2 +- functions_func_f.html | 2 +- functions_func_g.html | 10 +- functions_func_h.html | 2 +- functions_func_l.html | 2 +- functions_func_m.html | 5 +- functions_func_o.html | 20 +- functions_func_p.html | 2 +- functions_func_r.html | 2 +- functions_func_s.html | 2 +- functions_func_t.html | 2 +- functions_func_u.html | 2 +- functions_func_v.html | 2 +- functions_g.html | 10 +- functions_h.html | 2 +- functions_i.html | 2 +- functions_l.html | 2 +- functions_m.html | 5 +- functions_o.html | 19 +- functions_p.html | 2 +- functions_r.html | 2 +- functions_rela.html | 2 +- functions_s.html | 2 +- functions_t.html | 2 +- functions_type.html | 7 +- functions_u.html | 2 +- functions_v.html | 8 +- functions_vars.html | 14 +- graph_legend.html | 2 +- handle_8hpp_source.html | 2 +- hashed__string_8hpp_source.html | 4 +- helper_8hpp_source.html | 9 +- hierarchy.html | 107 +-- ident_8hpp_source.html | 4 +- index.html | 656 +----------------- inherit_graph_1.map | 3 +- inherit_graph_1.md5 | 2 +- inherit_graph_1.png | Bin 1047 -> 3368 bytes inherit_graph_10.map | 2 +- inherit_graph_10.md5 | 2 +- inherit_graph_10.png | Bin 1983 -> 1908 bytes inherit_graph_11.map | 2 +- inherit_graph_11.md5 | 2 +- inherit_graph_11.png | Bin 1851 -> 2036 bytes inherit_graph_12.map | 2 +- inherit_graph_12.md5 | 2 +- inherit_graph_12.png | Bin 1336 -> 1983 bytes inherit_graph_13.map | 2 +- inherit_graph_13.md5 | 2 +- inherit_graph_13.png | Bin 1633 -> 1851 bytes inherit_graph_14.map | 2 +- inherit_graph_14.md5 | 2 +- inherit_graph_14.png | Bin 1672 -> 1336 bytes inherit_graph_15.map | 2 +- inherit_graph_15.md5 | 2 +- inherit_graph_15.png | Bin 1281 -> 1633 bytes inherit_graph_16.map | 2 +- inherit_graph_16.md5 | 2 +- inherit_graph_16.png | Bin 2122 -> 1672 bytes inherit_graph_17.map | 2 +- inherit_graph_17.md5 | 2 +- inherit_graph_17.png | Bin 1723 -> 1281 bytes inherit_graph_18.map | 2 +- inherit_graph_18.md5 | 2 +- inherit_graph_18.png | Bin 1138 -> 2122 bytes inherit_graph_19.map | 2 +- inherit_graph_19.md5 | 2 +- inherit_graph_19.png | Bin 2696 -> 1723 bytes inherit_graph_2.map | 2 +- inherit_graph_2.md5 | 2 +- inherit_graph_2.png | Bin 2271 -> 2192 bytes inherit_graph_20.map | 2 +- inherit_graph_20.md5 | 2 +- inherit_graph_20.png | Bin 2274 -> 1138 bytes inherit_graph_21.map | 3 +- inherit_graph_21.md5 | 2 +- inherit_graph_21.png | Bin 7482 -> 2696 bytes inherit_graph_22.map | 2 +- inherit_graph_22.md5 | 2 +- inherit_graph_22.png | Bin 1637 -> 2274 bytes inherit_graph_23.map | 3 +- inherit_graph_23.md5 | 2 +- inherit_graph_23.png | Bin 1090 -> 7482 bytes inherit_graph_24.map | 2 +- inherit_graph_24.md5 | 2 +- inherit_graph_24.png | Bin 2626 -> 1637 bytes inherit_graph_25.map | 2 +- inherit_graph_25.md5 | 2 +- inherit_graph_25.png | Bin 1730 -> 1090 bytes inherit_graph_26.map | 2 +- inherit_graph_26.md5 | 2 +- inherit_graph_26.png | Bin 2193 -> 2626 bytes inherit_graph_27.map | 2 +- inherit_graph_27.md5 | 2 +- inherit_graph_27.png | Bin 2056 -> 1730 bytes inherit_graph_28.map | 2 +- inherit_graph_28.md5 | 2 +- inherit_graph_28.png | Bin 2161 -> 2193 bytes inherit_graph_29.map | 2 +- inherit_graph_29.md5 | 2 +- inherit_graph_29.png | Bin 2062 -> 2056 bytes inherit_graph_3.map | 2 +- inherit_graph_3.md5 | 2 +- inherit_graph_3.png | Bin 2308 -> 1554 bytes inherit_graph_30.map | 2 +- inherit_graph_30.md5 | 2 +- inherit_graph_30.png | Bin 1819 -> 2161 bytes inherit_graph_31.map | 2 +- inherit_graph_31.md5 | 2 +- inherit_graph_31.png | Bin 2059 -> 2062 bytes inherit_graph_32.map | 2 +- inherit_graph_32.md5 | 2 +- inherit_graph_32.png | Bin 2332 -> 1819 bytes inherit_graph_33.map | 2 +- inherit_graph_33.md5 | 2 +- inherit_graph_33.png | Bin 3872 -> 2059 bytes inherit_graph_34.map | 2 +- inherit_graph_34.md5 | 2 +- inherit_graph_34.png | Bin 2675 -> 2332 bytes inherit_graph_35.map | 2 +- inherit_graph_35.md5 | 2 +- inherit_graph_35.png | Bin 1767 -> 3872 bytes inherit_graph_36.map | 2 +- inherit_graph_36.md5 | 2 +- inherit_graph_36.png | Bin 2140 -> 2675 bytes inherit_graph_37.map | 2 +- inherit_graph_37.md5 | 2 +- inherit_graph_37.png | Bin 1954 -> 3272 bytes inherit_graph_38.map | 2 +- inherit_graph_38.md5 | 2 +- inherit_graph_38.png | Bin 2414 -> 1767 bytes inherit_graph_39.map | 3 +- inherit_graph_39.md5 | 2 +- inherit_graph_39.png | Bin 3584 -> 2140 bytes inherit_graph_4.map | 2 +- inherit_graph_4.md5 | 2 +- inherit_graph_4.png | Bin 1844 -> 2271 bytes inherit_graph_40.map | 2 +- inherit_graph_40.md5 | 2 +- inherit_graph_40.png | Bin 1551 -> 1954 bytes inherit_graph_41.map | 2 +- inherit_graph_41.md5 | 2 +- inherit_graph_41.png | Bin 1250 -> 2414 bytes inherit_graph_42.map | 3 +- inherit_graph_42.md5 | 2 +- inherit_graph_42.png | Bin 965 -> 3584 bytes inherit_graph_43.map | 2 +- inherit_graph_43.md5 | 2 +- inherit_graph_43.png | Bin 2384 -> 2545 bytes inherit_graph_44.map | 2 +- inherit_graph_44.md5 | 2 +- inherit_graph_44.png | Bin 2384 -> 1551 bytes inherit_graph_45.map | 3 + inherit_graph_45.md5 | 1 + inherit_graph_45.png | Bin 0 -> 1250 bytes inherit_graph_46.map | 3 + inherit_graph_46.md5 | 1 + inherit_graph_46.png | Bin 0 -> 965 bytes inherit_graph_47.map | 3 + inherit_graph_47.md5 | 1 + inherit_graph_47.png | Bin 0 -> 2384 bytes inherit_graph_48.map | 3 + inherit_graph_48.md5 | 1 + inherit_graph_48.png | Bin 0 -> 2384 bytes inherit_graph_49.map | 3 + inherit_graph_49.md5 | 1 + inherit_graph_49.png | Bin 0 -> 1138 bytes inherit_graph_5.map | 2 +- inherit_graph_5.md5 | 2 +- inherit_graph_5.png | Bin 1425 -> 2308 bytes inherit_graph_50.map | 3 + inherit_graph_50.md5 | 1 + inherit_graph_50.png | Bin 0 -> 2696 bytes inherit_graph_51.map | 3 + inherit_graph_51.md5 | 1 + inherit_graph_51.png | Bin 0 -> 2274 bytes inherit_graph_52.map | 4 + inherit_graph_52.md5 | 1 + inherit_graph_52.png | Bin 0 -> 7482 bytes inherit_graph_53.map | 3 + inherit_graph_53.md5 | 1 + inherit_graph_53.png | Bin 0 -> 1637 bytes inherit_graph_54.map | 3 + inherit_graph_54.md5 | 1 + inherit_graph_54.png | Bin 0 -> 1090 bytes inherit_graph_55.map | 3 + inherit_graph_55.md5 | 1 + inherit_graph_55.png | Bin 0 -> 2626 bytes inherit_graph_56.map | 3 + inherit_graph_56.md5 | 1 + inherit_graph_56.png | Bin 0 -> 1730 bytes inherit_graph_57.map | 3 + inherit_graph_57.md5 | 1 + inherit_graph_57.png | Bin 0 -> 2193 bytes inherit_graph_58.map | 3 + inherit_graph_58.md5 | 1 + inherit_graph_58.png | Bin 0 -> 2056 bytes inherit_graph_59.map | 3 + inherit_graph_59.md5 | 1 + inherit_graph_59.png | Bin 0 -> 2161 bytes inherit_graph_6.map | 2 +- inherit_graph_6.md5 | 2 +- inherit_graph_6.png | Bin 1508 -> 1844 bytes inherit_graph_60.map | 3 + inherit_graph_60.md5 | 1 + inherit_graph_60.png | Bin 0 -> 2062 bytes inherit_graph_61.map | 3 + inherit_graph_61.md5 | 1 + inherit_graph_61.png | Bin 0 -> 1819 bytes inherit_graph_62.map | 3 + inherit_graph_62.md5 | 1 + inherit_graph_62.png | Bin 0 -> 2059 bytes inherit_graph_63.map | 3 + inherit_graph_63.md5 | 1 + inherit_graph_63.png | Bin 0 -> 2332 bytes inherit_graph_64.map | 3 + inherit_graph_64.md5 | 1 + inherit_graph_64.png | Bin 0 -> 3872 bytes inherit_graph_65.map | 3 + inherit_graph_65.md5 | 1 + inherit_graph_65.png | Bin 0 -> 2675 bytes inherit_graph_66.map | 3 + inherit_graph_66.md5 | 1 + inherit_graph_66.png | Bin 0 -> 3272 bytes inherit_graph_67.map | 3 + inherit_graph_67.md5 | 1 + inherit_graph_67.png | Bin 0 -> 1767 bytes inherit_graph_68.map | 3 + inherit_graph_68.md5 | 1 + inherit_graph_68.png | Bin 0 -> 2140 bytes inherit_graph_69.map | 3 + inherit_graph_69.md5 | 1 + inherit_graph_69.png | Bin 0 -> 1954 bytes inherit_graph_7.map | 2 +- inherit_graph_7.md5 | 2 +- inherit_graph_7.png | Bin 3863 -> 1425 bytes inherit_graph_70.map | 3 + inherit_graph_70.md5 | 1 + inherit_graph_70.png | Bin 0 -> 2414 bytes inherit_graph_71.map | 4 + inherit_graph_71.md5 | 1 + inherit_graph_71.png | Bin 0 -> 3584 bytes inherit_graph_72.map | 3 + inherit_graph_72.md5 | 1 + inherit_graph_72.png | Bin 0 -> 2545 bytes inherit_graph_73.map | 3 + inherit_graph_73.md5 | 1 + inherit_graph_73.png | Bin 0 -> 1551 bytes inherit_graph_74.map | 3 + inherit_graph_74.md5 | 1 + inherit_graph_74.png | Bin 0 -> 1250 bytes inherit_graph_75.map | 3 + inherit_graph_75.md5 | 1 + inherit_graph_75.png | Bin 0 -> 965 bytes inherit_graph_76.map | 3 + inherit_graph_76.md5 | 1 + inherit_graph_76.png | Bin 0 -> 2384 bytes inherit_graph_77.map | 3 + inherit_graph_77.md5 | 1 + inherit_graph_77.png | Bin 0 -> 2384 bytes inherit_graph_8.map | 2 +- inherit_graph_8.md5 | 2 +- inherit_graph_8.png | Bin 1908 -> 1508 bytes inherit_graph_9.map | 2 +- inherit_graph_9.md5 | 2 +- inherit_graph_9.png | Bin 2036 -> 3863 bytes inherits.html | 115 +-- loader_8hpp_source.html | 2 +- locator_8hpp_source.html | 2 +- locator_8md_source.html | 74 ++ meta_8hpp_source.html | 103 +++ monostate_8hpp_source.html | 2 +- namespaceentt.html | 154 ++-- namespacemembers.html | 8 +- namespacemembers_func.html | 8 +- namespacemembers_type.html | 2 +- namespacemembers_vars.html | 2 +- namespaces.html | 2 +- pages.html | 9 +- process_8hpp_source.html | 2 +- process_8md_source.html | 74 ++ prototype_8hpp_source.html | 47 +- registry_8hpp_source.html | 133 ++-- resource_8md_source.html | 74 ++ scheduler_8hpp_source.html | 2 +- search/all_0.js | 7 +- search/all_1.js | 3 +- search/all_12.js | 2 +- search/all_13.js | 1 + search/all_2.js | 10 +- search/all_3.js | 6 +- search/all_4.js | 5 +- search/all_6.js | 2 +- search/all_a.js | 2 +- search/all_c.js | 4 +- search/all_f.js | 2 + search/classes_0.js | 6 +- search/classes_1.js | 3 +- search/classes_2.js | 5 +- search/classes_3.js | 8 +- search/classes_4.js | 6 +- search/classes_5.js | 2 +- search/classes_6.js | 3 +- search/classes_7.js | 3 +- search/classes_8.js | 2 +- search/classes_9.js | 7 +- search/classes_a.js | 13 +- search/classes_b.js | 22 +- search/classes_c.js | 14 +- search/classes_d.js | 3 +- search/functions_0.js | 4 +- search/functions_11.js | 1 + search/functions_2.js | 4 +- search/functions_3.js | 6 +- search/functions_6.js | 2 +- search/functions_9.js | 2 +- search/functions_a.js | 2 +- search/pages_0.js | 8 +- search/pages_1.html | 26 + search/pages_1.js | 4 + search/searchdata.js | 4 +- search/typedefs_2.js | 2 +- search/typedefs_7.js | 2 +- search/variables_0.js | 2 +- search/variables_2.js | 2 +- search/variables_3.html | 26 + search/variables_3.js | 4 + shared_8md_source.html | 74 ++ sigh_8hpp_source.html | 42 +- signal_8md_source.html | 74 ++ snapshot_8hpp_source.html | 48 +- sparse__set_8hpp_source.html | 84 +-- structentt_1_1Actor-members.html | 10 +- structentt_1_1Actor.html | 125 ++-- ...entt_1_1Emitter_1_1Connection-members.html | 2 +- structentt_1_1Emitter_1_1Connection.html | 2 +- structentt_1_1InsertionSort-members.html | 2 +- structentt_1_1InsertionSort.html | 2 +- structentt_1_1MetaAny-members.html | 100 +++ structentt_1_1MetaAny.html | 151 ++++ structentt_1_1Monostate-members.html | 2 +- structentt_1_1Monostate.html | 2 +- structentt_1_1OneShotBubbleSort-members.html | 2 +- structentt_1_1OneShotBubbleSort.html | 2 +- structentt_1_1ProcessAdaptor-members.html | 2 +- structentt_1_1ProcessAdaptor.html | 2 +- structentt_1_1ServiceLocator-members.html | 2 +- structentt_1_1ServiceLocator.html | 14 +- structentt_1_1StdSort-members.html | 2 +- structentt_1_1StdSort.html | 2 +- structentt_1_1entt__traits.html | 2 +- ...its_3_01std_1_1uint16__t_01_4-members.html | 6 +- ...ntt__traits_3_01std_1_1uint16__t_01_4.html | 18 +- ...its_3_01std_1_1uint32__t_01_4-members.html | 6 +- ...ntt__traits_3_01std_1_1uint32__t_01_4.html | 18 +- ...its_3_01std_1_1uint64__t_01_4-members.html | 6 +- ...ntt__traits_3_01std_1_1uint64__t_01_4.html | 18 +- ...ntt_1_1internal_1_1CtorHelper-members.html | 82 +++ structentt_1_1internal_1_1CtorHelper.html | 98 +++ ...uctentt_1_1internal_1_1FunctionHelper.html | 19 +- ...per_3_01Ret_07Args_8_8_8_08_4-members.html | 86 +++ ...ctionHelper_3_01Ret_07Args_8_8_8_08_4.html | 127 ++++ ...1Ret_07Args_8_8_8_08_4__inherit__graph.map | 5 + ...1Ret_07Args_8_8_8_08_4__inherit__graph.md5 | 1 + ...1Ret_07Args_8_8_8_08_4__inherit__graph.png | Bin 0 -> 32351 bytes structentt_1_1internal_1_1Holder-members.html | 86 +++ structentt_1_1internal_1_1Holder.html | 111 +++ ...ntt_1_1internal_1_1HolderType-members.html | 90 +++ structentt_1_1internal_1_1HolderType.html | 139 ++++ ...1_1internal_1_1HolderType__coll__graph.map | 3 + ...1_1internal_1_1HolderType__coll__graph.md5 | 1 + ...1_1internal_1_1HolderType__coll__graph.png | Bin 0 -> 4058 bytes ...internal_1_1HolderType__inherit__graph.map | 3 + ...internal_1_1HolderType__inherit__graph.md5 | 1 + ...internal_1_1HolderType__inherit__graph.png | Bin 0 -> 4058 bytes ..._1_1internal_1_1Holder__inherit__graph.map | 3 + ..._1_1internal_1_1Holder__inherit__graph.md5 | 1 + ..._1_1internal_1_1Holder__inherit__graph.png | Bin 0 -> 4079 bytes ...t_1_1internal_1_1MetaCtorNode-members.html | 89 +++ structentt_1_1internal_1_1MetaCtorNode.html | 139 ++++ ...1internal_1_1MetaCtorNode__coll__graph.map | 15 + ...1internal_1_1MetaCtorNode__coll__graph.md5 | 1 + ...1internal_1_1MetaCtorNode__coll__graph.png | Bin 0 -> 93755 bytes ...t_1_1internal_1_1MetaDataNode-members.html | 91 +++ structentt_1_1internal_1_1MetaDataNode.html | 141 ++++ ...1internal_1_1MetaDataNode__coll__graph.map | 15 + ...1internal_1_1MetaDataNode__coll__graph.md5 | 1 + ...1internal_1_1MetaDataNode__coll__graph.png | Bin 0 -> 109975 bytes ...t_1_1internal_1_1MetaDtorNode-members.html | 84 +++ structentt_1_1internal_1_1MetaDtorNode.html | 111 +++ ...1internal_1_1MetaDtorNode__coll__graph.map | 6 + ...1internal_1_1MetaDtorNode__coll__graph.md5 | 1 + ...1internal_1_1MetaDtorNode__coll__graph.png | Bin 0 -> 13668 bytes ...t_1_1internal_1_1MetaFuncNode-members.html | 94 +++ structentt_1_1internal_1_1MetaFuncNode.html | 154 ++++ ...1internal_1_1MetaFuncNode__coll__graph.map | 15 + ...1internal_1_1MetaFuncNode__coll__graph.md5 | 1 + ...1internal_1_1MetaFuncNode__coll__graph.png | Bin 0 -> 108924 bytes ...tentt_1_1internal_1_1MetaInfo-members.html | 82 +++ structentt_1_1internal_1_1MetaInfo.html | 127 ++++ ...t_1_1internal_1_1MetaInfo__coll__graph.map | 17 + ...t_1_1internal_1_1MetaInfo__coll__graph.md5 | 1 + ...t_1_1internal_1_1MetaInfo__coll__graph.png | Bin 0 -> 130233 bytes ..._1internal_1_1MetaInfo__inherit__graph.map | 3 + ..._1internal_1_1MetaInfo__inherit__graph.md5 | 1 + ..._1internal_1_1MetaInfo__inherit__graph.png | Bin 0 -> 5286 bytes ...tentt_1_1internal_1_1MetaNode-members.html | 82 +++ structentt_1_1internal_1_1MetaNode.html | 118 ++++ ...nal_1_1MetaNode_3_01Type_01_4-members.html | 88 +++ ...1_1internal_1_1MetaNode_3_01Type_01_4.html | 145 ++++ ...1_1MetaNode_3_01Type_01_4__coll__graph.map | 16 + ...1_1MetaNode_3_01Type_01_4__coll__graph.md5 | 1 + ...1_1MetaNode_3_01Type_01_4__coll__graph.png | Bin 0 -> 139142 bytes ...t_1_1internal_1_1MetaNode__coll__graph.map | 16 + ...t_1_1internal_1_1MetaNode__coll__graph.md5 | 1 + ...t_1_1internal_1_1MetaNode__coll__graph.png | Bin 0 -> 124979 bytes ...t_1_1internal_1_1MetaPropNode-members.html | 85 +++ structentt_1_1internal_1_1MetaPropNode.html | 112 +++ ...1internal_1_1MetaPropNode__coll__graph.map | 4 + ...1internal_1_1MetaPropNode__coll__graph.md5 | 1 + ...1internal_1_1MetaPropNode__coll__graph.png | Bin 0 -> 7718 bytes ...t_1_1internal_1_1MetaTypeNode-members.html | 90 +++ structentt_1_1internal_1_1MetaTypeNode.html | 138 ++++ ...1internal_1_1MetaTypeNode__coll__graph.map | 15 + ...1internal_1_1MetaTypeNode__coll__graph.md5 | 1 + ...1internal_1_1MetaTypeNode__coll__graph.png | Bin 0 -> 115771 bytes ...tentt_1_1internal_1_1ReflectionHelper.html | 87 +++ ...1_5_00d602dc6ec169f254929375e78a46dac.html | 145 ++++ ...1_5_015539704a649a59d142205c030330d2b.html | 89 +++ ..._1_5_0420e89fa634eb8a1fc577ac631093008.map | 3 + ..._1_5_0420e89fa634eb8a1fc577ac631093008.md5 | 1 + ..._1_5_0420e89fa634eb8a1fc577ac631093008.png | Bin 0 -> 9276 bytes ...1_5_0868046ef5528de2d018c38a0bece18e0.html | 145 ++++ ..._1_5_09ed366b0b925f8491739847cc864d665.map | 3 + ..._1_5_09ed366b0b925f8491739847cc864d665.md5 | 1 + ..._1_5_09ed366b0b925f8491739847cc864d665.png | Bin 0 -> 9951 bytes ...1_5_0a1cab8ad1dbb86fac6e7c34dde0c3c6b.html | 89 +++ ..._1_5_0c965b95e1f82696bad2e71b49fa6d8dd.map | 3 + ..._1_5_0c965b95e1f82696bad2e71b49fa6d8dd.md5 | 1 + ..._1_5_0c965b95e1f82696bad2e71b49fa6d8dd.png | Bin 0 -> 9951 bytes ..._1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.map | 3 + ..._1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.md5 | 1 + ..._1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.png | Bin 0 -> 9276 bytes ...7Args_502ffb16ff5bf47e94661cfa018f4eed.map | 3 + ...7Args_502ffb16ff5bf47e94661cfa018f4eed.md5 | 1 + ...7Args_502ffb16ff5bf47e94661cfa018f4eed.png | Bin 0 -> 8021 bytes ...Args_858d6f74f0eb72d4936c15a8caa3af63.html | 145 ++++ ...Args_d401927d8e36c51002e803efb588b956.html | 89 +++ ...7Args_eba2d57ab4ca242c26bb20abfcabfd26.map | 3 + ...7Args_eba2d57ab4ca242c26bb20abfcabfd26.md5 | 1 + ...7Args_eba2d57ab4ca242c26bb20abfcabfd26.png | Bin 0 -> 8021 bytes ..._1_5_18969de809d65f64025243166eb229a2.html | 84 +++ ..._1_5_a9c4ab474d7f81ef29f999b86b0cb449.html | 107 +++ ...1Data32bead6fb6a894c5b73d1813ddcab196.html | 84 +++ ...1Datab92364bff7ad5f1dfeed3ce3d11c82e8.html | 107 +++ ...1Clas693684ab033d6c2c6a6373a3be8f3e53.html | 84 +++ ...1Clasc540f55fdf60969a618f02a1d390fabd.html | 107 +++ ...1_5_05e1cabbf44c196359d3ef7436afd34e3.html | 84 +++ ...1_5_0b9659031a38e282dc2052fd28bd776a7.html | 107 +++ ...ntt_1_1internal_1_1TypeHelper-members.html | 82 +++ structentt_1_1internal_1_1TypeHelper.html | 97 +++ ...l_1_1TypeHelper_3_01void_01_4-members.html | 82 +++ ...1internal_1_1TypeHelper_3_01void_01_4.html | 97 +++ structentt_1_1internal_1_1Utils-members.html | 84 +++ structentt_1_1internal_1_1Utils.html | 103 +++ structentt_1_1persistent__t.html | 2 +- structentt_1_1raw__t.html | 2 +- structentt_1_1tag__t.html | 2 +- utility_8hpp_source.html | 5 +- view_8hpp_source.html | 32 +- 602 files changed, 11605 insertions(+), 1772 deletions(-) create mode 100644 attachee_8hpp_source.html create mode 100644 autotoc_md1.html create mode 100644 autotoc_md41.html create mode 100644 autotoc_md44.html create mode 100644 autotoc_md49.html create mode 100644 autotoc_md52.html create mode 100644 autotoc_md53.html create mode 100644 autotoc_md8.html create mode 100644 classentt_1_1Attachee.html create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4-members.html create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4.html create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__coll__graph.map create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__coll__graph.md5 create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__coll__graph.png create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__inherit__graph.map create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__inherit__graph.md5 create mode 100644 classentt_1_1Attachee_3_01Entity_00_01Type_01_4__inherit__graph.png create mode 100644 classentt_1_1Attachee_3_01Entity_01_4-members.html create mode 100644 classentt_1_1Attachee_3_01Entity_01_4.html create mode 100644 classentt_1_1Attachee_3_01Entity_01_4__inherit__graph.map create mode 100644 classentt_1_1Attachee_3_01Entity_01_4__inherit__graph.md5 create mode 100644 classentt_1_1Attachee_3_01Entity_01_4__inherit__graph.png create mode 100644 classentt_1_1Meta-members.html create mode 100644 classentt_1_1Meta.html create mode 100644 classentt_1_1MetaCtor-members.html create mode 100644 classentt_1_1MetaCtor.html create mode 100644 classentt_1_1MetaData-members.html create mode 100644 classentt_1_1MetaData.html create mode 100644 classentt_1_1MetaDtor-members.html create mode 100644 classentt_1_1MetaDtor.html create mode 100644 classentt_1_1MetaFunc-members.html create mode 100644 classentt_1_1MetaFunc.html create mode 100644 classentt_1_1MetaProp-members.html create mode 100644 classentt_1_1MetaProp.html create mode 100644 classentt_1_1MetaType-members.html create mode 100644 classentt_1_1MetaType.html create mode 100644 core_8md_source.html create mode 100644 dir_c5715f7ee899854a669b87bbaa642de0.html create mode 100644 entity_8md_source.html create mode 100644 factory_8hpp_source.html create mode 100644 inherit_graph_45.map create mode 100644 inherit_graph_45.md5 create mode 100644 inherit_graph_45.png create mode 100644 inherit_graph_46.map create mode 100644 inherit_graph_46.md5 create mode 100644 inherit_graph_46.png create mode 100644 inherit_graph_47.map create mode 100644 inherit_graph_47.md5 create mode 100644 inherit_graph_47.png create mode 100644 inherit_graph_48.map create mode 100644 inherit_graph_48.md5 create mode 100644 inherit_graph_48.png create mode 100644 inherit_graph_49.map create mode 100644 inherit_graph_49.md5 create mode 100644 inherit_graph_49.png create mode 100644 inherit_graph_50.map create mode 100644 inherit_graph_50.md5 create mode 100644 inherit_graph_50.png create mode 100644 inherit_graph_51.map create mode 100644 inherit_graph_51.md5 create mode 100644 inherit_graph_51.png create mode 100644 inherit_graph_52.map create mode 100644 inherit_graph_52.md5 create mode 100644 inherit_graph_52.png create mode 100644 inherit_graph_53.map create mode 100644 inherit_graph_53.md5 create mode 100644 inherit_graph_53.png create mode 100644 inherit_graph_54.map create mode 100644 inherit_graph_54.md5 create mode 100644 inherit_graph_54.png create mode 100644 inherit_graph_55.map create mode 100644 inherit_graph_55.md5 create mode 100644 inherit_graph_55.png create mode 100644 inherit_graph_56.map create mode 100644 inherit_graph_56.md5 create mode 100644 inherit_graph_56.png create mode 100644 inherit_graph_57.map create mode 100644 inherit_graph_57.md5 create mode 100644 inherit_graph_57.png create mode 100644 inherit_graph_58.map create mode 100644 inherit_graph_58.md5 create mode 100644 inherit_graph_58.png create mode 100644 inherit_graph_59.map create mode 100644 inherit_graph_59.md5 create mode 100644 inherit_graph_59.png create mode 100644 inherit_graph_60.map create mode 100644 inherit_graph_60.md5 create mode 100644 inherit_graph_60.png create mode 100644 inherit_graph_61.map create mode 100644 inherit_graph_61.md5 create mode 100644 inherit_graph_61.png create mode 100644 inherit_graph_62.map create mode 100644 inherit_graph_62.md5 create mode 100644 inherit_graph_62.png create mode 100644 inherit_graph_63.map create mode 100644 inherit_graph_63.md5 create mode 100644 inherit_graph_63.png create mode 100644 inherit_graph_64.map create mode 100644 inherit_graph_64.md5 create mode 100644 inherit_graph_64.png create mode 100644 inherit_graph_65.map create mode 100644 inherit_graph_65.md5 create mode 100644 inherit_graph_65.png create mode 100644 inherit_graph_66.map create mode 100644 inherit_graph_66.md5 create mode 100644 inherit_graph_66.png create mode 100644 inherit_graph_67.map create mode 100644 inherit_graph_67.md5 create mode 100644 inherit_graph_67.png create mode 100644 inherit_graph_68.map create mode 100644 inherit_graph_68.md5 create mode 100644 inherit_graph_68.png create mode 100644 inherit_graph_69.map create mode 100644 inherit_graph_69.md5 create mode 100644 inherit_graph_69.png create mode 100644 inherit_graph_70.map create mode 100644 inherit_graph_70.md5 create mode 100644 inherit_graph_70.png create mode 100644 inherit_graph_71.map create mode 100644 inherit_graph_71.md5 create mode 100644 inherit_graph_71.png create mode 100644 inherit_graph_72.map create mode 100644 inherit_graph_72.md5 create mode 100644 inherit_graph_72.png create mode 100644 inherit_graph_73.map create mode 100644 inherit_graph_73.md5 create mode 100644 inherit_graph_73.png create mode 100644 inherit_graph_74.map create mode 100644 inherit_graph_74.md5 create mode 100644 inherit_graph_74.png create mode 100644 inherit_graph_75.map create mode 100644 inherit_graph_75.md5 create mode 100644 inherit_graph_75.png create mode 100644 inherit_graph_76.map create mode 100644 inherit_graph_76.md5 create mode 100644 inherit_graph_76.png create mode 100644 inherit_graph_77.map create mode 100644 inherit_graph_77.md5 create mode 100644 inherit_graph_77.png create mode 100644 locator_8md_source.html create mode 100644 meta_8hpp_source.html create mode 100644 process_8md_source.html create mode 100644 resource_8md_source.html create mode 100644 search/pages_1.html create mode 100644 search/pages_1.js create mode 100644 search/variables_3.html create mode 100644 search/variables_3.js create mode 100644 shared_8md_source.html create mode 100644 signal_8md_source.html create mode 100644 structentt_1_1MetaAny-members.html create mode 100644 structentt_1_1MetaAny.html create mode 100644 structentt_1_1internal_1_1CtorHelper-members.html create mode 100644 structentt_1_1internal_1_1CtorHelper.html rename structentt_1_1break__t.html => structentt_1_1internal_1_1FunctionHelper.html (77%) create mode 100644 structentt_1_1internal_1_1FunctionHelper_3_01Ret_07Args_8_8_8_08_4-members.html create mode 100644 structentt_1_1internal_1_1FunctionHelper_3_01Ret_07Args_8_8_8_08_4.html create mode 100644 structentt_1_1internal_1_1FunctionHelper_3_01Ret_07Args_8_8_8_08_4__inherit__graph.map create mode 100644 structentt_1_1internal_1_1FunctionHelper_3_01Ret_07Args_8_8_8_08_4__inherit__graph.md5 create mode 100644 structentt_1_1internal_1_1FunctionHelper_3_01Ret_07Args_8_8_8_08_4__inherit__graph.png create mode 100644 structentt_1_1internal_1_1Holder-members.html create mode 100644 structentt_1_1internal_1_1Holder.html create mode 100644 structentt_1_1internal_1_1HolderType-members.html create mode 100644 structentt_1_1internal_1_1HolderType.html create mode 100644 structentt_1_1internal_1_1HolderType__coll__graph.map create mode 100644 structentt_1_1internal_1_1HolderType__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1HolderType__coll__graph.png create mode 100644 structentt_1_1internal_1_1HolderType__inherit__graph.map create mode 100644 structentt_1_1internal_1_1HolderType__inherit__graph.md5 create mode 100644 structentt_1_1internal_1_1HolderType__inherit__graph.png create mode 100644 structentt_1_1internal_1_1Holder__inherit__graph.map create mode 100644 structentt_1_1internal_1_1Holder__inherit__graph.md5 create mode 100644 structentt_1_1internal_1_1Holder__inherit__graph.png create mode 100644 structentt_1_1internal_1_1MetaCtorNode-members.html create mode 100644 structentt_1_1internal_1_1MetaCtorNode.html create mode 100644 structentt_1_1internal_1_1MetaCtorNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaCtorNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaCtorNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaDataNode-members.html create mode 100644 structentt_1_1internal_1_1MetaDataNode.html create mode 100644 structentt_1_1internal_1_1MetaDataNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaDataNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaDataNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaDtorNode-members.html create mode 100644 structentt_1_1internal_1_1MetaDtorNode.html create mode 100644 structentt_1_1internal_1_1MetaDtorNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaDtorNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaDtorNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaFuncNode-members.html create mode 100644 structentt_1_1internal_1_1MetaFuncNode.html create mode 100644 structentt_1_1internal_1_1MetaFuncNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaFuncNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaFuncNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaInfo-members.html create mode 100644 structentt_1_1internal_1_1MetaInfo.html create mode 100644 structentt_1_1internal_1_1MetaInfo__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaInfo__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaInfo__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaInfo__inherit__graph.map create mode 100644 structentt_1_1internal_1_1MetaInfo__inherit__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaInfo__inherit__graph.png create mode 100644 structentt_1_1internal_1_1MetaNode-members.html create mode 100644 structentt_1_1internal_1_1MetaNode.html create mode 100644 structentt_1_1internal_1_1MetaNode_3_01Type_01_4-members.html create mode 100644 structentt_1_1internal_1_1MetaNode_3_01Type_01_4.html create mode 100644 structentt_1_1internal_1_1MetaNode_3_01Type_01_4__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaNode_3_01Type_01_4__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaNode_3_01Type_01_4__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaPropNode-members.html create mode 100644 structentt_1_1internal_1_1MetaPropNode.html create mode 100644 structentt_1_1internal_1_1MetaPropNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaPropNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaPropNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1MetaTypeNode-members.html create mode 100644 structentt_1_1internal_1_1MetaTypeNode.html create mode 100644 structentt_1_1internal_1_1MetaTypeNode__coll__graph.map create mode 100644 structentt_1_1internal_1_1MetaTypeNode__coll__graph.md5 create mode 100644 structentt_1_1internal_1_1MetaTypeNode__coll__graph.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_00d602dc6ec169f254929375e78a46dac.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_015539704a649a59d142205c030330d2b.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0420e89fa634eb8a1fc577ac631093008.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0420e89fa634eb8a1fc577ac631093008.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0420e89fa634eb8a1fc577ac631093008.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0868046ef5528de2d018c38a0bece18e0.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_09ed366b0b925f8491739847cc864d665.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_09ed366b0b925f8491739847cc864d665.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_09ed366b0b925f8491739847cc864d665.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0a1cab8ad1dbb86fac6e7c34dde0c3c6b.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0c965b95e1f82696bad2e71b49fa6d8dd.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0c965b95e1f82696bad2e71b49fa6d8dd.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0c965b95e1f82696bad2e71b49fa6d8dd.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07Class_1_1_5_0fd3deeb7c311fb4d4563e7d5ae0b9955.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_502ffb16ff5bf47e94661cfa018f4eed.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_502ffb16ff5bf47e94661cfa018f4eed.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_502ffb16ff5bf47e94661cfa018f4eed.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_858d6f74f0eb72d4936c15a8caa3af63.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_d401927d8e36c51002e803efb588b956.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_eba2d57ab4ca242c26bb20abfcabfd26.map create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_eba2d57ab4ca242c26bb20abfcabfd26.md5 create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Ret_07_5_08_07Args_eba2d57ab4ca242c26bb20abfcabfd26.png create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Type_01Class_1_1_5_18969de809d65f64025243166eb229a2.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Type_01Class_1_1_5_a9c4ab474d7f81ef29f999b86b0cb449.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Type_01_5_00_01Data32bead6fb6a894c5b73d1813ddcab196.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01Type_01_5_00_01Datab92364bff7ad5f1dfeed3ce3d11c82e8.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01const_01Type_01Clas693684ab033d6c2c6a6373a3be8f3e53.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01const_01Type_01Clasc540f55fdf60969a618f02a1d390fabd.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01const_01Type_01_5_05e1cabbf44c196359d3ef7436afd34e3.html create mode 100644 structentt_1_1internal_1_1ReflectionHelper_3_01std_1_1integral__constant_3_01const_01Type_01_5_0b9659031a38e282dc2052fd28bd776a7.html create mode 100644 structentt_1_1internal_1_1TypeHelper-members.html create mode 100644 structentt_1_1internal_1_1TypeHelper.html create mode 100644 structentt_1_1internal_1_1TypeHelper_3_01void_01_4-members.html create mode 100644 structentt_1_1internal_1_1TypeHelper_3_01void_01_4.html create mode 100644 structentt_1_1internal_1_1Utils-members.html create mode 100644 structentt_1_1internal_1_1Utils.html diff --git a/CONTRIBUTING_8md_source.html b/CONTRIBUTING_8md_source.html index 980dcb744..65bcbca97 100644 --- a/CONTRIBUTING_8md_source.html +++ b/CONTRIBUTING_8md_source.html @@ -22,7 +22,7 @@
EnTT -  2.7.2 +  2.7.3
diff --git a/README_8md_source.html b/README_8md_source.html index c4a4f94bd..66bc75cf9 100644 --- a/README_8md_source.html +++ b/README_8md_source.html @@ -22,7 +22,7 @@
EnTT -  2.7.2 +  2.7.3
@@ -63,7 +63,7 @@ $(function() {
README.md
-
1 ![EnTT: Gaming meets modern C++](https://user-images.githubusercontent.com/1812216/42513718-ee6e98d0-8457-11e8-9baf-8d83f61a3097.png)
2 
3 <!--
4 @cond TURN_OFF_DOXYGEN
5 -->
6 [![Build Status](https://travis-ci.org/skypjack/entt.svg?branch=master)](https://travis-ci.org/skypjack/entt)
7 [![Build status](https://ci.appveyor.com/api/projects/status/rvhaabjmghg715ck?svg=true)](https://ci.appveyor.com/project/skypjack/entt)
8 [![Coverage Status](https://coveralls.io/repos/github/skypjack/entt/badge.svg?branch=master)](https://coveralls.io/github/skypjack/entt?branch=master)
9 [![Gitter chat](https://badges.gitter.im/skypjack/entt.png)](https://gitter.im/skypjack/entt)
10 [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=W2HF9FESD5LJY&lc=IT&item_name=Michele%20Caini&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted)
11 
12 # Table of Contents
13 
14 * [Introduction](#introduction)
15 * [Build Instructions](#build-instructions)
16 * [Crash Course: entity-component system](#crash-course-entity-component-system)
17  * [Design choices](#design-choices)
18  * [A bitset-free entity-component system](#a-bitset-free-entity-component-system)
19  * [Pay per use](#pay-per-use)
20  * [Vademecum](#vademecum)
21  * [The Registry, the Entity and the Component](#the-registry-the-entity-and-the-component)
22  * [Single instance components](#single-instance-components)
23  * [Observe changes](#observe-changes)
24  * [Who let the tags out?](#who-let-the-tags-out)
25  * [Runtime components](#runtime-components)
26  * [A journey through a plugin](#a-journey-through-a-plugin)
27  * [Sorting: is it possible?](#sorting-is-it-possible)
28  * [Snapshot: complete vs continuous](#snapshot-complete-vs-continuous)
29  * [Snapshot loader](#snapshot-loader)
30  * [Continuous loader](#continuous-loader)
31  * [Archives](#archives)
32  * [One example to rule them all](#one-example-to-rule-them-all)
33  * [Prototype](#prototype)
34  * [Helpers](#helpers)
35  * [Dependency function](#dependency-function)
36  * [Labels](#labels)
37  * [Null entity](#null-entity)
38  * [View: to persist or not to persist?](#view-to-persist-or-not-to-persist)
39  * [Standard View](#standard-view)
40  * [Single component standard view](#single-component-standard-view)
41  * [Multi component standard view](#multi-component-standard-view)
42  * [Persistent View](#persistent-view)
43  * [Raw View](#raw-view)
44  * [Runtime View](#runtime-view)
45  * [Give me everything](#give-me-everything)
46  * [Iterations: what is allowed and what is not](#iterations-what-is-allowed-and-what-is-not)
47  * [Multithreading](#multithreading)
48 * [Crash Course: core functionalities](#crash-course-core-functionalities)
49  * [Compile-time identifiers](#compile-time-identifiers)
50  * [Runtime identifiers](#runtime-identifiers)
51  * [Hashed strings](#hashed-strings)
52  * [Monostate](#monostate)
53 * [Crash Course: service locator](#crash-course-service-locator)
54 * [Crash Course: cooperative scheduler](#crash-course-cooperative-scheduler)
55  * [The process](#the-process)
56  * [The scheduler](#the-scheduler)
57 * [Crash Course: resource management](#crash-course-resource-management)
58  * [The resource, the loader and the cache](#the-resource-the-loader-and-the-cache)
59 * [Crash Course: events, signals and everything in between](#crash-course-events-signals-and-everything-in-between)
60  * [Signals](#signals)
61  * [Delegate](#delegate)
62  * [Event dispatcher](#event-dispatcher)
63  * [Event emitter](#event-emitter)
64 * [Packaging Tools](#packaging-tools)
65 * [EnTT in Action](#entt-in-action)
66 * [License](#license)
67 * [Support](#support)
68  * [Donation](#donation)
69  * [Hire me](#hire-me)
70 <!--
71 @endcond TURN_OFF_DOXYGEN
72 -->
73 
74 # Introduction
75 
76 `EnTT` is a header-only, tiny and easy to use entity-component system (and much
77 more) written in modern C++.<br/>
78 The entity-component-system (also known as _ECS_) is an architectural pattern
79 used mostly in game development. For further details:
80 
81 * [Entity Systems Wiki](http://entity-systems.wikidot.com/)
82 * [Evolve Your Hierarchy](http://cowboyprogramming.com/2007/01/05/evolve-your-heirachy/)
83 * [ECS on Wikipedia](https://en.wikipedia.org/wiki/Entity%E2%80%93component%E2%80%93system)
84 
85 A long time ago, the sole entity-component system was part of the project. After
86 a while the codebase has grown and more and more classes have become part of the
87 repository.<br/>
88 Here is a brief, yet incomplete list of what it offers today:
89 
90 * Statically generated integer identifiers for types (assigned either at
91  compile-time or at runtime).
92 * A constexpr utility for human readable resource identifiers.
93 * A minimal configuration system built on top of the monostate pattern.
94 * An incredibly fast entity-component system based on sparse sets, with its own
95  views and a _pay for what you use_ policy to adjust performance and memory
96  usage according to users' requirements.
97 * Actor class for those who aren't confident with entity-component systems.
98 * The smallest and most basic implementation of a service locator ever seen.
99 * A cooperative scheduler for processes of any type.
100 * All what is needed for resource management (cache, loaders, handles).
101 * Delegates, signal handlers (with built-in support for collectors) and a tiny
102  event dispatcher.
103 * A general purpose event emitter, that is a CRTP idiom based class template.
104 * An event dispatcher for immediate and delayed events to integrate in loops.
105 * ...
106 * Any other business.
107 
108 Consider it a work in progress. The whole API is also fully documented in-code
109 for those who are brave enough to read it.
110 
111 Currently, `EnTT` is tested on Linux, Microsoft Windows and OS X. It has proven
112 to work also on both Android and iOS.<br/>
113 Most likely it will not be problematic on other systems as well, but has not
114 been sufficiently tested so far.
115 
116 ## Code Example
117 
118 ```cpp
119 #include <entt/entt.hpp>
120 #include <cstdint>
121 
122 struct Position {
123  float x;
124  float y;
125 };
126 
127 struct Velocity {
128  float dx;
129  float dy;
130 };
131 
132 void update(entt::DefaultRegistry &registry) {
133  auto view = registry.view<Position, Velocity>();
134 
135  for(auto entity: view) {
136  // gets only the components that are going to be used ...
137 
138  auto &velocity = view.get<Velocity>(entity);
139 
140  velocity.dx = 0.;
141  velocity.dy = 0.;
142 
143  // ...
144  }
145 }
146 
147 void update(std::uint64_t dt, entt::DefaultRegistry &registry) {
148  registry.view<Position, Velocity>().each([dt](auto entity, auto &position, auto &velocity) {
149  // gets all the components of the view at once ...
150 
151  position.x += velocity.dx * dt;
152  position.y += velocity.dy * dt;
153 
154  // ...
155  });
156 }
157 
158 int main() {
159  entt::DefaultRegistry registry;
160  std::uint64_t dt = 16;
161 
162  for(auto i = 0; i < 10; ++i) {
163  auto entity = registry.create();
164  registry.assign<Position>(entity, i * 1.f, i * 1.f);
165  if(i % 2 == 0) { registry.assign<Velocity>(entity, i * .1f, i * .1f); }
166  }
167 
168  update(dt, registry);
169  update(registry);
170 
171  // ...
172 }
173 ```
174 
175 ## Motivation
176 
177 I started working on `EnTT` because of the wrong reason: my goal was to design
178 an entity-component system that beated another well known open source solution
179 in terms of performance and used (possibly) less memory in the average
180 case.<br/>
181 In the end, I did it, but it wasn't much satisfying. Actually it wasn't
182 satisfying at all. The fastest and nothing more, fairly little indeed. When I
183 realized it, I tried hard to keep intact the great performance of `EnTT` and to
184 add all the features I wanted to see in *my own library* at the same time.
185 
186 Nowadays, `EnTT` is finally what I was looking for: still faster than its
187 _competitors_, lower memory usage in the average case, a really good API and an
188 amazing set of features. And even more, of course.
189 
190 ## Performance
191 
192 As it stands right now, `EnTT` is just fast enough for my requirements if
193 compared to my first choice (it was already amazingly fast actually).<br/>
194 Below is a comparison between the two (both of them compiled with GCC 7.3.0 on a
195 Dell XPS 13 out of the mid 2014):
196 
197 | Benchmark | EntityX (compile-time) | EnTT |
198 |-----------|-------------|-------------|
199 | Create 1M entities | 0.0147s | **0.0046s** |
200 | Destroy 1M entities | 0.0053s | **0.0045s** |
201 | 1M entities, one component | 0.0012s | **1.9e-07s** |
202 | 1M entities, two components | 0.0012s | **3.8e-07s** |
203 | 1M entities, two components<br/>Half of the entities have all the components | 0.0009s | **3.8e-07s** |
204 | 1M entities, two components<br/>One of the entities has all the components | 0.0008s | **1.0e-06s** |
205 | 1M entities, five components | 0.0010s | **7.0e-07s** |
206 | 1M entities, ten components | 0.0011s | **1.2e-06s** |
207 | 1M entities, ten components<br/>Half of the entities have all the components | 0.0010s | **1.2e-06s** |
208 | 1M entities, ten components<br/>One of the entities has all the components | 0.0008s | **1.2e-06s** |
209 | Sort 150k entities, one component<br/>Arrays are in reverse order | - | **0.0036s** |
210 | Sort 150k entities, enforce permutation<br/>Arrays are in reverse order | - | **0.0005s** |
211 | Sort 150k entities, one component<br/>Arrays are almost sorted, std::sort | - | **0.0035s** |
212 | Sort 150k entities, one component<br/>Arrays are almost sorted, insertion sort | - | **0.0007s** |
213 
214 Note: The default version of `EntityX` (`master` branch) wasn't added to the
215 comparison because it's already much slower than its compile-time counterpart.
216 
217 Pretty interesting, aren't them? In fact, these benchmarks are the same used by
218 `EntityX` to show _how fast it is_. To be honest, they aren't so good and these
219 results shouldn't be taken much seriously (they are completely unrealistic
220 indeed).<br/>
221 The proposed entity-component system is incredibly fast to iterate entities,
222 this is a fact. The compiler can make a lot of optimizations because of how
223 `EnTT` works, even more when components aren't used at all. This is exactly the
224 case for these benchmarks. On the other hand and if we consider real world
225 cases, `EnTT` is in the middle between a bit and much faster than the other
226 solutions around when users also access the components and not just the
227 entities, although it is not as fast as reported by these benchmarks.<br/>
228 This is why they are completely wrong and cannot be used to evaluate any of the
229 entity-component systems.
230 
231 If you decide to use `EnTT`, choose it because of its API, features and
232 performance, not because there is a benchmark somewhere that makes it seem the
233 fastest.
234 
235 Probably I'll try to get out of `EnTT` more features and even better performance
236 in the future, mainly for fun.<br/>
237 If you want to contribute and/or have any suggestion, feel free to make a PR or
238 open an issue to discuss your idea.
239 
240 # Build Instructions
241 
242 ## Requirements
243 
244 To be able to use `EnTT`, users must provide a full-featured compiler that
245 supports at least C++14.<br/>
246 The requirements below are mandatory to compile the tests and to extract the
247 documentation:
248 
249 * CMake version 3.2 or later.
250 * Doxygen version 1.8 or later.
251 
252 ## Library
253 
254 `EnTT` is a header-only library. This means that including the `entt.hpp` header
255 is enough to include the library as a whole and use it. For those who are
256 interested only in the entity-component system, consider to include the sole
257 `entity/registry.hpp` header instead.<br/>
258 It's a matter of adding the following line to the top of a file:
259 
260 ```cpp
261 #include <entt/entt.hpp>
262 ```
263 
264 Use the line below to include only the entity-component system instead:
265 
266 ```cpp
267 #include <entt/entity/registry.hpp>
268 ```
269 
270 Then pass the proper `-I` argument to the compiler to add the `src` directory to
271 the include paths.
272 
273 ### Side note: shared libraries
274 
275 To make sure that an application and a shared library that use both `EnTT` can
276 interact correctly when symbols are hidden by default, there are some tricks to
277 follow.<br/>
278 In particular and in order to avoid undefined behaviors, all the instantiation
279 of the `Family` class template shall be made explicit along with the system-wide
280 specifier to use to export them.
281 
282 At the time I'm writing this document, the classes that use internally the above
283 mentioned class template are `Dispatcher`, `Emitter` and `Registry`. Therefore
284 and as an example, if you use the `Registry` class template in your shared
285 library and want to set symbols visibility to _hidden_ by default, the following
286 lines are required to allow it to function properly with a client that also uses
287 the `Registry` somehow:
288 
289 * On GNU/Linux:
290 
291  ```cpp
292  namespace entt {
293  template class __attribute__((visibility("default"))) Family<struct InternalRegistryTagFamily>;
294  template class __attribute__((visibility("default"))) Family<struct InternalRegistryComponentFamily>;
295  template class __attribute__((visibility("default"))) Family<struct InternalRegistryHandlerFamily>;
296  }
297  ```
298 
299 * On Windows:
300 
301  ```cpp
302  namespace entt {
303  template class __declspec(dllexport) Family<struct InternalRegistryTagFamily>;
304  template class __declspec(dllexport) Family<struct InternalRegistryComponentFamily>;
305  template class __declspec(dllexport) Family<struct InternalRegistryHandlerFamily>;
306  }
307  ```
308 
309 Otherwise, the risk is that type identifiers are different between the shared
310 library and the application and this will prevent the whole thing from
311 functioning correctly for obvious reasons.
312 
313 ## Documentation
314 
315 The documentation is based on [doxygen](http://www.stack.nl/~dimitri/doxygen/).
316 To build it:
317 
318  $ cd build
319  $ cmake .. -DBUILD_DOCS=ON
320  $ make
321 
322 The API reference will be created in HTML format within the directory
323 `build/docs/html`. To navigate it with your favorite browser:
324 
325  $ cd build
326  $ your_favorite_browser docs/html/index.html
327 
328 <!--
329 @cond TURN_OFF_DOXYGEN
330 -->
331 The API reference is also available [online](https://skypjack.github.io/entt/)
332 for the latest version.
333 <!--
334 @endcond TURN_OFF_DOXYGEN
335 -->
336 
337 ## Tests
338 
339 To compile and run the tests, `EnTT` requires *googletest*.<br/>
340 `cmake` will download and compile the library before compiling anything else.
341 In order to build without tests set CMake option `BUILD_TESTING=OFF`.
342 
343 To build the most basic set of tests:
344 
345 * `$ cd build`
346 * `$ cmake ..`
347 * `$ make`
348 * `$ make test`
349 
350 Note that benchmarks are not part of this set.
351 
352 # Crash Course: entity-component system
353 
354 ## Design choices
355 
356 ### A bitset-free entity-component system
357 
358 `EnTT` is a _bitset-free_ entity-component system that doesn't require users to
359 specify the component set at compile-time.<br/>
360 This is why users can instantiate the core class simply like:
361 
362 ```cpp
363 entt::DefaultRegistry registry;
364 ```
365 
366 In place of its more annoying and error-prone counterpart:
367 
368 ```cpp
369 entt::DefaultRegistry<Comp0, Comp1, ..., CompN> registry;
370 ```
371 
372 ### Pay per use
373 
374 `EnTT` is entirely designed around the principle that users have to pay only for
375 what they want.
376 
377 When it comes to using an entity-component system, the tradeoff is usually
378 between performance and memory usage. The faster it is, the more memory it uses.
379 However, slightly worse performance along non-critical paths are the right price
380 to pay to reduce memory usage and I've always wondered why this kind of tools do
381 not leave me the choice.<br/>
382 `EnTT` follows a completely different approach. It squeezes the best from the
383 basic data structures and gives users the possibility to pay more for higher
384 performance where needed.<br/>
385 The disadvantage of this approach is that users need to know the systems they
386 are working on and the tools they are using. Otherwise, the risk to ruin the
387 performance along critical paths is high.
388 
389 So far, this choice has proven to be a good one and I really hope it can be for
390 many others besides me.
391 
392 ## Vademecum
393 
394 The `Registry` to store, the views to iterate. That's all.
395 
396 An entity (the _E_ of an _ECS_) is an opaque identifier that users should just
397 use as-is and store around if needed. Do not try to inspect an entity
398 identifier, its format can change in future and a registry offers all the
399 functionalities to query them out-of-the-box. The underlying type of an entity
400 (either `std::uint16_t`, `std::uint32_t` or `std::uint64_t`) can be specified
401 when defining a registry (actually the `DefaultRegistry` is nothing more than a
402 `Registry` where the type of the entities is `std::uint32_t`).<br/>
403 Components (the _C_ of an _ECS_) should be plain old data structures or more
404 complex and movable data structures with a proper constructor. Actually, the
405 sole requirement of a component type is that it must be both move constructible
406 and move assignable. They are list initialized by using the parameters provided
407 to construct the component itself. No need to register components or their types
408 neither with the registry nor with the entity-component system at all.<br/>
409 Systems (the _S_ of an _ECS_) are just plain functions, functors, lambdas or
410 whatever users want. They can accept a `Registry` or a view of any type and use
411 them the way they prefer. No need to register systems or their types neither
412 with the registry nor with the entity-component system at all.
413 
414 The following sections will explain in short how to use the entity-component
415 system, the core part of the whole library.<br/>
416 In fact, the project is composed of many other classes in addition to those
417 describe below. For more details, please refer to the inline documentation.
418 
419 ## The Registry, the Entity and the Component
420 
421 A registry can store and manage entities, as well as create views to iterate the
422 underlying data structures.<br/>
423 `Registry` is a class template that lets users decide what's the preferred type
424 to represent an entity. Because `std::uint32_t` is large enough for almost all
425 the cases, there exists also an alias named `DefaultRegistry` for
426 `Registry<std::uint32_t>`.
427 
428 Entities are represented by _entity identifiers_. An entity identifier is an
429 opaque type that users should not inspect or modify in any way. It carries
430 information about the entity itself and its version.
431 
432 A registry can be used both to construct and destroy entities:
433 
434 ```cpp
435 // constructs a naked entity with no components and returns its identifier
436 auto entity = registry.create();
437 
438 // destroys an entity and all its components
439 registry.destroy(entity);
440 ```
441 
442 Entities can also be destroyed _by type_, that is by specifying the types of the
443 tags or components that identify them:
444 
445 ```cpp
446 // destroys the entity that owns the given tag, if any
447 registry.destroy<MyTag>(entt::tag_t{});
448 
449 // destroys the entities that own the given components, if any
450 registry.destroy<AComponent, AnotherComponent>();
451 ```
452 
453 When an entity is destroyed, the registry can freely reuse it internally with a
454 slightly different identifier. In particular, the version of an entity is
455 increased each and every time it's discarded.<br/>
456 In case entity identifiers are stored around, the registry offers all the
457 functionalities required to test them and get out of the them all the
458 information they carry:
459 
460 ```cpp
461 // returns true if the entity is still valid, false otherwise
462 bool b = registry.valid(entity);
463 
464 // gets the version contained in the entity identifier
465 auto version = registry.version(entity);
466 
467 // gets the actual version for the given entity
468 auto curr = registry.current(entity);
469 ```
470 
471 Components can be assigned to or removed from entities at any time with a few
472 calls to member functions of the registry. As for the entities, the registry
473 offers also a set of functionalities users can use to work with the components.
474 
475 The `assign` member function template creates, initializes and assigns to an
476 entity the given component. It accepts a variable number of arguments to
477 construct the component itself if present:
478 
479 ```cpp
480 registry.assign<Position>(entity, 0., 0.);
481 
482 // ...
483 
484 Velocity &velocity = registry.assign<Velocity>(entity);
485 velocity.dx = 0.;
486 velocity.dy = 0.;
487 ```
488 
489 If an entity already has the given component, the `replace` member function
490 template can be used to replace it:
491 
492 ```cpp
493 registry.replace<Position>(entity, 0., 0.);
494 
495 // ...
496 
497 Velocity &velocity = registry.replace<Velocity>(entity);
498 velocity.dx = 0.;
499 velocity.dy = 0.;
500 ```
501 
502 In case users want to assign a component to an entity, but it's unknown whether
503 the entity already has it or not, `accommodate` does the work in a single call
504 (there is a performance penalty to pay for this mainly due to the fact that it
505 has to check if the entity already has the given component or not):
506 
507 ```cpp
508 registry.accommodate<Position>(entity, 0., 0.);
509 
510 // ...
511 
512 Velocity &velocity = registry.accommodate<Velocity>(entity);
513 velocity.dx = 0.;
514 velocity.dy = 0.;
515 ```
516 
517 Note that `accommodate` is a slightly faster alternative for the following
518 `if/else` statement and nothing more:
519 
520 ```cpp
521 if(registry.has<Comp>(entity)) {
522  registry.replace<Comp>(entity, arg1, argN);
523 } else {
524  registry.assign<Comp>(entity, arg1, argN);
525 }
526 ```
527 
528 As already shown, if in doubt about whether or not an entity has one or more
529 components, the `has` member function template may be useful:
530 
531 ```cpp
532 bool b = registry.has<Position, Velocity>(entity);
533 ```
534 
535 On the other side, if the goal is to delete a single component, the `remove`
536 member function template is the way to go when it's certain that the entity owns
537 a copy of the component:
538 
539 ```cpp
540 registry.remove<Position>(entity);
541 ```
542 
543 Otherwise consider to use the `reset` member function. It behaves similarly to
544 `remove` but with a strictly defined behavior (and a performance penalty is the
545 price to pay for this). In particular it removes the component if and only if it
546 exists, otherwise it returns safely to the caller:
547 
548 ```cpp
549 registry.reset<Position>(entity);
550 ```
551 
552 There exist also two other _versions_ of the `reset` member function:
553 
554 * If no entity is passed to it, `reset` will remove the given component from
555  each entity that has it:
556 
557  ```cpp
558  registry.reset<Position>();
559  ```
560 
561 * If neither the entity nor the component are specified, all the entities still
562  in use and their components are destroyed:
563 
564  ```cpp
565  registry.reset();
566  ```
567 
568 Finally, references to components can be retrieved simply by doing this:
569 
570 ```cpp
571 const auto &cregistry = registry;
572 
573 // const and non-const reference
574 const Position &position = cregistry.get<Position>(entity);
575 Position &position = registry.get<Position>(entity);
576 
577 // const and non-const references
578 std::tuple<const Position &, const Velocity &> tup = cregistry.get<Position, Velocity>(entity);
579 std::tuple<Position &, Velocity &> tup = registry.get<Position, Velocity>(entity);
580 ```
581 
582 The `get` member function template gives direct access to the component of an
583 entity stored in the underlying data structures of the registry.
584 
585 ### Single instance components
586 
587 In those cases where all what is needed is a single instance component, tags are
588 the right tool to achieve the purpose.<br/>
589 Tags undergo the same requirements of components. They can be either plain old
590 data structures or more complex and movable data structures with a proper
591 constructor.<br/>
592 Actually, the same type can be used both as a tag and as a component and the
593 registry will not complain about it. It is up to users to properly manage their
594 own types. In some cases, the tag `tag_t` must also be used in order to
595 disambiguate overloads of member functions.
596 
597 Attaching tags to entities and removing them is trivial:
598 
599 ```cpp
600 auto player = registry.create();
601 auto camera = registry.create();
602 
603 // attaches a default-initialized tag to an entity
604 registry.assign<PlayingCharacter>(entt::tag_t{}, player);
605 
606 // attaches a tag to an entity and initializes it
607 registry.assign<Camera>(entt::tag_t{}, camera, player);
608 
609 // removes tags from their owners
610 registry.remove<PlayingCharacter>();
611 registry.remove<Camera>();
612 ```
613 
614 In case a tag already has an owner, its content can be updated by means of the
615 `replace` member function template and the ownership of the tag can be
616 transferred to another entity using the `move` member function template:
617 
618 ```
619 // replaces the content of the given tag
620 Point &point = registry.replace<Point>(entt::tag_t{}, 1.f, 1.f);
621 
622 // transfers the ownership of the tag to another entity
623 entity_type prev = registry.move<Point>(next);
624 ```
625 
626 If in doubt about whether or not a tag already has an owner, the `has` member
627 function template may be useful:
628 
629 ```cpp
630 bool b = registry.has<PlayingCharacter>();
631 ```
632 
633 References to tags can be retrieved simply by doing this:
634 
635 ```cpp
636 const auto &cregistry = registry;
637 
638 // either a non-const reference ...
639 PlayingCharacter &player = registry.get<PlayingCharacter>();
640 
641 // ... or a const one
642 const Camera &camera = cregistry.get<Camera>();
643 ```
644 
645 The `get` member function template gives direct access to the tag as stored in
646 the underlying data structures of the registry.
647 
648 As shown above, in almost all the cases the entity identifier isn't required.
649 Since a single instance component can have only one associated entity, it
650 doesn't make much sense to mention it explicitly.<br/>
651 To find out who the owner is, just do the following:
652 
653 ```cpp
654 auto player = registry.attachee<PlayingCharacter>();
655 ```
656 
657 Note that iterating tags isn't possible for obvious reasons. Tags give direct
658 access to single entities and nothing more.
659 
660 ### Observe changes
661 
662 Because of how the registry works internally, it stores a couple of signal
663 handlers for each pool in order to notify some of its data structures on the
664 construction and destruction of components.<br/>
665 These signal handlers are also exposed and made available to users. This is the
666 basic brick to build fancy things like dependencies and reactive systems.
667 
668 To get a sink to be used to connect and disconnect listeners so as to be
669 notified on the creation of a component, use the `construction` member function:
670 
671 ```cpp
672 // connects a free function
673 registry.construction<Position>().connect<&MyFreeFunction>();
674 
675 // connects a member function
676 registry.construction<Position>().connect<MyClass, &MyClass::member>(&instance);
677 
678 // disconnects a free function
679 registry.construction<Position>().disconnect<&MyFreeFunction>();
680 
681 // disconnects a member function
682 registry.construction<Position>().disconnect<MyClass, &MyClass::member>(&instance);
683 ```
684 
685 To be notified when components are destroyed, use the `destruction` member
686 function instead.
687 
688 The function type of a listener is the same in both cases:
689 
690 ```cpp
691 void(Registry<Entity> &, Entity);
692 ```
693 
694 In other terms, a listener is provided with the registry that triggered the
695 notification and the entity affected by the change. Note also that:
696 
697 * Listeners are invoked **after** components have been assigned to entities.
698 * Listeners are invoked **before** components have been removed from entities.
699 * The order of invocation of the listeners isn't guaranteed in any case.
700 
701 There are also some limitations on what a listener can and cannot do. In
702 particular:
703 
704 * Connecting and disconnecting other functions from within the body of a
705  listener should be avoided. It can lead to undefined behavior in some cases.
706 * Assigning and removing components and tags from within the body of a listener
707  that observes the destruction of instances of a given type should be avoided.
708  It can lead to undefined behavior in some cases. This type of listeners is
709  intended to provide users with an easy way to perform cleanup and nothing
710  more.
711 
712 To a certain extent, these limitations do not apply. However, it is risky to try
713 to force them and users should respect the limitations unless they know exactly
714 what they are doing. Subtle bugs are the price to pay in case of errors
715 otherwise.
716 
717 In general, events and therefore listeners must not be used as replacements for
718 systems. They should not contain much logic and interactions with a registry
719 should be kept to a minimum, if possible. Note also that the greater the number
720 of listeners, the greater the performance hit when components are created or
721 destroyed.
722 
723 #### Who let the tags out?
724 
725 As an extension, signals are also provided with tags. Although they are not
726 strictly required internally, it makes sense that a user expects signal support
727 even when it comes to tags actually.<br/>
728 Signals for tags undergo exactly the same requirements of those introduced for
729 components. Also the function type for a listener is the same and it's invoked
730 with the same guarantees discussed above.
731 
732 To get the sinks for a tag just use tag `tag_t` to disambiguate overloads of
733 member functions as in the following example:
734 
735 ```cpp
736 registry.construction<MyTag>(entt::tag_t{}).connect<&MyFreeFunction>();
737 registry.destruction<MyTag>(entt::tag_t{}).connect<MyClass, &MyClass::member>(&instance);
738 ```
739 
740 Listeners for tags and components are managed separately and do not influence
741 each other in any case. Therefore, note that the greater the number of listeners
742 for a type, the greater the performance hit when a tag of the given type is
743 created or destroyed.
744 
745 ### Runtime components
746 
747 Defining components at runtime is useful to support plugin systems and mods in
748 general. However, it seems impossible with a tool designed around a bunch of
749 templates. Indeed it's not that difficult.<br/>
750 Of course, some features cannot be easily exported into a runtime
751 environment. As an example, sorting a group of components defined at runtime
752 isn't for free if compared to most of the other operations. However, the basic
753 functionalities of an entity-component system such as `EnTT` fit the problem
754 perfectly and can also be used to manage runtime components if required.<br/>
755 All that is necessary to do it is to know the identifiers of the components. An
756 identifier is nothing more than a number or similar that can be used at runtime
757 to work with the type system.
758 
759 In `EnTT`, identifiers are easily accessible:
760 
761 ```cpp
762 entt::DefaultRegistry registry;
763 
764 // standard component identifier
765 auto ctype = registry.type<Position>();
766 
767 // single instance component identifier
768 auto ttype = registry.type<PlayingCharacter>(entt::tag_t{});
769 ```
770 
771 Once the identifiers are made available, almost everything becomes pretty
772 simple.
773 
774 #### A journey through a plugin
775 
776 `EnTT` comes with an example (actually a test) that shows how to integrate
777 compile-time and runtime components in a stack based JavaScript environment. It
778 uses [`Duktape`](https://github.com/svaarala/duktape) under the hood, mainly
779 because I wanted to learn how it works at the time I was writing the code.
780 
781 The code is not production-ready and overall performance can be highly improved.
782 However, I sacrificed optimizations in favor of a more readable piece of code. I
783 hope I succeeded.<br/>
784 Note also that this isn't neither the only nor (probably) the best way to do it.
785 In fact, the right way depends on the scripting language and the problem one is
786 facing in general.<br/>
787 That being said, feel free to use it at your own risk.
788 
789 The basic idea is that of creating a compile-time component aimed to map all the
790 runtime components assigned to an entity.<br/>
791 Identifiers come in use to address the right function from a map when invoked
792 from the runtime environment and to filter entities when iterating.<br/>
793 With a bit of gymnastic, one can narrow views and improve the performance to
794 some extent but it was not the goal of the example.
795 
796 ### Sorting: is it possible?
797 
798 It goes without saying that sorting entities and components is possible with
799 `EnTT`.<br/>
800 In fact, there are two functions that respond to slightly different needs:
801 
802 * Components can be sorted directly:
803 
804  ```cpp
805  registry.sort<Renderable>([](const auto &lhs, const auto &rhs) {
806  return lhs.z < rhs.z;
807 
808  });
809  ```
810 
811  There exists also the possibility to use a custom sort function object, as
812  long as it adheres to the requirements described in the inline
813  documentation.<br/>
814  This is possible mainly because users can get much more with a custom sort
815  function object if the pattern of usage is known. As an example, in case of an
816  almost sorted pool, quick sort could be much, much slower than insertion sort.
817 
818 * Components can be sorted according to the order imposed by another component:
819 
820  ```cpp
821  registry.sort<Movement, Physics>();
822  ```
823 
824  In this case, instances of `Movement` are arranged in memory so that cache
825  misses are minimized when the two components are iterated together.
826 
827 ### Snapshot: complete vs continuous
828 
829 The `Registry` class offers basic support to serialization.<br/>
830 It doesn't convert components and tags to bytes directly, there wasn't the need
831 of another tool for serialization out there. Instead, it accepts an opaque
832 object with a suitable interface (namely an _archive_) to serialize its internal
833 data structures and restore them later. The way types and instances are
834 converted to a bunch of bytes is completely in charge to the archive and thus to
835 final users.
836 
837 The goal of the serialization part is to allow users to make both a dump of the
838 entire registry or a narrower snapshot, that is to select only the components
839 and the tags in which they are interested.<br/>
840 Intuitively, the use cases are different. As an example, the first approach is
841 suitable for local save/restore functionalities while the latter is suitable for
842 creating client-server applications and for transferring somehow parts of the
843 representation side to side.
844 
845 To take a snapshot of the registry, use the `snapshot` member function. It
846 returns a temporary object properly initialized to _save_ the whole registry or
847 parts of it.
848 
849 Example of use:
850 
851 ```cpp
852 OutputArchive output;
853 
854 registry.snapshot()
855  .entities(output)
856  .destroyed(output)
857  .component<AComponent, AnotherComponent>(output)
858  .tag<MyTag>(output);
859 ```
860 
861 It isn't necessary to invoke all these functions each and every time. What
862 functions to use in which case mostly depends on the goal and there is not a
863 golden rule to do that.
864 
865 The `entities` member function asks the registry to serialize all the entities
866 that are still in use along with their versions. On the other side, the
867 `destroyed` member function tells to the registry to serialize the entities that
868 have been destroyed and are no longer in use.<br/>
869 These two functions can be used to save and restore the whole set of entities
870 with the versions they had during serialization.
871 
872 The `component` member function is a function template the aim of which is to
873 store aside components. The presence of a template parameter list is a
874 consequence of a couple of design choices from the past and in the present:
875 
876 * First of all, there is no reason to force a user to serialize all the
877  components at once and most of the times it isn't desiderable. As an example,
878  in case the stuff for the HUD in a game is put into the registry for some
879  reasons, its components can be freely discarded during a serialization step
880  because probably the software already knows how to reconstruct the HUD
881  correctly from scratch.
882 
883 * Furthermore, the registry makes heavy use of _type-erasure_ techniques
884  internally and doesn't know at any time what types of components it contains.
885  Therefore being explicit at the call point is mandatory.
886 
887 There exists also another version of the `component` member function that
888 accepts a range of entities to serialize. This version is a bit slower than the
889 other one, mainly because it iterates the range of entities more than once for
890 internal purposes. However, it can be used to filter out those entities that
891 shouldn't be serialized for some reasons.<br/>
892 As an example:
893 
894 ```cpp
895 const auto view = registry.view<Serialize>();
896 OutputArchive output;
897 
898 registry.snapshot()
899  .component<AComponent, AnotherComponent>(output, view.cbegin(), view.cend());
900 ```
901 
902 The `tag` member function is similar to the previous one, apart from the fact
903 that it works with tags and not with components.<br/>
904 Note also that both `component` and `tag` store items along with entities. It
905 means that they work properly without a call to the `entities` member function.
906 
907 Once a snapshot is created, there exist mainly two _ways_ to load it: as a whole
908 and in a kind of _continuous mode_.<br/>
909 The following sections describe both loaders and archives in details.
910 
911 #### Snapshot loader
912 
913 A snapshot loader requires that the destination registry be empty and loads all
914 the data at once while keeping intact the identifiers that the entities
915 originally had.<br/>
916 To do that, the registry offers a member function named `restore` that returns a
917 temporary object properly initialized to _restore_ a snapshot.
918 
919 Example of use:
920 
921 ```cpp
922 InputArchive input;
923 
924 registry.restore()
925  .entities(input)
926  .destroyed(input)
927  .component<AComponent, AnotherComponent>(input)
928  .tag<MyTag>(input)
929  .orphans();
930 ```
931 
932 It isn't necessary to invoke all these functions each and every time. What
933 functions to use in which case mostly depends on the goal and there is not a
934 golden rule to do that. For obvious reasons, what is important is that the data
935 are restored in exactly the same order in which they were serialized.
936 
937 The `entities` and `destroyed` member functions restore the sets of entities and
938 the versions that the entities originally had at the source.
939 
940 The `component` member function restores all and only the components specified
941 and assigns them to the right entities. Note that the template parameter list
942 must be exactly the same used during the serialization. The same applies to the
943 `tag` member function.
944 
945 The `orphans` member function literally destroys those entities that have
946 neither components nor tags. It's usually useless if the snapshot is a full dump
947 of the source. However, in case all the entities are serialized but only few
948 components and tags are saved, it could happen that some of the entities have
949 neither components nor tags once restored. The best users can do to deal with
950 them is to destroy those entities and thus update their versions.
951 
952 #### Continuous loader
953 
954 A continuous loader is designed to load data from a source registry to a
955 (possibly) non-empty destination. The loader can accommodate in a registry more
956 than one snapshot in a sort of _continuous loading_ that updates the
957 destination one step at a time.<br/>
958 Identifiers that entities originally had are not transferred to the target.
959 Instead, the loader maps remote identifiers to local ones while restoring a
960 snapshot. Because of that, this kind of loader offers a way to update
961 automatically identifiers that are part of components or tags (as an example, as
962 data members or gathered in a container).<br/>
963 Another difference with the snapshot loader is that the continuous loader does
964 not need to work with the private data structures of a registry. Furthermore, it
965 has an internal state that must persist over time. Therefore, there is no reason
966 to create it by means of a registry, or to limit its lifetime to that of a
967 temporary object.
968 
969 Example of use:
970 
971 ```cpp
972 entt::ContinuousLoader<entity_type> loader{registry};
973 InputArchive input;
974 
975 loader.entities(input)
976  .destroyed(input)
977  .component<AComponent, AnotherComponent, DirtyComponent>(input, &DirtyComponent::parent, &DirtyComponent::child)
978  .tag<MyTag, DirtyTag>(input, &DirtyTag::container)
979  .orphans()
980  .shrink();
981 ```
982 
983 It isn't necessary to invoke all these functions each and every time. What
984 functions to use in which case mostly depends on the goal and there is not a
985 golden rule to do that. For obvious reasons, what is important is that the data
986 are restored in exactly the same order in which they were serialized.
987 
988 The `entities` and `destroyed` member functions restore groups of entities and
989 map each entity to a local counterpart when required. In other terms, for each
990 remote entity identifier not yet registered by the loader, the latter creates a
991 local identifier so that it can keep the local entity in sync with the remote
992 one.
993 
994 The `component` and `tag` member functions restore all and only the components
995 and the tags specified and assign them to the right entities.<br/>
996 In case the component or the tag contains entities itself (either as data
997 members of type `entity_type` or as containers of entities), the loader can
998 update them automatically. To do that, it's enough to specify the data members
999 to update as shown in the example.
1000 
1001 The `orphans` member function literally destroys those entities that have
1002 neither components nor tags after a restore. It has exactly the same purpose
1003 described in the previous section and works the same way.
1004 
1005 Finally, `shrink` helps to purge local entities that no longer have a remote
1006 conterpart. Users should invoke this member function after restoring each
1007 snapshot, unless they know exactly what they are doing.
1008 
1009 #### Archives
1010 
1011 Archives must publicly expose a predefined set of member functions. The API is
1012 straightforward and consists only of a group of function call operators that
1013 are invoked by the snapshot class and the loaders.
1014 
1015 In particular:
1016 
1017 * An output archive, the one used when creating a snapshot, must expose a
1018  function call operator with the following signature to store entities:
1019 
1020  ```cpp
1021  void operator()(Entity);
1022  ```
1023 
1024  Where `Entity` is the type of the entities used by the registry. Note that all
1025  the member functions of the snapshot class make also an initial call to this
1026  endpoint to save the _size_ of the set they are going to store.<br/>
1027  In addition, an archive must accept a pair of entity and either component or
1028  tag for each type to be serialized. Therefore, given a type `T`, the archive
1029  must contain a function call operator with the following signature:
1030 
1031  ```cpp
1032  void operator()(Entity, const T &);
1033  ```
1034 
1035  The output archive can freely decide how to serialize the data. The register
1036  is not affected at all by the decision.
1037 
1038 * An input archive, the one used when restoring a snapshot, must expose a
1039  function call operator with the following signature to load entities:
1040 
1041  ```cpp
1042  void operator()(Entity &);
1043  ```
1044 
1045  Where `Entity` is the type of the entities used by the registry. Each time the
1046  function is invoked, the archive must read the next element from the
1047  underlying storage and copy it in the given variable. Note that all the member
1048  functions of a loader class make also an initial call to this endpoint to read
1049  the _size_ of the set they are going to load.<br/>
1050  In addition, the archive must accept a pair of entity and either component or
1051  tag for each type to be restored. Therefore, given a type `T`, the archive
1052  must contain a function call operator with the following signature:
1053 
1054  ```cpp
1055  void operator()(Entity &, T &);
1056  ```
1057 
1058  Every time such an operator is invoked, the archive must read the next
1059  elements from the underlying storage and copy them in the given variables.
1060 
1061 #### One example to rule them all
1062 
1063 `EnTT` comes with some examples (actually some tests) that show how to integrate
1064 a well known library for serialization as an archive. It uses
1065 [`Cereal C++`](https://uscilab.github.io/cereal/) under the hood, mainly
1066 because I wanted to learn how it works at the time I was writing the code.
1067 
1068 The code is not production-ready and it isn't neither the only nor (probably)
1069 the best way to do it. However, feel free to use it at your own risk.
1070 
1071 The basic idea is to store everything in a group of queues in memory, then bring
1072 everything back to the registry with different loaders.
1073 
1074 ### Prototype
1075 
1076 A prototype defines a type of an application in terms of its parts. They can be
1077 used to assign components to entities of a registry at once.<br/>
1078 Roughly speaking, in most cases prototypes can be considered just as templates
1079 to use to initialize entities according to _concepts_. In fact, users can create
1080 how many prototypes they want, each one initialized differently from the others.
1081 
1082 The following is an example of use of a prototype:
1083 
1084 ```cpp
1085 entt::DefaultRegistry registry;
1086 entt::DefaultPrototype prototype{registry};
1087 
1088 prototype.set<Position>(100.f, 100.f);
1089 prototype.set<Velocity>(0.f, 0.f);
1090 
1091 // ...
1092 
1093 const auto entity = prototype();
1094 ```
1095 
1096 To assign and remove components from a prototype, it offers two dedicated member
1097 functions named `set` and `unset`. The `has` member function can be used to know
1098 if a given prototype contains one or more components and the `get` member
1099 function can be used to retrieve the components.
1100 
1101 Creating an entity from a prototype is straightforward:
1102 
1103 * To create a new entity from scratch and assign it a prototype, this is the way
1104  to go:
1105  ```cpp
1106  const auto entity = prototype();
1107  ```
1108  It is equivalent to the following invokation:
1109  ```cpp
1110  const auto entity = prototype.create();
1111  ```
1112 
1113 * In case we want to initialize an already existing entity, we can provide the
1114  `operator()` directly with the entity identifier:
1115  ```cpp
1116  prototype(entity);
1117  ```
1118  It is equivalent to the following invokation:
1119  ```cpp
1120  prototype.assign(entity);
1121  ```
1122  Note that existing components aren't overwritten in this case. Only those
1123  components that the entity doesn't own yet are copied over. All the other
1124  components remain unchanged.
1125 
1126 * Finally, to assign or replace all the components for an entity, thus
1127  overwriting existing ones:
1128  ```cpp
1129  prototype.accommodate(entity);
1130  ```
1131 
1132 In the examples above, the prototype uses its underlying registry to create
1133 entities and components both for its purposes and when it's cloned. To use a
1134 different repository to clone a prototype, all the member functions accept also
1135 a reference to a valid registry as a first argument.
1136 
1137 Prototypes are a very useful tool that can save a lot of typing sometimes.
1138 Furthermore, the codebase may be easier to maintain, since updating a prototype
1139 is much less error prone than jumping around in the codebase to update all the
1140 snippets copied and pasted around to initialize entities and components.
1141 
1142 ### Helpers
1143 
1144 The so called _helpers_ are small classes and functions mainly designed to offer
1145 built-in support for the most basic functionalities.<br/>
1146 The list of helpers will grow longer as time passes and new ideas come out.
1147 
1148 #### Dependency function
1149 
1150 A _dependency function_ is a predefined listener, actually a function template
1151 to use to automatically assign components to an entity when a type has a
1152 dependency on some other types.<br/>
1153 The following adds components `AType` and `AnotherType` whenever `MyType` is
1154 assigned to an entity:
1155 
1156 ```cpp
1157 entt::dependency<AType, AnotherType>(registry.construction<MyType>());
1158 ```
1159 
1160 A component is assigned to an entity and thus default initialized only in case
1161 the entity itself hasn't it yet. It means that already existent components won't
1162 be overriden.<br/>
1163 A dependency can easily be broken by means of the same function template:
1164 
1165 ```cpp
1166 entt::dependency<AType, AnotherType>(entt::break_t{}, registry.construction<MyType>());
1167 ```
1168 
1169 #### Labels
1170 
1171 There's nothing magical about the way labels can be assigned to entities while
1172 avoiding a performance hit at runtime. Nonetheless, the syntax can be annoying
1173 and that's why a more user-friendly shortcut is provided to do it.<br/>
1174 This shortcut is the alias template `entt::label`.
1175 
1176 If used in combination with hashed strings, it helps to use labels where types
1177 would be required otherwise. As an example:
1178 
1179 ```cpp
1180 registry.assign<entt::label<"enemy"_hs>>(entity);
1181 ```
1182 
1183 ### Null entity
1184 
1185 In `EnTT`, there exists a sort of _null entity_ made available to users that is
1186 accessible via the `entt::null` variable.<br/>
1187 The library guarantees that the following expression always returns false:
1188 
1189 ```cpp
1190 registry.valid(entt::null);
1191 ```
1192 
1193 In other terms, a registry will reject the null entity in all cases because it
1194 isn't considered valid. It means that the null entity cannot own components or
1195 tags for obvious reasons.<br/>
1196 The type of the null entity is internal and should not be used for any purpose
1197 other than defining the null entity itself. However, there exist implicit
1198 conversions from the null entity to identifiers of any allowed type:
1199 
1200 ```cpp
1201 typename entt::DefaultRegistry::entity_type null = entt::null;
1202 ```
1203 
1204 Similarly, the null entity can be compared to any other identifier:
1205 
1206 ```cpp
1207 const auto entity = registry.create();
1208 const bool null = (entity == entt::null);
1209 ```
1210 
1211 ## View: to persist or not to persist?
1212 
1213 First of all, it is worth answering an obvious question: why views?<br/>
1214 Roughly speaking, they are a good tool to enforce single responsibility. A
1215 system that has access to a registry can create and destroy entities, as well as
1216 assign and remove components. On the other side, a system that has access to a
1217 view can only iterate entities and their components, then read or update the
1218 data members of the latter.<br/>
1219 It is a subtle difference that can help designing a better software sometimes.
1220 
1221 There are mainly four kinds of views: standard (also known as `View`),
1222 persistent (also known as `PersistentView`), raw (also known as `RawView`) and
1223 runtime (also known as `RuntimeView`).<br/>
1224 All of them have pros and cons to take in consideration. In particular:
1225 
1226 * Standard views:
1227 
1228  Pros:
1229 
1230  * They work out-of-the-box and don't require any dedicated data structure.
1231  * Creating and destroying them isn't expensive at all because they don't have
1232  any type of initialization.
1233  * They are the best tool for iterating entities for a single component.
1234  * They are the best tool for iterating entities for multiple components when
1235  one of the components is assigned to a significantly low number of entities.
1236  * They don't affect any other operations of the registry.
1237 
1238  Cons:
1239 
1240  * Their performance tend to degenerate when the number of components to
1241  iterate grows up and the most of the entities have all of them.
1242 
1243 * Persistent views:
1244 
1245  Pros:
1246 
1247  * Once prepared, creating and destroying them isn't expensive at all because
1248  they don't have any type of initialization.
1249  * They are the best tool for iterating entities for multiple components when
1250  most entities have them all.
1251 
1252  Cons:
1253 
1254  * They have dedicated data structures and thus affect the memory usage to a
1255  minimal extent.
1256  * If not previously prepared, the first time they are used they go through an
1257  initialization step that could take a while.
1258  * They affect to a minimum the creation and destruction of entities and
1259  components. In other terms: the more persistent views there will be, the
1260  less performing will be creating and destroying entities and components.
1261 
1262 * Raw views:
1263 
1264  Pros:
1265 
1266  * They work out-of-the-box and don't require any dedicated data structure.
1267  * Creating and destroying them isn't expensive at all because they don't have
1268  any type of initialization.
1269  * They are the best tool for iterating components when it is not necessary to
1270  know which entities they belong to.
1271  * They don't affect any other operations of the registry.
1272 
1273  Cons:
1274 
1275  * They can be used to iterate only one type of component at a time.
1276  * They don't return the entity to which a component belongs to the caller.
1277 
1278 * Runtime views:
1279 
1280  Pros:
1281 
1282  * Their lists of components are defined at runtime and not at compile-time.
1283  * Creating and destroying them isn't expensive at all because they don't have
1284  any type of initialization.
1285  * They are the best tool for things like plugin systems and mods in general.
1286  * They don't affect any other operations of the registry.
1287 
1288  Cons:
1289 
1290  * Their performances are definitely lower than those of all the other views,
1291  although they are still usable and sufficient for most of the purposes.
1292 
1293 To sum up and as a rule of thumb:
1294 
1295 * Use a raw view to iterate components only (no entities) for a given type.
1296 * Use a standard view to iterate entities and components for a single type.
1297 * Use a standard view to iterate entities and components for multiple types when
1298  the number of types is low. Standard views are really optimized and persistent
1299  views won't add much in this case.
1300 * Use a standard view to iterate entities and components for multiple types when
1301  a significantly low number of entities have one of the components.
1302 * Use a standard view in all those cases where a persistent view would give a
1303  boost to performance but the iteration isn't performed frequently.
1304 * Prepare and use a persistent view when you want to iterate only entities for
1305  multiple components.
1306 * Prepare and use a persistent view when you want to iterate entities for
1307  multiple components and each component is assigned to a great number of
1308  entities but the intersection between the sets of entities is small.
1309 * Prepare and use a persistent view in all the cases where a standard view
1310  wouldn't fit well otherwise.
1311 * Finally, in case you don't know at compile-time what are the components to
1312  use, choose a runtime view and set them during execution.
1313 
1314 To easily iterate entities and components, all the views offer the common
1315 `begin` and `end` member functions that allow users to use a view in a typical
1316 range-for loop. Almost all the views offer also a *more functional* `each`
1317 member function that accepts a callback for convenience.<br/>
1318 Continue reading for more details or refer to the inline documentation.
1319 
1320 ### Standard View
1321 
1322 A standard view behaves differently if it's constructed for a single component
1323 or if it has been requested to iterate multiple components. Even the API is
1324 different in the two cases.<br/>
1325 All that they share is the way they are created by means of a registry:
1326 
1327 ```cpp
1328 // single component standard view
1329 auto single = registry.view<Position>();
1330 
1331 // multi component standard view
1332 auto multi = registry.view<Position, Velocity>();
1333 ```
1334 
1335 For all that remains, it's worth discussing them separately.<br/>
1336 
1337 #### Single component standard view
1338 
1339 Single component standard views are specialized in order to give a boost in
1340 terms of performance in all the situation. This kind of views can access the
1341 underlying data structures directly and avoid superfluous checks.<br/>
1342 They offer a bunch of functionalities to get the number of entities they are
1343 going to return and a raw access to the entity list as well as to the component
1344 list. It's also possible to ask a view if it contains a given entity.<br/>
1345 Refer to the inline documentation for all the details.
1346 
1347 There is no need to store views around for they are extremely cheap to
1348 construct, even though they can be copied without problems and reused freely. In
1349 fact, they return newly created and correctly initialized iterators whenever
1350 `begin` or `end` are invoked.<br/>
1351 To iterate a single component standard view, either use it in a range-for loop:
1352 
1353 ```cpp
1354 auto view = registry.view<Renderable>();
1355 
1356 for(auto entity: view) {
1357  Renderable &renderable = view.get(entity);
1358 
1359  // ...
1360 }
1361 ```
1362 
1363 Or rely on the `each` member function to iterate entities and get all their
1364 components at once:
1365 
1366 ```cpp
1367 registry.view<Renderable>().each([](auto entity, auto &renderable) {
1368  // ...
1369 });
1370 ```
1371 
1372 The `each` member function is highly optimized. Unless users want to iterate
1373 only entities, using `each` should be the preferred approach.
1374 
1375 **Note**: prefer the `get` member function of a view instead of the `get` member
1376 function template of a registry during iterations, if possible. However, keep in
1377 mind that it works only with the components of the view itself.
1378 
1379 #### Multi component standard view
1380 
1381 Multi component standard views iterate entities that have at least all the given
1382 components in their bags. During construction, these views look at the number of
1383 entities available for each component and pick up a reference to the smallest
1384 set of candidates in order to speed up iterations.<br/>
1385 They offer fewer functionalities than their companion views for single
1386 component. In particular, a multi component standard view exposes utility
1387 functions to get the estimated number of entities it is going to return and to
1388 know whether it's empty or not. It's also possible to ask a view if it contains
1389 a given entity.<br/>
1390 Refer to the inline documentation for all the details.
1391 
1392 There is no need to store views around for they are extremely cheap to
1393 construct, even though they can be copied without problems and reused freely. In
1394 fact, they return newly created and correctly initialized iterators whenever
1395 `begin` or `end` are invoked.<br/>
1396 To iterate a multi component standard view, either use it in a range-for loop:
1397 
1398 ```cpp
1399 auto view = registry.view<Position, Velocity>();
1400 
1401 for(auto entity: view) {
1402  // a component at a time ...
1403  Position &position = view.get<Position>(entity);
1404  Velocity &velocity = view.get<Velocity>(entity);
1405 
1406  // ... or multiple components at once
1407  std::tuple<Position &, Velocity &> tup = view.get<Position, Velocity>(entity);
1408 
1409  // ...
1410 }
1411 ```
1412 
1413 Or rely on the `each` member function to iterate entities and get all their
1414 components at once:
1415 
1416 ```cpp
1417 registry.view<Position, Velocity>().each([](auto entity, auto &position, auto &velocity) {
1418  // ...
1419 });
1420 ```
1421 
1422 The `each` member function is highly optimized. Unless users want to iterate
1423 only entities or get only some of the components, using `each` should be the
1424 preferred approach.
1425 
1426 **Note**: prefer the `get` member function of a view instead of the `get` member
1427 function template of a registry during iterations, if possible. However, keep in
1428 mind that it works only with the components of the view itself.
1429 
1430 ### Persistent View
1431 
1432 A persistent view returns all the entities and only the entities that have at
1433 least the given components. Moreover, it's guaranteed that the entity list is
1434 tightly packed in memory for fast iterations.<br/>
1435 In general, persistent views don't stay true to the order of any set of
1436 components unless users explicitly sort them.
1437 
1438 Persistent views can be used only to iterate multiple components. To create this
1439 kind of views, the tag `persistent_t` must also be used in order to disambiguate
1440 overloads of the `view` member function:
1441 
1442 ```cpp
1443 auto view = registry.view<Position, Velocity>(entt::persistent_t{});
1444 ```
1445 
1446 There is no need to store views around for they are extremely cheap to
1447 construct, even though they can be copied without problems and reused freely. In
1448 fact, they return newly created and correctly initialized iterators whenever
1449 `begin` or `end` are invoked.<br/>
1450 That being said, persistent views perform an initialization step the very first
1451 time they are constructed and this could be quite costly. To avoid it, consider
1452 asking to the registry to _prepare_ them when no entities have been created yet:
1453 
1454 ```cpp
1455 registry.prepare<Position, Velocity>();
1456 ```
1457 
1458 If the registry is empty, preparation is extremely fast. Moreover the `prepare`
1459 member function template is idempotent. Feel free to invoke it even more than
1460 once: if the view has been already prepared before, the function returns
1461 immediately and does nothing.
1462 
1463 A persistent view offers a bunch of functionalities to get the number of
1464 entities it's going to return, a raw access to the entity list and the
1465 possibility to sort the underlying data structures according to the order of one
1466 of the components for which it has been constructed. It's also possible to ask a
1467 view if it contains a given entity.<br/>
1468 Refer to the inline documentation for all the details.
1469 
1470 To iterate a persistent view, either use it in a range-for loop:
1471 
1472 ```cpp
1473 auto view = registry.view<Position, Velocity>(entt::persistent_t{});
1474 
1475 for(auto entity: view) {
1476  // a component at a time ...
1477  Position &position = view.get<Position>(entity);
1478  Velocity &velocity = view.get<Velocity>(entity);
1479 
1480  // ... or multiple components at once
1481  std::tuple<Position &, Velocity &> tup = view.get<Position, Velocity>(entity);
1482 
1483  // ...
1484 }
1485 ```
1486 
1487 Or rely on the `each` member function to iterate entities and get all their
1488 components at once:
1489 
1490 ```cpp
1491 registry.view<Position, Velocity>(entt::persistent_t{}).each([](auto entity, auto &position, auto &velocity) {
1492  // ...
1493 });
1494 ```
1495 
1496 Performance are more or less the same. The best approach depends mainly on
1497 whether all the components have to be accessed or not.
1498 
1499 **Note**: prefer the `get` member function of a view instead of the `get` member
1500 function template of a registry during iterations, if possible. However, keep in
1501 mind that it works only with the components of the view itself.
1502 
1503 ### Raw View
1504 
1505 Raw views return all the components of a given type. This kind of views can
1506 access components directly and avoid extra indirections like when components are
1507 accessed via an entity identifier.<br/>
1508 They offer a bunch of functionalities to get the number of instances they are
1509 going to return and a raw access to the entity list as well as to the component
1510 list.<br/>
1511 Refer to the inline documentation for all the details.
1512 
1513 Raw views can be used only to iterate components for a single type. To create
1514 this kind of views, the tag `raw_t` must also be used in order to disambiguate
1515 overloads of the `view` member function:
1516 
1517 ```cpp
1518 auto view = registry.view<Renderable>(entt::raw_t{});
1519 ```
1520 
1521 There is no need to store views around for they are extremely cheap to
1522 construct, even though they can be copied without problems and reused freely. In
1523 fact, they return newly created and correctly initialized iterators whenever
1524 `begin` or `end` are invoked.<br/>
1525 To iterate a raw view, use it in a range-for loop:
1526 
1527 ```cpp
1528 auto view = registry.view<Renderable>(entt::raw_t{});
1529 
1530 for(auto &&component: raw) {
1531  // ...
1532 }
1533 ```
1534 
1535 Or rely on the `each` member function:
1536 
1537 ```cpp
1538 registry.view<Renderable>(entt::raw_t{}).each([](auto &renderable) {
1539  // ...
1540 });
1541 ```
1542 
1543 Performance are exactly the same in both cases.
1544 
1545 **Note**: raw views don't have a `get` member function for obvious reasons.
1546 
1547 ### Runtime View
1548 
1549 Runtime views iterate entities that have at least all the given components in
1550 their bags. During construction, these views look at the number of entities
1551 available for each component and pick up a reference to the smallest
1552 set of candidates in order to speed up iterations.<br/>
1553 They offer more or less the same functionalities of a multi component standard
1554 view. However, they don't expose a `get` member function and users should refer
1555 to the registry that generated the view to access components. In particular, a
1556 runtime view exposes utility functions to get the estimated number of entities
1557 it is going to return and to know whether it's empty or not. It's also possible
1558 to ask a view if it contains a given entity.<br/>
1559 Refer to the inline documentation for all the details.
1560 
1561 Runtime view are extremely cheap to construct and should not be stored around in
1562 any case. They should be used immediately after creation and then they should be
1563 thrown away. The reasons for this go far beyond the scope of this document.<br/>
1564 To iterate a runtime view, either use it in a range-for loop:
1565 
1566 ```cpp
1567 using component_type = typename decltype(registry)::component_type;
1568 component_type types[] = { registry.type<Position>(), registry.type<Velocity>() };
1569 
1570 auto view = registry.view(std::cbegin(types), std::cend(types));
1571 
1572 for(auto entity: view) {
1573  // a component at a time ...
1574  Position &position = registry.get<Position>(entity);
1575  Velocity &velocity = registry.get<Velocity>(entity);
1576 
1577  // ... or multiple components at once
1578  std::tuple<Position &, Velocity &> tup = view.get<Position, Velocity>(entity);
1579 
1580  // ...
1581 }
1582 ```
1583 
1584 Or rely on the `each` member function to iterate entities:
1585 
1586 ```cpp
1587 using component_type = typename decltype(registry)::component_type;
1588 component_type types[] = { registry.type<Position>(), registry.type<Velocity>() };
1589 
1590 auto view = registry.view(std::cbegin(types), std::cend(types)).each([](auto entity) {
1591  // ...
1592 });
1593 ```
1594 
1595 Performance are exactly the same in both cases.
1596 
1597 **Note**: runtime views are meant for all those cases where users don't know at
1598 compile-time what components to use to iterate entities. This is particularly
1599 well suited to plugin systems and mods in general. Where possible, don't use
1600 runtime views, as their performance are slightly inferior to those of the other
1601 views.
1602 
1603 
1604 ### Give me everything
1605 
1606 Views are narrow windows on the entire list of entities. They work by filtering
1607 entities according to their components.<br/>
1608 In some cases there may be the need to iterate all the entities still in use
1609 regardless of their components. The registry offers a specific member function
1610 to do that:
1611 
1612 ```cpp
1613 registry.each([](auto entity) {
1614  // ...
1615 });
1616 ```
1617 
1618 It returns to the caller all the entities that are still in use by means of the
1619 given function.<br/>
1620 As a rule of thumb, consider using a view if the goal is to iterate entities
1621 that have a determinate set of components. A view is usually much faster than
1622 combining this function with a bunch of custom tests.<br/>
1623 In all the other cases, this is the way to go.
1624 
1625 There exists also another member function to use to retrieve orphans. An orphan
1626 is an entity that is still in use and has neither assigned components nor
1627 tags.<br/>
1628 The signature of the function is the same of `each`:
1629 
1630 ```cpp
1631 registry.orphans([](auto entity) {
1632  // ...
1633 });
1634 ```
1635 
1636 To test the _orphanity_ of a single entity, use the member function `orphan`
1637 instead. It accepts a valid entity identifer as an argument and returns true in
1638 case the entity is an orphan, false otherwise.
1639 
1640 In general, all these functions can result in poor performance.<br/>
1641 `each` is fairly slow because of some checks it performs on each and every
1642 entity. For similar reasons, `orphans` can be even slower. Both functions should
1643 not be used frequently to avoid the risk of a performance hit.
1644 
1645 ## Iterations: what is allowed and what is not
1646 
1647 Most of the _ECS_ available out there have some annoying limitations (at least
1648 from my point of view): entities and components cannot be created nor destroyed
1649 during iterations.<br/>
1650 `EnTT` partially solves the problem with a few limitations:
1651 
1652 * Creating entities and components is allowed during iterations.
1653 * Deleting an entity or removing its components is allowed during iterations if
1654  it's the one currently returned by the view. For all the other entities,
1655  destroying them or removing their components isn't allowed and it can result
1656  in undefined behavior.
1657 
1658 Iterators are invalidated and the behavior is undefined if an entity is modified
1659 or destroyed and it's not the one currently returned by the view nor a newly
1660 created one.<br/>
1661 To work around it, possible approaches are:
1662 
1663 * Store aside the entities and the components to be removed and perform the
1664  operations at the end of the iteration.
1665 * Mark entities and components with a proper tag component that indicates they
1666  must be purged, then perform a second iteration to clean them up one by one.
1667 
1668 A notable side effect of this feature is that the number of required allocations
1669 is further reduced in most of the cases.
1670 
1671 ## Multithreading
1672 
1673 In general, the entire registry isn't thread safe as it is. Thread safety isn't
1674 something that users should want out of the box for several reasons. Just to
1675 mention one of them: performance.<br/>
1676 Views and consequently the approach adopted by `EnTT` are the great exception to
1677 the rule. It's true that views and thus their iterators aren't thread safe by
1678 themselves. Because of this users shouldn't try to iterate a set of components
1679 and modify the same set concurrently. However:
1680 
1681 * As long as a thread iterates the entities that have the component `X` or
1682  assign and removes that component from a set of entities, another thread can
1683  safely do the same with components `Y` and `Z` and everything will work like a
1684  charm. As a trivial example, users can freely execute the rendering system and
1685  iterate the renderable entities while updating a physic component concurrently
1686  on a separate thread.
1687 
1688 * Similarly, a single set of components can be iterated by multiple threads as
1689  long as the components are neither assigned nor removed in the meantime. In
1690  other words, a hypothetical movement system can start multiple threads, each
1691  of which will access the components that carry information about velocity and
1692  position for its entities.
1693 
1694 This kind of entity-component systems can be used in single threaded
1695 applications as well as along with async stuff or multiple threads. Moreover,
1696 typical thread based models for _ECS_ don't require a fully thread safe registry
1697 to work. Actually, users can reach the goal with the registry as it is while
1698 working with most of the common models.
1699 
1700 Because of the few reasons mentioned above and many others not mentioned, users
1701 are completely responsible for synchronization whether required. On the other
1702 hand, they could get away with it without having to resort to particular
1703 expedients.
1704 
1705 # Crash Course: core functionalities
1706 
1707 `EnTT` comes with a bunch of core functionalities mostly used by the other parts
1708 of the library itself.<br/>
1709 Hardly users will include these features in their code, but it's worth
1710 describing what `EnTT` offers so as not to reinvent the wheel in case of need.
1711 
1712 ## Compile-time identifiers
1713 
1714 Sometimes it's useful to be able to give unique identifiers to types at
1715 compile-time.<br/>
1716 There are plenty of different solutions out there and I could have used one of
1717 them. However, I decided to spend my time to define a compact and versatile tool
1718 that fully embraces what the modern C++ has to offer.
1719 
1720 The _result of my efforts_ is the `Identifier` class template:
1721 
1722 ```cpp
1723 #include <ident.hpp>
1724 
1725 // defines the identifiers for the given types
1726 using ID = entt::Identifier<AType, AnotherType>;
1727 
1728 // ...
1729 
1730 switch(aTypeIdentifier) {
1731 case ID::get<AType>():
1732  // ...
1733  break;
1734 case ID::get<AnotherType>():
1735  // ...
1736  break;
1737 default:
1738  // ...
1739 }
1740 ```
1741 
1742 This is all what the class template has to offer: a static `get` member function
1743 that returns a numerical identifier for the given type. It can be used in any
1744 context where constant expressions are required.
1745 
1746 As long as the list remains unchanged, identifiers are also guaranteed to be the
1747 same for every run. In case they have been used in a production environment and
1748 a type has to be removed, one can just use a placeholder to left the other
1749 identifiers unchanged:
1750 
1751 ```cpp
1752 template<typename> struct IgnoreType {};
1753 
1754 using ID = entt::Identifier<
1755  ATypeStillValid,
1756  IgnoreType<ATypeNoLongerValid>,
1757  AnotherTypeStillValid
1758 >;
1759 ```
1760 
1761 A bit ugly to see, but it works at least.
1762 
1763 ## Runtime identifiers
1764 
1765 Sometimes it's useful to be able to give unique identifiers to types at
1766 runtime.<br/>
1767 There are plenty of different solutions out there and I could have used one of
1768 them. In fact, I adapted the most common one to my requirements and used it
1769 extensively within the entire library.
1770 
1771 It's the `Family` class. Here is an example of use directly from the
1772 entity-component system:
1773 
1774 ```cpp
1775 using component_family = entt::Family<struct InternalRegistryComponentFamily>;
1776 
1777 // ...
1778 
1779 template<typename Component>
1780 component_type component() const noexcept {
1781  return component_family::type<Component>();
1782 }
1783 ```
1784 
1785 This is all what a _family_ has to offer: a `type` member function that returns
1786 a numerical identifier for the given type.
1787 
1788 Please, note that identifiers aren't guaranteed to be the same for every run.
1789 Indeed it mostly depends on the flow of execution.
1790 
1791 ## Hashed strings
1792 
1793 A hashed string is a zero overhead resource identifier. Users can use
1794 human-readable identifiers in the codebase while using their numeric
1795 counterparts at runtime, thus without affecting performance.<br/>
1796 The class has an implicit `constexpr` constructor that chews a bunch of
1797 characters. Once created, all what one can do with it is getting back the
1798 original string or converting it into a number.<br/>
1799 The good part is that a hashed string can be used wherever a constant expression
1800 is required and no _string-to-number_ conversion will take place at runtime if
1801 used carefully.
1802 
1803 Example of use:
1804 
1805 ```cpp
1806 auto load(entt::HashedString::hash_type resource) {
1807  // uses the numeric representation of the resource to load and return it
1808 }
1809 
1810 auto resource = load(entt::HashedString{"gui/background"});
1811 ```
1812 
1813 There is also a _user defined literal_ dedicated to hashed strings to make them
1814 more user-friendly:
1815 
1816 ```cpp
1817 constexpr auto str = "text"_hs;
1818 ```
1819 
1820 ### Conflicts
1821 
1822 The hashed string class uses internally FNV-1a to compute the numeric
1823 counterpart of a string. Because of the _pigeonhole principle_, conflicts are
1824 possible. This is a fact.<br/>
1825 There is no silver bullet to solve the problem of conflicts when dealing with
1826 hashing functions. In this case, the best solution seemed to be to give up.
1827 That's all.<br/>
1828 After all, human-readable resource identifiers aren't something strictly defined
1829 and over which users have not the control. Choosing a slightly different
1830 identifier is probably the best solution to make the conflict disappear in this
1831 case.
1832 
1833 ## Monostate
1834 
1835 The monostate pattern is often presented as an alternative to a singleton based
1836 configuration system. This is exactly its purpose in `EnTT`. Moreover, this
1837 implementation is thread safe by design (hopefully).<br/>
1838 Keys are represented by hashed strings, values are basic types like `int`s or
1839 `bool`s. Values of different types can be associated to each key, even more than
1840 one at a time. Because of this, users must pay attention to use the same type
1841 both during an assignment and when they try to read back their data. Otherwise,
1842 they will probably incur in unexpected results.
1843 
1844 Example of use:
1845 
1846 ```cpp
1847 entt::Monostate<entt::HashedString{"mykey"}>{} = true;
1848 entt::Monostate<"mykey"_hs>{} = 42;
1849 
1850 // ...
1851 
1852 const bool b = entt::Monostate<"mykey"_hs>{};
1853 const int i = entt::Monostate<entt::HashedString{"mykey"}>{};
1854 ```
1855 
1856 # Crash Course: service locator
1857 
1858 Usually service locators are tightly bound to the services they expose and it's
1859 hard to define a general purpose solution. This template based implementation
1860 tries to fill the gap and to get rid of the burden of defining a different
1861 specific locator for each application.<br/>
1862 This class is tiny, partially unsafe and thus risky to use. Moreover it doesn't
1863 fit probably most of the scenarios in which a service locator is required. Look
1864 at it as a small tool that can sometimes be useful if the user knows how to
1865 handle it.
1866 
1867 The API is straightforward. The basic idea is that services are implemented by
1868 means of interfaces and rely on polymorphism.<br/>
1869 The locator is instantiated with the base type of the service if any and a
1870 concrete implementation is provided along with all the parameters required to
1871 initialize it. As an example:
1872 
1873 ```cpp
1874 // the service has no base type, a locator is used to treat it as a kind of singleton
1875 entt::ServiceLocator<MyService>::set(params...);
1876 
1877 // sets up an opaque service
1878 entt::ServiceLocator<AudioInterface>::set<AudioImplementation>(params...);
1879 
1880 // resets (destroys) the service
1881 entt::ServiceLocator<AudioInterface>::reset();
1882 ```
1883 
1884 The locator can also be queried to know if an active service is currently set
1885 and to retrieve it if necessary (either as a pointer or as a reference):
1886 
1887 ```cpp
1888 // no service currently set
1889 auto empty = entt::ServiceLocator<AudioInterface>::empty();
1890 
1891 // gets a (possibly empty) shared pointer to the service ...
1892 std::shared_ptr<AudioInterface> ptr = entt::ServiceLocator<AudioInterface>::get();
1893 
1894 // ... or a reference, but it's undefined behaviour if the service isn't set yet
1895 AudioInterface &ref = entt::ServiceLocator<AudioInterface>::ref();
1896 ```
1897 
1898 A common use is to wrap the different locators in a container class, creating
1899 aliases for the various services:
1900 
1901 ```cpp
1902 struct Locator {
1903  using Camera = entt::ServiceLocator<CameraInterface>;
1904  using Audio = entt::ServiceLocator<AudioInterface>;
1905  // ...
1906 };
1907 
1908 // ...
1909 
1910 void init() {
1911  Locator::Camera::set<CameraNull>();
1912  Locator::Audio::set<AudioImplementation>(params...);
1913  // ...
1914 }
1915 ```
1916 
1917 # Crash Course: cooperative scheduler
1918 
1919 Sometimes processes are a useful tool to work around the strict definition of a
1920 system and introduce logic in a different way, usually without resorting to the
1921 introduction of other components.
1922 
1923 `EnTT` offers a minimal support to this paradigm by introducing a few classes
1924 that users can use to define and execute cooperative processes.
1925 
1926 ## The process
1927 
1928 A typical process must inherit from the `Process` class template that stays true
1929 to the CRTP idiom. Moreover, derived classes must specify what's the intended
1930 type for elapsed times.
1931 
1932 A process should expose publicly the following member functions whether
1933 required (note that it isn't required to define a function unless the derived
1934 class wants to _override_ the default behavior):
1935 
1936 * `void update(Delta, void *);`
1937 
1938  It's invoked once per tick until a process is explicitly aborted or it
1939  terminates either with or without errors. Even though it's not mandatory to
1940  declare this member function, as a rule of thumb each process should at
1941  least define it to work properly. The `void *` parameter is an opaque pointer
1942  to user data (if any) forwarded directly to the process during an update.
1943 
1944 * `void init(void *);`
1945 
1946  It's invoked at the first tick, immediately before an update. The `void *`
1947  parameter is an opaque pointer to user data (if any) forwarded directly to the
1948  process during an update.
1949 
1950 * `void succeeded();`
1951 
1952  It's invoked in case of success, immediately after an update and during the
1953  same tick.
1954 
1955 * `void failed();`
1956 
1957  It's invoked in case of errors, immediately after an update and during the
1958  same tick.
1959 
1960 * `void aborted();`
1961 
1962  It's invoked only if a process is explicitly aborted. There is no guarantee
1963  that it executes in the same tick, this depends solely on whether the
1964  process is aborted immediately or not.
1965 
1966 Derived classes can also change the internal state of a process by invoking
1967 `succeed` and `fail`, as well as `pause` and `unpause` the process itself. All
1968 these are protected member functions made available to be able to manage the
1969 life cycle of a process from a derived class.
1970 
1971 Here is a minimal example for the sake of curiosity:
1972 
1973 ```cpp
1974 struct MyProcess: entt::Process<MyProcess, std::uint32_t> {
1975  using delta_type = std::uint32_t;
1976 
1977  void update(delta_type delta, void *) {
1978  remaining = delta > remaining ? delta_type{] : (remaining - delta);
1979 
1980  // ...
1981 
1982  if(!remaining) {
1983  succeed();
1984  }
1985  }
1986 
1987  void init(void *data) {
1988  remaining = *static_cast<delta_type *>(data);
1989  }
1990 
1991 private:
1992  delta_type remaining;
1993 };
1994 ```
1995 
1996 ### Adaptor
1997 
1998 Lambdas and functors can't be used directly with a scheduler for they are not
1999 properly defined processes with managed life cycles.<br/>
2000 This class helps in filling the gap and turning lambdas and functors into
2001 full featured processes usable by a scheduler.
2002 
2003 The function call operator has a signature similar to the one of the `update`
2004 function of a process but for the fact that it receives two extra arguments to
2005 call whenever a process is terminated with success or with an error:
2006 
2007 ```cpp
2008 void(Delta delta, void *data, auto succeed, auto fail);
2009 ```
2010 
2011 Parameters have the following meaning:
2012 
2013 * `delta` is the elapsed time.
2014 * `data` is an opaque pointer to user data if any, `nullptr` otherwise.
2015 * `succeed` is a function to call when a process terminates with success.
2016 * `fail` is a function to call when a process terminates with errors.
2017 
2018 Both `succeed` and `fail` accept no parameters at all.
2019 
2020 Note that usually users shouldn't worry about creating adaptors at all. A
2021 scheduler creates them internally each and every time a lambda or a functor is
2022 used as a process.
2023 
2024 ## The scheduler
2025 
2026 A cooperative scheduler runs different processes and helps managing their life
2027 cycles.
2028 
2029 Each process is invoked once per tick. If it terminates, it's removed
2030 automatically from the scheduler and it's never invoked again. Otherwise it's
2031 a good candidate to run once more the next tick.<br/>
2032 A process can also have a child. In this case, the process is replaced with
2033 its child when it terminates if it returns with success. In case of errors,
2034 both the process and its child are discarded. This way, it's easy to create
2035 chain of processes to run sequentially.
2036 
2037 Using a scheduler is straightforward. To create it, users must provide only the
2038 type for the elapsed times and no arguments at all:
2039 
2040 ```cpp
2041 Scheduler<std::uint32_t> scheduler;
2042 ```
2043 
2044 It has member functions to query its internal data structures, like `empty` or
2045 `size`, as well as a `clear` utility to reset it to a clean state:
2046 
2047 ```cpp
2048 // checks if there are processes still running
2049 const auto empty = scheduler.empty();
2050 
2051 // gets the number of processes still running
2052 Scheduler<std::uint32_t>::size_type size = scheduler.size();
2053 
2054 // resets the scheduler to its initial state and discards all the processes
2055 scheduler.clear();
2056 ```
2057 
2058 To attach a process to a scheduler there are mainly two ways:
2059 
2060 * If the process inherits from the `Process` class template, it's enough to
2061  indicate its type and submit all the parameters required to construct it to
2062  the `attach` member function:
2063 
2064  ```cpp
2065  scheduler.attach<MyProcess>("foobar");
2066  ```
2067 
2068 * Otherwise, in case of a lambda or a functor, it's enough to provide an
2069  instance of the class to the `attach` member function:
2070 
2071  ```cpp
2072  scheduler.attach([](auto...){ /* ... */ });
2073  ```
2074 
2075 In both cases, the return value is an opaque object that offers a `then` member
2076 function to use to create chains of processes to run sequentially.<br/>
2077 As a minimal example of use:
2078 
2079 ```cpp
2080 // schedules a task in the form of a lambda function
2081 scheduler.attach([](auto delta, void *, auto succeed, auto fail) {
2082  // ...
2083 })
2084 // appends a child in the form of another lambda function
2085 .then([](auto delta, void *, auto succeed, auto fail) {
2086  // ...
2087 })
2088 // appends a child in the form of a process class
2089 .then<MyProcess>();
2090 ```
2091 
2092 To update a scheduler and thus all its processes, the `update` member function
2093 is the way to go:
2094 
2095 ```cpp
2096 // updates all the processes, no user data are provided
2097 scheduler.update(delta);
2098 
2099 // updates all the processes and provides them with custom data
2100 scheduler.update(delta, &data);
2101 ```
2102 
2103 In addition to these functions, the scheduler offers an `abort` member function
2104 that can be used to discard all the running processes at once:
2105 
2106 ```cpp
2107 // aborts all the processes abruptly ...
2108 scheduler.abort(true);
2109 
2110 // ... or gracefully during the next tick
2111 scheduler.abort();
2112 ```
2113 
2114 # Crash Course: resource management
2115 
2116 Resource management is usually one of the most critical part of a software like
2117 a game. Solutions are often tuned to the particular application. There exist
2118 several approaches and all of them are perfectly fine as long as they fit the
2119 requirements of the piece of software in which they are used.<br/>
2120 Examples are loading everything on start, loading on request, predictive
2121 loading, and so on.
2122 
2123 `EnTT` doesn't pretend to offer a _one-fits-all_ solution for the different
2124 cases. Instead, it offers a minimal and perhaps trivial cache that can be useful
2125 most of the time during prototyping and sometimes even in a production
2126 environment.<br/>
2127 For those interested in the subject, the plan is to improve it considerably over
2128 time in terms of performance, memory usage and functionalities. Hoping to make
2129 it, of course, one step at a time.
2130 
2131 ## The resource, the loader and the cache
2132 
2133 There are three main actors in the model: the resource, the loader and the
2134 cache.
2135 
2136 The _resource_ is whatever the user wants it to be. An image, a video, an audio,
2137 whatever. There are no limits.<br/>
2138 As a minimal example:
2139 
2140 ```cpp
2141 struct MyResource { const int value; };
2142 ```
2143 
2144 A _loader_ is a class the aim of which is to load a specific resource. It has to
2145 inherit directly from the dedicated base class as in the following example:
2146 
2147 ```cpp
2148 struct MyLoader final: entt::ResourceLoader<MyLoader, MyResource> {
2149  // ...
2150 };
2151 ```
2152 
2153 Where `MyResource` is the type of resources it creates.<br/>
2154 A resource loader must also expose a public const member function named `load`
2155 that accepts a variable number of arguments and returns a shared pointer to a
2156 resource.<br/>
2157 As an example:
2158 
2159 ```cpp
2160 struct MyLoader: entt::ResourceLoader<MyLoader, MyResource> {
2161  std::shared_ptr<MyResource> load(int value) const {
2162  // ...
2163  return std::shared_ptr<MyResource>(new MyResource{ value });
2164  }
2165 };
2166 ```
2167 
2168 In general, resource loaders should not have a state or retain data of any type.
2169 They should let the cache manage their resources instead.<br/>
2170 As a side note, base class and CRTP idiom aren't strictly required with the
2171 current implementation. One could argue that a cache can easily work with
2172 loaders of any type. However, future changes won't be breaking ones by forcing
2173 the use of a base class today and that's why the model is already in its place.
2174 
2175 Finally, a cache is a specialization of a class template tailored to a specific
2176 resource:
2177 
2178 ```cpp
2179 using MyResourceCache = entt::ResourceCache<MyResource>;
2180 
2181 // ...
2182 
2183 MyResourceCache cache{};
2184 ```
2185 
2186 The idea is to create different caches for different types of resources and to
2187 manage each one independently and in the most appropriate way.<br/>
2188 As a (very) trivial example, audio tracks can survive in most of the scenes of
2189 an application while meshes can be associated with a single scene and then
2190 discarded when the user leaves it.
2191 
2192 A cache offers a set of basic functionalities to query its internal state and to
2193 _organize_ it:
2194 
2195 ```cpp
2196 // gets the number of resources managed by a cache
2197 const auto size = cache.size();
2198 
2199 // checks if a cache contains at least a valid resource
2200 const auto empty = cache.empty();
2201 
2202 // clears a cache and discards its content
2203 cache.clear();
2204 ```
2205 
2206 Besides these member functions, it contains what is needed to load, use and
2207 discard resources of the given type.<br/>
2208 Before to explore this part of the interface, it makes sense to mention how
2209 resources are identified. The type of the identifiers to use is defined as:
2210 
2211 ```cpp
2212 entt::ResourceCache<Resource>::resource_type
2213 ```
2214 
2215 Where `resource_type` is an alias for `entt::HashedString`. Therefore, resource
2216 identifiers are created explicitly as in the following example:
2217 
2218 ```cpp
2219 constexpr auto identifier = entt::ResourceCache<Resource>::resource_type{"my/resource/identifier"};
2220 // this is equivalent to the following
2221 constexpr auto hs = entt::HashedString{"my/resource/identifier"};
2222 ```
2223 
2224 The class `HashedString` is described in a dedicated section, so I won't do in
2225 details here.
2226 
2227 Resources are loaded and thus stored in a cache through the `load` member
2228 function. It accepts the loader to use as a template parameter, the resource
2229 identifier and the parameters used to construct the resource as arguments:
2230 
2231 ```cpp
2232 // uses the identifier declared above
2233 cache.load<MyLoader>(identifier, 0);
2234 
2235 // uses a const char * directly as an identifier
2236 cache.load<MyLoader>("another/identifier", 42);
2237 ```
2238 
2239 The return value can be used to know if the resource has been loaded correctly.
2240 In case the loader returns an invalid pointer or the resource already exists in
2241 the cache, a false value is returned:
2242 
2243 ```cpp
2244 if(!cache.load<MyLoader>("another/identifier", 42)) {
2245  // ...
2246 }
2247 ```
2248 
2249 Unfortunately, in this case there is no way to know what was the problem
2250 exactly. However, before trying to load a resource or after an error, one can
2251 use the `contains` member function to know if a cache already contains a
2252 specific resource:
2253 
2254 ```cpp
2255 auto exists = cache.contains("my/identifier");
2256 ```
2257 
2258 There exists also a member function to use to force a reload of an already
2259 existing resource if needed:
2260 
2261 ```cpp
2262 auto result = cache.reload<MyLoader>("another/identifier", 42);
2263 ```
2264 
2265 As above, the function returns true in case of success, false otherwise. The
2266 sole difference in this case is that an error necessarily means that the loader
2267 has failed for some reasons to load the resource.<br/>
2268 Note that the `reload` member function is a kind of alias of the following
2269 snippet:
2270 
2271 ```cpp
2272 cache.discard(identifier);
2273 cache.load<MyLoader>(identifier, 42);
2274 ```
2275 
2276 Where the `discard` member function is used to get rid of a resource if loaded.
2277 In case the cache doesn't contain a resource for the given identifier, the
2278 function does nothing and returns immediately.
2279 
2280 So far, so good. Resources are finally loaded and stored within the cache.<br/>
2281 They are returned to users in the form of handles. To get one of them:
2282 
2283 ```cpp
2284 auto handle = cache.handle("my/identifier");
2285 ```
2286 
2287 The idea behind a handle is the same of the flyweight pattern. In other terms,
2288 resources aren't copied around. Instead, instances are shared between handles.
2289 Users of a resource owns a handle and it guarantees that a resource isn't
2290 destroyed until all the handles are destroyed, even if the resource itself is
2291 removed from the cache.<br/>
2292 Handles are tiny objects both movable and copyable. They returns the contained
2293 resource as a const reference on request:
2294 
2295 * By means of the `get` member function:
2296 
2297  ```cpp
2298  const auto &resource = handle.get();
2299  ```
2300 
2301 * Using the proper cast operator:
2302 
2303  ```cpp
2304  const auto &resource = handle;
2305  ```
2306 
2307 * Through the dereference operator:
2308 
2309  ```cpp
2310  const auto &resource = *handle;
2311  ```
2312 
2313 The resource can also be accessed directly using the arrow operator if required:
2314 
2315 ```cpp
2316 auto value = handle->value;
2317 ```
2318 
2319 To test if a handle is still valid, the cast operator to `bool` allows users to
2320 use it in a guard:
2321 
2322 ```cpp
2323 if(handle) {
2324  // ...
2325 }
2326 ```
2327 
2328 Finally, in case there is the need to load a resource and thus to get a handle
2329 without storing the resource itself in the cache, users can rely on the `temp`
2330 member function template.<br/>
2331 The declaration is similar to the one of `load` but for the fact that it doesn't
2332 return a boolean value. Instead, it returns a (possibly invalid) handle for the
2333 resource:
2334 
2335 ```cpp
2336 auto handle = cache.temp<MyLoader>("another/identifier", 42);
2337 ```
2338 
2339 Do not forget to test the handle for validity. Otherwise, getting the reference
2340 to the resource it points may result in undefined behavior.
2341 
2342 # Crash Course: events, signals and everything in between
2343 
2344 Signals are usually a core part of games and software architectures in
2345 general.<br/>
2346 Roughly speaking, they help to decouple the various parts of a system while
2347 allowing them to communicate with each other somehow.
2348 
2349 The so called _modern C++_ comes with a tool that can be useful in these terms,
2350 the `std::function`. As an example, it can be used to create delegates.<br/>
2351 However, there is no guarantee that an `std::function` does not perform
2352 allocations under the hood and this could be problematic sometimes. Furthermore,
2353 it solves a problem but may not adapt well to other requirements that may arise
2354 from time to time.
2355 
2356 In case that the flexibility and potential of an `std::function` are not
2357 required or where you are looking for something different, `EnTT` offers a full
2358 set of classes to solve completely different problems.
2359 
2360 ## Signals
2361 
2362 Signal handlers work with naked pointers, function pointers and pointers to
2363 member functions. Listeners can be any kind of objects and the user is in charge
2364 of connecting and disconnecting them from a signal to avoid crashes due to
2365 different lifetimes. On the other side, performance shouldn't be affected that
2366 much by the presence of such a signal handler.<br/>
2367 A signal handler can be used as a private data member without exposing any
2368 _publish_ functionality to the clients of a class. The basic idea is to impose a
2369 clear separation between the signal itself and its _sink_ class, that is a tool
2370 to be used to connect and disconnect listeners on the fly.
2371 
2372 The API of a signal handler is straightforward. The most important thing is that
2373 it comes in two forms: with and without a collector. In case a signal is
2374 associated with a collector, all the values returned by the listeners can be
2375 literally _collected_ and used later by the caller. Otherwise it works just like
2376 a plain signal that emits events from time to time.<br/>
2377 
2378 **Note**: collectors are allowed only in case of function types whose the return
2379 type isn't `void` for obvious reasons.
2380 
2381 To create instances of signal handlers there exist mainly two ways:
2382 
2383 ```cpp
2384 // no collector type
2385 entt::SigH<void(int, char)> signal;
2386 
2387 // explicit collector type
2388 entt::SigH<void(int, char), MyCollector<bool>> collector;
2389 ```
2390 
2391 As expected, they offer all the basic functionalities required to know how many
2392 listeners they contain (`size`) or if they contain at least a listener (`empty`)
2393 and even to swap two signal handlers (`swap`).
2394 
2395 Besides them, there are member functions to use both to connect and disconnect
2396 listeners in all their forms by means of a sink:
2397 
2398 ```cpp
2399 void foo(int, char) { /* ... */ }
2400 
2401 struct S {
2402  void bar(int, char) { /* ... */ }
2403 };
2404 
2405 // ...
2406 
2407 S instance;
2408 
2409 signal.sink().connect<&foo>();
2410 signal.sink().connect<S, &S::bar>(&instance);
2411 
2412 // ...
2413 
2414 // disconnects a free function
2415 signal.sink().disconnect<&foo>();
2416 
2417 // disconnect a specific member function of an instance ...
2418 signal.sink().disconnect<S, &S::bar>(&instance);
2419 
2420 // ... or an instance as a whole
2421 signal.sink().disconnect(&instance);
2422 
2423 // discards all the listeners at once
2424 signal.sink().disconnect();
2425 ```
2426 
2427 Once listeners are attached (or even if there are no listeners at all), events
2428 and data in general can be published through a signal by means of the `publish`
2429 member function:
2430 
2431 ```cpp
2432 signal.publish(42, 'c');
2433 ```
2434 
2435 To collect data, the `collect` member function should be used instead. Below is
2436 a minimal example to show how to use it:
2437 
2438 ```cpp
2439 struct MyCollector {
2440  std::vector<int> vec{};
2441 
2442  bool operator()(int v) noexcept {
2443  vec.push_back(v);
2444  return true;
2445  }
2446 };
2447 
2448 int f() { return 0; }
2449 int g() { return 1; }
2450 
2451 // ...
2452 
2453 entt::SigH<int(), MyCollector<int>> signal;
2454 
2455 signal.sink().connect<&f>();
2456 signal.sink().connect<&g>();
2457 
2458 MyCollector collector = signal.collect();
2459 
2460 assert(collector.vec[0] == 0);
2461 assert(collector.vec[1] == 1);
2462 ```
2463 
2464 As shown above, a collector must expose a function operator that accepts as an
2465 argument a type to which the return type of the listeners can be converted.
2466 Moreover, it has to return a boolean value that is false to stop collecting
2467 data, true otherwise. This way one can avoid calling all the listeners in case
2468 it isn't necessary.
2469 
2470 ## Delegate
2471 
2472 A delegate can be used as general purpose invoker with no memory overhead for
2473 free functions and member functions provided along with an instance on which
2474 to invoke them.<br/>
2475 It does not claim to be a drop-in replacement for an `std::function`, so do not
2476 expect to use it whenever an `std::function` fits well. However, it can be used
2477 to send opaque delegates around to be used to invoke functions as needed.
2478 
2479 The interface is trivial. It offers a default constructor to create empty
2480 delegates:
2481 
2482 ```cpp
2483 entt::Delegate<int(int)> delegate{};
2484 ```
2485 
2486 All what is needed to create an instance is to specify the type of the function
2487 the delegate will _contain_, that is the signature of the free function or the
2488 member function one wants to assign to it.
2489 
2490 Attempting to use an empty delegate by invoking its function call operator
2491 results in undefined behavior, most likely a crash actually. Before to use a
2492 delegate, it must be initialized.<br/>
2493 There exist two functions to do that, both named `connect`:
2494 
2495 ```cpp
2496 int f(int i) { return i; }
2497 
2498 struct MyStruct {
2499  int f(int i) { return i }
2500 };
2501 
2502 // bind a free function to the delegate
2503 delegate.connect<&f>();
2504 
2505 // bind a member function to the delegate
2506 MyStruct instance;
2507 delegate.connect<MyStruct, &MyStruct::f>(&instance);
2508 ```
2509 
2510 It hasn't a `disconnect` counterpart. Instead, there exists a `reset` member
2511 function to clear it.<br/>
2512 The `empty` member function can be used to know if a delegate is empty:
2513 
2514 ```cpp
2515 const auto empty = delegate.empty();
2516 ```
2517 
2518 Finally, to invoke a delegate, the function call operator is the way to go as
2519 usual:
2520 
2521 ```cpp
2522 auto ret = delegate(42);
2523 ```
2524 
2525 Probably too much small and pretty poor of functionalities, but the delegate
2526 class can help in a lot of cases and it has shown that it is worth keeping it
2527 within the library.
2528 
2529 ## Event dispatcher
2530 
2531 The event dispatcher class is designed so as to be used in a loop. It allows
2532 users both to trigger immediate events or to queue events to be published all
2533 together once per tick.<br/>
2534 This class shares part of its API with the one of the signal handler, but it
2535 doesn't require that all the types of events are specified when declared:
2536 
2537 ```cpp
2538 // define a general purpose dispatcher that works with naked pointers
2539 entt::Dispatcher dispatcher{};
2540 ```
2541 
2542 In order to register an instance of a class to a dispatcher, its type must
2543 expose one or more member functions of which the return types are `void` and the
2544 argument lists are `const E &`, for each type of event `E`.<br/>
2545 To ease the development, member functions that are named `receive` are
2546 automatically detected and have not to be explicitly specified when registered.
2547 In all the other cases, the name of the member function aimed to receive the
2548 event must be provided to the `connect` member function of the sink bound to the
2549 specific event:
2550 
2551 ```cpp
2552 struct AnEvent { int value; };
2553 struct AnotherEvent {};
2554 
2555 struct Listener
2556 {
2557  void receive(const AnEvent &) { /* ... */ }
2558  void method(const AnotherEvent &) { /* ... */ }
2559 };
2560 
2561 // ...
2562 
2563 Listener listener;
2564 dispatcher.sink<AnEvent>().connect(&listener);
2565 dispatcher.sink<AnotherEvent>().connect<Listener, &Listener::method>(&listener);
2566 ```
2567 
2568 The `disconnect` member function follows the same pattern and can be used to
2569 selectively remove listeners:
2570 
2571 ```cpp
2572 dispatcher.sink<AnEvent>().disconnect(&listener);
2573 dispatcher.sink<AnotherEvent>().disconnect<Listener, &Listener::method>(&listener);
2574 ```
2575 
2576 The `trigger` member function serves the purpose of sending an immediate event
2577 to all the listeners registered so far. It offers a convenient approach that
2578 relieves the user from having to create the event itself. Instead, it's enough
2579 to specify the type of event and provide all the parameters required to
2580 construct it.<br/>
2581 As an example:
2582 
2583 ```cpp
2584 dispatcher.trigger<AnEvent>(42);
2585 dispatcher.trigger<AnotherEvent>();
2586 ```
2587 
2588 Listeners are invoked immediately, order of execution isn't guaranteed. This
2589 method can be used to push around urgent messages like an _is terminating_
2590 notification on a mobile app.
2591 
2592 On the other hand, the `enqueue` member function queues messages together and
2593 allows to maintain control over the moment they are sent to listeners. The
2594 signature of this method is more or less the same of `trigger`:
2595 
2596 ```cpp
2597 dispatcher.enqueue<AnEvent>(42);
2598 dispatcher.enqueue<AnotherEvent>();
2599 ```
2600 
2601 Events are stored aside until the `update` member function is invoked, then all
2602 the messages that are still pending are sent to the listeners at once:
2603 
2604 ```cpp
2605 // emits all the events of the given type at once
2606 dispatcher.update<MyEvent>();
2607 
2608 // emits all the events queued so far at once
2609 dispatcher.update();
2610 ```
2611 
2612 This way users can embed the dispatcher in a loop and literally dispatch events
2613 once per tick to their systems.
2614 
2615 ## Event emitter
2616 
2617 A general purpose event emitter thought mainly for those cases where it comes to
2618 working with asynchronous stuff.<br/>
2619 Originally designed to fit the requirements of
2620 [`uvw`](https://github.com/skypjack/uvw) (a wrapper for `libuv` written in
2621 modern C++), it was adapted later to be included in this library.
2622 
2623 To create a custom emitter type, derived classes must inherit directly from the
2624 base class as:
2625 
2626 ```cpp
2627 struct MyEmitter: Emitter<MyEmitter> {
2628  // ...
2629 }
2630 ```
2631 
2632 The full list of accepted types of events isn't required. Handlers are created
2633 internally on the fly and thus each type of event is accepted by default.
2634 
2635 Whenever an event is published, an emitter provides the listeners with a
2636 reference to itself along with a const reference to the event. Therefore
2637 listeners have an handy way to work with it without incurring in the need of
2638 capturing a reference to the emitter itself.<br/>
2639 In addition, an opaque object is returned each time a connection is established
2640 between an emitter and a listener, allowing the caller to disconnect them at a
2641 later time.<br/>
2642 The opaque object used to handle connections is both movable and copyable. On
2643 the other side, an event emitter is movable but not copyable by default.
2644 
2645 To create new instances of an emitter, no arguments are required:
2646 
2647 ```cpp
2648 MyEmitter emitter{};
2649 ```
2650 
2651 Listeners must be movable and callable objects (free functions, lambdas,
2652 functors, `std::function`s, whatever) whose function type is:
2653 
2654 ```cpp
2655 void(const Event &, MyEmitter &)
2656 ```
2657 
2658 Where `Event` is the type of event they want to listen.<br/>
2659 There are two ways to attach a listener to an event emitter that differ
2660 slightly from each other:
2661 
2662 * To register a long-lived listener, use the `on` member function. It is meant
2663  to register a listener designed to be invoked more than once for the given
2664  event type.<br/>
2665  As an example:
2666 
2667  ```cpp
2668  auto conn = emitter.on<MyEvent>([](const MyEvent &event, MyEmitter &emitter) {
2669  // ...
2670  });
2671  ```
2672 
2673  The connection object can be freely discarded. Otherwise, it can be used later
2674  to disconnect the listener if required.
2675 
2676 * To register a short-lived listener, use the `once` member function. It is
2677  meant to register a listener designed to be invoked only once for the given
2678  event type. The listener is automatically disconnected after the first
2679  invocation.<br/>
2680  As an example:
2681 
2682  ```cpp
2683  auto conn = emitter.once<MyEvent>([](const MyEvent &event, MyEmitter &emitter) {
2684  // ...
2685  });
2686  ```
2687 
2688  The connection object can be freely discarded. Otherwise, it can be used later
2689  to disconnect the listener if required.
2690 
2691 In both cases, the connection object can be used with the `erase` member
2692 function:
2693 
2694 ```cpp
2695 emitter.erase(conn);
2696 ```
2697 
2698 There are also two member functions to use either to disconnect all the
2699 listeners for a given type of event or to clear the emitter:
2700 
2701 ```cpp
2702 // removes all the listener for the specific event
2703 emitter.clear<MyEvent>();
2704 
2705 // removes all the listeners registered so far
2706 emitter.clear();
2707 ```
2708 
2709 To send an event to all the listeners that are interested in it, the `publish`
2710 member function offers a convenient approach that relieves the user from having
2711 to create the event:
2712 
2713 ```cpp
2714 struct MyEvent { int i; };
2715 
2716 // ...
2717 
2718 emitter.publish<MyEvent>(42);
2719 ```
2720 
2721 Finally, the `empty` member function tests if there exists at least either a
2722 listener registered with the event emitter or to a given type of event:
2723 
2724 ```cpp
2725 bool empty;
2726 
2727 // checks if there is any listener registered for the specific event
2728 empty = emitter.empty<MyEvent>();
2729 
2730 // checks it there are listeners registered with the event emitter
2731 empty = emitter.empty();
2732 ```
2733 
2734 In general, the event emitter is a handy tool when the derived classes _wrap_
2735 asynchronous operations, because it introduces a _nice-to-have_ model based on
2736 events and listeners that kindly hides the complexity behind the scenes. However
2737 it is not limited to such uses.
2738 
2739 # Packaging Tools
2740 
2741 `EnTT` is available for some of the most known packaging tools. In particular:
2742 
2743 * [`vcpkg`](https://github.com/Microsoft/vcpkg/tree/master/ports/entt),
2744  Microsoft VC++ Packaging Tool.
2745 * [`Homebrew`](https://github.com/skypjack/homebrew-entt), the missing package
2746  manager for macOS.<br/>
2747  Available as a homebrew formula. Just type the following to install it:
2748  ```
2749  brew install skypjack/entt/entt
2750  ```
2751 
2752 Consider this list a work in progress and help me to make it longer.
2753 
2754 # EnTT in Action
2755 
2756 `EnTT` is widely used in private and commercial applications. I cannot even
2757 mention most of them because of some signatures I put on some documents time
2758 ago.<br/>
2759 Fortunately, there are also people who took the time to implement open source
2760 projects based on EnTT and did not hold back when it came to documenting them.
2761 
2762 Below an incomplete list of projects and articles:
2763 
2764 * [Minecraft](https://minecraft.net/en-us/attribution/): of course, **that** Minecraft, by Mojang (see the open source attributions page).
2765 * [Face Smash](https://play.google.com/store/apps/details?id=com.gamee.facesmash):
2766  the emojis dominate the world, destroy them all with your facial expressions.
2767 * [EnttPong](https://github.com/reworks/EnttPong): example game with `EnTT`.
2768 * [Space Battle: Huge edition](http://victor.madtriangles.com/code%20experiment/2018/06/11/post-ecs-battle-huge.html):
2769  huge space battle built entirely from scratch.
2770 * [Space Battle](https://github.com/vblanco20-1/ECS_SpaceBattle): huge space
2771  battle built on `UE4`.
2772 * [Experimenting with ECS in UE4](http://victor.madtriangles.com/code%20experiment/2018/03/25/post-ue4-ecs-battle.html):
2773  interesting article about `UE4` and `EnTT`.
2774 * [Implementing ECS architecture in UE4](https://forums.unrealengine.com/development-discussion/c-gameplay-programming/1449913-implementing-ecs-architecture-in-ue4-giant-space-battle):
2775  giant space battle.
2776 * [MatchOneEntt](https://github.com/mhaemmerle/MatchOneEntt): port of
2777  [Match One](https://github.com/sschmid/Match-One) for `Entitas-CSharp`.
2778 * [Randballs](https://github.com/gale93/randballs): simple `SFML` and `EnTT`
2779  playground.
2780 * ...
2781 
2782 If you know of other resources out there that are about `EnTT`, feel free to
2783 open an issue or a PR and I'll be glad to add them to the list.
2784 
2785 <!--
2786 @cond TURN_OFF_DOXYGEN
2787 -->
2788 # Contributors
2789 
2790 `EnTT` was written initially as a faster alternative to other well known and
2791 open source entity-component systems. Nowadays this library is moving its first
2792 steps. Much more will come in the future and hopefully I'm going to work on it
2793 for a long time.<br/>
2794 Requests for features, PR, suggestions ad feedback are highly appreciated.
2795 
2796 If you find you can help me and want to contribute to the project with your
2797 experience or you do want to get part of the project for some other reasons,
2798 feel free to contact me directly (you can find the mail in the
2799 [profile](https://github.com/skypjack)).<br/>
2800 I can't promise that each and every contribution will be accepted, but I can
2801 assure that I'll do my best to take them all seriously.
2802 
2803 If you decide to participate, please see the guidelines for
2804 [contributing](docs/CONTRIBUTING.md) before to create issues or pull requests.<br/>
2805 Take also a look at the
2806 [contributors list](https://github.com/skypjack/entt/blob/master/AUTHORS) to
2807 know who has participated so far.
2808 <!--
2809 @endcond TURN_OFF_DOXYGEN
2810 -->
2811 
2812 # License
2813 
2814 Code and documentation Copyright (c) 2017-2018 Michele Caini.<br/>
2815 Logo Copyright (c) 2018 Richard Caseres.
2816 
2817 Code released under
2818 [the MIT license](https://github.com/skypjack/entt/blob/master/LICENSE).
2819 Documentation released under
2820 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).<br/>
2821 Logo released under
2822 [CC BY-SA 4.0](https://creativecommons.org/licenses/by-sa/4.0/).
2823 
2824 <!--
2825 @cond TURN_OFF_DOXYGEN
2826 -->
2827 # Support
2828 
2829 ## Donation
2830 
2831 Developing and maintaining `EnTT` takes some time and lots of coffee. I'd like
2832 to add more and more functionalities in future and turn it in a full-featured
2833 solution.<br/>
2834 If you want to support this project, you can offer me an espresso. I'm from
2835 Italy, we're used to turning the best coffee ever in code. If you find that
2836 it's not enough, feel free to support me the way you prefer.<br/>
2837 Take a look at the donation button at the top of the page for more details or
2838 just click [here](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=W2HF9FESD5LJY&lc=IT&item_name=Michele%20Caini&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted).
2839 
2840 ## Hire me
2841 
2842 If you start using `EnTT` and need help, if you want a new feature and want me
2843 to give it the highest priority, if you have any other reason to contact me:
2844 do not hesitate. I'm available for hiring.<br/>
2845 Feel free to take a look at my [profile](https://github.com/skypjack) and
2846 contact me by mail.
2847 <!--
2848 @endcond TURN_OFF_DOXYGEN
2849 -->
+
1 ![EnTT: Gaming meets modern C++](https://user-images.githubusercontent.com/1812216/42513718-ee6e98d0-8457-11e8-9baf-8d83f61a3097.png)
2 
3 <!--
4 @cond TURN_OFF_DOXYGEN
5 -->
6 [![Build Status](https://travis-ci.org/skypjack/entt.svg?branch=master)](https://travis-ci.org/skypjack/entt)
7 [![Build status](https://ci.appveyor.com/api/projects/status/rvhaabjmghg715ck?svg=true)](https://ci.appveyor.com/project/skypjack/entt)
8 [![Coverage Status](https://coveralls.io/repos/github/skypjack/entt/badge.svg?branch=master)](https://coveralls.io/github/skypjack/entt?branch=master)
9 [![Gitter chat](https://badges.gitter.im/skypjack/entt.png)](https://gitter.im/skypjack/entt)
10 [![Donate](https://img.shields.io/badge/Donate-PayPal-green.svg)](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=W2HF9FESD5LJY&lc=IT&item_name=Michele%20Caini&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted)
11 
12 # Table of Contents
13 
14 * [Introduction](#introduction)
15  * [Code Example](#code-example)
16  * [Motivation](#motivation)
17  * [Performance](#performance)
18 * [Build Instructions](#build-instructions)
19  * [Requirements](#requirements)
20  * [Library](#library)
21  * [Documentation](#documentation)
22  * [Tests](#tests)
23 * [Packaging Tools](#packaging-tools)
24 * [EnTT in Action](#entt-in-action)
25 * [Contributors](#contributors)
26 * [License](#license)
27 * [Support](#support)
28  * [Donation](#donation)
29  * [Hire me](#hire-me)
30 <!--
31 @endcond TURN_OFF_DOXYGEN
32 -->
33 
34 # Introduction
35 
36 `EnTT` is a header-only, tiny and easy to use entity-component system (and much
37 more) written in modern C++ and even
38 [used by Mojang in Minecraft](https://minecraft.net/en-us/attribution/).<br/>
39 The entity-component-system (also known as _ECS_) is an architectural pattern
40 used mostly in game development. For further details:
41 
42 * [Entity Systems Wiki](http://entity-systems.wikidot.com/)
43 * [Evolve Your Hierarchy](http://cowboyprogramming.com/2007/01/05/evolve-your-heirachy/)
44 * [ECS on Wikipedia](https://en.wikipedia.org/wiki/Entity%E2%80%93component%E2%80%93system)
45 
46 A long time ago, the sole entity-component system was part of the project. After
47 a while the codebase has grown and more and more classes have become part of the
48 repository.<br/>
49 Here is a brief, yet incomplete list of what it offers today:
50 
51 * Statically generated integer identifiers for types (assigned either at
52  compile-time or at runtime).
53 * A constexpr utility for human readable resource identifiers.
54 * A minimal configuration system built on top of the monostate pattern.
55 * An incredibly fast entity-component system based on sparse sets, with its own
56  views and a _pay for what you use_ policy to adjust performance and memory
57  usage according to users' requirements.
58 * A lot of facilities built on top of the entity-component system to help
59  developers and avoid reinventing the wheel (ie dependencies, snapshot, actor
60  class for those who aren't confident with the architecture and so on).
61 * The smallest and most basic implementation of a service locator ever seen.
62 * A cooperative scheduler for processes of any type.
63 * All what is needed for resource management (cache, loaders, handles).
64 * Delegates, signal handlers (with built-in support for collectors) and a tiny
65  event dispatcher.
66 * A general purpose event emitter, that is a CRTP idiom based class template.
67 * An event dispatcher for immediate and delayed events to integrate in loops.
68 * ...
69 * Any other business.
70 
71 Consider it a work in progress. The whole API is also fully documented in-code
72 for those who are brave enough to read it.
73 
74 Currently, `EnTT` is tested on Linux, Microsoft Windows and OS X. It has proven
75 to work also on both Android and iOS.<br/>
76 Most likely it will not be problematic on other systems as well, but has not
77 been sufficiently tested so far.
78 
79 ## Code Example
80 
81 ```cpp
82 #include <entt/entt.hpp>
83 #include <cstdint>
84 
85 struct Position {
86  float x;
87  float y;
88 };
89 
90 struct Velocity {
91  float dx;
92  float dy;
93 };
94 
95 void update(entt::DefaultRegistry &registry) {
96  auto view = registry.view<Position, Velocity>();
97 
98  for(auto entity: view) {
99  // gets only the components that are going to be used ...
100 
101  auto &velocity = view.get<Velocity>(entity);
102 
103  velocity.dx = 0.;
104  velocity.dy = 0.;
105 
106  // ...
107  }
108 }
109 
110 void update(std::uint64_t dt, entt::DefaultRegistry &registry) {
111  registry.view<Position, Velocity>().each([dt](auto entity, auto &position, auto &velocity) {
112  // gets all the components of the view at once ...
113 
114  position.x += velocity.dx * dt;
115  position.y += velocity.dy * dt;
116 
117  // ...
118  });
119 }
120 
121 int main() {
122  entt::DefaultRegistry registry;
123  std::uint64_t dt = 16;
124 
125  for(auto i = 0; i < 10; ++i) {
126  auto entity = registry.create();
127  registry.assign<Position>(entity, i * 1.f, i * 1.f);
128  if(i % 2 == 0) { registry.assign<Velocity>(entity, i * .1f, i * .1f); }
129  }
130 
131  update(dt, registry);
132  update(registry);
133 
134  // ...
135 }
136 ```
137 
138 ## Motivation
139 
140 I started working on `EnTT` because of the wrong reason: my goal was to design
141 an entity-component system that beated another well known open source solution
142 in terms of performance and used (possibly) less memory in the average
143 case.<br/>
144 In the end, I did it, but it wasn't much satisfying. Actually it wasn't
145 satisfying at all. The fastest and nothing more, fairly little indeed. When I
146 realized it, I tried hard to keep intact the great performance of `EnTT` and to
147 add all the features I wanted to see in *my own library* at the same time.
148 
149 Nowadays, `EnTT` is finally what I was looking for: still faster than its
150 _competitors_, lower memory usage in the average case, a really good API and an
151 amazing set of features. And even more, of course.
152 
153 ## Performance
154 
155 As it stands right now, `EnTT` is just fast enough for my requirements if
156 compared to my first choice (it was already amazingly fast actually).<br/>
157 Below is a comparison between the two (both of them compiled with GCC 7.3.0 on a
158 Dell XPS 13 out of the mid 2014):
159 
160 | Benchmark | EntityX (compile-time) | EnTT |
161 |-----------|-------------|-------------|
162 | Create 1M entities | 0.0147s | **0.0046s** |
163 | Destroy 1M entities | 0.0053s | **0.0045s** |
164 | 1M entities, one component | 0.0012s | **1.9e-07s** |
165 | 1M entities, two components | 0.0012s | **3.8e-07s** |
166 | 1M entities, two components<br/>Half of the entities have all the components | 0.0009s | **3.8e-07s** |
167 | 1M entities, two components<br/>One of the entities has all the components | 0.0008s | **1.0e-06s** |
168 | 1M entities, five components | 0.0010s | **7.0e-07s** |
169 | 1M entities, ten components | 0.0011s | **1.2e-06s** |
170 | 1M entities, ten components<br/>Half of the entities have all the components | 0.0010s | **1.2e-06s** |
171 | 1M entities, ten components<br/>One of the entities has all the components | 0.0008s | **1.2e-06s** |
172 | Sort 150k entities, one component<br/>Arrays are in reverse order | - | **0.0036s** |
173 | Sort 150k entities, enforce permutation<br/>Arrays are in reverse order | - | **0.0005s** |
174 | Sort 150k entities, one component<br/>Arrays are almost sorted, std::sort | - | **0.0035s** |
175 | Sort 150k entities, one component<br/>Arrays are almost sorted, insertion sort | - | **0.0007s** |
176 
177 Note: The default version of `EntityX` (`master` branch) wasn't added to the
178 comparison because it's already much slower than its compile-time counterpart.
179 
180 Pretty interesting, aren't them? In fact, these benchmarks are the same used by
181 `EntityX` to show _how fast it is_. To be honest, they aren't so good and these
182 results shouldn't be taken much seriously (they are completely unrealistic
183 indeed).<br/>
184 The proposed entity-component system is incredibly fast to iterate entities,
185 this is a fact. The compiler can make a lot of optimizations because of how
186 `EnTT` works, even more when components aren't used at all. This is exactly the
187 case for these benchmarks. On the other hand and if we consider real world
188 cases, `EnTT` is in the middle between a bit and much faster than the other
189 solutions around when users also access the components and not just the
190 entities, although it is not as fast as reported by these benchmarks.<br/>
191 This is why they are completely wrong and cannot be used to evaluate any of the
192 entity-component systems.
193 
194 If you decide to use `EnTT`, choose it because of its API, features and
195 performance, not because there is a benchmark somewhere that makes it seem the
196 fastest.
197 
198 Probably I'll try to get out of `EnTT` more features and even better performance
199 in the future, mainly for fun.<br/>
200 If you want to contribute and/or have any suggestion, feel free to make a PR or
201 open an issue to discuss your idea.
202 
203 # Build Instructions
204 
205 ## Requirements
206 
207 To be able to use `EnTT`, users must provide a full-featured compiler that
208 supports at least C++14.<br/>
209 The requirements below are mandatory to compile the tests and to extract the
210 documentation:
211 
212 * CMake version 3.2 or later.
213 * Doxygen version 1.8 or later.
214 
215 ## Library
216 
217 `EnTT` is a header-only library. This means that including the `entt.hpp` header
218 is enough to include the library as a whole and use it. For those who are
219 interested only in the entity-component system, consider to include the sole
220 `entity/registry.hpp` header instead.<br/>
221 It's a matter of adding the following line to the top of a file:
222 
223 ```cpp
224 #include <entt/entt.hpp>
225 ```
226 
227 Use the line below to include only the entity-component system instead:
228 
229 ```cpp
230 #include <entt/entity/registry.hpp>
231 ```
232 
233 Then pass the proper `-I` argument to the compiler to add the `src` directory to
234 the include paths.
235 
236 ## Documentation
237 
238 The documentation is based on [doxygen](http://www.stack.nl/~dimitri/doxygen/).
239 To build it:
240 
241  $ cd build
242  $ cmake .. -DBUILD_DOCS=ON
243  $ make
244 
245 The API reference will be created in HTML format within the directory
246 `build/docs/html`. To navigate it with your favorite browser:
247 
248  $ cd build
249  $ your_favorite_browser docs/html/index.html
250 
251 <!--
252 @cond TURN_OFF_DOXYGEN
253 -->
254 The API reference is also available [online](https://skypjack.github.io/entt/)
255 for the latest version.<br/>
256 There exists also a [wiki](https://github.com/skypjack/entt/wiki) dedicated to
257 the project where users can find all related documentation pages.
258 <!--
259 @endcond TURN_OFF_DOXYGEN
260 -->
261 
262 ## Tests
263 
264 To compile and run the tests, `EnTT` requires *googletest*.<br/>
265 `cmake` will download and compile the library before compiling anything else.
266 In order to build without tests set CMake option `BUILD_TESTING=OFF`.
267 
268 To build the most basic set of tests:
269 
270 * `$ cd build`
271 * `$ cmake ..`
272 * `$ make`
273 * `$ make test`
274 
275 Note that benchmarks are not part of this set.
276 
277 # Packaging Tools
278 
279 `EnTT` is available for some of the most known packaging tools. In particular:
280 
281 * [`vcpkg`](https://github.com/Microsoft/vcpkg/tree/master/ports/entt),
282  Microsoft VC++ Packaging Tool.
283 * [`Homebrew`](https://github.com/skypjack/homebrew-entt), the missing package
284  manager for macOS.<br/>
285  Available as a homebrew formula. Just type the following to install it:
286  ```
287  brew install skypjack/entt/entt
288  ```
289 
290 Consider this list a work in progress and help me to make it longer.
291 
292 # EnTT in Action
293 
294 `EnTT` is widely used in private and commercial applications. I cannot even
295 mention most of them because of some signatures I put on some documents time
296 ago.<br/>
297 Fortunately, there are also people who took the time to implement open source
298 projects based on EnTT and did not hold back when it came to documenting them.
299 
300 Below an incomplete list of projects and articles:
301 
302 * [Minecraft](https://minecraft.net/en-us/attribution/): of course, **that**
303  Minecraft, by Mojang (see the open source attributions page).
304 * [Face Smash](https://play.google.com/store/apps/details?id=com.gamee.facesmash):
305  the emojis dominate the world, destroy them all with your facial expressions.
306 * [shiva](https://github.com/Milerius/shiva): modern C++ Engine with modularity.
307 * [Classic Tower Defence](https://github.com/kerndog73/Classic-Tower-Defence):
308  a tiny little tower defence game featuring a homemade font.
309  [Check it out](https://indi-kernick.itch.io/classic-tower-defence).
310 * [The Machine](https://github.com/Kerndog73/The-Machine): a box pushing puzzler
311  with logic gates and other cool stuff.
312  [Check it out](https://indi-kernick.itch.io/the-machine-web-version).
313 * [EnttPong](https://github.com/reworks/EnttPong): example game with `EnTT`.
314 * [Space Battle: Huge edition](http://victor.madtriangles.com/code%20experiment/2018/06/11/post-ecs-battle-huge.html):
315  huge space battle built entirely from scratch.
316 * [Space Battle](https://github.com/vblanco20-1/ECS_SpaceBattle): huge space
317  battle built on `UE4`.
318 * [Experimenting with ECS in UE4](http://victor.madtriangles.com/code%20experiment/2018/03/25/post-ue4-ecs-battle.html):
319  interesting article about `UE4` and `EnTT`.
320 * [Implementing ECS architecture in UE4](https://forums.unrealengine.com/development-discussion/c-gameplay-programming/1449913-implementing-ecs-architecture-in-ue4-giant-space-battle):
321  giant space battle.
322 * [MatchOneEntt](https://github.com/mhaemmerle/MatchOneEntt): port of
323  [Match One](https://github.com/sschmid/Match-One) for `Entitas-CSharp`.
324 * [Randballs](https://github.com/gale93/randballs): simple `SFML` and `EnTT`
325  playground.
326 * ...
327 
328 If you know of other resources out there that are about `EnTT`, feel free to
329 open an issue or a PR and I'll be glad to add them to the list.
330 
331 <!--
332 @cond TURN_OFF_DOXYGEN
333 -->
334 # Contributors
335 
336 `EnTT` was written initially as a faster alternative to other well known and
337 open source entity-component systems. Nowadays this library is moving its first
338 steps. Much more will come in the future and hopefully I'm going to work on it
339 for a long time.<br/>
340 Requests for features, PR, suggestions ad feedback are highly appreciated.
341 
342 If you find you can help me and want to contribute to the project with your
343 experience or you do want to get part of the project for some other reasons,
344 feel free to contact me directly (you can find the mail in the
345 [profile](https://github.com/skypjack)).<br/>
346 I can't promise that each and every contribution will be accepted, but I can
347 assure that I'll do my best to take them all seriously.
348 
349 If you decide to participate, please see the guidelines for
350 [contributing](docs/CONTRIBUTING.md) before to create issues or pull requests.<br/>
351 Take also a look at the
352 [contributors list](https://github.com/skypjack/entt/blob/master/AUTHORS) to
353 know who has participated so far.
354 <!--
355 @endcond TURN_OFF_DOXYGEN
356 -->
357 
358 # License
359 
360 Code and documentation Copyright (c) 2017-2018 Michele Caini.<br/>
361 Logo Copyright (c) 2018 Richard Caseres.
362 
363 Code released under
364 [the MIT license](https://github.com/skypjack/entt/blob/master/LICENSE).
365 Documentation released under
366 [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/).<br/>
367 Logo released under
368 [CC BY-SA 4.0](https://creativecommons.org/licenses/by-sa/4.0/).
369 
370 <!--
371 @cond TURN_OFF_DOXYGEN
372 -->
373 # Support
374 
375 ## Donation
376 
377 Developing and maintaining `EnTT` takes some time and lots of coffee. I'd like
378 to add more and more functionalities in future and turn it in a full-featured
379 solution.<br/>
380 If you want to support this project, you can offer me an espresso. I'm from
381 Italy, we're used to turning the best coffee ever in code. If you find that
382 it's not enough, feel free to support me the way you prefer.<br/>
383 Take a look at the donation button at the top of the page for more details or
384 just click [here](https://www.paypal.com/cgi-bin/webscr?cmd=_donations&business=W2HF9FESD5LJY&lc=IT&item_name=Michele%20Caini&currency_code=EUR&bn=PP%2dDonationsBF%3abtn_donateCC_LG%2egif%3aNonHosted).
385 
386 ## Hire me
387 
388 If you start using `EnTT` and need help, if you want a new feature and want me
389 to give it the highest priority, if you have any other reason to contact me:
390 do not hesitate. I'm available for hiring.<br/>
391 Feel free to take a look at my [profile](https://github.com/skypjack) and
392 contact me by mail.
393 <!--
394 @endcond TURN_OFF_DOXYGEN
395 -->