Added support for resources.