structurevalue.h

Go to the documentation of this file.
00001 #ifndef _GSTREAMERMM_STRUCTUREVALUE_H
00002 #define _GSTREAMERMM_STRUCTUREVALUE_H
00003 // -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*-
00004 
00005 /* gstreamermm - a C++ wrapper for gstreamer
00006  *
00007  * Copyright 2008 The gstreamermm Development Team
00008  *
00009  * This library is free software; you can redistribute it and/or
00010  * modify it under the terms of the GNU Library General Public
00011  * License as published by the Free Software Foundation; either
00012  * version 2 of the License, or (at your option) any later version.
00013  *
00014  * This library is distributed in the hope that it will be useful,
00015  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00016  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00017  * Library General Public License for more details.
00018  *
00019  * You should have received a copy of the GNU Library General Public
00020  * License along with this library; if not, write to the Free
00021  * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00022  */
00023 
00024 
00025 #include <glib-object.h>
00026 #include <glibmm/value.h>
00027 
00028 namespace Gst
00029 {
00030 
00033 class StructureValueBase
00034 {
00035 public:
00036   GType type()  const { return type_;  }
00037 
00038 protected:
00039   explicit StructureValueBase(GType type);
00040 
00041 private:
00042   GType type_;
00043 };
00044 
00045 
00050 template <class T>
00051 class StructureValue : public StructureValueBase
00052 {
00053 public:
00054   typedef T               ElementType;
00055   typedef Glib::Value<T>  ValueType;
00056 
00057   StructureValue() : StructureValueBase(ValueType::value_type()) {}
00058 };
00059 
00060 } // namespace Gst
00061 
00062 
00063 #endif /* _GSTREAMERMM_STRUCTUREVALUE_H */
00064 

Generated on Sun Jul 27 17:07:20 2008 for gstreamermm by  doxygen 1.5.4