if (subparts[0] == "POST") req.Method = HttpMethodType.Post;
if (!String.IsNullOrEmpty(subparts[1]))
{
//在“目录”拆分路径
string[] resourcePaths = subparts[1].Split(new string[] { "/" }, StringSplitOptions.RemoveEmptyEntries);
if (resourcePaths.Length > 0)
{
///
/// 我们作出区分之间HttpStaticRequest HttpPage的
///
string resourceFullName = resourcePaths[resourcePaths.Length - 1];
if (HttpHelper.IsStaticResource(resourceFullName))
{
request = HttpRequestType.HttpStaticRequest;
}
}
}
else throw new InvalidOperationException("Invalid Request : " + req.CompleteRequest); HTTP服务器软件系统的设计与实现(14):http://www.751com.cn/jisuanji/lunwen_3170.html