BString-class           package:Biostrings           R Documentation

_T_h_e _B_S_t_r_i_n_g _c_l_a_s_s

_D_e_s_c_r_i_p_t_i_o_n:

     The 'BString' class is a general container for storing a big
     string (a long sequence of characters) and to make its
     manipulation easy and efficient. The 'DNAString', 'RNAString' and
     'AAString' classes are direct 'BString' derivations with the more
     specific purpose of storing a DNA sequence ('DNAString'), a RNA
     sequence ('RNAString') or a sequence of amino acids ('AAString').

_D_e_t_a_i_l_s:

     The 2 main differences between a 'BString' object and a standard
     character vector are: (1) the data stored in a 'BString' object
     are not copied on object duplication and (2) a 'BString' can only
     store a single string (see the 'BStringViews' for an efficient way
     to store a collection of big strings in a single object). A
     'BString' object can be used to store any non-empty string based
     on a single-byte character set.

_A_c_c_e_s_o_r _m_e_t_h_o_d_s:

     In the code snippets below, 'x' is a 'BString' (or derived) object
     and 'i' is a numeric vector.

      'letter(x, i)': [TODO: Document me]

_C_o_n_s_t_r_u_c_t_o_r-_l_i_k_e _f_u_n_c_t_i_o_n_s _a_n_d _g_e_n_e_r_i_c_s:

     In the code snippet below, 'src' can be a character vector or a
     'BString' (or derived) object.

      'BString(src)': [TODO: Document me]

_S_t_a_n_d_a_r_d _g_e_n_e_r_i_c _m_e_t_h_o_d_s:

     In the code snippets below, 'x', 'object', 'e1' and 'e2' are
     'BString' (or derived) objects, and 'i' is a numeric vector.

      'length(x)' or 'nchar(x)': Used to get the length of a 'BString',
          i.e., its number of letters

      'x[i]': [TODO: Document me]

      'e1 == e2': [TODO: Document me]

      'e1 != e2': [TODO: Document me]

      'as.character(x)': [TODO: Document me]

      'toString(x)': [TODO: Document me]

_O_t_h_e_r _f_u_n_c_t_i_o_n_s _a_n_d _g_e_n_e_r_i_c_s:

     In the code snippets below, 'x' is a 'BString' (or derived) object
     and 'first' and 'last' are single numerics.

      'subBString(x, first, last)': [TODO: Document me]

_A_u_t_h_o_r(_s):

     H. Pages

_S_e_e _A_l_s_o:

     DNAString-class, RNAString-class, AAString-class
     BStringViews-class

_E_x_a_m_p_l_e_s:

       b <- BString("I am a BString object")
       length(b)

