1 |
joko |
1.1 |
package StructureAlterer::Handlers; |
2 |
|
|
|
3 |
|
|
use strict; |
4 |
|
|
use warnings; |
5 |
|
|
|
6 |
|
|
use UML::Utils; |
7 |
|
|
|
8 |
|
|
#----------------------------------- |
9 |
|
|
# generic_nuller |
10 |
|
|
|
11 |
|
|
sub generic_nuller { |
12 |
|
|
my $filename = shift; |
13 |
|
|
my $cmd; |
14 |
|
|
if ( -f $filename ) { |
15 |
|
|
$cmd="> $filename"; |
16 |
|
|
#`$cmd`; |
17 |
|
|
print "ccc: ", $cmd, "\n"; |
18 |
|
|
} |
19 |
|
|
if ( -d $filename ) { |
20 |
|
|
my $dirlist = UML::Utils::GetDirList($filename); |
21 |
|
|
my @dir = split("\n", $dirlist); |
22 |
|
|
foreach (@dir) { |
23 |
|
|
$cmd = ''; |
24 |
|
|
if (-f) { $cmd = $_; } |
25 |
|
|
print $cmd, "\n"; |
26 |
|
|
} |
27 |
|
|
} |
28 |
|
|
} |
29 |
|
|
|
30 |
|
|
1; |