File indexing completed on 2025-01-05 03:59:00
0001 // SPDX-License-Identifier: LGPL-2.1-or-later 0002 // 0003 // SPDX-FileCopyrightText: 2011 Niko Sams <niko.sams@gmail.com> 0004 // 0005 0006 #ifndef MARBLE_GEODATASIMPLEARRAYDATA_H 0007 #define MARBLE_GEODATASIMPLEARRAYDATA_H 0008 0009 #include "GeoDataObject.h" 0010 0011 class QVariant; 0012 0013 namespace Marble { 0014 0015 class GeoDataSimpleArrayDataPrivate; 0016 0017 /** 0018 */ 0019 class DIGIKAM_EXPORT GeoDataSimpleArrayData : public GeoDataObject 0020 { 0021 0022 public: 0023 GeoDataSimpleArrayData(); 0024 GeoDataSimpleArrayData( const GeoDataSimpleArrayData& other ); 0025 bool operator==( const GeoDataSimpleArrayData &other ) const; 0026 bool operator!=( const GeoDataSimpleArrayData &other) const; 0027 ~GeoDataSimpleArrayData() override; 0028 0029 /** 0030 * Returns the number of value in the array 0031 */ 0032 int size() const; 0033 0034 /** 0035 * Returns the value at index @p index 0036 */ 0037 QVariant valueAt( int index ) const; 0038 0039 /** 0040 * Returns all values in the array 0041 */ 0042 QList< QVariant > valuesList() const; 0043 0044 /** 0045 * Append a value to the array 0046 */ 0047 void append( const QVariant& value ); 0048 0049 const char* nodeType() const override; 0050 void pack( QDataStream& stream ) const override; 0051 void unpack( QDataStream& stream ) override; 0052 0053 private: 0054 GeoDataSimpleArrayDataPrivate *d; 0055 }; 0056 0057 } 0058 0059 #endif // MARBLE_GEODATASIMPLEARRAYDATA_H