public async Task <object> GetAsync(string contentTypeId)
        {
            var singleton = SingletonProvider.Get(contentTypeId);

            if (singleton == null)
            {
                return(null);
            }

            return(await ContentGetter.GetAsync(singleton.ContentTypeId, singleton.KeyValues).ConfigureAwait(false));
        }
        public async Task <T> GetAsync <T>() where T : class
        {
            var singleton = SingletonProvider.Get <T>();

            if (singleton == null)
            {
                return(null);
            }

            return((T)await ContentGetter.GetAsync(singleton.ContentTypeId, singleton.KeyValues).ConfigureAwait(false));
        }
Beispiel #3
0
        public T Get <T>(string language) where T : class
        {
            var singleton = SingletonProvider.Get <T>();

            if (singleton == null)
            {
                return(null);
            }

            return(ContentGetter.Get <T>(singleton.Id, language));
        }