Skip to content

Commit

Permalink
doco
Browse files Browse the repository at this point in the history
  • Loading branch information
plicease committed Mar 18, 2015
1 parent 9408154 commit b32332e
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 4 deletions.
11 changes: 9 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,12 @@ This module also provides a direct interface to the `ftpparse` function as well.

# FUNCTIONS

## parse\_dir( $listing, \[ $time\_zone, \[ $type, \[ $error \] \] \] )
## parse\_dir

my $dir = parse_dir( $listing );
my $dir = parse_dir( $listing, $time_zone );
my $dir = parse_dir( $listing, $time_zone, $type );
my $dir = parse_dir( $listing, $time_zone, $type, $error);

The first argument ($listing) is the directory listing to parse.
It can be a scalar, a reference to an array of directory lines or a
Expand Down Expand Up @@ -104,7 +109,9 @@ so this is always undef.
Any field which could not be determined by the algorithm will be
`undef`.

## ftpparse( $line )
## ftpparse

my $hash = ftpparse( $line );

Parse a single line from an FTP listing. Returns a hash ref of
information about the file found in that line, or undef if no
Expand Down
11 changes: 9 additions & 2 deletions lib/File/Listing/Ftpcopy.pm
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,12 @@ This module also provides a direct interface to the C<ftpparse> function as well
=head1 FUNCTIONS
=head2 parse_dir( $listing, [ $time_zone, [ $type, [ $error ] ] ] )
=head2 parse_dir
my $dir = parse_dir( $listing );
my $dir = parse_dir( $listing, $time_zone );
my $dir = parse_dir( $listing, $time_zone, $type );
my $dir = parse_dir( $listing, $time_zone, $type, $error);
The first argument ($listing) is the directory listing to parse.
It can be a scalar, a reference to an array of directory lines or a
Expand Down Expand Up @@ -216,7 +221,9 @@ sub parse_dir ($;$$$)
return wantarray ? @answer : \@answer;
}

=head2 ftpparse( $line )
=head2 ftpparse
my $hash = ftpparse( $line );
Parse a single line from an FTP listing. Returns a hash ref of
information about the file found in that line, or undef if no
Expand Down

0 comments on commit b32332e

Please sign in to comment.