Skip to content
Snippets Groups Projects
Commit 406f2d11 authored by Karsten Rink's avatar Karsten Rink
Browse files

added missing files

parent 27ea6bab
No related branches found
No related tags found
No related merge requests found
/**
* Copyright (c) 2012, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*
* \file ElementStatus.cpp
*
* Created on 2012-12-18 by Karsten Rink
*/
#include "ElementStatus.h"
namespace MeshLib {
ElementStatus::ElementStatus(Mesh const*const mesh)
: _mesh(mesh), _status(mesh->getNElements(), true)
{
}
}
/**
* Copyright (c) 2012, OpenGeoSys Community (http://www.opengeosys.org)
* Distributed under a Modified BSD License.
* See accompanying file LICENSE.txt or
* http://www.opengeosys.org/project/license
*
*
* \file ElementStatus.h
*
* Created on 2012-12-18 by Karsten Rink
*/
#ifndef ELEMENTSTATUS_H_
#define ELEMENTSTATUS_H_
#include "Mesh.h"
namespace MeshLib {
/**
* An object to store which elements of the mesh are active and which are inactive
*/
class ElementStatus
{
public:
/// Constructor using mesh
ElementStatus(Mesh const*const mesh);
bool getElementStatus(unsigned i) { return _status[i]; };
bool isActive(unsigned i) { return _status[i]; };
void setActive(unsigned i) { _status[i] = true; };
void setInactive(unsigned i) { _status[i] = false; };
void setElementStatus(unsigned i, bool status) { _status[i] = status; };
~ElementStatus() {};
protected:
Mesh const*const _mesh;
std::vector<bool> _status;
}; /* class */
} /* namespace */
#endif /* ELEMENTSTATUS_H_ */
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment