\hypertarget{interfacemom__restart_1_1query__initialized}{}\section{mom\+\_\+restart\+:\+:query\+\_\+initialized Interface Reference}
\label{interfacemom__restart_1_1query__initialized}\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}


\subsection{Detailed Description}
Indicate whether a field has been read from a restart file. 

Definition at line 127 of file M\+O\+M\+\_\+restart.\+F90.

\subsection*{Private functions}
\begin{DoxyCompactItemize}
\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_aab7618a35470325d0e71f735062076df}{query\+\_\+initialized\+\_\+name} (name, CS)
\begin{DoxyCompactList}\small\item\em query\+\_\+initialized\+\_\+name determines whether a named field has been successfully read from a restart file yet. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a019232dcb10d95b4afb2465e3e9d156e}{query\+\_\+initialized\+\_\+0d} (f\+\_\+ptr, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a9b9078b4d2d319db2e42c5b136297ef3}{query\+\_\+initialized\+\_\+0d\+\_\+name} (f\+\_\+ptr, name, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_af7d990c5d2fa87ba9ded702da6882e8a}{query\+\_\+initialized\+\_\+1d} (f\+\_\+ptr, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_abc9c751887b1b1de63f314083190ae55}{query\+\_\+initialized\+\_\+1d\+\_\+name} (f\+\_\+ptr, name, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a26a3f5be16287c44d1c6671d09b57146}{query\+\_\+initialized\+\_\+2d} (f\+\_\+ptr, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a16c24c5211593798974d8b031df3f09f}{query\+\_\+initialized\+\_\+2d\+\_\+name} (f\+\_\+ptr, name, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a279ceb2d87f86af8cfe05c3b31591f7e}{query\+\_\+initialized\+\_\+3d} (f\+\_\+ptr, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a2a6459fa473dac0bcc1c021e617d1b12}{query\+\_\+initialized\+\_\+3d\+\_\+name} (f\+\_\+ptr, name, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a8ac9fb65f1baf382c18cc83882c97aa6}{query\+\_\+initialized\+\_\+4d} (f\+\_\+ptr, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. \end{DoxyCompactList}\item 
logical function \hyperlink{interfacemom__restart_1_1query__initialized_a45b4e201527e3ce2d238e895d855878f}{query\+\_\+initialized\+\_\+4d\+\_\+name} (f\+\_\+ptr, name, CS)
\begin{DoxyCompactList}\small\item\em Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Detailed Description}
Indicate whether a field has been read from a restart file. 

Definition at line 127 of file M\+O\+M\+\_\+restart.\+F90.



