38 lines
810 B
C++
38 lines
810 B
C++
|
//
|
||
|
// php-armadillo/resizable_vector.hh
|
||
|
//
|
||
|
// @Author CismonX
|
||
|
//
|
||
|
|
||
|
#ifndef PHP_ARMA_RESIZABLE_VECTOR_HH
|
||
|
#define PHP_ARMA_RESIZABLE_VECTOR_HH
|
||
|
|
||
|
#include "common/php_arma.hh"
|
||
|
|
||
|
namespace php_arma
|
||
|
{
|
||
|
template <typename T, typename ChildT>
|
||
|
struct resizable_vector
|
||
|
{
|
||
|
using native_t = typename ChildT::native_t;
|
||
|
|
||
|
PHP_ARMA_COMMON_DECLARE();
|
||
|
|
||
|
private:
|
||
|
static PHP_FUNCTION(fromString);
|
||
|
static PHP_FUNCTION(fromArray);
|
||
|
static PHP_FUNCTION(resize);
|
||
|
static PHP_FUNCTION(setSize);
|
||
|
static PHP_FUNCTION(zeros);
|
||
|
static PHP_FUNCTION(inRange);
|
||
|
};
|
||
|
|
||
|
void resizable_vector_init();
|
||
|
|
||
|
constexpr const char resizable_vector_php_name[] = "ResizbaleVector";
|
||
|
|
||
|
inline zend_class_entry *resizable_vector_ce;
|
||
|
}
|
||
|
|
||
|
#endif // !PHP_ARMA_RESIZABLE_VECTOR
|