// Import framework stuff
use Org\Mxchange\CoreFramework\Filesystem\CloseableFile;
use Org\Mxchange\CoreFramework\Filesystem\FilePointer;
+use Org\Mxchange\CoreFramework\Generic\FrameworkInterface;
use Org\Mxchange\CoreFramework\Generic\NullPointerException;
use Org\Mxchange\CoreFramework\Object\BaseFrameworkSystem;
throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
} elseif (!is_object($this->getFileObject())) {
// Pointer is not a valid resource!
- throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())));
+ throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Close the file pointer by NULL-ing it
use Org\Mxchange\CoreFramework\Filesystem\FileNotFoundException;
use Org\Mxchange\CoreFramework\Filesystem\FileReadProtectedException;
use Org\Mxchange\CoreFramework\Filesystem\Pointer\InputPointer;
+use Org\Mxchange\CoreFramework\Generic\FrameworkInterface;
use Org\Mxchange\CoreFramework\Generic\NullPointerException;
use Org\Mxchange\CoreFramework\Generic\UnsupportedOperationException;
use Org\Mxchange\CoreFramework\Object\BaseFrameworkSystem;
throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
} elseif (!is_object($this->getFileObject())) {
// Pointer is not a valid resource!
- throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())));
+ throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Read data from the file pointer and return it
use Org\Mxchange\CoreFramework\Filesystem\FileNotFoundException;
use Org\Mxchange\CoreFramework\Filesystem\FileReadProtectedException;
use Org\Mxchange\CoreFramework\Filesystem\Pointer\InputPointer;
+use Org\Mxchange\CoreFramework\Generic\FrameworkInterface;
use Org\Mxchange\CoreFramework\Generic\NullPointerException;
use Org\Mxchange\CoreFramework\Generic\UnsupportedOperationException;
use Org\Mxchange\CoreFramework\Object\BaseFrameworkSystem;
throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
} elseif (!is_object($this->getFileObject())) {
// Pointer is not a valid resource!
- throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())));
+ throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Is $bytes set?
throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
} elseif (!is_object($this->getFileObject())) {
// Pointer is not a valid resource!
- throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())));
+ throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Write data to the file pointer and return written bytes
throw new NullPointerException($this, self::EXCEPTION_IS_NULL_POINTER);
} elseif (!is_object($this->getFileObject())) {
// Pointer is not a valid object!
- throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())));
+ throw new LogicException(sprintf('this->fileObject[]=%s is no object', gettype($this->getFileObject())), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Write data to the file pointer and return written bytes
continue;
} elseif (!($entry instanceof Registerable)) {
// Not registerable?!
- throw new LogicException(sprintf('entry[]=%s does not implement Registerable.', gettype($entry)));
+ throw new LogicException(sprintf('entry[]=%s does not implement Registerable.', gettype($entry)), FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Is the current key set?
throw new InvalidArgumentException('Parameter "str" is empty', FrameworkInterface::EXCEPTION_INVALID_ARGUMENT);
} elseif (!extension_loaded('hash')) {
// Should be there
- throw new LogicException('Extension ext-hash not loaded');
+ throw new LogicException('Extension ext-hash not loaded', FrameworkInterface::EXCEPTION_LOGIC_EXCEPTION);
}
// Invoke static initializer
interface FrameworkInterface {
// Exception constants
const EXCEPTION_INVALID_ARGUMENT = 0x200;
+ const EXCEPTION_LOGIC_EXCEPTION = 0x201;
/**
* Getter for field name