com.astroshare.astroonline.soap
Class ClientCache

java.lang.Object
  extended by com.astroshare.astroonline.soap.ClientCache
Direct Known Subclasses:
ClientCacheYearly

public class ClientCache
extends java.lang.Object

Gets horoscopes from Astro Share soap server and stores them in cache.

The horoscopes are cached with it's current date. The date of the client machine (it this case a server?) is used to determine the date for the daily horoscopes.

Astro Share horoscopes can only be used with a proper license. The Astro Share soap server checks access based on the server's ip address. If the ip addess is not authorized, an access denied is returned.


Field Summary
protected static java.util.HashMap<java.lang.String,java.lang.Object> cachedHoroscopes
           
protected static org.apache.log4j.Logger log
          init logging
 
Constructor Summary
ClientCache()
           
 
Method Summary
static void clearCachedHoroscopes()
           Clear cache.
protected static java.util.HashMap<java.lang.String,java.lang.Object> getHoroscope(java.lang.String id, java.lang.String language, java.lang.String dateString, java.lang.String soapMethod, java.lang.String title)
           Try to get horoscopes from cache.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

log

protected static org.apache.log4j.Logger log
init logging


cachedHoroscopes

protected static java.util.HashMap<java.lang.String,java.lang.Object> cachedHoroscopes
Constructor Detail

ClientCache

public ClientCache()
Method Detail

clearCachedHoroscopes

public static void clearCachedHoroscopes()

Clear cache.


getHoroscope

protected static java.util.HashMap<java.lang.String,java.lang.Object> getHoroscope(java.lang.String id,
                                                                                   java.lang.String language,
                                                                                   java.lang.String dateString,
                                                                                   java.lang.String soapMethod,
                                                                                   java.lang.String title)

Try to get horoscopes from cache.

Parameters:
id - Cache id
language - Language
dateString - date in string format (YYYMMDD)
soapMethod - soapMethod necessary for call
title - Horoscope title
Returns:
HashMap holding the requested horoscope data


Astro-Online © 2001 − 2008 Astro Share
Documentation generated on: Thursday August 12th 2008 (PS)