CR2RE Pipeline Reference Manual 1.6.7
irplib_framelist.h
1/* $Id: irplib_framelist.h,v 1.8 2008-11-20 10:24:47 llundin Exp $
2 *
3 * This file is part of the irplib package
4 * Copyright (C) 2002,2003 European Southern Observatory
5 *
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02111-1307 USA
19 */
20
21/*
22 * $Author: llundin $
23 * $Date: 2008-11-20 10:24:47 $
24 * $Revision: 1.8 $
25 * $Name: not supported by cvs2svn $
26 */
27
28#ifndef IRPLIB_FRAMELIST_H
29#define IRPLIB_FRAMELIST_H
30
31/*-----------------------------------------------------------------------------
32 Includes
33 -----------------------------------------------------------------------------*/
34
35#include <cpl.h>
36
37/*-----------------------------------------------------------------------------
38 New type
39 -----------------------------------------------------------------------------*/
40
41typedef struct _irplib_framelist_ irplib_framelist;
42
43/*-----------------------------------------------------------------------------
44 Function prototypes
45 -----------------------------------------------------------------------------*/
46
47/* Constructors and destructor */
48
49irplib_framelist * irplib_framelist_new(void);
50
51void irplib_framelist_delete(irplib_framelist *);
52
53irplib_framelist * irplib_framelist_cast(const cpl_frameset *);
54
55irplib_framelist * irplib_framelist_extract(const irplib_framelist *,
56 const char *);
57irplib_framelist * irplib_framelist_extract_regexp(const irplib_framelist *,
58 const char *, cpl_boolean);
59
60/* Accessors and element modifiers */
61
62int irplib_framelist_get_size(const irplib_framelist *);
63
64const cpl_frame * irplib_framelist_get_const(const irplib_framelist *, int);
65
66cpl_frame * irplib_framelist_get(irplib_framelist *, int);
67
68const cpl_propertylist * irplib_framelist_get_propertylist_const(
69 const irplib_framelist *,
70 int);
71
72cpl_propertylist * irplib_framelist_get_propertylist(irplib_framelist *, int);
73
74cpl_error_code irplib_framelist_set_propertylist(irplib_framelist *, int,
75 const cpl_propertylist *);
76
77cpl_error_code irplib_framelist_load_propertylist(irplib_framelist *, int,
78 int, const char *,
79 cpl_boolean);
80
81cpl_error_code irplib_framelist_load_propertylist_all(irplib_framelist *, int,
82 const char *,
83 cpl_boolean);
84
85cpl_error_code irplib_framelist_set_tag_all(irplib_framelist *, const char *);
86
87
88/* Inserting and removing elements */
89
90cpl_error_code irplib_framelist_set(irplib_framelist *, cpl_frame *, int);
91
92cpl_error_code irplib_framelist_erase(irplib_framelist *, int);
93
94cpl_frame * irplib_framelist_unset(irplib_framelist *, int, cpl_propertylist **);
95
96void irplib_framelist_empty(irplib_framelist *);
97
98/* Others */
99cpl_error_code irplib_framelist_contains(const irplib_framelist *, const char *,
100 cpl_type, cpl_boolean, double);
101
102cpl_imagelist * irplib_imagelist_load_framelist(const irplib_framelist *,
103 cpl_type, int, int);
104
105cpl_frameset * irplib_frameset_cast(const irplib_framelist *);
106
107#endif
int irplib_framelist_get_size(const irplib_framelist *)
Get the size of a framelist.
cpl_frame * irplib_framelist_unset(irplib_framelist *, int, cpl_propertylist **)
Erase a frame from a framelist and return it to the caller.
cpl_error_code irplib_framelist_set(irplib_framelist *, cpl_frame *, int)
Add a frame to a framelist.
cpl_frameset * irplib_frameset_cast(const irplib_framelist *)
Create a CPL frameset from an irplib_framelist.
irplib_framelist * irplib_framelist_extract(const irplib_framelist *, const char *)
Extract the frames with the given tag from a framelist.
irplib_framelist * irplib_framelist_extract_regexp(const irplib_framelist *, const char *, cpl_boolean)
Extract the frames with the given tag from a framelist.
cpl_error_code irplib_framelist_load_propertylist(irplib_framelist *, int, int, const char *, cpl_boolean)
Load the propertylist of the specified frame in the framelist.
cpl_frame * irplib_framelist_get(irplib_framelist *, int)
Get the specified frame from the framelist.
irplib_framelist * irplib_framelist_cast(const cpl_frameset *)
Create an irplib_framelist from a cpl_framelist.
void irplib_framelist_delete(irplib_framelist *)
Deallocate an irplib_framelist with its frames and properties.
void irplib_framelist_empty(irplib_framelist *)
Erase all frames from a framelist.
cpl_error_code irplib_framelist_set_tag_all(irplib_framelist *, const char *)
Set the tag of all frames in the list.
cpl_error_code irplib_framelist_erase(irplib_framelist *, int)
Erase a frame from a framelist and delete it and its propertylist.
cpl_error_code irplib_framelist_set_propertylist(irplib_framelist *, int, const cpl_propertylist *)
Duplicate a propertylist to the specified position in the framelist.
cpl_propertylist * irplib_framelist_get_propertylist(irplib_framelist *, int)
Get the propertylist of the specified frame in the framelist.
irplib_framelist * irplib_framelist_new(void)
Create an empty framelist.
const cpl_propertylist * irplib_framelist_get_propertylist_const(const irplib_framelist *, int)
Get the propertylist of the specified frame in the framelist.
const cpl_frame * irplib_framelist_get_const(const irplib_framelist *, int)
Get the specified frame from the framelist.
cpl_error_code irplib_framelist_load_propertylist_all(irplib_framelist *, int, const char *, cpl_boolean)
Load the propertylists of all frames in the framelist.
cpl_imagelist * irplib_imagelist_load_framelist(const irplib_framelist *, cpl_type, int, int)
Load an imagelist from a framelist.
cpl_error_code irplib_framelist_contains(const irplib_framelist *, const char *, cpl_type, cpl_boolean, double)
Verify that a property is present for all frames.