Software Index
Linux Software Utilities  

Hey::Common

download download home home   report broken
important software information
company name:
Dusty Wilson
license: Freeware
minimum requirements: No special requirements.
functional limitations:
Hey::Common description
Hey::Common is a Perl module with common functions used in other Hey::* modules.

SYNOPSIS

use Hey::Common;
my $common = Hey::Common->new;

my $money = $common->formatMoney(524.4); # will return string "524.40"

new

my $common = Hey::Common->new;

This function provides access to all of these following methods.

forceArray

$data->{users} = $common->forceArray($data->{users});

The input can either be an array ref or non-array ref. The output will either be that same array ref, or the non-array ref as the only item in an array as a ref.

This is useful for items that might or might not be an array ref, but you are expecting an array ref.

randomCode

$someRandomCode = $common->randomCode($lengthOfCodeRequested, $keyStringOfPermittedCharacters);

$someRandomCode = $common->randomCode(); # defaults for length and key
$someRandomCode = $common->randomCode(8); # choose a specific length, but default key
$someRandomCode = $common->randomCode(12, 'abcdefg'); # choose a specific length and key

$lengthOfCodeRequested defaults to 16.

$keyStringOfPermittedCharacters defaults to 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789'.

deepCopy

my $newCopyOfSomeHashRef = $common->deepCopy($someHashRef);

It makes a copy of a reference instead of making a reference to it. There's some usefulness there.

isAffirmative

if ($common->isAffirmative('y')) {
print "'y' is affirmative, so you'll see this.";
}

if ($common->isAffirmative('no')) {
print "'no' is not affirmative, so you won't see this";
}

This checks to see if the value is affirmative.

Things that are affirmative are: 'y', 'yes', 't', 'true', or any true numerical value.
isNegative

if ($common->isNegative('y')) {
print "'y' is not negative, so you won't see this.";
}

if ($common->isNegative('no')) {
print "'no' is negative, so you'll see this";
}

This checks to see if the value is negative.

Things that are negative are: 'n', 'no', 'f', 'false', any false numerical value (zero), or undef/null.

smtpClient

my @aListOfRecipientEmailAddresses = ('george@somewhere.com', 'ed@server.com', 'ralph@elsewhere.com');

my $contentOfEmailIncludingHeader = 'smtp.server.someplace.com',
From => 'fred@someplace.com',
To => @aListOfRecipientEmailAddresses,
Content => $contentOfEmailIncludingHeader });

'Host' is optional and defaults to 'localhost'. Of course, you would need to be able to send email through whatever host you specify.

'From' is a single email address that is used as the envelope address.

'To' can be a single email address or a list of email addresses as a scalar or an array ref.

'Content' is the content of the email, with header and body included.

formatMoney

my $money = 515.3;
$money = $common->formatMoney($money);

$money is the non-formatted money amount. It will be returned as a formatted string, but with no currency symbol.

sha1

my $something = 'This is something that will be hashed.';
my $sha1Hash = $common->sha1($something);

$something is any value that you want hashed. It can be a binary value or a simple scalar.

$sha1Hash is a simple sha1 hex of whatever you passed in.. The CPAN Search Site - search.cpan.org. Publisher of Hey::Common, Author of Hey::Common 0.01. Hey::Common is a Perl module with common functions used in other Hey::* modules. SYNOPSIS use Hey::Common; my $common = Hey::Common-new; my $money = $common-formatMoney(524.4); # will return
Similar software
gnome-js-common (Popularity: ) : Gnome JS common package

gnome-js-common is a GNOME library.

Installation:

The simplest way to compile this package is:

1. `cd' to the directory containing the package's source code and type `./configure' to configure the package for your system. If you're using `csh' on an ...

Hey::Cache (Popularity: ) : Hey::Cache is a Perl module to cache data multiple data structures.

SYNOPSIS

use Hey::Cache;

my $cache = Hey::Cache->new(
Namespace => 'WeatherApp2000', # string (optional, default='default')
CacheFile => 'fun_cache_file.xml', # file path and name (optional, default='cache.xml')
AutoSync => 1, # boolean (optional, ...

ConceptNet (Popularity: ) : ConceptNet is a Python API to a Semantic Network Representation of the Open Mind Common Sense Project.. . Publisher of ConceptNet, Author of ConceptNet 4.0b3. ConceptNet is a Python API to a Semantic Network Representation of the Open Mind Common ...
Evolution Data Server (Popularity: ) : Evolution Data Server provides a single database for common, desktop-wide information, such as a user's address book or calendar events.

Evolution Data Server is also a dependency of the clock applet from the gnome-applets package, 2.10 release.

Evolution provides integrated mail, addressbook ...

ToscaWidgets (Popularity: ) : ToscaWidgets is a web widget toolkit for Python to aid in the creation, packaging and distribution of common view elements normally used in the web.

These widgets are portable among any Python web-application framework or application that supports the WSGI standard.. ...

Ghost for Linux (Popularity: ) : Ghost for Linux project is a hard disk and partition imaging and cloning tool similar to "Norton Ghost" and by Symantec.

The created images are optionally compressed, and they can be stored on a local hard drive or transferred to an ...

GNOME System Tools (Popularity: ) : Formerly known as the Ximian Setup Tools, GNOME System Tools are a fully integrated set of tools aimed to make easy the job that means the computer administration on an UNIX or Linux system.

They're thought to help from the new ...

Gloobus (Popularity: ) : Gloobus is a quicklook for Linux using openGL.

The point of this application is to preview the most common files in a very graphical and fast way!

KEYS

Gloobus: left and right arrow to move
"q" to quit
"spacebar" to launch the preview of the ...

HTML::Element::Library (Popularity: ) : HTML::Element::Library is a Perl module that provides API calls for common actions on trees when using HTML::Tree.

SYNOPSIS

use HTML::Element::Library;. metaperl.org - premiere python and perl consulting. Publisher of HTML::Element::Library, Author of HTML::Element::Library 3.53. HTML::Element::Library is a Perl module that provides ...

R-Studio for Linux (Popularity: ) : R-Studio for Linux extends the family of powerful and cost-effective data recovery software from R-TT to the Linux operating system. Thanks to R-Studio for Linux's flexible parameters and customizable settings, users get absolute control over their data recovery tasks. R-Studio ...
Hangman Pro for Macintosh (Popularity: ) : Hangman Pro is a modern take on the classic hangman word guessing game. It features colorful, non-violent graphics, digitized sounds, dozens of built-in word categories, unlimited lists of your own words, hints, timed games, photo fun, and much more. Hangman ...
HelpMaster for Linux (Popularity: ) : HelpMaster is an authoring tool for Sun's JavaHelp component. HelpMaster provides complete control over all aspects of the JavaHelp system allowing you to create an easy to use help system for users.

Please note that HelpMaster only facilitates the creation of ...

User reviews

Write a review:
1 2 3 4 5 6 7 8 9 10
1=poor 10=excellent
Write review*
Your name*
Email*
  (Comments are moderated, and will not appear on this site until the editor has approved them)
 
Similar scripts
Common Factors Calculator (Popularity: ) : Common Factors Calculator allows you to determine the two numbers common factors.
Range minima and least common ancestors (Popularity: ) : This script implements data structures for solving the following two problems: - Range minimization: given an array X of data, quickly find min(X[i:j]) for different ranges i:j. - Least common ancestors: given a tree, quickly find the lowest tree node ...
Greatest Common Factor - Finder (Popularity: ) : Finds the divisors of integer x that do not divide evenly into integer y, and the program finds the greatest common factor (or g.c.f.) of x and y.
Extended great common divisor function (Popularity: ) : This script contains a function that finds out the gcd(a,b)(great common divisor of a and b) as a linear conbination of a anb b, ax by=gcd(a,b).
Greatest Common Factor (Popularity: ) : This script helps you to find the Greatest Common Factor (GCF) of a group of two or three numbers.
GNU Common (Popularity: ) : GNU Common C is a portable and highly optimized class framework for writing C applications that need to use threads and support concurrent sychronization, and that use sockets, XML parsing, serialization, config files, thread-optimized String and data structure classes, etc.This ...
Linear versus Compounded Returns: Common Pitfalls in Risk and Portfolio Management (Popularity: ) : To walk through the code and for a thorough description, refer toA. Meucci, (2010) "Linear versus Compounded Returns: Common Pitfalls in Risk and Portfolio Management",Latest version of code and article available at http://symmys.com/node/141
LCSSubStr-a function that return two string's largest common part (Sripts) (Popularity: ) : a function that return two string's largest common part% Usage:% [ret]=LCSubstr(s,t)% s: input string 1% t: input string 2% ret: Largest Common String% z: Largest Common String Length% L : Compare matrix% Example:% >>a='This is very common string';% >>b='string is ...
PHP common DB interface for Scripts (Popularity: ) : PHP common DB interface is a database programming API.It provides a collection of functions who will act as an upper layer of the PHP native database calls, to make less troublesome the porting of same application to different underlying databases.MSSQL,mySQL ...
Doctrine Common (Popularity: ) : The Doctrine Common annotations library was born from a need in the Doctrine2 ORM to allow the mapping information to be specified as metadata embedded in the class files, on properties and methods. The library is independent and can be ...
Rate me
supported os's
stats
downloads 4
version 0.01
size in Kb 10
popularity   
981/1272475
user rating 0/10
our rating 0 Stars
share info
Recommend Hey::Common
Report spyware
New Software
Popular Software
Latest Reviews