Page 1 of 1

About Question enthuware.jwpv6.2.641 :

Posted: Sat Apr 06, 2013 2:13 am
by koitoer
I'm partially agree with the response, but I think in most of the cases you will have javax.servlet.ServletRegistration.Dynamic obtained via ServletContext, on this interface you have method for configure async support, as this interface implements Registration.Dynamic interface.

So I think javax.servlet.Registration.Dynamic and javax.servlet.ServletRegistration.Dynamic are valid, also if you are talking about configure async support on servlet, ServletRegistration.Dynamic looks like better option. Just my comment. XD

Re: About Question enthuware.jwpv6.2.641 :

Posted: Sat Apr 06, 2013 6:17 am
by admin
The setAsyncSupported method is declared in Registration.Dynamic so this is the only required interface for this purpose. Yes, ServletRegistration.Dynamic can also be used but not required.

HTH,
Paul.

Re: About Question enthuware.jwpv6.2.641 :

Posted: Fri Jan 20, 2017 2:17 pm
by manoj6992
javax.servlet.ServletRegistration extends javax.servlet.Registration: Provides addMapping and addMappings
All Known Subinterfaces: ServletRegistration.Dynamic
Looks like the above explanation provided is wrong.
I don't find any addMappings() for javax.servlet.ServletRegistration Interface.

Below is what I found (ref: http://docs.oracle.com/javaee/6/api/jav ... ation.html)
==================================================================
addMapping(java.lang.String... urlPatterns)
getMappings()
getRunAsRole()

Can you please confirm.

Regards,
Manoj

Re: About Question enthuware.jwpv6.2.641 :

Posted: Fri Jan 20, 2017 10:44 pm
by admin
You are right, it should be getMappings. Fixed.
thank you for your feedback!
Paul.