\hypertarget{classentt_1_1basic__snapshot}{}\doxysection{entt\+::basic\+\_\+snapshot$<$ Entity $>$ Class Template Reference}
\label{classentt_1_1basic__snapshot}\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}


Utility class to create snapshots from a registry.  




{\ttfamily \#include $<$entt.\+hpp$>$}

\doxysubsection*{Public Types}
\begin{DoxyCompactItemize}
\item 
\mbox{\Hypertarget{classentt_1_1basic__snapshot_aeb9724b67563bf7f74440e5a8feb711c}\label{classentt_1_1basic__snapshot_aeb9724b67563bf7f74440e5a8feb711c}} 
using \mbox{\hyperlink{classentt_1_1basic__snapshot_aeb9724b67563bf7f74440e5a8feb711c}{entity\+\_\+type}} = Entity
\begin{DoxyCompactList}\small\item\em Underlying entity identifier. \end{DoxyCompactList}\end{DoxyCompactItemize}
\doxysubsection*{Public Member Functions}
\begin{DoxyCompactItemize}
\item 
\mbox{\hyperlink{classentt_1_1basic__snapshot_ac0777064a8cd3109286398e2488e7111}{basic\+\_\+snapshot}} (const \mbox{\hyperlink{classentt_1_1basic__registry}{basic\+\_\+registry}}$<$ \mbox{\hyperlink{classentt_1_1basic__snapshot_aeb9724b67563bf7f74440e5a8feb711c}{entity\+\_\+type}} $>$ \&source) E\+N\+T\+T\+\_\+\+N\+O\+E\+X\+C\+E\+PT
\begin{DoxyCompactList}\small\item\em Constructs an instance that is bound to a given registry. \end{DoxyCompactList}\item 
\mbox{\Hypertarget{classentt_1_1basic__snapshot_a10f658d8e4feb7df9da8b48119551334}\label{classentt_1_1basic__snapshot_a10f658d8e4feb7df9da8b48119551334}} 
\mbox{\hyperlink{classentt_1_1basic__snapshot_a10f658d8e4feb7df9da8b48119551334}{basic\+\_\+snapshot}} (\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \&\&)=default
\begin{DoxyCompactList}\small\item\em Default move constructor. \end{DoxyCompactList}\item 
\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \& \mbox{\hyperlink{classentt_1_1basic__snapshot_a1484b609195cfd057bbdd8808d4392bc}{operator=}} (\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \&\&)=default
\begin{DoxyCompactList}\small\item\em Default move assignment operator. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename Archive $>$ }\\const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \& \mbox{\hyperlink{classentt_1_1basic__snapshot_a79fe1641f3b448b37b8aecfcabf52a5e}{entities}} (Archive \&archive) const
\begin{DoxyCompactList}\small\item\em Puts aside all the entities from the underlying registry. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename... Component, typename Archive $>$ }\\const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \& \mbox{\hyperlink{classentt_1_1basic__snapshot_a59cf70d5b7730d388f3a63845e8faede}{component}} (Archive \&archive) const
\begin{DoxyCompactList}\small\item\em Puts aside the given components. \end{DoxyCompactList}\item 
{\footnotesize template$<$typename... Component, typename Archive , typename It $>$ }\\const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} \& \mbox{\hyperlink{classentt_1_1basic__snapshot_a05fff12a4af42f0ad77dc4893856772c}{component}} (Archive \&archive, It first, It last) const
\begin{DoxyCompactList}\small\item\em Puts aside the given components for the entities in a range. \end{DoxyCompactList}\end{DoxyCompactItemize}


\doxysubsection{Detailed Description}
\subsubsection*{template$<$typename Entity$>$\newline
class entt\+::basic\+\_\+snapshot$<$ Entity $>$}

Utility class to create snapshots from a registry. 

A {\itshape snapshot} can be either a dump of the entire registry or a narrower selection of components of interest.~\newline
 This type can be used in both cases if provided with a correctly configured output archive.


\begin{DoxyTemplParams}{Template Parameters}
{\em Entity} & A valid entity type (see \mbox{\hyperlink{structentt_1_1entt__traits}{entt\+\_\+traits}} for more details). \\
\hline
\end{DoxyTemplParams}


\doxysubsection{Constructor \& Destructor Documentation}
\mbox{\Hypertarget{classentt_1_1basic__snapshot_ac0777064a8cd3109286398e2488e7111}\label{classentt_1_1basic__snapshot_ac0777064a8cd3109286398e2488e7111}} 
\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}!basic\_snapshot@{basic\_snapshot}}
\index{basic\_snapshot@{basic\_snapshot}!entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}
\doxysubsubsection{\texorpdfstring{basic\_snapshot()}{basic\_snapshot()}}
{\footnotesize\ttfamily template$<$typename Entity $>$ \\
\mbox{\hyperlink{classentt_1_1basic__snapshot}{entt\+::basic\+\_\+snapshot}}$<$ Entity $>$\+::\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}} (\begin{DoxyParamCaption}\item[{const \mbox{\hyperlink{classentt_1_1basic__registry}{basic\+\_\+registry}}$<$ \mbox{\hyperlink{classentt_1_1basic__snapshot_aeb9724b67563bf7f74440e5a8feb711c}{entity\+\_\+type}} $>$ \&}]{source }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [inline]}}



Constructs an instance that is bound to a given registry. 


\begin{DoxyParams}{Parameters}
{\em source} & A valid reference to a registry. \\
\hline
\end{DoxyParams}


