?? photoinfo.cs
字號(hào):
namespace ASPNET.StarterKit.Communities.PhotoGallery {
using System;
using System.Data.SqlClient;
//*********************************************************************
//
// PhotoInfo Class
//
// Represents all information about a particular photo.
//
//*********************************************************************
public class PhotoInfo : ContentInfo {
int _imageID;
string _imageName;
string _fullDescription;
//*********************************************************************
//
// PhotoInfo Constructor
//
// Calls base ContentInfo constructor to initialize general
// content information and then initialize photo specific
// information from a SqlDataReader.
//
//*********************************************************************
public PhotoInfo(SqlDataReader dr) : base(dr) {
// Populate required fields
_imageID = (int)dr["Image_ID"];
_imageName = (string)dr["Image_FileName"];
// Populate optional fields
if (dr["Photo_FullDescription"] != DBNull.Value)
_fullDescription = (string)dr["Photo_FullDescription"];
}
//*********************************************************************
//
// ImageID Property
//
// Represents the ID for an image.
//
//*********************************************************************
public int ImageID {
get {return _imageID;}
set {_imageID = value;}
}
//*********************************************************************
//
// ImageName Property
//
// Represents the file name of an image.
//
//*********************************************************************
public string ImageName {
get {return _imageName;}
set {_imageName = value;}
}
//*********************************************************************
//
// FullDescription Property
//
// Represents the full description of an image.
//
//*********************************************************************
public string FullDescription {
get {return _fullDescription;}
set {_fullDescription = value;}
}
}
}
?? 快捷鍵說明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -