Commit ca052786 authored by Emmanuel Christophe's avatar Emmanuel Christophe
Browse files

BUG: full-fledged itk::LightObject for keywordlist classes (wrapping requirements)

parent c1a349bc
......@@ -19,9 +19,8 @@
#define __otbImageKeywordlist_h
#include <iostream>
#include <map>
#include "itkObject.h"
#include "itkLightObject.h"
#include "itkObjectFactory.h"
#include "base/ossimString.h"
......@@ -41,20 +40,22 @@ namespace otb
* \ingroup Projections
*
*/
class ITK_EXPORT ImageKeywordlist
class ITK_EXPORT ImageKeywordlist : public itk::LightObject
{
public:
/** Standard class typedefs. */
typedef ImageKeywordlist Self;
typedef ImageKeywordlist Self;
typedef itk::LightObject Superclass;
typedef itk::SmartPointer<Self> Pointer;
typedef itk::SmartPointer<const Self> ConstPointer;
//virtual const char *GetNameOfClass() const
//{return "ImageKeywordlist";}
/** Creation through the object factory */
itkNewMacro(Self);
/** Standard type macros */
itkTypeMacro(ImageKeywordlist, itk::LightObject);
typedef std::map<ossimString, ossimString> KeywordlistMap;
/** Run-time type information (and related methods). */
itkTypeMacro(ImageKeywordlist, ImageKeywordlist);
/** Get the internal map container */
const KeywordlistMap& GetKeywordlist() const
{
......
......@@ -38,18 +38,23 @@ namespace otb
*
*/
class VectorDataKeywordlist
class VectorDataKeywordlist : public itk::LightObject
{
public:
/** Smart pointer typedef support. */
typedef VectorDataKeywordlist Self;
typedef VectorDataKeywordlist Self;
typedef itk::LightObject Superclass;
typedef itk::SmartPointer<Self> Pointer;
typedef itk::SmartPointer<const Self> ConstPointer;
/** Creation through the object factory */
itkNewMacro(Self);
/** Standard type macros */
itkTypeMacro(VectorDataKeywordlist, itk::LightObject);
typedef std::pair<OGRFieldDefn*, OGRField> FieldType;
typedef std::vector<FieldType> FieldListType;
virtual const char *GetNameOfClass() const
{return "VectorDataKeywordlist"; }
void AddField(OGRFieldDefn* fieldDefn, OGRField* field);
/**
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment