Implemented caching on swig rendering