else .as <- function(from) as(from, class)
getDefaultSlotValue <- function(classname, slotname, where=.GlobalEnv)
stop("prototype for class \"", classname, "\" ",
setDefaultSlotValue <- function(classname, slotname, value, where=.GlobalEnv)
setPrototypeFromObject <- function(classname, object, where=.GlobalEnv)
stop("'object' must be a ", classname, " instance")
ans_rownames <- .rownames2(names(x), lx, top_idx, bottom_idx)
.rownames2 <- function(names=NULL, len=NULL, tindex=NULL, bindex=NULL)
if (is.null(tindex) && is.null(bindex)) {
nelt_to_display0 <- min(length(x), (max.width+1L) %/% (elt_width0+1L))
head_ii0 <- seq_len(nelt_to_display0 %/% 2L)
tail_ii0 <- length(x) + head_ii0 - length(head_ii0)
nelt_to_display <- min(length(x), (max.width+1L) %/% (elt_width+1L))
head_ii <- seq_len((nelt_to_display+1L) %/% 2L)
tail_ii <- length(x) + seq_len(nelt_to_display %/% 2L) - nelt_to_display %/% 2L
ans <- paste(paste(ans_head, collapse=" "), "...", paste(ans_tail, collapse=" "))
if (nchar(ans) <= max.width || length(ans_head) == 0L)
if (nchar(ans) <= max.width || length(ans_tail) == 0L)
paste(paste(ans_head, collapse=" "), "...", paste(ans_tail, collapse=" "))

### The Vector virtual class is a general container for storing a finite
### sequence i.e. an ordered finite collection of elements.
### Need to be defined before the Vector class. See DataTable-API.R for the
### implementation of the DataTable API.
### 3 accessors for the same slot: elementMetadata(), mcols(), and values().
### mcols() is the recommended one, use of elementMetadata() or values() is
"replacement 'elementMetadata' value must be a DataTable object or NULL"
"the number of rows in elementMetadata 'value' "
"(if non-NULL) must match the length of 'x'"
"Some 'from' names in value not found on 'x': "
"'length(x)' must be a single non-negative integer"
"'names(x)' must be NULL or an unnamed character vector"
"when not NULL, 'names(x)' must have the length of 'x'"
"'mcols(x)' must be a DataTable object or NULL"
"number of rows in DataTable 'mcols(x)' "
## dynamically call [i,,,..,drop=FALSE] with as many "," as length(dim)-1
## Which one is faster, vector_seqselect or vector_subsetByRanges?
#ans <- .Call2("vector_subsetByRanges", x, start(i), width(i),
"extractROWS does not support objects of class "
### Works on any Vector object for which c() and [ work. Assumes 'value' is
## Assuming that objects of class 'class(x)' can be combined with c().
## Assuming that [ works on objects of class 'class(x)'.
### Simple helper functions for some common subsetting operations.
### FIXME: This method alters the semantic of stats::window() on ordinary
### vectors (the result has no 'tsp' attribute). Not really acceptable.
### FIXME: This method alters the semantic of stats::window() on factors
### (the result has no 'tsp' attribute). Not really acceptable.
### S3/S4 combo for as.data.frame.Vector
### FIXME: This method doesn't work properly on DataTable objects if 'after'
"'.index.var' must be a single, non-NA string"