\hypertarget{utility_8h}{\section{meowpp/utility.h File Reference}
\label{utility_8h}\index{meowpp/utility.\-h@{meowpp/utility.\-h}}
}
{\ttfamily \#include $<$cstdlib$>$}\\*
{\ttfamily \#include $<$cstring$>$}\\*
{\ttfamily \#include $<$cstdio$>$}\\*
{\ttfamily \#include $<$cstdarg$>$}\\*
{\ttfamily \#include $<$string$>$}\\*
\subsection*{Namespaces}
\begin{DoxyCompactItemize}
\item 
namespace \hyperlink{namespacemeow}{meow}
\end{DoxyCompactItemize}
\subsection*{Macros}
\begin{DoxyCompactItemize}
\item 
\#define \hyperlink{utility_8h_a7b550f1ff25a89286527a460c390a902}{debug\-Printf}(str)
\begin{DoxyCompactList}\small\item\em 若\-D\-E\-B\-U\-G有被define過, 將字串印到stderr, 並且附上檔名行號與所在函數名 \end{DoxyCompactList}\end{DoxyCompactItemize}
\subsection*{Functions}
\begin{DoxyCompactItemize}
\item 
std\-::string \hyperlink{namespacemeow_a09946550cc38b132151643d3408b0175}{meow\-::string\-Printf} (char const $\ast$fmt,...)
\begin{DoxyCompactList}\small\item\em 類似\-C的printf, 不過是將格式化的字串丟到 {\ttfamily std\-::string} 裡回傳 \end{DoxyCompactList}\item 
std\-::string \hyperlink{namespacemeow_a532a4a224ccd34baa4c6317a8a014ba4}{meow\-::string\-Replace} (std\-::string str, std\-::string const \&from, std\-::string const \&to)
\begin{DoxyCompactList}\small\item\em 將輸入字串中的某個pattern取代成另一個pattern \end{DoxyCompactList}\item 
bool \hyperlink{namespacemeow_a375bf0494e671d61343f5be28f3204fb}{meow\-::cstring\-End\-With} (char const $\ast$str, \hyperlink{classint}{int} n,...)
\begin{DoxyCompactList}\small\item\em 檢查給定字串的結尾是否符合給定的數個patterns中的一個 \end{DoxyCompactList}\item 
void \hyperlink{namespacemeow_a644a491d867da42696e3cf226019fc25}{meow\-::debug\-Printf\-\_\-} (char const $\ast$file, char const $\ast$func, size\-\_\-t line, char const $\ast$msg)
\item 
void \hyperlink{namespacemeow_a9aad86d9211af4ca27b72f87c2643926}{meow\-::message\-Printf} (\hyperlink{classint}{int} level\-\_\-change, char const $\ast$fmt,...)
\begin{DoxyCompactList}\small\item\em 階層式輸出 \end{DoxyCompactList}\item 
bool \hyperlink{namespacemeow_a575ff1d89bedceb3f850e0c6b7ab2396}{meow\-::filename\-Compare} (std\-::string const \&f1, std\-::string const \&f2)
\begin{DoxyCompactList}\small\item\em 將兩個字串用人類習慣的檔名排序方式排序 \end{DoxyCompactList}\end{DoxyCompactItemize}


\subsection{Macro Definition Documentation}
\hypertarget{utility_8h_a7b550f1ff25a89286527a460c390a902}{\index{utility.\-h@{utility.\-h}!debug\-Printf@{debug\-Printf}}
\index{debug\-Printf@{debug\-Printf}!utility.h@{utility.\-h}}
\subsubsection[{debug\-Printf}]{\setlength{\rightskip}{0pt plus 5cm}\#define debug\-Printf(
\begin{DoxyParamCaption}
\item[{}]{str}
\end{DoxyParamCaption}
)}}\label{utility_8h_a7b550f1ff25a89286527a460c390a902}
{\bfseries Value\-:}
\begin{DoxyCode}
\hyperlink{namespacemeow_a644a491d867da42696e3cf226019fc25}{debugPrintf\_}(\(\backslash\)
             \_\_FILE\_\_,\(\backslash\)
             \_\_FUNCTION\_\_,\(\backslash\)
             \_\_LINE\_\_,\(\backslash\)
             str)
\end{DoxyCode}


若\-D\-E\-B\-U\-G有被define過, 將字串印到stderr, 並且附上檔名行號與所在函數名 


\begin{DoxyParams}[1]{Parameters}
\mbox{\tt in}  & {\em str} & 要輸出的字串, 必須是c string, 即 {\ttfamily char} {\ttfamily const$\ast$} 型態 \\
\hline
\end{DoxyParams}
\begin{DoxyReturn}{Returns}
無 
\end{DoxyReturn}
\begin{DoxyNote}{Note}
這是一個 {\bfseries macro} 
\end{DoxyNote}
