22#ifndef Rcpp__newDateVector_h
23#define Rcpp__newDateVector_h
35 template <
int RTYPE,
bool NA,
typename VEC>
44 size_t n = this->
size();
45 std::vector<Date> v(n);
46 for (
size_t i=0; i<n; i++)
65 Rf_setAttrib(*
this, R_ClassSymbol, dateclass);
71 for (
size_t i=0; i<n; i++) {
73 if ((i+1) % 8 == 0) os <<
"\n";
std::string format(const char *fmt="%Y-%m-%d") const
Vector & operator=(const Vector &rhs)
newDateVector(const VectorBase< RTYPE, NA, VEC > &vec)
newDateVector & operator=(const newDateVector &rhs)
std::vector< Date > getDates() const
friend std::ostream & operator<<(std::ostream &s, const newDateVector d)
Vector< REALSXP > NumericVector
std::ostream & operator<<(std::ostream &os, const Date d)