FEI Version of the Day
Loading...
Searching...
No Matches
fei_DirichletBCRecord.hpp
1#ifndef _fei_DirichletBCRecord_hpp_
2#define _fei_DirichletBCRecord_hpp_
3
4/*--------------------------------------------------------------------*/
5/* Copyright 2005 Sandia Corporation. */
6/* Under the terms of Contract DE-AC04-94AL85000, there is a */
7/* non-exclusive license for use of this work by or on behalf */
8/* of the U.S. Government. Export of this program may require */
9/* a license from the United States Government. */
10/*--------------------------------------------------------------------*/
11
12#include <fei_macros.hpp>
13
14namespace fei {
15
16struct DirichletBCRecord {
17 int IDType;
18 int ID;
19 int fieldID;
20 int whichComponent;
21 double prescribedValue;
22
23 bool operator!=(const DirichletBCRecord& rhs) const
24 {
25 return IDType != rhs.IDType || ID != rhs.ID ||
26 fieldID != rhs.fieldID || whichComponent != rhs.whichComponent;
27 }
28};
29
30class less_DirichletBCRecord {
31 public:
32 less_DirichletBCRecord(){}
33 ~less_DirichletBCRecord(){}
34
35 bool operator()(const DirichletBCRecord& lhs,
36 const DirichletBCRecord& rhs)
37 {
38 if (lhs.IDType < rhs.IDType) return true;
39 if (lhs.IDType > rhs.IDType) return false;
40
41 if (lhs.ID < rhs.ID) return true;
42 if (lhs.ID > rhs.ID) return false;
43
44 if (lhs.fieldID < rhs.fieldID) return true;
45 if (lhs.fieldID > rhs.fieldID) return false;
46
47 if (lhs.whichComponent < rhs.whichComponent) return true;
48 if (lhs.whichComponent > rhs.whichComponent) return false;
49
50 return false;
51 }
52};
53
54}//namespace fei
55
56#endif
57