2 * mlt_properties.h -- base properties class
3 * Copyright (C) 2003-2004 Ushodaya Enterprises Limited
4 * Author: Charles Yates <charles.yates@pandora.be>
5 * Contributor: Dan Dennedy <dan@dennedy.org>
7 * This library is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU Lesser General Public
9 * License as published by the Free Software Foundation; either
10 * version 2.1 of the License, or (at your option) any later version.
12 * This library 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 GNU
15 * Lesser General Public License for more details.
17 * You should have received a copy of the GNU Lesser General Public
18 * License along with this library; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 #ifndef _MLT_PROPERTIES_H_
23 #define _MLT_PROPERTIES_H_
25 #include "mlt_types.h"
26 #include "mlt_events.h"
29 /** The properties base class defines the basic property propagation and
33 struct mlt_properties_s
44 extern int mlt_properties_init( mlt_properties
, void *child
);
45 extern mlt_properties
mlt_properties_new( );
46 extern mlt_properties
mlt_properties_load( const char *file
);
47 extern int mlt_properties_inc_ref( mlt_properties self
);
48 extern int mlt_properties_dec_ref( mlt_properties self
);
49 extern int mlt_properties_ref_count( mlt_properties self
);
50 extern void mlt_properties_mirror( mlt_properties self
, mlt_properties that
);
51 extern int mlt_properties_inherit( mlt_properties self
, mlt_properties that
);
52 extern int mlt_properties_pass( mlt_properties self
, mlt_properties that
, const char *prefix
);
53 extern void mlt_properties_pass_property( mlt_properties self
, mlt_properties that
, const char *name
);
54 extern int mlt_properties_pass_list( mlt_properties self
, mlt_properties that
, const char *list
);
55 extern int mlt_properties_set( mlt_properties self
, const char *name
, const char *value
);
56 extern int mlt_properties_set_or_default( mlt_properties self
, const char *name
, const char *value
, const char *def
);
57 extern int mlt_properties_parse( mlt_properties self
, const char *namevalue
);
58 extern char *mlt_properties_get( mlt_properties self
, const char *name
);
59 extern char *mlt_properties_get_name( mlt_properties self
, int index
);
60 extern char *mlt_properties_get_value( mlt_properties self
, int index
);
61 extern void *mlt_properties_get_data_at( mlt_properties self
, int index
, int *size
);
62 extern int mlt_properties_get_int( mlt_properties self
, const char *name
);
63 extern int mlt_properties_set_int( mlt_properties self
, const char *name
, int value
);
64 extern int64_t mlt_properties_get_int64( mlt_properties self
, const char *name
);
65 extern int mlt_properties_set_int64( mlt_properties self
, const char *name
, int64_t value
);
66 extern double mlt_properties_get_double( mlt_properties self
, const char *name
);
67 extern int mlt_properties_set_double( mlt_properties self
, const char *name
, double value
);
68 extern mlt_position
mlt_properties_get_position( mlt_properties self
, const char *name
);
69 extern int mlt_properties_set_position( mlt_properties self
, const char *name
, mlt_position value
);
70 extern int mlt_properties_set_data( mlt_properties self
, const char *name
, void *value
, int length
, mlt_destructor
, mlt_serialiser
);
71 extern void *mlt_properties_get_data( mlt_properties self
, const char *name
, int *length
);
72 extern int mlt_properties_rename( mlt_properties self
, const char *source
, const char *dest
);
73 extern int mlt_properties_count( mlt_properties self
);
74 extern void mlt_properties_dump( mlt_properties self
, FILE *output
);
75 extern void mlt_properties_debug( mlt_properties self
, const char *title
, FILE *output
);
76 extern int mlt_properties_save( mlt_properties
, const char * );
77 extern int mlt_properties_dir_list( mlt_properties
, const char *, const char *, int );
78 extern void mlt_properties_close( mlt_properties self
);
79 extern int mlt_properties_is_sequence( mlt_properties self
);
80 extern mlt_properties
mlt_properties_parse_yaml( const char *file
);
81 extern char *mlt_properties_serialise_yaml( mlt_properties self
);