コード例 #1
0
        public override Task <CompanyDescriptionObj> GetCompanyDescription(IdRequestCompanyDescription request, ServerCallContext context)
        {
            var _logic = new CompanyDescriptionLogic(new EFGenericRepository <CompanyDescriptionPoco>());
            CompanyDescriptionPoco poco = _logic.Get(Guid.Parse(request.Id));

            if (poco == null)
            {
                throw new ArgumentOutOfRangeException();
            }
            return(TranslateFromPoco(poco));
        }
コード例 #2
0
        //get
        public override Task <CompanyDescriptionreply> GetCompanyDescription(IdRequestCompanyDescription request, ServerCallContext context)
        {
            CompanyDescriptionPoco poco = _logic.Get(Guid.Parse(request.Id));

            return(Task.FromResult <CompanyDescriptionreply>(FromPoco(poco)));
        }