Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How many ways are available to ger RequestDispatcher object?

Answers were Sorted based on User's Feedback



How many ways are available to ger RequestDispatcher object?..

Answer / vijay

by two ways we can get the RequestDispatcher object.

1) by using ServletContext.getRequestDispatcher().
2)by using HttpServletRquest.getRequestDispatcher().this
method inherted from ServletRequest.

Is This Answer Correct ?    24 Yes 4 No

How many ways are available to ger RequestDispatcher object?..

Answer / rice

There are two ways to get RequestDispatcher object in the
servlet.

1. calling the getRequestDispatcher(String path) method on
ServletRequest.

RequestDispatcher rd=request.getRequestDispatcher(String path);


2. By getRequRequestDispatcher(String path) method on
ServletContext.

RequestDispatcher rd=context.getRequestDispatcher(String path);

Is This Answer Correct ?    17 Yes 0 No

How many ways are available to ger RequestDispatcher object?..

Answer / seshendra

There are three ways to get RequestDispatcher object in the
servlet.

1. calling the getRequestDispatcher(String path) method on
ServletRequest.

RequestDispatcher rd=request.getRequestDispatcher(String path);


2. By getRequRequestDispatcher(String path) method on
ServletContext.

RequestDispatcher rd=context.getRequestDispatcher(String path);

3.by calling getNamedDispatcher(servlet logical name)on
ServletContext object


RequestDispatcher rd=context.getNamedDispatcher(servlet
logical name)

Is This Answer Correct ?    15 Yes 0 No

How many ways are available to ger RequestDispatcher object?..

Answer / venkat

there are two ways.


RequestDispatcher rd=req.getRequestDispatcher("\a.jsp");

RequestDispatcher rd=sc.getRequestDispatcher("\a.jsp");

Is This Answer Correct ?    3 Yes 0 No

Post New Answer

More Servlets Interview Questions

Is classes folder is compulsory in web-inf/ even though u r deploying ur application with war file?

3 Answers   Bosch, Cognizant,


Difference between httpservlet and generic servlets?

0 Answers  


Explain request dispatcher and its methods.

0 Answers  


Differentiate between the print writer and servlet output stream?

0 Answers  


What is the difference between the include() and forward() methods?

0 Answers  


What is a servlet engine?

0 Answers  


Can a jsp be called using a servlet?

0 Answers  


Can we call destroy() method inside the init() method? What happens when we do so?

9 Answers   Ericsson,


program for RequestDispatcher in servlets?

3 Answers   Wipro,


Can a servlet be called by passing its name as a parameter in the URL?

1 Answers   iFlex,


What happens, if server sends a cookie to a browser that doesn't supports cookies?

2 Answers  


What is ServletContext() and what is its use?

9 Answers   Prime Technology, TCS,


Categories