\subsection{Functions and subroutines}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a019232dcb10d95b4afb2465e3e9d156e}\label{interfacemom__restart_1_1query__initialized_a019232dcb10d95b4afb2465e3e9d156e}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+0d@{query\+\_\+initialized\+\_\+0d}}
\index{query\+\_\+initialized\+\_\+0d@{query\+\_\+initialized\+\_\+0d}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+0d()}{query\_initialized\_0d()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+0d (\begin{DoxyParamCaption}\item[{real, intent(in), target}]{f\+\_\+ptr,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 536 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
536   \textcolor{keywordtype}{real},         \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
537   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
538   \textcolor{keywordtype}{logical} :: query\_initialized
539 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr has}
540 \textcolor{comment}{! been initialized from a restart file.}
541 
542   \textcolor{keywordtype}{integer} :: m,n
543   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
544       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
545   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
546 
547   query\_initialized = .false.
548   n = cs%novars+1
549   \textcolor{keywordflow}{do} m=1,cs%novars
550     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr0d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
551       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
552       n = m ; \textcolor{keywordflow}{exit}
553 \textcolor{keywordflow}{    endif}
554 \textcolor{keywordflow}{  enddo}
555 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
556 \textcolor{comment}{! queried again.}
557   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
558 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a9b9078b4d2d319db2e42c5b136297ef3}\label{interfacemom__restart_1_1query__initialized_a9b9078b4d2d319db2e42c5b136297ef3}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+0d\+\_\+name@{query\+\_\+initialized\+\_\+0d\+\_\+name}}
\index{query\+\_\+initialized\+\_\+0d\+\_\+name@{query\+\_\+initialized\+\_\+0d\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+0d\+\_\+name()}{query\_initialized\_0d\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+0d\+\_\+name (\begin{DoxyParamCaption}\item[{real, intent(in), target}]{f\+\_\+ptr,  }\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 675 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
675   \textcolor{keywordtype}{real},         \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
676   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
677   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
678   \textcolor{keywordtype}{logical} :: query\_initialized
679 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr or with the}
680 \textcolor{comment}{! specified variable name has been initialized from a restart file.}
681 
682   \textcolor{keywordtype}{integer} :: m,n
683   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
684       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
685   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
686 
687   query\_initialized = .false.
688   n = cs%novars+1
689   \textcolor{keywordflow}{do} m=1,cs%novars
690     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr0d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
691       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
692       n = m ; \textcolor{keywordflow}{exit}
693 \textcolor{keywordflow}{    endif}
694 \textcolor{keywordflow}{  enddo}
695 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
696 \textcolor{comment}{! queried again.}
697   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
698   \textcolor{keywordflow}{if} (n==cs%novars+1) \textcolor{keywordflow}{then}
699     \textcolor{keywordflow}{if} (is\_root\_pe()) &
700       \textcolor{keyword}{call }mom\_error(note,\textcolor{stringliteral}{"MOM\_restart: Unable to find "}//name//\textcolor{stringliteral}{" queried by pointer, "}//&
701         \textcolor{stringliteral}{"probably because of the suspect comparison of pointers by ASSOCIATED."})
702     query\_initialized = query\_initialized\_name(name, cs)
703 \textcolor{keywordflow}{  endif}
704 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_af7d990c5d2fa87ba9ded702da6882e8a}\label{interfacemom__restart_1_1query__initialized_af7d990c5d2fa87ba9ded702da6882e8a}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+1d@{query\+\_\+initialized\+\_\+1d}}
\index{query\+\_\+initialized\+\_\+1d@{query\+\_\+initialized\+\_\+1d}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+1d()}{query\_initialized\_1d()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+1d (\begin{DoxyParamCaption}\item[{real, dimension(\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 563 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
563   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:)}, \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
564   \textcolor{keywordtype}{type}(mom\_restart\_cs),       \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
565   \textcolor{keywordtype}{logical} :: query\_initialized
566 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr has}
567 \textcolor{comment}{! been initialized from a restart file.}
568 
569   \textcolor{keywordtype}{integer} :: m,n
570   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
571       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
572   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
573 
574   query\_initialized = .false.
575   n = cs%novars+1
576   \textcolor{keywordflow}{do} m=1,cs%novars
577     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr1d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
578       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
579       n = m ; \textcolor{keywordflow}{exit}
580 \textcolor{keywordflow}{    endif}
581 \textcolor{keywordflow}{  enddo}
582 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
583 \textcolor{comment}{! queried again.}
584   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
585 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_abc9c751887b1b1de63f314083190ae55}\label{interfacemom__restart_1_1query__initialized_abc9c751887b1b1de63f314083190ae55}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+1d\+\_\+name@{query\+\_\+initialized\+\_\+1d\+\_\+name}}
\index{query\+\_\+initialized\+\_\+1d\+\_\+name@{query\+\_\+initialized\+\_\+1d\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+1d\+\_\+name()}{query\_initialized\_1d\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+1d\+\_\+name (\begin{DoxyParamCaption}\item[{real, dimension(\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 710 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
710   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:)},  &
711                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
712   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
713   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
714   \textcolor{keywordtype}{logical} :: query\_initialized
715 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr or with the}
716 \textcolor{comment}{! specified variable name has been initialized from a restart file.}
717 
718   \textcolor{keywordtype}{integer} :: m,n
719   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
720       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
721   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
722 
723   query\_initialized = .false.
724   n = cs%novars+1
725   \textcolor{keywordflow}{do} m=1,cs%novars
726     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr1d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
727       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
728       n = m ; \textcolor{keywordflow}{exit}
729 \textcolor{keywordflow}{    endif}
730 \textcolor{keywordflow}{  enddo}
731 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
732 \textcolor{comment}{! queried again.}
733   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
734   \textcolor{keywordflow}{if} (n==cs%novars+1) \textcolor{keywordflow}{then}
735     \textcolor{keywordflow}{if} (is\_root\_pe()) &
736       \textcolor{keyword}{call }mom\_error(note,\textcolor{stringliteral}{"MOM\_restart: Unable to find "}//name//\textcolor{stringliteral}{" queried by pointer, "}//&
737         \textcolor{stringliteral}{"probably because of the suspect comparison of pointers by ASSOCIATED."})
738     query\_initialized = query\_initialized\_name(name, cs)
739 \textcolor{keywordflow}{  endif}
740 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a26a3f5be16287c44d1c6671d09b57146}\label{interfacemom__restart_1_1query__initialized_a26a3f5be16287c44d1c6671d09b57146}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+2d@{query\+\_\+initialized\+\_\+2d}}
\index{query\+\_\+initialized\+\_\+2d@{query\+\_\+initialized\+\_\+2d}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+2d()}{query\_initialized\_2d()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+2d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 590 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
590   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:)}, &
591                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
592   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
593   \textcolor{keywordtype}{logical} :: query\_initialized
594 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr has}
595 \textcolor{comment}{! been initialized from a restart file.}
596 
597   \textcolor{keywordtype}{integer} :: m,n
598   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
599       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
600   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
601 
602   query\_initialized = .false.
603   n = cs%novars+1
604   \textcolor{keywordflow}{do} m=1,cs%novars
605     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr2d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
606       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
607       n = m ; \textcolor{keywordflow}{exit}
608 \textcolor{keywordflow}{    endif}
609 \textcolor{keywordflow}{  enddo}
610 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
611 \textcolor{comment}{! queried again.}
612   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
613 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a16c24c5211593798974d8b031df3f09f}\label{interfacemom__restart_1_1query__initialized_a16c24c5211593798974d8b031df3f09f}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+2d\+\_\+name@{query\+\_\+initialized\+\_\+2d\+\_\+name}}
\index{query\+\_\+initialized\+\_\+2d\+\_\+name@{query\+\_\+initialized\+\_\+2d\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+2d\+\_\+name()}{query\_initialized\_2d\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+2d\+\_\+name (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 746 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
746   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:)},  &
747                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
748   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
749   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
750   \textcolor{keywordtype}{logical} :: query\_initialized
751 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr or with the}
752 \textcolor{comment}{! specified variable name has been initialized from a restart file.}
753 
754   \textcolor{keywordtype}{integer} :: m,n
755   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
756       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
757   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
758 
759   query\_initialized = .false.
760   n = cs%novars+1
761   \textcolor{keywordflow}{do} m=1,cs%novars
762     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr2d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
763       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
764       n = m ; \textcolor{keywordflow}{exit}
765 \textcolor{keywordflow}{    endif}
766 \textcolor{keywordflow}{  enddo}
767 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
768 \textcolor{comment}{! queried again.}
769   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
770   \textcolor{keywordflow}{if} (n==cs%novars+1) \textcolor{keywordflow}{then}
771     \textcolor{keywordflow}{if} (is\_root\_pe()) &
772       \textcolor{keyword}{call }mom\_error(note,\textcolor{stringliteral}{"MOM\_restart: Unable to find "}//name//\textcolor{stringliteral}{" queried by pointer, "}//&
773         \textcolor{stringliteral}{"probably because of the suspect comparison of pointers by ASSOCIATED."})
774     query\_initialized = query\_initialized\_name(name, cs)
775 \textcolor{keywordflow}{  endif}
776 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a279ceb2d87f86af8cfe05c3b31591f7e}\label{interfacemom__restart_1_1query__initialized_a279ceb2d87f86af8cfe05c3b31591f7e}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+3d@{query\+\_\+initialized\+\_\+3d}}
\index{query\+\_\+initialized\+\_\+3d@{query\+\_\+initialized\+\_\+3d}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+3d()}{query\_initialized\_3d()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+3d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 618 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
618   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:,:)}, &
619                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
620   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
621   \textcolor{keywordtype}{logical} :: query\_initialized
622 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr has}
623 \textcolor{comment}{! been initialized from a restart file.}
624 
625   \textcolor{keywordtype}{integer} :: m,n
626   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
627       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
628   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
629 
630   query\_initialized = .false.
631   n = cs%novars+1
632   \textcolor{keywordflow}{do} m=1,cs%novars
633     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr3d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
634       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
635       n = m ; \textcolor{keywordflow}{exit}
636 \textcolor{keywordflow}{    endif}
637 \textcolor{keywordflow}{  enddo}
638 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
639 \textcolor{comment}{! queried again.}
640   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
641 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a2a6459fa473dac0bcc1c021e617d1b12}\label{interfacemom__restart_1_1query__initialized_a2a6459fa473dac0bcc1c021e617d1b12}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+3d\+\_\+name@{query\+\_\+initialized\+\_\+3d\+\_\+name}}
\index{query\+\_\+initialized\+\_\+3d\+\_\+name@{query\+\_\+initialized\+\_\+3d\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+3d\+\_\+name()}{query\_initialized\_3d\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+3d\+\_\+name (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 782 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
782   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:,:)},  &
783                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
784   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
785   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
786   \textcolor{keywordtype}{logical} :: query\_initialized
787 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr or with the}
788 \textcolor{comment}{! specified variable name has been initialized from a restart file.}
789 
790   \textcolor{keywordtype}{integer} :: m, n
791   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
792       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
793   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
794 
795   query\_initialized = .false.
796   n = cs%novars+1
797   \textcolor{keywordflow}{do} m=1,cs%novars
798     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr3d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
799       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
800       n = m ; \textcolor{keywordflow}{exit}
801 \textcolor{keywordflow}{    endif}
802 \textcolor{keywordflow}{  enddo}
803 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
804 \textcolor{comment}{! queried again.}
805   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
806   \textcolor{keywordflow}{if} (n==cs%novars+1) \textcolor{keywordflow}{then}
807     \textcolor{keywordflow}{if} (is\_root\_pe()) &
808       \textcolor{keyword}{call }mom\_error(note, \textcolor{stringliteral}{"MOM\_restart: Unable to find "}//name//\textcolor{stringliteral}{" queried by pointer, "}//&
809         \textcolor{stringliteral}{"possibly because of the suspect comparison of pointers by ASSOCIATED."})
810     query\_initialized = query\_initialized\_name(name, cs)
811 \textcolor{keywordflow}{  endif}
812 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a8ac9fb65f1baf382c18cc83882c97aa6}\label{interfacemom__restart_1_1query__initialized_a8ac9fb65f1baf382c18cc83882c97aa6}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+4d@{query\+\_\+initialized\+\_\+4d}}
\index{query\+\_\+initialized\+\_\+4d@{query\+\_\+initialized\+\_\+4d}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+4d()}{query\_initialized\_4d()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+4d (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 646 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
646   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:,:,:)},  &
647                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
648   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
649   \textcolor{keywordtype}{logical} :: query\_initialized
650 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr has}
651 \textcolor{comment}{! been initialized from a restart file.}
652 
653   \textcolor{keywordtype}{integer} :: m,n
654   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
655       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
656   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
657 
658   query\_initialized = .false.
659   n = cs%novars+1
660   \textcolor{keywordflow}{do} m=1,cs%novars
661     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr4d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
662       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
663       n = m ; \textcolor{keywordflow}{exit}
664 \textcolor{keywordflow}{    endif}
665 \textcolor{keywordflow}{  enddo}
666 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
667 \textcolor{comment}{! queried again.}
668   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
669 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_a45b4e201527e3ce2d238e895d855878f}\label{interfacemom__restart_1_1query__initialized_a45b4e201527e3ce2d238e895d855878f}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+4d\+\_\+name@{query\+\_\+initialized\+\_\+4d\+\_\+name}}
\index{query\+\_\+initialized\+\_\+4d\+\_\+name@{query\+\_\+initialized\+\_\+4d\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+4d\+\_\+name()}{query\_initialized\_4d\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+4d\+\_\+name (\begin{DoxyParamCaption}\item[{real, dimension(\+:,\+:,\+:,\+:), intent(in), target}]{f\+\_\+ptr,  }\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



Indicate whether the field pointed to by f\+\_\+ptr or with the specified variable name has been initialized from a restart file. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em f\+\_\+ptr} & A pointer to the field that is being queried\\
\hline
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 818 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
818   \textcolor{keywordtype}{real}, \textcolor{keywordtype}{dimension(:,:,:,:)},  &
819                 \textcolor{keywordtype}{target}, \textcolor{keywordtype}{intent(in)} :: f\_ptr\textcolor{comment}{ !< A pointer to the field that is being queried}
820   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
821   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
822   \textcolor{keywordtype}{logical} :: query\_initialized
823 \textcolor{comment}{!   This subroutine tests whether the field pointed to by f\_ptr or with the}
824 \textcolor{comment}{! specified variable name has been initialized from a restart file.}
825 
826   \textcolor{keywordtype}{integer} :: m, n
827   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
828       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
829   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
830 
831   query\_initialized = .false.
832   n = cs%novars+1
833   \textcolor{keywordflow}{do} m=1,cs%novars
834     \textcolor{keywordflow}{if} (\textcolor{keyword}{associated}(cs%var\_ptr4d(m)%p,f\_ptr)) \textcolor{keywordflow}{then}
835       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
836       n = m ; \textcolor{keywordflow}{exit}
837 \textcolor{keywordflow}{    endif}
838 \textcolor{keywordflow}{  enddo}
839 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
840 \textcolor{comment}{! queried again.}
841   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
842   \textcolor{keywordflow}{if} (n==cs%novars+1) \textcolor{keywordflow}{then}
843     \textcolor{keywordflow}{if} (is\_root\_pe()) &
844       \textcolor{keyword}{call }mom\_error(note, \textcolor{stringliteral}{"MOM\_restart: Unable to find "}//name//\textcolor{stringliteral}{" queried by pointer, "}//&
845         \textcolor{stringliteral}{"possibly because of the suspect comparison of pointers by ASSOCIATED."})
846     query\_initialized = query\_initialized\_name(name, cs)
847 \textcolor{keywordflow}{  endif}
848 
\end{DoxyCode}
\mbox{\Hypertarget{interfacemom__restart_1_1query__initialized_aab7618a35470325d0e71f735062076df}\label{interfacemom__restart_1_1query__initialized_aab7618a35470325d0e71f735062076df}} 
\index{mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}!query\+\_\+initialized\+\_\+name@{query\+\_\+initialized\+\_\+name}}
\index{query\+\_\+initialized\+\_\+name@{query\+\_\+initialized\+\_\+name}!mom\+\_\+restart\+::query\+\_\+initialized@{mom\+\_\+restart\+::query\+\_\+initialized}}
\subsubsection{\texorpdfstring{query\+\_\+initialized\+\_\+name()}{query\_initialized\_name()}}
{\footnotesize\ttfamily logical function mom\+\_\+restart\+::query\+\_\+initialized\+::query\+\_\+initialized\+\_\+name (\begin{DoxyParamCaption}\item[{character(len=$\ast$), intent(in)}]{name,  }\item[{type(\hyperlink{structmom__restart_1_1mom__restart__cs}{mom\+\_\+restart\+\_\+cs}), pointer}]{CS }\end{DoxyParamCaption})\hspace{0.3cm}{\ttfamily [private]}}



query\+\_\+initialized\+\_\+name determines whether a named field has been successfully read from a restart file yet. 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em name} & The name of the field that is being queried\\
\hline
 & {\em cs} & A pointer to a M\+O\+M\+\_\+restart\+\_\+\+CS object (intent in) \\
