Back to index

salome-kernel  6.5.0
SALOMEDS_AttributeTableOfString.hxx
Go to the documentation of this file.
00001 // Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 //  File   : SALOMEDS_AttributeTableOfString.hxx
00024 //  Author : Sergey RUIN
00025 //  Module : SALOME
00026 //
00027 #ifndef SALOMEDS_AttributeTableOfString_HeaderFile
00028 #define SALOMEDS_AttributeTableOfString_HeaderFile
00029 
00030 #include "SALOMEDSClient_AttributeTableOfString.hxx"
00031 #include "SALOMEDS_GenericAttribute.hxx"
00032 #include "SALOMEDSImpl_AttributeTableOfString.hxx"
00033 
00034 // IDL headers
00035 #include <SALOMEconfig.h>
00036 #include CORBA_SERVER_HEADER(SALOMEDS)
00037 #include CORBA_SERVER_HEADER(SALOMEDS_Attributes)
00038 
00039 #include <vector>
00040 
00041 class SALOMEDS_AttributeTableOfString: public SALOMEDS_GenericAttribute, public SALOMEDSClient_AttributeTableOfString
00042 {
00043 public:  
00044   SALOMEDS_AttributeTableOfString(SALOMEDSImpl_AttributeTableOfString* theAttr);
00045   SALOMEDS_AttributeTableOfString(SALOMEDS::AttributeTableOfString_ptr theAttr);
00046   ~SALOMEDS_AttributeTableOfString();
00047 
00048   virtual void SetTitle(const std::string& theTitle);
00049   virtual std::string GetTitle();
00050   virtual void SetRowTitle(int theIndex, const std::string& theTitle);
00051   virtual std::string GetRowTitle(int theIndex);
00052   virtual void SetRowTitles(const std::vector<std::string>& theTitles);
00053   virtual std::vector<std::string> GetRowTitles();
00054   virtual void SetColumnTitle(int theIndex, const std::string& theTitle);
00055   virtual std::string GetColumnTitle(int theIndex);
00056   virtual void SetColumnTitles(const std::vector<std::string>& theTitles);
00057   virtual std::vector<std::string> GetColumnTitles();
00058 
00059   virtual void SetRowUnit(int theIndex, const std::string& theUnit);
00060   virtual std::string GetRowUnit(int theIndex);
00061   virtual void SetRowUnits(const std::vector<std::string>& theUnits);
00062   virtual std::vector<std::string> GetRowUnits();
00063 
00064   virtual int GetNbRows();
00065   virtual int GetNbColumns();
00066   virtual void AddRow(const std::vector<std::string>& theData);
00067   virtual void SetRow(int theRow, const std::vector<std::string>& theData);
00068   virtual std::vector<std::string> GetRow(int theRow);
00069   virtual void AddColumn(const std::vector<std::string>& theData);
00070   virtual void SetColumn(int theColumn, const std::vector<std::string>& theData);
00071   virtual std::vector<std::string> GetColumn(int theColumn);
00072   virtual void PutValue(const std::string& theValue, int theRow, int theColumn);
00073   virtual bool HasValue(int theRow, int theColumn);
00074   virtual std::string GetValue(int theRow, int theColumn);
00075   virtual void RemoveValue(int theRow, int theColumn);
00076 
00077   virtual std::vector<int> GetRowSetIndices(int theRow);
00078   virtual void SetNbColumns(int theNbColumns);    
00079 
00080   virtual std::vector<int> SortRow(int theRow, SortOrder theOrder, SortPolicy thePolicy);
00081   virtual std::vector<int> SortColumn(int theColumn, SortOrder theOrder, SortPolicy thePolicy);
00082   virtual std::vector<int> SortByRow(int theRow, SortOrder theOrder, SortPolicy thePolicy);
00083   virtual std::vector<int> SortByColumn(int theColumn, SortOrder theOrder, SortPolicy thePolicy);
00084   virtual void SwapCells(int theRow1, int theColumn1, int theRow2, int theColumn2);
00085   virtual void SwapRows(int theRow1, int theRow2);
00086   virtual void SwapColumns(int theColumn1, int theColumn2);
00087 };
00088 
00089 #endif