Previous questions
1) In Singleton Design Pattern, synchronization is essential ?
Ans) In Singleton Design Pattern , synchronization is essential only for the first time when the instance is to be created. When the instance is created then it becomes an overhead for each request.
public class Singleton
{
private static Singleton uniqueinstance;
private Singleton()
{
}
public static Singleton getinstance()
{
if(uniqueinstance == null)
{
uniqueinstance = new Singleton();
}
return uniqueinstance;
}
}
In the above code, when for the first time getinstance method is called, synchronization is needed. After the first instance is created, we no longer need synchronization.
---------------------------------------------------
2) Tell me the exact difference between IQueryable and IEnumerable interface ?
Ans)
IEnumerable
---------------------------------------------------------
3)When a dynamic compilation of a website project is bad ?
Ans)
Dynamic compilation happens for a website project not for a web application project.
If the site is very large, dynamic compilation of a Web site project might take a noticeable amount of time. Dynamic compilation occurs when a request for a site resource is received after an update to the site, and the request that triggers compilation might be delayed while the required resources are compiled. If the delay is unacceptable, you can pre-compile the site. However, then some of the advantages of dynamic compilation are lost.
Previous questions
Previous questions
1) In Singleton Design Pattern, synchronization is essential ?
Ans) In Singleton Design Pattern , synchronization is essential only for the first time when the instance is to be created. When the instance is created then it becomes an overhead for each request.
public class Singleton
{
private static Singleton uniqueinstance;
private Singleton()
{
}
public static Singleton getinstance()
{
if(uniqueinstance == null)
{
uniqueinstance = new Singleton();
}
return uniqueinstance;
}
}
In the above code, when for the first time getinstance method is called, synchronization is needed. After the first instance is created, we no longer need synchronization.
---------------------------------------------------
2) Tell me the exact difference between IQueryable and IEnumerable interface ?
Ans)
IEnumerable
---------------------------------------------------------
3)When a dynamic compilation of a website project is bad ?
Ans)
Dynamic compilation happens for a website project not for a web application project.
If the site is very large, dynamic compilation of a Web site project might take a noticeable amount of time. Dynamic compilation occurs when a request for a site resource is received after an update to the site, and the request that triggers compilation might be delayed while the required resources are compiled. If the delay is unacceptable, you can pre-compile the site. However, then some of the advantages of dynamic compilation are lost.
Previous questions