📄 cpanplus::backend.3
字号:
.\" Automatically generated by Pod::Man 2.16 (Pod::Simple 3.05).\".\" Standard preamble:.\" ========================================================================.de Sh \" Subsection heading.br.if t .Sp.ne 5.PP\fB\\$1\fR.PP...de Sp \" Vertical space (when we can't use .PP).if t .sp .5v.if n .sp...de Vb \" Begin verbatim text.ft CW.nf.ne \\$1...de Ve \" End verbatim text.ft R.fi...\" Set up some character translations and predefined strings. \*(-- will.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left.\" double quote, and \*(R" will give a right double quote. \*(C+ will.\" give a nicer C++. Capital omega is used to do unbreakable dashes and.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,.\" nothing in troff, for use with C<>..tr \(*W-.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'.ie n \{\. ds -- \(*W-. ds PI pi. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch. ds L" "". ds R" "". ds C` "". ds C' ""'br\}.el\{\. ds -- \|\(em\|. ds PI \(*p. ds L" ``. ds R" '''br\}.\".\" Escape single quotes in literal strings from groff's Unicode transform..ie \n(.g .ds Aq \(aq.el .ds Aq '.\".\" If the F register is turned on, we'll generate index entries on stderr for.\" titles (.TH), headers (.SH), subsections (.Sh), items (.Ip), and index.\" entries marked with X<> in POD. Of course, you'll have to process the.\" output yourself in some meaningful fashion..ie \nF \{\. de IX. tm Index:\\$1\t\\n%\t"\\$2"... nr % 0. rr F.\}.el \{\. de IX...\}.\".\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2)..\" Fear. Run. Save yourself. No user-serviceable parts.. \" fudge factors for nroff and troff.if n \{\. ds #H 0. ds #V .8m. ds #F .3m. ds #[ \f1. ds #] \fP.\}.if t \{\. ds #H ((1u-(\\\\n(.fu%2u))*.13m). ds #V .6m. ds #F 0. ds #[ \&. ds #] \&.\}. \" simple accents for nroff and troff.if n \{\. ds ' \&. ds ` \&. ds ^ \&. ds , \&. ds ~ ~. ds /.\}.if t \{\. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u". ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'.\}. \" troff and (daisy-wheel) nroff accents.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'.ds 8 \h'\*(#H'\(*b\h'-\*(#H'.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#].ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#].ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#].ds ae a\h'-(\w'a'u*4/10)'e.ds Ae A\h'-(\w'A'u*4/10)'E. \" corrections for vroff.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'. \" for low resolution devices (crt and lpr).if \n(.H>23 .if \n(.V>19 \\{\. ds : e. ds 8 ss. ds o a. ds d- d\h'-1'\(ga. ds D- D\h'-1'\(hy. ds th \o'bp'. ds Th \o'LP'. ds ae ae. ds Ae AE.\}.rm #[ #] #H #V #F C.\" ========================================================================.\".IX Title "CPANPLUS::Backend 3".TH CPANPLUS::Backend 3 "2007-12-18" "perl v5.10.0" "Perl Programmers Reference Guide".\" For nroff, turn off justification. Always turn off hyphenation; it makes.\" way too many mistakes in technical documents..if n .ad l.nh.SH "NAME"CPANPLUS::Backend.SH "SYNOPSIS".IX Header "SYNOPSIS".Vb 2\& my $cb = CPANPLUS::Backend\->new;\& my $conf = $cb\->configure_object;\&\& my $author = $cb\->author_tree(\*(AqKANE\*(Aq);\& my $mod = $cb\->module_tree(\*(AqSome::Module\*(Aq);\& my $mod = $cb\->parse_module( module => \*(AqSome::Module\*(Aq );\&\& my @objs = $cb\->search( type => TYPE,\& allow => [...] );\&\& $cb\->flush(\*(Aqall\*(Aq);\& $cb\->reload_indices;\& $cb\->local_mirror;.Ve.SH "DESCRIPTION".IX Header "DESCRIPTION"This module provides the programmer's interface to the \f(CW\*(C`CPANPLUS\*(C'\fRlibraries..SH "ENVIRONMENT".IX Header "ENVIRONMENT"When \f(CW\*(C`CPANPLUS::Backend\*(C'\fR is loaded, which is necessary for justabout every <\s-1CPANPLUS\s0> operation, the environment variable\&\f(CW\*(C`PERL5_CPANPLUS_IS_RUNNING\*(C'\fR is set to the current process id..PPAdditionally, the environment variable \f(CW\*(C`PERL5_CPANPLUS_IS_VERSION\*(C'\fR will be set to the version of \f(CW\*(C`CPANPLUS::Backend\*(C'\fR..PPThis information might be useful somehow to spawned processes..SH "METHODS".IX Header "METHODS".ie n .Sh "$cb = CPANPLUS::Backend\->new( [\s-1CONFIGURE_OBJ\s0] )".el .Sh "\f(CW$cb\fP = CPANPLUS::Backend\->new( [\s-1CONFIGURE_OBJ\s0] )".IX Subsection "$cb = CPANPLUS::Backend->new( [CONFIGURE_OBJ] )"This method returns a new \f(CW\*(C`CPANPLUS::Backend\*(C'\fR object.This also initialises the config corresponding to this object.You have two choices in this:.ie n .IP "Provide a valid ""CPANPLUS::Configure"" object" 4.el .IP "Provide a valid \f(CWCPANPLUS::Configure\fR object" 4.IX Item "Provide a valid CPANPLUS::Configure object"This will be used verbatim..IP "No arguments" 4.IX Item "No arguments"Your default config will be loaded and used..PPNew will return a \f(CW\*(C`CPANPLUS::Backend\*(C'\fR object on success and die onfailure..ie n .Sh "$href\fP = \f(CW$cb\->module_tree( [@modules_names_list] )".el .Sh "\f(CW$href\fP = \f(CW$cb\fP\->module_tree( [@modules_names_list] )".IX Subsection "$href = $cb->module_tree( [@modules_names_list] )"Returns a reference to the \s-1CPANPLUS\s0 module tree..PPIf you give it any arguments, they will be treated as module namesand \f(CW\*(C`module_tree\*(C'\fR will try to look up these module names andreturn the corresponding module objects instead..PPSee CPANPLUS::Module for the operations you can perform on amodule object..ie n .Sh "$href\fP = \f(CW$cb\->author_tree( [@author_names_list] )".el .Sh "\f(CW$href\fP = \f(CW$cb\fP\->author_tree( [@author_names_list] )".IX Subsection "$href = $cb->author_tree( [@author_names_list] )"Returns a reference to the \s-1CPANPLUS\s0 author tree..PPIf you give it any arguments, they will be treated as author namesand \f(CW\*(C`author_tree\*(C'\fR will try to look up these author names andreturn the corresponding author objects instead..PPSee CPANPLUS::Module::Author for the operations you can perform onan author object..ie n .Sh "$conf\fP = \f(CW$cb\->configure_object;".el .Sh "\f(CW$conf\fP = \f(CW$cb\fP\->configure_object;".IX Subsection "$conf = $cb->configure_object;"Returns a copy of the \f(CW\*(C`CPANPLUS::Configure\*(C'\fR object..PPSee CPANPLUS::Configure for operations you can perform on aconfigure object..ie n .Sh "$su\fP = \f(CW$cb\->selfupdate_object;".el .Sh "\f(CW$su\fP = \f(CW$cb\fP\->selfupdate_object;".IX Subsection "$su = $cb->selfupdate_object;"Returns a copy of the \f(CW\*(C`CPANPLUS::Selfupdate\*(C'\fR object..PPSee the CPANPLUS::Selfupdate manpage for the operationsyou can perform on the selfupdate object..ie n .Sh "@mods\fP = \f(CW$cb\->search( type => \s-1TYPE\s0, allow => \s-1AREF\s0, [data => \s-1AREF\s0, verbose => \s-1BOOL\s0] )".el .Sh "\f(CW@mods\fP = \f(CW$cb\fP\->search( type => \s-1TYPE\s0, allow => \s-1AREF\s0, [data => \s-1AREF\s0, verbose => \s-1BOOL\s0] )".IX Subsection "@mods = $cb->search( type => TYPE, allow => AREF, [data => AREF, verbose => BOOL] )"\&\f(CW\*(C`search\*(C'\fR enables you to search for either module or author objects,based on their data. The \f(CW\*(C`type\*(C'\fR you can specify is any of theaccessors specified in \f(CW\*(C`CPANPLUS::Module::Author\*(C'\fR or\&\f(CW\*(C`CPANPLUS::Module\*(C'\fR. \f(CW\*(C`search\*(C'\fR will determine by the \f(CW\*(C`type\*(C'\fR youspecified whether to search by author object or module object..PPYou have to specify an array reference of regular expressions orstrings to match against. The rules used for this array ref are thesame as in \f(CW\*(C`Params::Check\*(C'\fR, so read that manpage for details..PPThe search is an \f(CW\*(C`or\*(C'\fR search, meaning that if \f(CW\*(C`any\*(C'\fR of the criteriamatch, the search is considered to be successful..PPYou can specify the result of a previous search as \f(CW\*(C`data\*(C'\fR to limitthe new search to these module or author objects, rather than theentire module or author tree. This is how you do \f(CW\*(C`and\*(C'\fR searches..PPReturns a list of module or author objects on success and falseon failure..PPSee CPANPLUS::Module for the operations you can perform on amodule object.See CPANPLUS::Module::Author for the operations you can perform onan author object..ie n .Sh "$backend_rv\fP = \f(CW$cb\->fetch( modules => \e@mods )".el .Sh "\f(CW$backend_rv\fP = \f(CW$cb\fP\->fetch( modules => \e@mods )".IX Subsection "$backend_rv = $cb->fetch( modules => @mods )"Fetches a list of modules. \f(CW@mods\fR can be a list of distributionnames, module names or module objects\*(--basically anything thatparse_module can understand..PPSee the equivalent method in \f(CW\*(C`CPANPLUS::Module\*(C'\fR for details onother options you can pass..PPSince this is a multi-module method call, the return value isimplemented as a \f(CW\*(C`CPANPLUS::Backend::RV\*(C'\fR object. Please consultthat module's documentation on how to interpret the return value..ie n .Sh "$backend_rv\fP = \f(CW$cb\->extract( modules => \e@mods )".el .Sh "\f(CW$backend_rv\fP = \f(CW$cb\fP\->extract( modules => \e@mods )".IX Subsection "$backend_rv = $cb->extract( modules => @mods )"Extracts a list of modules. \f(CW@mods\fR can be a list of distributionnames, module names or module objects\*(--basically anything thatparse_module can understand..PPSee the equivalent method in \f(CW\*(C`CPANPLUS::Module\*(C'\fR for details onother options you can pass..PPSince this is a multi-module method call, the return value isimplemented as a \f(CW\*(C`CPANPLUS::Backend::RV\*(C'\fR object. Please consultthat module's documentation on how to interpret the return value..ie n .Sh "$backend_rv\fP = \f(CW$cb\->install( modules => \e@mods )".el .Sh "\f(CW$backend_rv\fP = \f(CW$cb\fP\->install( modules => \e@mods )".IX Subsection "$backend_rv = $cb->install( modules => @mods )"Installs a list of modules. \f(CW@mods\fR can be a list of distributionnames, module names or module objects\*(--basically anything thatparse_module can understand..PPSee the equivalent method in \f(CW\*(C`CPANPLUS::Module\*(C'\fR for details onother options you can pass..PPSince this is a multi-module method call, the return value isimplemented as a \f(CW\*(C`CPANPLUS::Backend::RV\*(C'\fR object. Please consultthat module's documentation on how to interpret the return value.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -