My Project
|
00001 /* Copyright (c) 2008, 2015, Oracle and/or its affiliates. All rights reserved. 00002 00003 This program is free software; you can redistribute it and/or modify 00004 it under the terms of the GNU General Public License as published by 00005 the Free Software Foundation; version 2 of the License. 00006 00007 This program is distributed in the hope that it will be useful, 00008 but WITHOUT ANY WARRANTY; without even the implied warranty of 00009 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00010 GNU General Public License for more details. 00011 00012 You should have received a copy of the GNU General Public License 00013 along with this program; if not, write to the Free Software Foundation, 00014 51 Franklin Street, Suite 500, Boston, MA 02110-1335 USA */ 00015 00016 #ifndef SQL_DIGEST_STREAM_H 00017 #define SQL_DIGEST_STREAM_H 00018 00019 #include "sql_digest.h" 00020 00026 struct sql_digest_state 00027 { 00034 int m_last_id_index; 00035 sql_digest_storage m_digest_storage; 00036 00037 inline void reset(unsigned char *token_array, uint length) 00038 { 00039 m_last_id_index= 0; 00040 m_digest_storage.reset(token_array, length); 00041 } 00042 00043 inline bool is_empty() 00044 { 00045 return m_digest_storage.is_empty(); 00046 } 00047 }; 00048 typedef struct sql_digest_state sql_digest_state; 00049 00050 #endif 00051