Skip to content

get cache created at NSDate #23

@prabirshrestha

Description

@prabirshrestha

add a method that allows to get the date when the cache was created.

- (NSDate*) getCreatedAt:(NSString*)key;

It will then allow to use this logic.

if has cachedData
    load from cachedData
    if cachedCreateDate is old
        fetch online, cache it and reload
else
    fetch online, cache it and load

I want to set the cache as long as possible, but if it is old I would like to load from cache and fetch online too.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions