Esempio n. 1
0
        public void Persist(SystemNews item)
        {
            VtsWebServiceClient service = new VtsWebServiceClient();

            service.NewsPersist(SystemNewsAssembler.FromDomainObjectToDto(item));
            service.Close();
        }
Esempio n. 2
0
        public static IEnumerable <SystemNews> GetLast(int topCount)
        {
            VtsWebServiceClient service = new VtsWebServiceClient();

            foreach (SystemNewsDto newsDto in service.NewsGetLast(topCount))
            {
                yield return(SystemNewsAssembler.FromDtoToDomainObject(newsDto));
            }
            service.Close();
        }
Esempio n. 3
0
        public IEnumerable <SystemNews> GetAll()
        {
            VtsWebServiceClient service = new VtsWebServiceClient();

            foreach (SystemNewsDto dto in service.NewsGetAll())
            {
                yield return(SystemNewsAssembler.FromDtoToDomainObject(dto));
            }
            service.Close();
        }
Esempio n. 4
0
        public SystemNews Get(long id)
        {
            VtsWebServiceClient service = new VtsWebServiceClient();

            return(SystemNewsAssembler.FromDtoToDomainObject(service.NewsGet(id)));
        }