com.blogspot.applications4android.comicreader.comictypes
Class DailyComic

java.lang.Object
  extended by com.blogspot.applications4android.comicreader.core.ComicParser
      extended by com.blogspot.applications4android.comicreader.core.Comic
          extended by com.blogspot.applications4android.comicreader.comictypes.DailyComic
Direct Known Subclasses:
BabyBlues, Blondie, DailyGoComicsCom, DailyKingFeaturesComic, DailyOregonlive, DayByDay, Dilbert, GirlGenius, Misfile, MotherGooseandGrimm, PennyArcade, USAcres, Userfriendly, Wulffmorgenthaler

public abstract class DailyComic
extends Comic

This class is useful for all those comics which are released daily and are indexed by calendar date.


Field Summary
protected static java.util.TimeZone m_zone
          use US timezone for dailycomic!
protected  Bound mBound
          bound for this comic
 
Fields inherited from class com.blogspot.applications4android.comicreader.core.Comic
DIALOG_DATE, DIALOG_NUMBER, mFirstUid, mLatestUid, mPrevSessionUid, NAV_CURRENT, NAV_FIRST, NAV_LATEST, NAV_LATEST_FORCE, NAV_NEXT, NAV_PREV_SESSION, NAV_PREVIOUS, NAV_RANDOM, PROPS, TYPE_CACHING, TYPE_FAVORITE, TYPE_LATEST, TYPE_PREV_SESSION, TYPE_PREVIEW
 
Constructor Summary
DailyComic()
          Constructor
 
Method Summary
 void addException(java.util.Calendar in, int increment)
          For those days which do not have a comic strip If the given daily comic series WAS irregular previously but now has been regular, then you have to override this function!
 int dialogType()
          Type of dialog to be used for choosing comics
 Bound getBound()
          Returns the bound for the current comic
 java.util.Calendar getCurrentCal()
          Helper function to get the current calendar
protected abstract  java.util.Calendar getFirstCalendar()
          Get a Calendar instance for the first comic strip.
protected  java.lang.String getFirstStripUrl()
          Gets the url for the first strip
protected abstract  java.util.Calendar getLatestCalendar()
          Get a Calendar instance for the latest comic strip.
protected  java.lang.String getLatestStripUrl()
          Gets the url for the latest strip
protected  java.lang.String getNextStripUrl()
          Gets the url for the next strip
protected  java.lang.String getPreviousStripUrl()
          Gets the url for the previous strip
protected  java.lang.String getRandomStripUrl()
          Gets the url for the previous strip
protected abstract  java.util.Calendar getTimeFromUrl(java.lang.String url)
          Helper function to convert the comic html URL into Calendar instance.
abstract  java.lang.String getUrlFromTime(java.util.Calendar cal)
          Helper function to convert the Calendar instance into url
protected  java.lang.String[] urlsNotForCaching()
          Gives out the list of urls (can be regexes) which are not supposed to be cached using 'mStrips'
 
Methods inherited from class com.blogspot.applications4android.comicreader.core.Comic
clearCache, clearHistory, currentHasImageText, currentTitleAsValidFilename, downloadCurrentStrip, getComicName, getComicWebPageUrl, getCurrentStrip, getDefaultZoom, getFirstStrip, getLatestStrip, getLatestStripForcefully, getLaunchType, getName, getNextStrip, getPreviousSessionStrip, getPreviousStrip, getRandomStrip, getStripFromUrl, hasPreviousSession, hasUid, isCurrentFavorite, isCurrentFirstStrip, isCurrentLatestStrip, navigateStrip, queryUid, readOnlyUnread, readProperties, setCacheEnabled, setComicName, setCurrentAsFavorite, setDefaultZoom, setLaunchType, writeProperties
 
Methods inherited from class com.blogspot.applications4android.comicreader.core.ComicParser
htmlNeeded, parse, parse
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

m_zone

protected static java.util.TimeZone m_zone
use US timezone for dailycomic!


mBound

protected Bound mBound
bound for this comic

Constructor Detail

DailyComic

public DailyComic()
Constructor

Method Detail

addException

public void addException(java.util.Calendar in,
                         int increment)
For those days which do not have a comic strip If the given daily comic series WAS irregular previously but now has been regular, then you have to override this function!

Parameters:
in - the calendar which needs to take care of this
increment - which date needs to be shown instead.

getCurrentCal

public java.util.Calendar getCurrentCal()
Helper function to get the current calendar

Returns:
calendar

getBound

public Bound getBound()
Description copied from class: Comic
Returns the bound for the current comic

Specified by:
getBound in class Comic
Returns:
bound

dialogType

public int dialogType()
Description copied from class: Comic
Type of dialog to be used for choosing comics

Specified by:
dialogType in class Comic
Returns:
int

getLatestStripUrl

protected java.lang.String getLatestStripUrl()
Description copied from class: Comic
Gets the url for the latest strip

Specified by:
getLatestStripUrl in class Comic
Returns:
url

getFirstStripUrl

protected java.lang.String getFirstStripUrl()
Description copied from class: Comic
Gets the url for the first strip

Specified by:
getFirstStripUrl in class Comic
Returns:
url

getNextStripUrl

protected java.lang.String getNextStripUrl()
Description copied from class: Comic
Gets the url for the next strip

Specified by:
getNextStripUrl in class Comic
Returns:
url

getPreviousStripUrl

protected java.lang.String getPreviousStripUrl()
Description copied from class: Comic
Gets the url for the previous strip

Specified by:
getPreviousStripUrl in class Comic
Returns:
url

getRandomStripUrl

protected java.lang.String getRandomStripUrl()
Description copied from class: Comic
Gets the url for the previous strip

Specified by:
getRandomStripUrl in class Comic
Returns:
url

getFirstCalendar

protected abstract java.util.Calendar getFirstCalendar()
Get a Calendar instance for the first comic strip.

Returns:
Calendar instance for the first strip

getLatestCalendar

protected abstract java.util.Calendar getLatestCalendar()
Get a Calendar instance for the latest comic strip.

Returns:
Calendar instance for the latest strip

getTimeFromUrl

protected abstract java.util.Calendar getTimeFromUrl(java.lang.String url)
Helper function to convert the comic html URL into Calendar instance.

Parameters:
url - comic html url
Returns:
the calendar instance.

getUrlFromTime

public abstract java.lang.String getUrlFromTime(java.util.Calendar cal)
Helper function to convert the Calendar instance into url

Parameters:
cal - calendar instance
Returns:
comic url

urlsNotForCaching

protected java.lang.String[] urlsNotForCaching()
Description copied from class: Comic
Gives out the list of urls (can be regexes) which are not supposed to be cached using 'mStrips'

Specified by:
urlsNotForCaching in class Comic
Returns:
list