NAME

Data::Hopen::Util::Filename - functions for manipulating filenames

SYNOPSIS

Nothing is exported by default. Each function is available via an OO interface or a procedural interface.

FUNCTIONS

obj

Return the given filename, with the extension of an object file added. Usage:

Data::Hopen::Util::Filename::obj(filename[, -strip=>true]);    # procedural
Data::Hopen::Util::Filename->new->obj(fn[, -strip=>true]);     # OO

If -strip => <truthy> is given, strip any existing extension first.

exe

Return the given filename, with the extension of an executable file added. Usage and options are the same as "obj".

lib

Return the given filename, with the extension of a library file added. Usage and options are the same as "obj".

new

Create a new instance for the OO interface. For example:

my $FN = Data::Hopen::Util::Filename->new;
say $fn->obj('hello');      # e.g., "hello.o" or "hello.obj"