Package                 package:R.oo                 R Documentation

_T_h_e _P_a_c_k_a_g_e _c_l_a_s_s _p_r_o_v_i_d_e_s _m_e_t_h_o_d_s _f_o_r _a_c_c_e_s_s_i_n_g _p_a_c_k_a_g_e _i_n_f_o_r_m_a_t_i_o_n

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

     Package:  R.oo 
      *Class Package*

     'Object'
      '~~|'
      '~~+--''Package'

     *Directly known subclasses:*


     public class *Package*
      extends Object

     Creates a Package that can be thrown and caught. The 'Package'
     class is the root class of all other 'Package' classes.

_U_s_a_g_e:

     Package(name=NULL)

_A_r_g_u_m_e_n_t_s:

    name: Name of the package.

_F_i_e_l_d_s _a_n_d _M_e_t_h_o_d_s:

     *Methods:*

         'as.character'         Gets a string representation of this package.
         'getAuthor'            Gets the Author of this package.
         'getBundle'            Gets the Bundle that this package might belong to.
         'getBundlePackages'    Gets the names of the other packages that is in the same bundle as this package.
         'getChangeLog'         Gets the change log of this package.
         'getClasses'           Gets all classes of a package.
         'getContents'          Gets the contents of this package.
         'getContribUrl'        Gets the URL(s) from where this package can be installed.
         'getDataPath'          Gets the path to the data (data/) directory of this package.
         'getDate'              Gets the date when package was build.
         'getDescription'       Gets the description of the package.
         'getDescriptionFile'   Gets the description file of this package.
         'getDevelUrl'          Gets the URL(s) from where the developers version of this package can be installed.
         'getDocPath'           Gets the path to the accompanying documentation (doc/) directory of this package.
         'getEnvironment'       Gets the environment of a loaded package.
         'getExamplePath'       Gets the path to the example (R-ex/) directory of this package.
         'getHistory'           -
         'getHowToCite'         Gets the howToCite of this package.
         'getLicense'           Gets the License of this package.
         'getMaintainer'        Gets the Maintainer of this package.
         'getName'              Gets the name of this package.
         'getPath'              Gets the library (system) path to this package.
         'getPosition'          Gets the search path position of the package.
         'getTitle'             Gets the Title of this package.
         'getUrl'               Gets the URL of this package.
         'getVersion'           Gets the version of this package.
         'isLoaded'             Checks if the package is installed on the search path or not.
         'll'                   Generates a list of informative properties of all members of the package.
         'load'                 Loads a package.
         'showChangeLog'        Show the change log of this package.
         'showContents'         Show the CONTENTS file of this package.
         'showDescriptionFile'  Show the DESCRIPTION file of this package.
         'showHistory'          -
         'showHowToCite'        Show the HOWTOCITE file of this package.
         'unload'               Unloads a package.
         'update'               Updates the package is a newer version is available.

     *Methods inherited from Object*:
      $, $<-, [[, [[<-, as.character, attach, attachLocally,
     clearCache, clone, detach, equals, extend, finalize, gc,
     getEnvironment, getFields, getInstanciationTime,
     getStaticInstance, hasField, hashCode, ll, load, objectSize,
     print, save

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

     Henrik Bengtsson (<URL: http://www.braju.com/R/>)

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

     ## Not run: # By defining .First.lib() as follows in zzz.R for a package, an
     # instance of class Package with the same name as the package will
     # be made available on the search path. More over, the code below
     # will also inform the user that the package has been loaded:
     #
     #  > library(R.oo)
     #  R.oo v0.52 (2003/04/13) was successfully loaded.
     #
     .First.lib <- function(libname, pkgname) {
       pkg <- Package(pkgname);
       assign(pkgname, pkg, pos=getPosition(pkg));
       cat(getName(pkg), " v", getVersion(pkg), " (", getDate(pkg), ")",
         " was successfully loaded.\n", sep="");
     }

     # The Package class works for any packages, loaded or not.

     # Some information about the base package
     pkg <- Package("base")
     print(pkg)
     # [1] "Package: base v1.6.2 (NA) is loaded (pos=5). The official webpage
     #      is NA and the maintainer is R Core Team <R-core@r-project.org>. The
     #      package is installed in c:/PROGRA~1/R/rw1062/library/base/."
     print(list.files(Package("base")$dataPath))

     # Some information about the R.oo package
     print(R.oo)
     # [1] "Package: R.oo v0.52 (2003/04/13) is loaded (pos=2). The official
     #      webpage is http://www.braju.com/R/ and the maintainer is Henrik
     #      Bengtsson <henrikb@braju.com>. The package is installed in
     #      c:/PROGRA~1/R/rw1062/library/R.oo/."

     # To check for updates and update a package, just do
     update(R.oo)

     ## End(Not run)

