Exemplo n.º 1
0
        public mwCategoryInfo[] getCategories(object blogid, string username, string password)
        {
            ValidateUserCredentials(username, password);

            var categoryInfos = new List <mwCategoryInfo>();
            var tags          = _repository.Query <Tag>();

            tags.Each(tag =>
            {
                mwCategoryInfo mwCategoryInfo = new mwCategoryInfo
                {
                    categoryid  = tag.ID.ToString(),
                    description = tag.Name,
                    title       = tag.Name,
                    htmlUrl     = _urlResolver.Tag(tag.Name),
                    rssUrl      = ""
                };
                categoryInfos.Add(mwCategoryInfo);
            });

            return(categoryInfos.ToArray());
        }
Exemplo n.º 2
0
        public mwCategoryInfo[] getCategories(object blogid, string username, string password)
        {
            ValidateUserCredentials(username, password);

            var categoryInfos = new List<mwCategoryInfo>();
            var tags = _repository.Query<Tag>();

            tags.Each(tag =>
            {
                mwCategoryInfo mwCategoryInfo = new mwCategoryInfo
                {
                    categoryid = tag.ID.ToString(),
                    description = tag.Name,
                    title = tag.Name,
                    htmlUrl = _urlResolver.Tag(tag.Name),
                    rssUrl = ""
                };
                categoryInfos.Add(mwCategoryInfo);
            });

            return categoryInfos.ToArray();
        }