.\" -*- mode: troff; coding: utf-8 -*- .\" Automatically generated by Pod::Man 5.01 (Pod::Simple 3.43) .\" .\" Standard preamble: .\" ======================================================================== .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 .. .\" \*(C` and \*(C' are quotes in nroff, nothing in troff, for use with C<>. .ie n \{\ . ds C` "" . ds C' "" 'br\} .el\{\ . ds C` . ds C' '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 >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "MetaCPAN::Client::File 3pm" .TH MetaCPAN::Client::File 3pm 2024-03-24 "perl v5.38.2" "User Contributed Perl Documentation" .\" 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 MetaCPAN::Client::File \- A File data object .SH VERSION .IX Header "VERSION" version 2.031001 .SH DESCRIPTION .IX Header "DESCRIPTION" A MetaCPAN file entity object. .SH ATTRIBUTES .IX Header "ATTRIBUTES" .SS status .IX Subsection "status" Returns a release status like \f(CW\*(C`backpan\*(C'\fR, \f(CW\*(C`cpan\*(C'\fR, or \f(CW\*(C`latest\*(C'\fR. .SS date .IX Subsection "date" An ISO8601 datetime string like \f(CW\*(C`2016\-11\-19T12:41:46\*(C'\fR indicating when the file was uploaded. .SS author .IX Subsection "author" The author's PAUSE id. .SS maturity .IX Subsection "maturity" This will be either \f(CW\*(C`release\*(C'\fR or \f(CW\*(C`developer\*(C'\fR. .SS directory .IX Subsection "directory" A boolean indicating whether or not the path represents a directory. .SS indexed .IX Subsection "indexed" A boolean indicating whether or not the content is indexed. .SS documentation .IX Subsection "documentation" The name of the module for which this file contains docs. This may be \f(CW\*(C`undef\*(C'\fR .SS id .IX Subsection "id" The file's internal MetaCPAN id. .SS authorized .IX Subsection "authorized" A boolean indicating whether or not this file was part of an authorized upload. .SS version .IX Subsection "version" The distribution version that contains this file. .SS version_numified .IX Subsection "version_numified" The numified version of the distribution that contains the file. .SS release .IX Subsection "release" The release that contains this file, which will be something like \&\f(CW\*(C`Moose\-2.2004\*(C'\fR. .SS binary .IX Subsection "binary" A boolean indicating whether or not this file contains binary content. .SS name .IX Subsection "name" The File's name, without any directory path included. .SS path .IX Subsection "path" The file's path \fIwithin the distribution archive\fR, relative to the root of the archive. .SS abstract .IX Subsection "abstract" If the file contains POD with a \f(CW\*(C`NAME\*(C'\fR section, then this attribute will include the abstract portion of the name. .SS deprecated .IX Subsection "deprecated" The deprecated field value for this file. .SS description .IX Subsection "description" If the file contains POD with a \f(CW\*(C`DESCRIPTION\*(C'\fR section, then this attribute will contain that description. .SS distribution .IX Subsection "distribution" The name of the distribution that contains the file. .SS level .IX Subsection "level" A 0\-indexed indication of how many directories deep this file is, relative to the archive root. .SS sloc .IX Subsection "sloc" If the file contains code, this will contain the number of lines of code in the file. .SS slop .IX Subsection "slop" If the file contains POD, this will contain the number of lines of POD in the file. .SS mime .IX Subsection "mime" The file's mime type. .SS module .IX Subsection "module" If the file contains module indexed by PAUSE, then this attribute contains an arrayref of hashrefs, one for each module. The hashrefs have the following keys: .IP \(bu 4 name .Sp The module name. .IP \(bu 4 indexed .Sp Whether or not the file is indexed by MetaCPAN. .IP \(bu 4 authorized .Sp Whether or not the module is part of an authorized upload. .IP \(bu 4 version .Sp The version of the module that this file contains. .IP \(bu 4 version_numified .Sp The numified version of the module that this file contains. .IP \(bu 4 associated_pod .Sp A path you can use with the \f(CW\*(C`MetaCPAN::Client\->file\*(C'\fR method to get the file that contains POD for this module. In most cases, that will be the same file as that one that contains this \f(CW\*(C`module\*(C'\fR data. .SS pod_lines .IX Subsection "pod_lines" An arrayref. .SS stat .IX Subsection "stat" A hashref containing \f(CWstat()\fR all information about the file. The keys are: .IP \(bu 4 mtime .Sp The Unix epoch of the file's last modified time. .IP \(bu 4 mode .Sp The file's mode (as an integer, not an octal representation). .IP \(bu 4 size .Sp The file's size in bytes. .SS download_url .IX Subsection "download_url" A URL for the distribution archive that contains this file. .SH METHODS .IX Header "METHODS" .SS pod .IX Subsection "pod" .Vb 2 \& my $pod = $module\->pod(); # default = plain \& my $pod = $module\->pod($type); .Ve .PP Returns the POD content for the module/file. .PP Takes a type as argument. .PP Supported types: \fBplain\fR, \fBhtml\fR, \fBx\-pod\fR, \fBx\-markdown\fR. .SS source .IX Subsection "source" .Vb 1 \& my $source = $module\->source(); .Ve .PP Returns the source code for the file. .SS metacpan_url .IX Subsection "metacpan_url" Returns a link to the file source page on MetaCPAN. .SH AUTHORS .IX Header "AUTHORS" .IP \(bu 4 Sawyer X .IP \(bu 4 Mickey Nasriachi .SH "COPYRIGHT AND LICENSE" .IX Header "COPYRIGHT AND LICENSE" This software is copyright (c) 2016 by Sawyer X. .PP This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.