Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

As client I want to have some standart cache policies #4

Open
Pitsko opened this issue Jul 24, 2013 · 0 comments
Open

As client I want to have some standart cache policies #4

Pitsko opened this issue Jul 24, 2013 · 0 comments

Comments

@Pitsko
Copy link

Pitsko commented Jul 24, 2013

As client I want to have some standart cache policies

something like there:
/* This is the default cache policy. When using this, requests
will first check if cached objects fitting the request are available in the cache.
If there is no cached data, empty result will be returned, and the request will proceed as normal.
If there is non-expired cached data (updated within the same running session; see \c setSessionExpireIn:), the request will
use it without contacting the server.
/
TRFetchRequestReturnCacheDataElseLoad = 0,

/** Request will not read from the cache when using this option.
 The receiver will be notified only once. If remote call fails,
 then receiver will get cached data with service error and fromCache=NO.*/
TRFetchRequestReloadIgnoringCacheData = 1,

/** When using this option, requests will succeed only if a response
     is already cached. If no response for a request is cached,
     the request will return empty data.*/
TRFetchRequestReturnCacheDataDontLoad = 2,

/** When using this policy, requests will first look to see if a
     cached response is available in the cache. If there is no cached data,
     the request will proceed as normal. If there is and the cached data
     has not expired, the request will use the cached data and then contacting
     with the server to retrieve updates.*/
TRFetchRequestReturnCacheDataThenLoad = 3
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant