2013-12-12 04:44:27 +08:00
|
|
|
import warnings
|
2006-05-02 09:31:56 +08:00
|
|
|
|
2013-12-12 06:31:34 +08:00
|
|
|
from django.apps import app_cache
|
2013-07-29 21:50:58 +08:00
|
|
|
|
2013-12-12 04:44:27 +08:00
|
|
|
warnings.warn(
|
|
|
|
"The utilities in django.db.models.loading are deprecated "
|
|
|
|
"in favor of the new application loading system.",
|
|
|
|
PendingDeprecationWarning, stacklevel=2)
|
2008-06-22 04:55:17 +08:00
|
|
|
|
2007-08-18 01:23:15 +08:00
|
|
|
__all__ = ('get_apps', 'get_app', 'get_models', 'get_model', 'register_models',
|
2007-08-18 12:16:04 +08:00
|
|
|
'load_app', 'app_cache_ready')
|
2006-07-30 05:04:41 +08:00
|
|
|
|
2007-08-18 01:23:15 +08:00
|
|
|
# These methods were always module level, so are kept that way for backwards
|
2013-05-09 22:16:43 +08:00
|
|
|
# compatibility.
|
2013-12-12 06:31:34 +08:00
|
|
|
get_apps = app_cache.get_apps
|
|
|
|
get_app_package = app_cache.get_app_package
|
|
|
|
get_app_path = app_cache.get_app_path
|
|
|
|
get_app_paths = app_cache.get_app_paths
|
|
|
|
get_app = app_cache.get_app
|
|
|
|
get_app_errors = app_cache.get_app_errors
|
|
|
|
get_models = app_cache.get_models
|
|
|
|
get_model = app_cache.get_model
|
|
|
|
register_models = app_cache.register_models
|
|
|
|
load_app = app_cache.load_app
|
|
|
|
app_cache_ready = app_cache.app_cache_ready
|