4
* Copyright (C) 2000, 2001, 2002 I�aki Garc�a Etxebarria
5
* Copyright (C) 2000, 2001, 2002, 2003, 2004 Michael H. Schimek
7
* This program is free software; you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation; either version 2 of the License, or
10
* (at your option) any later version.
12
* This program is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
17
* You should have received a copy of the GNU General Public License
18
* along with this program; if not, write to the Free Software
19
* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
22
/* $Id: page_num.h,v 1.1 2004/11/03 06:46:08 mschimek Exp $ */
28
#include "libvbi/bcd.h" /* vbi3_pgno, vbi3_subno */
29
#include "libvbi/network.h" /* vbi3_network */
38
network_set (vbi3_network * dst,
39
const vbi3_network * src)
43
success = vbi3_network_set (dst, src);
48
page_num_equal (const page_num * ad1,
51
return (vbi3_network_equal (&ad1->network, &ad2->network)
52
&& ad1->pgno == ad2->pgno
53
&& (ad1->subno == ad2->subno
54
|| VBI3_ANY_SUBNO == ad1->subno
55
|| VBI3_ANY_SUBNO == ad2->subno));
59
page_num_equal2 (const page_num * ad1,
60
const vbi3_network * nk2,
64
return (vbi3_network_equal (&ad1->network, nk2)
66
&& (ad1->subno == subno2
67
|| VBI3_ANY_SUBNO == ad1->subno
68
|| VBI3_ANY_SUBNO == subno2));
72
page_num_destroy (page_num * pn)
74
vbi3_network_destroy (&pn->network);
78
page_num_set (page_num * pn,
79
const vbi3_network * nk,
83
network_set (&pn->network, nk);
88
#endif /* PAGE_NUM_H */