Religion::Islam::PrayMind - a Perl module that is a client for PrayerMinder server


NAME

Religion::Islam::PrayMind - a Perl module that is a client for PrayerMinder server


SYNOPSIS

  use Religion::Islam::PrayMind;
  $p1 = new PMConnect(ClientID => "xxxx");
  #where xxxx is the client web site's ID at the PrayerMinder server.
  $p1->GetList(<listtype> [, <parentID>);
  $p1->GetPrayerTimes(<cityID>);


DESCRIPTION

This module provides ways to obtain data from the PrayerMinder server. It is built on top of the XML::Parser manpage. Each call to the GetList manpage or the GetPrayerTimes manpage methods opens a socket connection to the PrayerMinder server, and creates a new instance of XML::Parser which is then used to parse the data received through the socket.

Example

The following files show example usage of the PrayMind module:

- ContinentsList.pl
- CountriesList.pl
- CitiesList.pl
- CityTimes.pl

EXPORT

Exported constants and variables


METHODS

new(ClientID => ``CLIENTID'')
This is a class method, the constructor for PMConnect. Client ID for the caller's PrayerMinder account is passed as keyword value pair.

GetList(LIST_TYPE [, PARENT_ID])
This method retrieves a list of locations.

PARAMETERS

GetListSize
Returns integer

Called after the GetList manpage to obtain the number of locations in the list.

GetElementID
Returns integer

Called after the GetList manpage to obtain the number of locations in the list.

GetElementName
Returns string

Called after the GetList manpage to obtain the number of locations in the list.

NextElement
Returns true if successful, false for no more elements.

Called after the GetList manpage to obtain the number of locations in the list.

GetPrayerTimes(CITY_ID)
This method retrieves prayer times for the requested city. CITY_ID specifies the ID of the city requested. the GetError manpage and the GetErrorText manpage must be called before calling any other methods to make sure no errors occurred.

CityID
Returns integer

Called after the GetPrayerTimes manpage to obtain the ID for the city.

CityTitle
Returns string

Called after the GetPrayerTimes manpage to obtain the title for the city.

CityTimeZone
Returns string (floating point decimal number)

Called after the GetPrayerTimes manpage to obtain the time zone for the city.

CityIslamicDate
Returns string

Called after the GetPrayerTimes manpage to obtain today's Islamic date for the city.

CityGregorianDate
Returns string

Called after the GetPrayerTimes manpage to obtain today's Gregorian date for the city.

CityAsrFiqh
Returns string

Called after the GetPrayerTimes manpage to obtain the default Asr fiqh method for the city.

CityPrayerTime(PRAYER_NAME)
Returns string

Called after the GetPrayerTimes manpage to obtain the requested prayer time for the city.

PARAMETERS

GetError
Returns the Error_ID manpage

Called after the GetPrayerTimes manpage or the GetList manpage to obtain the error ID. Returns values indicates error ID or IDS_NoError if no errors occurred.

GetErrorText
Returns string

Called after the GetError manpage to obtain the text description of the last error.


AUTHOR

Tasmin Ahmad, <support@prayerminder.com>

Web site: http://www.prayerminder.com/

 Religion::Islam::PrayMind - a Perl module that is a client for PrayerMinder server