Ignore:
Timestamp:
2002-11-18T17:43:56+13:00 (21 years ago)
Author:
kjdon
Message:

added John T's changes into CVS - added info to enable retrieval of usage info in xml

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/gsdl/perllib/plugins/BibTexPlug.pm

    r3426 r3540  
    5151}
    5252
     53my $arguments =
     54[ {     'name' => "process_exp",
     55    'desc' => "A perl regular expression to match against filenames. Matching filenames will be processed by this plugin. Each plugin has its own default process_exp. e.g HTMLPlug defaults to '(?i)\.html?\$' i.e. all documents ending in .htm or .html (case-insensitive).",
     56    'type' => "string",
     57    'reqd' => "no" ,
     58    'deft' => q^(?i)\.bib$^ }
     59];
     60
     61my $options =
     62{   'name'     => "BibTexPlug",
     63    'desc'     => "BibTexPlug reads bibliography files in BibTex format. BibTexPlug creates a document object for every reference a the file. It is a subclass of SplitPlug, so if there are multiple records, all are read.",
     64    'inherits' => "Yes",
     65    'args'     => $arguments };
     66
    5367# This plugin processes files with the suffix ".bib"
    5468sub get_default_process_exp {
     
    5973sub get_default_split_exp {
    6074    return q^\n+(?=@)^;
     75}
     76sub new {
     77    my $class = shift (@_);
     78    my $self = new SplitPlug ($class, @_);
     79    # 14-05-02 To allow for proper inheritance of arguments - John Thompson
     80    my $option_list = $self->{'option_list'};
     81    push( @{$option_list}, $options );
     82    return bless $self, $class;
    6183}
    6284
     
    368390 
    369391   $text =~ s/([\w\d\.\-]+@[\w\d\.\-]+)/<a href=\"mailto:$1\">$1<\/a>/g;
    370    $text =~ s/(http:\/\/[\w\d\.\-]+[\/\w\d\.\-]*)/<a href=\"$1">$1<\/a>/g;
     392   $text =~ s/(http:\/\/[\w\d\.\-]+[\/\w\d\.\-]*)/<a href=\"$1\">$1<\/a>/g;
    371393
    372394   return $text;
Note: See TracChangeset for help on using the changeset viewer.