Essence

Text

Included libraries Package variables General documentation Methods

Package variables top
No package variables defined.
Inherit top
Exporter
Synopsistop
No synopsis!
Descriptiontop
No description!
Methodstop
remove_whitespaceNo descriptionCode
split_wordsNo descriptionCode
trimNo descriptionCode

Methods description


Methods code

remove_whitespacedescriptiontopprevnext
sub remove_whitespace {
    my $text = shift;
    $text =~ s/\s//g;
    return $text;
}
split_wordsdescriptiontopprevnext
sub split_words {
    my $text = shift;
     
    my @words = split /\s|\,|\-|\(|\)|¡@|¡]|¡\^|¡A|¡B|¡C|¡u|¡m|¡n|¡F|¡þ|¡v|¡G|¡H|¡S|¡T|¡I|\?|\!|¡§|¡¨|¡y|¡z|\./, $text;

    my @ret = ();
  
    foreach my $w (@words) {
	next if $w =~ /^$/;
	push @ret, $w;
    }

    return @ret;
}
trimdescriptiontopprevnext
sub trim {
    my $text = shift;
    $text =~ s/^\s+//;
    $text =~ s/\s+$//;
    return $text;
}

General documentation

No general documentation available.