\hline
\end{DoxyParams}


Definition at line 502 of file M\+O\+M\+\_\+restart.\+F90.


\begin{DoxyCode}
502   \textcolor{keywordtype}{character(len=*)},     \textcolor{keywordtype}{intent(in)} :: name\textcolor{comment}{ !< The name of the field that is being queried}
503   \textcolor{keywordtype}{type}(mom\_restart\_cs), \textcolor{keywordtype}{pointer}    :: cs\textcolor{comment}{ !< A pointer to a MOM\_restart\_CS object (intent in)}
504   \textcolor{keywordtype}{logical} :: query\_initialized
505 \textcolor{comment}{!   This subroutine returns .true. if the field referred to by name has}
506 \textcolor{comment}{! initialized from a restart file, and .false. otherwise.}
507 
508   \textcolor{keywordtype}{integer} :: m,n
509   \textcolor{keywordflow}{if} (.not.\textcolor{keyword}{associated}(cs)) \textcolor{keyword}{call }mom\_error(fatal, \textcolor{stringliteral}{"MOM\_restart "} // &
510       \textcolor{stringliteral}{"query\_initialized: Module must be initialized before it is used."})
511   \textcolor{keywordflow}{if} (cs%novars > cs%max\_fields) \textcolor{keyword}{call }restart\_error(cs)
512 
513   query\_initialized = .false.
514   n = cs%novars+1
515   \textcolor{keywordflow}{do} m=1,cs%novars
516     \textcolor{keywordflow}{if} (trim(name) == cs%restart\_field(m)%var\_name) \textcolor{keywordflow}{then}
517       \textcolor{keywordflow}{if} (cs%restart\_field(m)%initialized) query\_initialized = .true.
518       n = m ; \textcolor{keywordflow}{exit}
519 \textcolor{keywordflow}{    endif}
520 \textcolor{keywordflow}{  enddo}
521 \textcolor{comment}{! Assume that you are going to initialize it now, so set flag to initialized if}
522 \textcolor{comment}{! queried again.}
523   \textcolor{keywordflow}{if} (n<=cs%novars) cs%restart\_field(n)%initialized = .true.
524   \textcolor{keywordflow}{if} ((n==cs%novars+1) .and. (is\_root\_pe())) &
525     \textcolor{keyword}{call }mom\_error(note,\textcolor{stringliteral}{"MOM\_restart: Unknown restart variable "}//name// &
526                         \textcolor{stringliteral}{" queried for initialization."})
527 
528   \textcolor{keywordflow}{if} ((is\_root\_pe()) .and. query\_initialized) &
529     \textcolor{keyword}{call }mom\_error(note,\textcolor{stringliteral}{"MOM\_restart: "}//name// &
530                          \textcolor{stringliteral}{" initialization confirmed by name."})
531 
\end{DoxyCode}


The documentation for this interface was generated from the following file\+:\begin{DoxyCompactItemize}
\item 
/home/cermak/src/\+M\+O\+M6.\+devrob/src/framework/M\+O\+M\+\_\+restart.\+F90\end{DoxyCompactItemize}
