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

Question #31

Closed
telip007 opened this issue Apr 1, 2016 · 1 comment
Closed

Question #31

telip007 opened this issue Apr 1, 2016 · 1 comment

Comments

@telip007
Copy link

telip007 commented Apr 1, 2016

Can I cache objects from custom class, for example class Car{ // methods... } ?

@zenangst
Copy link
Contributor

zenangst commented Apr 2, 2016

Hey @telip007, yeah it supports custom objects, they just need to conform to the Cachable protocol as stated in the README. There is also an example in the playground.

https://github.com/hyperoslo/Cache/blob/master/Playgrounds/CustomCache.playground/Contents.swift#L25-L48

https://github.com/hyperoslo/Cache#cachable-protocol

Hope this helps.

@zenangst zenangst closed this as completed Apr 2, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants