Devel::PerlySense::Bookmark::Match - A Bookmark match


Devel-PerlySense documentation Contained in the Devel-PerlySense distribution.

Index


Code Index:

NAME

Top

Devel::PerlySense::Bookmark::Match - A Bookmark match

DESCRIPTION

Top

A match has a Location (file + line), and a corresponding Definition that caused it to match.

PROPERTIES

Top

oLocation

The Document::Location where this match matched.

oDefinition

Bookmark::Definition that was used to match this.

line

The source line where the match matched.

Default: ""

text

The textual match that was captured (or the entire line).

Default: ""

METHODS

Top

new(file, row, line, text, oDefinition)

Create new PerlySense::Bookmark::Match object.

AUTHOR

Top

Johan Lindström, <johanl[ÄT]DarSerMan.com>

BUGS

Top

Please report any bugs or feature requests to bug-devel-perlysense@rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Devel-PerlySense. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

ACKNOWLEDGEMENTS

Top

COPYRIGHT & LICENSE

Top


Devel-PerlySense documentation Contained in the Devel-PerlySense distribution.




use strict;
use warnings;

package Devel::PerlySense::Bookmark::Match;
our $VERSION = '0.01';





use Spiffy -Base;
use Carp;
use Data::Dumper;

use Devel::PerlySense;
use Devel::PerlySense::Document::Location;





field "oLocation" => undef;





field "oDefinition" => undef;





field "line" => "";





field "text" => "";





sub new {
    my ($file, $row, $line, $text, $oDefinition) = Devel::PerlySense::Util::aNamedArg(["file", "row", "line", "text", "oDefinition"], @_);

    $self = bless {}, $self;    #Create the object. It looks weird because of Spiffy
    $self->oLocation(Devel::PerlySense::Document::Location->new(
        file => $file,
        row => $row,
        col => 0,  #When a col is needed, add it here
    ));
    $self->oDefinition($oDefinition);
    $self->line($line);
    $self->text($text);

    return($self);
}





1;





__END__