Ignore:
Timestamp:
2008-06-05T09:29:32+12:00 (16 years ago)
Author:
kjdon
Message:

plugin overhaul: plugins renamed to xxPlugin, and in some cases the names are made more sensible. They now use the new base plugins. Hopefully we have better code reuse. Some of the plugins still need work done as I didn't want to spend another month doing this before committing it. Alos, I haven't really tested anything yet...

File:
1 edited

Legend:

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

    r15865 r15872  
    2828# especially SRCPlug by John McPherson Nov 2000
    2929
    30 package FavouritesPlug;
     30package FavouritesPlugin;
    3131
    32 use BasPlug;
     32use ReadTextFile;
    3333use strict;
    3434no strict 'refs'; # allow filehandles to be variables and viceversa
    3535
    3636sub BEGIN {
    37     @FavouritesPlug::ISA = ('BasPlug');
     37    @FavouritesPlugin::ISA = ('ReadTextFile');
    3838}
    3939
    4040my $arguments =
    4141    [ { 'name' => "process_exp",
    42     'desc' => "{BasPlug.process_exp}",
     42    'desc' => "{ReadTextFile.process_exp}",
    4343    'type' => "regexp",
    4444    'deft' => &get_default_process_exp(),
    4545    'reqd' => "no" } ];
    4646
    47 my $options = { 'name'     => "FavouritesPlug",
    48         'desc'     => "FavouritesPlug imports Internet Explorer style Favourites. Favourites are often found in the \"C:\\Documents and Settings\\[your username]\\Favorites\" folder on your computer, but can also be made by dragging a bookmark or location from your browser (any) to the desktop.",
     47my $options = { 'name'     => "FavouritesPlugin",
     48        'desc'     => "{FavouritesPlugin.desc}",
    4949        'abstract' => "no",
    5050        'inherits' => "yes",
     
    5757    push(@$pluginlist, $class);
    5858
    59     if(defined $arguments){ push(@{$hashArgOptLists->{"ArgList"}},@{$arguments});}
    60     if(defined $options) { push(@{$hashArgOptLists->{"OptList"}},$options)};
     59    push(@{$hashArgOptLists->{"ArgList"}},@{$arguments});
     60    push(@{$hashArgOptLists->{"OptList"}},$options);
    6161
    62     my $self = new BasPlug($pluginlist, $inputargs, $hashArgOptLists);
     62    my $self = new ReadTextFile($pluginlist, $inputargs, $hashArgOptLists);
    6363
    6464    return bless $self, $class;
     
    8080
    8181    my $section = $doc_obj->get_top_section();
    82     print STDERR "<Processing n='$file' p='FavouritesPlug'>\n" if ($gli);
    83     print $outhandle "FavouritesPlug: processing $file\n" if $self->{'verbosity'} > 1;
     82    print STDERR "<Processing n='$file' p='FavouritesPlugin'>\n" if ($gli);
     83    print $outhandle "FavouritesPlugin: processing $file\n" if $self->{'verbosity'} > 1;
    8484
    8585    # don't want mg to turn escape chars into actual values
Note: See TracChangeset for help on using the changeset viewer.