Example #1
0
def readCache(cacheType):
    rtn = None
    filename = configCommon.getCacheFile(cacheType)
    if (os.path.exists(filename) and os.path.isdir(filename)):
        with open(filename, "rb") as f:
            rtn = pickle.load(f)

    return rtn
Example #2
0
def readCache(cacheType):
    rtn = None
    filename = configCommon.getCacheFile(cacheType)
    if os.path.exists(filename) and os.path.isdir(filename):
        with open(filename, "rb") as f:
            rtn = pickle.load(f)

    return rtn
Example #3
0
def writeCache(cacheType, data):
    filename = configCommon.getCacheFile(cacheType)
    with open(filename, "wb") as f:
        pickle.dump(data, f)
Example #4
0
def writeCache(cacheType, data):
    filename = configCommon.getCacheFile(cacheType)
    with open(filename, "wb") as f:
        pickle.dump(data, f)