Changeset 269


Ignore:
Timestamp:
May 14, 2006, 11:15:08 AM (14 years ago)
Author:
Dominic Hargreaves
Message:

Some renames.

Location:
wiki-toolkit-plugin-locator-grid/trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • wiki-toolkit-plugin-locator-grid/trunk/Changes

    r156 r269  
     10.04    14 May 2006
     2        Rename to Wiki::Toolkit::Plugin::Locator::Grid
     3
    140.03    5 January 2005
    25        Fix to tests so they don't die when no backends are configured
  • wiki-toolkit-plugin-locator-grid/trunk/Makefile.PL

    r149 r269  
    11use ExtUtils::MakeMaker;
    22
    3 WriteMakefile( NAME         => "CGI::Wiki::Plugin::Locator::Grid",
     3WriteMakefile( NAME         => "Wiki::Toolkit::Plugin::Locator::Grid",
    44               VERSION_FROM => "lib/CGI/Wiki/Plugin/Locator/Grid.pm",
    5                PREREQ_PM    => { 'CGI::Wiki' => 0.36, # for Plugin base class
     5               PREREQ_PM    => { 'Wiki::Toolkit' => 0,
    66                                 'Test::More' => 0,
    77                                 'Carp' => 0
  • wiki-toolkit-plugin-locator-grid/trunk/lib/CGI/Wiki/Plugin/Locator/Grid.pm

    r156 r269  
    1 package CGI::Wiki::Plugin::Locator::Grid;
     1package Wiki::Toolkit::Plugin::Locator::Grid;
    22
    33use strict;
    44
    55use vars qw( $VERSION @ISA );
    6 $VERSION = '0.03';
     6$VERSION = '0.04';
    77
    88use Carp qw( croak );
    9 use CGI::Wiki::Plugin;
    10 
    11 @ISA = qw( CGI::Wiki::Plugin );
     9use Wiki::Toolkit::Plugin;
     10
     11@ISA = qw( Wiki::Toolkit::Plugin );
    1212
    1313=head1 NAME
    1414
    15 CGI::Wiki::Plugin::Locator::Grid - A CGI::Wiki plugin to manage co-ordinate data.
     15Wiki::Toolkit::Plugin::Locator::Grid - A Wiki::Toolkit plugin to manage co-ordinate data.
    1616
    1717=head1 DESCRIPTION
    1818
    1919Access to and calculations using co-ordinate metadata supplied to a
    20 CGI::Wiki wiki when writing a node.
     20Wiki::Toolkit wiki when writing a node.
    2121
    2222B<Note:> This is I<read-only> access. If you want to write to a node's
    2323metadata, you need to do it using the C<write_node> method of
    24 L<CGI::Wiki>.
     24L<Wiki::Toolkit>.
    2525
    2626We assume that the points are located on a flat, square grid with unit
     
    2929=head1 SYNOPSIS
    3030
    31   use CGI::Wiki;
    32   use CGI::Wiki::Plugin::Locator::Grid;
    33 
    34   my $wiki = CGI::Wiki->new( ... );
    35   my $locator = CGI::Wiki::Plugin::Locator::Grid->new;
     31  use Wiki::Toolkit;
     32  use Wiki::Toolkit::Plugin::Locator::Grid;
     33
     34  my $wiki = Wiki::Toolkit->new( ... );
     35  my $locator = Wiki::Toolkit::Plugin::Locator::Grid->new;
    3636  $wiki->register_plugin( plugin => $locator );
    3737
     
    5151
    5252  # Maybe our wiki calls the x and y co-ordinates something else.
    53   my $locator = CGI::Wiki::Plugin::Locator::Grid->new(
     53  my $locator = Wiki::Toolkit::Plugin::Locator::Grid->new(
    5454                                                       x => "os_x",
    5555                                                       y => "os_y",
     
    6464  # By default we assume that x and y co-ordinates are stored in
    6565  # metadata called "x" and "y".
    66   my $locator = CGI::Wiki::Plugin::Locator::Grid->new;
     66  my $locator = Wiki::Toolkit::Plugin::Locator::Grid->new;
    6767
    6868  # But maybe our wiki calls the x and y co-ordinates something else.
    69   my $locator = CGI::Wiki::Plugin::Locator::Grid->new(
     69  my $locator = Wiki::Toolkit::Plugin::Locator::Grid->new(
    7070                                                       x => "os_x",
    7171                                                       y => "os_y",
     
    239239        if $args{node};
    240240    # Postgres is a fussy bugger.
    241     if ( ref $store eq "CGI::Wiki::Store::Pg" ) {
     241    if ( ref $store eq "Wiki::Toolkit::Store::Pg" ) {
    242242        $sql =~ s/metadata_value/metadata_value::integer/gs;
    243243    }
    244244    # SQLite 3 is even fussier.
    245     if ( ref $store eq "CGI::Wiki::Store::SQLite"
     245    if ( ref $store eq "Wiki::Toolkit::Store::SQLite"
    246246         && $DBD::SQLite::VERSION >= "1.00" ) {
    247247        $sql =~ s/metadata_value/metadata_value+0/gs; # yuck
     
    266266=over 4
    267267
    268 =item * L<CGI::Wiki>
     268=item * L<Wiki::Toolkit>
    269269
    270270=item * L<OpenGuides> - an application that uses this plugin.
     
    275275
    276276Kake Pugh (kake@earth.li).
     277The Wiki::Toolkit team (http://www.wiki-toolkit.org/)
    277278
    278279=head1 COPYRIGHT
    279280
    280281     Copyright (C) 2004 Kake L Pugh.  All Rights Reserved.
     282     Copyright (C) 2006 the Wiki::Toolkit Team. All Rights Reserved.
    281283
    282284This module is free software; you can redistribute it and/or modify it
     
    286288
    287289This module is based heavily on (and is the replacement for)
    288 L<CGI::Wiki::Plugin::Locator::UK>.
     290L<Wiki::Toolkit::Plugin::Locator::UK>.
    289291
    290292The following thanks are due to people who helped with
    291 L<CGI::Wiki::Plugin::Locator::UK>: Nicholas Clark found a very silly
     293L<Wiki::Toolkit::Plugin::Locator::UK>: Nicholas Clark found a very silly
    292294bug in a pre-release version, oops :) Stephen White got me thinking in
    293295the right way to implement C<find_within_distance>. Marcel Gruenauer
  • wiki-toolkit-plugin-locator-grid/trunk/t/01_load.t

    r149 r269  
    22use Test::More tests => 1;
    33
    4 use_ok( "CGI::Wiki::Plugin::Locator::Grid" );
     4use_ok( "Wiki::Toolkit::Plugin::Locator::Grid" );
  • wiki-toolkit-plugin-locator-grid/trunk/t/02_locator.t

    r156 r269  
    11use strict;
    2 use CGI::Wiki::Plugin::Locator::Grid;
    3 use CGI::Wiki::TestLib;
     2use Wiki::Toolkit::Plugin::Locator::Grid;
     3use Wiki::Toolkit::TestLib;
    44use Test::More;
    55
    6 my $iterator = CGI::Wiki::TestLib->new_wiki_maker;
     6my $iterator = Wiki::Toolkit::TestLib->new_wiki_maker;
    77
    88unless ( $iterator->number ) {
     
    1515while ( my $wiki = $iterator->new_wiki ) {
    1616      print "# Store: " . (ref $wiki->store) . "\n";
    17       my $locator = eval { CGI::Wiki::Plugin::Locator::Grid->new; };
     17      my $locator = eval { Wiki::Toolkit::Plugin::Locator::Grid->new; };
    1818      is( $@, "", "'new' doesn't croak" );
    19       isa_ok( $locator, "CGI::Wiki::Plugin::Locator::Grid" );
     19      isa_ok( $locator, "Wiki::Toolkit::Plugin::Locator::Grid" );
    2020      $wiki->register_plugin( plugin => $locator );
    2121
  • wiki-toolkit-plugin-locator-grid/trunk/t/03_different_names.t

    r156 r269  
    11use strict;
    2 use CGI::Wiki::Plugin::Locator::Grid;
    3 use CGI::Wiki::TestLib;
     2use Wiki::Toolkit::Plugin::Locator::Grid;
     3use Wiki::Toolkit::TestLib;
    44use Test::More;
    55
    6 my $iterator = CGI::Wiki::TestLib->new_wiki_maker;
     6my $iterator = Wiki::Toolkit::TestLib->new_wiki_maker;
    77
    88unless ( $iterator->number ) {
     
    1515while ( my $wiki = $iterator->new_wiki ) {
    1616
    17     my $locator = CGI::Wiki::Plugin::Locator::Grid->new(
     17    my $locator = Wiki::Toolkit::Plugin::Locator::Grid->new(
    1818        x => "easting",
    1919        y => "northing",
    2020    );
    21     isa_ok( $locator, "CGI::Wiki::Plugin::Locator::Grid" );
     21    isa_ok( $locator, "Wiki::Toolkit::Plugin::Locator::Grid" );
    2222    $wiki->register_plugin( plugin => $locator );
    2323
Note: See TracChangeset for help on using the changeset viewer.