if ((a_size + (a)) >= a_maxSize) extend ((a));
DataBlock::DataBlock(const char* buffer, const int size, const bool deepCopy)
-throw(RuntimeException) :
+noexcept(false) :
a_buffer(NULL),
a_size(0),
a_deepCopy(deepCopy),
}
DataBlock::DataBlock(const DataBlock& other)
-throw(RuntimeException) :
+noexcept(false) :
a_buffer(NULL),
a_size(0),
a_deepCopy(other.a_deepCopy),
}
void DataBlock::initialize(const char* buffer, const int size)
-throw(RuntimeException) {
+noexcept(false) {
if(a_deepCopy == false) {
a_buffer = const_cast <char*>(buffer);
a_size = size;
}
void DataBlock::setSize(const int size)
-throw(RuntimeException) {
+noexcept(false) {
// if (size > a_maxSize) {
// string msg ("DataBlock::setSize | MaxSize: ");
// msg += functions::asString (a_maxSize);
}
void DataBlock::allocate(const int nbytes)
-throw(RuntimeException) {
+noexcept(false) {
if(nbytes > a_size) {
if(a_maxSize == 0) {
if(a_deepCopy == false)
}
void DataBlock::assign(const char* buffer, const int size)
-throw(RuntimeException) {
+noexcept(false) {
if(a_deepCopy == false) {
a_buffer = const_cast <char*>(buffer);
a_size = size;
}
DataBlock& DataBlock::operator = (const DataBlock & right)
-throw(RuntimeException) {
+noexcept(false) {
if(this != &right) {
if(a_deepCopy) {
a_size = 0;
}
const char DataBlock::operator [](const int pos) const
-throw(RuntimeException) {
+noexcept(false) {
if(pos >= a_size) {
std::string msg("Position: ");
msg += functions::asString(pos);
}
char& DataBlock::operator [](const int pos)
-throw(RuntimeException) {
+noexcept(false) {
if(pos >= a_size) {
std::string msg("Position: ");
msg += functions::asString(pos);
}
void DataBlock::append(const char* data, const int len)
-throw(RuntimeException) {
+noexcept(false) {
if(a_buffer == data && data != NULL && len > 0)
throw RuntimeException("Can not append myself", ANNA_FILE_LOCATION);
}
void DataBlock::remove(const int pos, const int nbytes)
-throw(RuntimeException) {
+noexcept(false) {
if(a_deepCopy == false)
throw RuntimeException("Deep copy not activated", ANNA_FILE_LOCATION);
}
void DataBlock::remove(const int nbytes)
-throw(RuntimeException) {
+noexcept(false) {
if(a_deepCopy == false)
throw RuntimeException("Deep copy not activated", ANNA_FILE_LOCATION);
}
void DataBlock::extend(const int nbytes)
-throw(RuntimeException) {
+noexcept(false) {
if(a_deepCopy == false)
throw RuntimeException("Deep copy not activated", ANNA_FILE_LOCATION);
}
std::string DataBlock::asString(const int characterByLine) const
-throw() {
+{
char aux [16];
std::string numbers;
std::string characters;