coin-Cgl
CglLandPTabRow.hpp
Go to the documentation of this file.
1 // Copyright (C) 2005-2008, Pierre Bonami and others. All Rights Reserved.
2 // Author: Pierre Bonami
3 // LIF
4 // CNRS, Aix-Marseille Universites
5 // Date: 02/23/08
6 //---------------------------------------------------------------------------
7 
8 #ifndef CglLandPTabRow_H
9 #define CglLandPTabRow_H
10 
11 #include "CoinIndexedVector.hpp"
12 #include <iostream>
13 
14 namespace LAP{
15 class CglLandPSimplex;
16 struct TabRow: public CoinIndexedVector {
18  int num;
20  double rhs;
23 
24 
25  TabRow(const CglLandPSimplex *si):
26  CoinIndexedVector(), num(-1), rhs(0), si_(si) {}
27  TabRow(const TabRow & source):CoinIndexedVector(source),
28  num(source.num), rhs(source.rhs) {
29  }
30  ~TabRow() {
31  }
32 
33  void print(std::ostream & os, int width = 9, const int * nonBasics = NULL,
34  int m = 0);
35  inline
36  const double& operator[](const int &index) const {
37  return denseVector()[index];
38  }
39 
40  inline
41  double& operator[](const int &index) {
42  return denseVector()[index];
43  }
44 };
45 }/* Ends LAP Namespace.*/
46 
47 #endif
48