Statistics
| Branch: | Revision:

iof-bird-daemon / nest / attrs.h @ 56a2bed4

History | View | Annotate | Download (961 Bytes)

1
/*
2
 *        BIRD Internet Routing Daemon -- Attribute Operations
3
 *
4
 *        (c) 2000 Martin Mares <mj@ucw.cz>
5
 *
6
 *        Can be freely distributed and used under the terms of the GNU GPL.
7
 */
8

    
9
#ifndef _BIRD_ATTRS_H_
10
#define _BIRD_ATTRS_H_
11

    
12
/* a-path.c */
13

    
14
#define AS_PATH_SET                1        /* Types of path segments */
15
#define AS_PATH_SEQUENCE        2
16

    
17
struct adata *as_path_prepend(struct linpool *pool, struct adata *olda, int as);
18
void as_path_format(struct adata *path, byte *buf, unsigned int size);
19
int as_path_getlen(struct adata *path);
20

    
21
struct f_path_mask {
22
  struct f_path_mask *next;
23
  int val;
24
};
25
#define PM_ANY -1
26

    
27
int as_path_match(struct adata *path, struct f_path_mask *mask);
28

    
29
/* a-set.c */
30

    
31
void int_set_format(struct adata *set, byte *buf, unsigned int size);
32
struct adata *int_set_add(struct linpool *pool, struct adata *list, u32 val);
33
int int_set_contains(struct adata *list, u32 val);
34
struct adata *int_set_del(struct linpool *pool, struct adata *list, u32 val);
35

    
36
#endif