+class WXDLLEXPORT wxItemContainerImmutable
+{
+public:
+ wxItemContainerImmutable() { }
+ virtual ~wxItemContainerImmutable();
+
+ // accessing strings
+ // -----------------
+
+ virtual int GetCount() const = 0;
+ bool IsEmpty() const { return GetCount() == 0; }
+
+ virtual wxString GetString(int n) const = 0;
+ wxArrayString GetStrings() const;
+ virtual void SetString(int n, const wxString& s) = 0;
+ virtual int FindString(const wxString& s) const = 0;
+
+
+ // selection
+ // ---------
+
+ virtual void SetSelection(int n) = 0;
+ virtual int GetSelection() const = 0;
+
+ // set selection to the specified string, return false if not found
+ bool SetStringSelection(const wxString& s);
+
+ // return the selected string or empty string if none
+ wxString GetStringSelection() const;
+
+ // this is the same as SetSelection( for single-selection controls but
+ // reads better for multi-selection ones
+ void Select(int n) { SetSelection(n); }
+
+
+protected:
+
+ // check that the index is valid
+ inline bool IsValid(int n) const { return n >= 0 && n < GetCount(); }
+};
+
+class WXDLLEXPORT wxItemContainer : public wxItemContainerImmutable