1/*****************************************************************************
2
3Copyright (C) 2013, 2017, MariaDB Corporation. All Rights Reserved.
4
5This program is free software; you can redistribute it and/or modify it under
6the terms of the GNU General Public License as published by the Free Software
7Foundation; version 2 of the License.
8
9This program is distributed in the hope that it will be useful, but WITHOUT
10ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12
13You should have received a copy of the GNU General Public License along with
14this program; if not, write to the Free Software Foundation, Inc.,
1551 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
16
17*****************************************************************************/
18
19/******************************************************************//**
20@file include/dict0pagecompress.h
21Helper functions for extracting/storing page compression information
22to dictionary.
23
24Created 11/12/2013 Jan Lindström jan.lindstrom@skysql.com
25***********************************************************************/
26
27#ifndef dict0pagecompress_h
28#define dict0pagecompress_h
29
30/********************************************************************//**
31Extract the page compression level from table flags.
32@return page compression level, or 0 if not compressed */
33UNIV_INLINE
34ulint
35dict_tf_get_page_compression_level(
36/*===============================*/
37 ulint flags) /*!< in: flags */
38 __attribute__((const));
39/********************************************************************//**
40Extract the page compression flag from table flags
41@return page compression flag, or false if not compressed */
42UNIV_INLINE
43ibool
44dict_tf_get_page_compression(
45/*==========================*/
46 ulint flags) /*!< in: flags */
47 __attribute__((const));
48
49/********************************************************************//**
50Check whether the table uses the page compressed page format.
51@return page compression level, or 0 if not compressed */
52UNIV_INLINE
53ulint
54dict_table_page_compression_level(
55/*==============================*/
56 const dict_table_t* table) /*!< in: table */
57 __attribute__((const));
58
59#include "dict0pagecompress.ic"
60
61#endif
62