2006-12-15

sql2005的xml字段类型在.net中的应用

来源: 本站收集整理 作者:佚名 评论 0 条
 
set
{
this._ServerGroupID = value;
}
}


/// <summary>
/// 服务器对应的店铺信息
/// </summary>
public MServerShopCollection ServerShops
{
get
{
return _ServerShops;
}
set
{
this._ServerShops = value;
}
}
#endregion
}

/// <summary>
/// 服务器对应的店铺
/// </summary>
/// <remarks>
/// 用于存放和服务器对应的店铺
/// </remarks>
[Serializable()]
[XmlRoot(ElementName = "Shop", Namespace = "http://www.linkedu.com.cn/MServerShop.xsd")]
public class MServerShop : BaseModelEntity
{
#region private
private int _ShopID;
private string _ShopName;
#endregion

#region constructor
/// <summary>
/// 服务器对应的店铺信息
/// </summary>
public MServerShop()
{
}

/// <summary>
/// 服务器对应的店铺信息
/// </summary>
/// <param name="_ShopID">店铺ID</param>
/// <param name="_ShopName">店铺名称</param>
public MServerShop(int _ShopID, string _ShopName)
{
this._ShopID = _ShopID;
this._ShopName = _ShopName;
}
#endregion

#region property
/// <summary>
/// 店铺ID
/// </summary>
[XmlAttribute]
public int ShopID
{
get
{
return _ShopID;
}
set
{
this._ShopID = value;
}
}

/// <summary>
/// 店铺名称
/// </summary>
[XmlAttribute]
public string ShopName
{
get
{
return _ShopName;
}
set
{
this._ShopName = value;
}
}
#endregion
}

为了对模型的集合信息进行描述,我们有设计了MServerGroupCollection(服务器群信息集合),MServer(服务器群下的服务器信息),MServerShopCollection(服务器对应的店铺集合)

/// <summary>
/// 服务器群信息集合
/// </summary>
/// <remarks>
[Serializable()]
[XmlRoot("ServerGroups")]
public class MServerGroupCollection : List<MServerGroup>
{
/// <summary>
共12页: 上一页 [1] [2] [3] 4 [5] [6] [7] [8] [9] [10] [11] [12] 下一页

(本文仅表明作者个人观点,不代表本站及其管理员立场.) 推荐 收藏 投稿 打印 返回 关闭
上一篇:SQL Server 2005与DB2 8.2对比分析  
下一篇:SQL Server2005发布元年 微软正身企业级应用
    评论加载中…
 推荐文章
     

网站首页  -  网站地图 -   站长论坛  -  网站投稿  -    -  网站管理
Copyright © 2008 芜湖站长站 All Rights Reserved 皖ICP备07500611号