做android开发时你还在为gson,json而人肉序列化与反序列化吗,上传文件时你还在使用UrlConnection或者HttpClient吗?
下面提供了asp.net 服务端与 android 客户端通过hessdroid (hessian 的android版) 通信解决方案,从此你不用再为上面的问题发愁了
中小应用,使用.net 的EF(数据库优先)或linq,那是相当的方便,做个管理页面也只要拖拖控件就好了(不拖都对不起自己尤其是自己从头整到尾的项目), 当然你需要使用EmitMapper一类的东西将dto映射到EF实体类上。

服务端定义实体类

using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace cn.fstudio.hessian.dto
{
    public class ResponseBase<T>
    {
        private int code;
        private string msg;
        private T model;

        public int Code
        {
            get { return code; }
            set { code = value; }
        }
        public string Msg
        {
            get { return msg; }
            set { msg = value; }
        }
        public T Model
        {
            get { return model; }
            set { model = value; }

        }
    }
}
View Code

相关文章:

  • 2021-12-01
  • 2021-08-11
  • 2021-08-04
  • 2021-11-21
  • 2021-11-22
  • 2022-02-26
  • 2021-09-29
猜你喜欢
  • 2021-11-06
  • 2021-04-22
  • 2022-12-23
  • 2021-10-04
相关资源
相似解决方案