[Rcpp-commits] r2867 - in pkg/RcppBDT: . R man

noreply at r-forge.r-project.org noreply at r-forge.r-project.org
Thu Jan 13 22:57:34 CET 2011


Author: edd
Date: 2011-01-13 22:57:33 +0100 (Thu, 13 Jan 2011)
New Revision: 2867

Added:
   pkg/RcppBDT/R/methods.R
Modified:
   pkg/RcppBDT/ChangeLog
   pkg/RcppBDT/man/bdt.Rd
Log:
added print method


Modified: pkg/RcppBDT/ChangeLog
===================================================================
--- pkg/RcppBDT/ChangeLog	2011-01-13 19:25:08 UTC (rev 2866)
+++ pkg/RcppBDT/ChangeLog	2011-01-13 21:57:33 UTC (rev 2867)
@@ -1,3 +1,8 @@
+2011-01-13  Dirk Eddelbuettel  <edd at debian.org>
+
+	* R/methods.R: added a print method
+	* man/bdt.Rd: documented print method
+
 2011-01-12  Dirk Eddelbuettel  <edd at debian.org>
 
 	* R/zzz.R (.onLoad): import module, construct from class 'date'
@@ -39,7 +44,7 @@
 
 	* demo/RcppBDT.R: updated to keep in sync with other changes
 
-2011-01-06  Dirk Eddelbuettel  <edd at dexter>
+2011-01-06  Dirk Eddelbuettel  <edd at debian.org>
 
 	* inst/include/RcppBDT.h: Added paragraph about the UseWithString
 	variable with governs whether input/output functionality is loaded

Added: pkg/RcppBDT/R/methods.R
===================================================================
--- pkg/RcppBDT/R/methods.R	                        (rev 0)
+++ pkg/RcppBDT/R/methods.R	2011-01-13 21:57:33 UTC (rev 2867)
@@ -0,0 +1,23 @@
+##
+## bdt.R: Some accessor functions for Boost Date_Time functionality
+##
+## Copyright (C) 2010 - 2011 Dirk Eddelbuettel and Romain Francois
+##
+## This file is part of RcppBDT.
+##
+## RcppBDT is free software: you can redistribute it and/or modify it
+## under the terms of the GNU General Public License as published by
+## the Free Software Foundation, either version 2 of the License, or
+## (at your option) any later version.
+##
+## RcppBDT is distributed in the hope that it will be useful, but
+## WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+## GNU General Public License for more details.
+##
+## You should have received a copy of the GNU General Public License
+## along with RcppBDT.  If not, see <http://www.gnu.org/licenses/>.
+
+setMethod("print", "Rcpp_date", function(x, ...) print(x$getDate(), ...))
+
+


Property changes on: pkg/RcppBDT/R/methods.R
___________________________________________________________________
Added: svn:executable
   + *
Added: svn:eol-style
   + native

Modified: pkg/RcppBDT/man/bdt.Rd
===================================================================
--- pkg/RcppBDT/man/bdt.Rd	2011-01-13 19:25:08 UTC (rev 2866)
+++ pkg/RcppBDT/man/bdt.Rd	2011-01-13 21:57:33 UTC (rev 2867)
@@ -1,6 +1,7 @@
 \name{bdt}
 \alias{bdt}
 \alias{bdtMod}
+\alias{print,Rcpp_date-method}
 \docType{package}
 \title{Default object for RcppBDT Boost Date_Time binding}
 \description{
@@ -14,6 +15,12 @@
   New instances can be created using either the default constructor
   (without argument) or the constructor using year, month, date arguments.
 }
+\section{Method}{
+  \describe{
+    \item{print}{\code{signature(x = "Rcpp_date")}: print a (BDT) date
+      class object}
+  }
+}
 \details{
   Please consult the Boost documentation for (copious) details on the
   Date_Time library. See the Rcpp-modules vignette for details on Rcpp



More information about the Rcpp-commits mailing list