Dip
0.92.4
Main Page
Related Pages
Modules
Namespaces
Classes
Files
File List
File Members
tmp
Dip-0.92.4
Dip
src
old
DecompMemPool.h
Go to the documentation of this file.
1
//===========================================================================//
2
// This file is part of the Decomp Solver Framework. //
3
// //
4
// Decomp is distributed under the Common Public License as part of the //
5
// COIN-OR repository (http://www.coin-or.org). //
6
// //
7
// Author: Matthew Galati, Lehigh University //
8
// //
9
// Copyright (C) 2002-2007, Lehigh University, Matthew Galati, and Ted Ralphs//
10
// All Rights Reserved. //
11
//===========================================================================//
12
13
#ifndef DECOMP_MEMPOOL_INCLUDED
14
#define DECOMP_MEMPOOL_INCLUDED
15
16
#include "
CoinError.hpp
"
17
18
// --------------------------------------------------------------------- //
19
class
DecompMemPool
{
20
public
:
21
double
*
dblArrNCoreCols
;
22
double
*
dblArrNCoreRows
;
23
24
public
:
25
void
allocateMemory
(
const
int
nCoreCols,
26
const
int
nCoreRows)
throw
(
CoinError
) {
27
if
(nCoreCols > 0) {
28
dblArrNCoreCols
=
new
double
[nCoreCols];
29
CoinAssertHint
(
dblArrNCoreCols
,
"Error: Out of Memory"
);
30
}
31
32
if
(nCoreRows > 0) {
33
dblArrNCoreRows
=
new
double
[nCoreRows];
34
CoinAssertHint
(
dblArrNCoreRows
,
"Error: Out of Memory"
);
35
}
36
}
37
38
public
:
39
DecompMemPool
() :
40
dblArrNCoreCols
(0),
41
dblArrNCoreRows
(0) {
42
}
43
~DecompMemPool
() {
44
UTIL_DELARR
(
dblArrNCoreCols
);
45
UTIL_DELARR
(
dblArrNCoreRows
);
46
}
47
};
48
49
#endif
CoinError.hpp
DecompMemPool
Definition:
DecompMemPool.h:22
UTIL_DELARR
#define UTIL_DELARR(x)
Definition:
UtilMacros.h:29
CoinAssertHint
#define CoinAssertHint(expression, hint)
Definition:
CoinError.hpp:184
DecompMemPool::allocateMemory
void allocateMemory(const int nCoreCols, const int nCoreRows)
Definition:
DecompMemPool.h:25
DecompMemPool::DecompMemPool
DecompMemPool()
Definition:
DecompMemPool.h:39
DecompMemPool::dblArrNCoreRows
double * dblArrNCoreRows
Definition:
DecompMemPool.h:25
CoinError
Error Class thrown by an exception.
Definition:
CoinError.hpp:42
DecompMemPool::~DecompMemPool
~DecompMemPool()
Definition:
DecompMemPool.h:43
DecompMemPool::dblArrNCoreCols
double * dblArrNCoreCols
Definition:
DecompMemPool.h:24
Generated by
1.8.5