\doxysubsection{Member Function Documentation}
\mbox{\Hypertarget{classentt_1_1basic__snapshot_a59cf70d5b7730d388f3a63845e8faede}\label{classentt_1_1basic__snapshot_a59cf70d5b7730d388f3a63845e8faede}} 
\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}!component@{component}}
\index{component@{component}!entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}
\doxysubsubsection{\texorpdfstring{component()}{component()}\hspace{0.1cm}{\footnotesize\ttfamily [1/2]}}
{\footnotesize\ttfamily template$<$typename Entity $>$ \\
template$<$typename... Component, typename Archive $>$ \\
const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}}\& \mbox{\hyperlink{classentt_1_1basic__snapshot}{entt\+::basic\+\_\+snapshot}}$<$ Entity $>$\+::component (\begin{DoxyParamCaption}\item[{Archive \&}]{archive }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Puts aside the given components. 

Each instance is serialized together with the entity to which it belongs. Entities are serialized along with their versions.


\begin{DoxyTemplParams}{Template Parameters}
{\em Component} & Types of components to serialize. \\
\hline
{\em Archive} & Type of output archive. \\
\hline
\end{DoxyTemplParams}

\begin{DoxyParams}{Parameters}
{\em archive} & A valid reference to an output archive. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
An object of this type to continue creating the snapshot. 
\end{DoxyReturn}
\mbox{\Hypertarget{classentt_1_1basic__snapshot_a05fff12a4af42f0ad77dc4893856772c}\label{classentt_1_1basic__snapshot_a05fff12a4af42f0ad77dc4893856772c}} 
\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}!component@{component}}
\index{component@{component}!entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}
\doxysubsubsection{\texorpdfstring{component()}{component()}\hspace{0.1cm}{\footnotesize\ttfamily [2/2]}}
{\footnotesize\ttfamily template$<$typename Entity $>$ \\
template$<$typename... Component, typename Archive , typename It $>$ \\
const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}}\& \mbox{\hyperlink{classentt_1_1basic__snapshot}{entt\+::basic\+\_\+snapshot}}$<$ Entity $>$\+::component (\begin{DoxyParamCaption}\item[{Archive \&}]{archive,  }\item[{It}]{first,  }\item[{It}]{last }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Puts aside the given components for the entities in a range. 

Each instance is serialized together with the entity to which it belongs. Entities are serialized along with their versions.


\begin{DoxyTemplParams}{Template Parameters}
{\em Component} & Types of components to serialize. \\
\hline
{\em Archive} & Type of output archive. \\
\hline
{\em It} & Type of input iterator. \\
\hline
\end{DoxyTemplParams}

\begin{DoxyParams}{Parameters}
{\em archive} & A valid reference to an output archive. \\
\hline
{\em first} & An iterator to the first element of the range to serialize. \\
\hline
{\em last} & An iterator past the last element of the range to serialize. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
An object of this type to continue creating the snapshot. 
\end{DoxyReturn}
\mbox{\Hypertarget{classentt_1_1basic__snapshot_a79fe1641f3b448b37b8aecfcabf52a5e}\label{classentt_1_1basic__snapshot_a79fe1641f3b448b37b8aecfcabf52a5e}} 
\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}!entities@{entities}}
\index{entities@{entities}!entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}
\doxysubsubsection{\texorpdfstring{entities()}{entities()}}
{\footnotesize\ttfamily template$<$typename Entity $>$ \\
template$<$typename Archive $>$ \\
const \mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}}\& \mbox{\hyperlink{classentt_1_1basic__snapshot}{entt\+::basic\+\_\+snapshot}}$<$ Entity $>$\+::entities (\begin{DoxyParamCaption}\item[{Archive \&}]{archive }\end{DoxyParamCaption}) const\hspace{0.3cm}{\ttfamily [inline]}}



Puts aside all the entities from the underlying registry. 

Entities are serialized along with their versions. Destroyed entities are taken in consideration as well by this function.


\begin{DoxyTemplParams}{Template Parameters}
{\em Archive} & Type of output archive. \\
\hline
\end{DoxyTemplParams}

\begin{DoxyParams}{Parameters}
{\em archive} & A valid reference to an output archive. \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
An object of this type to continue creating the snapshot. 
\end{DoxyReturn}
\mbox{\Hypertarget{classentt_1_1basic__snapshot_a1484b609195cfd057bbdd8808d4392bc}\label{classentt_1_1basic__snapshot_a1484b609195cfd057bbdd8808d4392bc}} 
\index{entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}!operator=@{operator=}}
\index{operator=@{operator=}!entt::basic\_snapshot$<$ Entity $>$@{entt::basic\_snapshot$<$ Entity $>$}}
\doxysubsubsection{\texorpdfstring{operator=()}{operator=()}}
{\footnotesize\ttfamily template$<$typename Entity $>$ \\
\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}}\& \mbox{\hyperlink{classentt_1_1basic__snapshot}{entt\+::basic\+\_\+snapshot}}$<$ Entity $>$\+::operator= (\begin{DoxyParamCaption}\item[{\mbox{\hyperlink{classentt_1_1basic__snapshot}{basic\+\_\+snapshot}}$<$ Entity $>$ \&\&}]{ }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [default]}}



Default move assignment operator. 

\begin{DoxyReturn}{Returns}
This snapshot. 
\end{DoxyReturn}


The documentation for this class was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
Light\+Framework/libs/entt/entt.\+hpp\end{DoxyCompactItemize}
