def getLimitRange(count, plusOne=False):
 retVal = None
 count = int(count)
 (limitStart, limitStop) = (1, count)
 if (isinstance(conf.limitStop, int) and (conf.limitStop > 0) and (conf.limitStop < limitStop)):
  limitStop = conf.limitStop
 if (isinstance(conf.limitStart, int) and (conf.limitStart > 0) and (conf.limitStart <= limitStop)):
  limitStart = conf.limitStart
 retVal = (xrange(limitStart, (limitStop + 1)) if plusOne else xrange((limitStart - 1), limitStop))
 return retVal

def getLimitRange ( count , plusOne = False ) : retVal = None count = int ( count ) ( limitStart , limitStop ) = ( 1 , count ) if ( isinstance ( conf . limitStop , int ) and ( conf . limitStop > 0 ) and ( conf . limitStop < limitStop ) ) : limitStop = conf . limitStop if ( isinstance ( conf . limitStart , int ) and ( conf . limitStart > 0 ) and ( conf . limitStart <= limitStop ) ) : limitStart = conf . limitStart retVal = ( xrange ( limitStart , ( limitStop + 1 ) ) if plusOne else xrange ( ( limitStart - 1 ) , limitStop ) ) return retVal
returns range of values used in limit/offset constructs .