47 lines
1.0 KiB
C++
47 lines
1.0 KiB
C++
//
|
|
// php-armadillo/subview_mat.hh
|
|
//
|
|
// @Author CismonX
|
|
//
|
|
|
|
#ifndef PHP_ARMA_SUBVIEW_MAT_HH
|
|
#define PHP_ARMA_SUBVIEW_MAT_HH
|
|
|
|
#include "common/php_arma.hh"
|
|
#include "common/instantiable.hh"
|
|
#include "complex.hh"
|
|
|
|
namespace php_arma
|
|
{
|
|
template <typename T> struct mat;
|
|
|
|
template <typename T>
|
|
struct subview_mat : instantiable<subview_mat<T>, true>
|
|
{
|
|
using native_t = arma::subview<T>;
|
|
using orig_t = mat<T>;
|
|
using subview_t = subview_mat<T>;
|
|
using with_int_elem_t = subview_mat<zend_long>;
|
|
using with_pod_elem_t = subview_mat<typename arma::get_pod_type<T>::result>;
|
|
|
|
friend void subview_mat_init();
|
|
|
|
PHP_ARMA_CE_HANDLRES_DECLARE();
|
|
|
|
private:
|
|
PHP_ARMA_COMMON_DECLARE();
|
|
|
|
static PHP_FUNCTION(toMat);
|
|
|
|
static void ce_init(zend_class_entry*);
|
|
};
|
|
|
|
void subview_mat_init();
|
|
|
|
constexpr const char subview_mat_php_name[] = "SvMat";
|
|
|
|
inline zend_class_entry *subview_mat_ce;
|
|
}
|
|
|
|
#endif // !PHP_ARMA_SUBVIEW_MAT_HH
|