Padre::Task::IntroduceTemporaryVariable3pm
Introduces a temporary variable using ppi
Usage
my $tempvarmaker = Padre::Task::IntroduceTemporaryVariable->new(document => $document_obj,start_location => [$line, $column], # or just character positionend_location => [$line, $column], # or ppi-style locationvarname => '$foo',);$tempvarmaker->schedule;
Overview
Given a region of code within a statement, replaces that code with a temporary variable. Declares and initializes the temporary variable right above the statement that included the selected expression.
Usually, you simply set "start_position" to what "$editor->GetSelectionStart" returns and "end_position" to "$editor->GetSelectionEnd - 1".
Copyright and license
Copyright 2008-2013 The Padre development team as listed in Padre.pm.
This program is free software; you can redistribute it and/or modify it under the same terms as Perl 5 itself.
Releases
2 releases since Debian 7 (Wheezy); the text changed 1 time.