lib/puppet_x/coi/jboss/functions/dirname.rb
# PRIVATE INTERNAL FUNCTION. Returns the dirname of a file
#
# @param args [Array] should be only one argument in array
# @return [string|string[]] the file path(s)
PRIVATE INTERNAL FUNCTION. Returns the dirname of a file
PRIVATE INTERNAL FUNCTION . Returns the dirname of a file
def dirname(args)
      validate_method_parameters('jboss_dirname', args) do
        { :desc => '1', :condition => args.size != 1 }
      end
      if args[0].is_a?(Array)
        args[0].collect { |a| File.dirname(a) }
      else
        File.dirname(args[0])
      end
    end
def dirname ( args ) validate_method_parameters ( 'jboss_dirname' , args ) do { :desc => '1' , :condition => args . size != 1 } end if args [ 0 ] . is_a? ( Array ) args [ 0 ] . collect { | a | File . dirname ( a ) } else File . dirname ( args [ 0 ] ) end end
PRIVATE INTERNAL FUNCTION.
PRIVATE INTERNAL FUNCTION .
] the file path(s)
] the file path ( s )
string|string[
args
should be only one argument in array
should be only one argument in array