00001 /* -*- Mode: C; indent-tabs-mode: t; c-basic-offset: 4; tab-width: 4 -*- */ 00026 /* 00027 * frpuniverse 00028 * Copyright (C) Peter L. Berghold 2008 <Peter@Berghold.net> 00029 * 00030 * frpuniverse is free software. 00031 * 00032 * You may redistribute it and/or modify it under the terms of the 00033 * GNU General Public License, as published by the Free Software 00034 * Foundation; either version 2 of the License, or (at your option) 00035 * any later version. 00036 * 00037 * frpuniverse is distributed in the hope that it will be useful, 00038 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00039 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 00040 * See the GNU General Public License for more details. 00041 * 00042 * You should have received a copy of the GNU General Public License 00043 * along with frpuniverse. If not, write to: 00044 * The Free Software Foundation, Inc., 00045 * 51 Franklin Street, Fifth Floor 00046 * Boston, MA 02110-1301, USA. 00047 */ 00048 00049 #ifndef _SPARSE_ARRAY_NODE_HPP_ 00050 #define _SPARSE_ARRAY_NODE_HPP_ 00051 00058 class sparseArrayNode 00059 { 00060 public: 00061 00066 sparseArrayNode(); 00067 00068 /* 00069 * A simple parametized constructor. 00070 * 00071 * @param row integer value for the row 00072 * @param column integer value for the column 00073 */ 00074 sparseArrayNode(int row,int column); 00075 00082 sparseArrayNode* getRight(); 00083 00090 void setRight(sparseArrayNode*); 00091 00098 sparseArrayNode* getDown(); 00099 00105 void setDown(sparseArrayNode*); 00106 00113 int getColumn(); 00114 00120 void setColumn(int); 00121 00127 int getRow(); 00128 00135 void setRow(int); 00136 00137 protected: 00138 00139 private: 00140 int row; 00141 int column; 00142 00143 sparseArrayNode* right; 00144 sparseArrayNode* down; 00145 00146 }; 00147 00148 #endif // _SPARSE_ARRAY_NODE_HPP_