0
Les instances d'exception statique sont-elles sécurisées? Toute bonne raison d'éviter ce qui suit?Instance d'exception statique
public class ResourceHttpHandler : IHttpHandler
{
private static HttpException notFoundException =
new HttpException(
(int)HttpStatusCode.NotFound,
"Assembly Not Found");
public bool IsReusable
{
get { return true; }
}
public void ProcessRequest(HttpContext context)
{
....
throw notFoundException;
....
}
}
Merci, j'étais sûr qu'il y avait quelque chose de mal, je ne pouvais pas savoir ce que :) – Diadistis