You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

43 lines
1.2 KiB
C

/* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 2; tab-width: 2 -*- */
/*
* cas.c
* Copyright (C) 2015 Alexander Vdolainen <avdolainen@zoho.com>
*
* libtdata is free software: you can redistribute it and/or modify it
* under the terms of the GNU Lesser General Public License as published
* by the Free Software Foundation, either version 2.1 of the License, or
* (at your option) any later version.
*
* libtdata is distributed in the hope that it will be useful, but
* WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
* See the GNU Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.";
*/
#ifndef __TDATA_CTRIE_H__
#define __TDATA_CTRIE_H__
#include "../config.h"
/* flags */
#define CTRIE_FLAG_RO (1 << 1)
/* structure Ctrie (flags is also underlying node type) */
typedef struct __ctrie_type {
int flags;
void **root;
}__attribute__((packed)) ctrie_t;
/* structure SNode (key-value node) */
typedef struct __ctrie_snode {
ct_key_t key;
void *value;
}__attribute__((packed)) ct_snode_t;
#endif /* __TDATA_CTRIE_H__ */