|
Spring Framework example source code file (WelcomePortlet.java)
The Spring Framework WelcomePortlet.java source codepackage org.springframework.samples.petportal.portlet; import java.io.IOException; import java.io.PrintWriter; import java.util.Enumeration; import javax.portlet.GenericPortlet; import javax.portlet.PortletException; import javax.portlet.RenderRequest; import javax.portlet.RenderResponse; import javax.portlet.WindowState; /** * An example of a pre-existing JSR-168 compliant portlet which is used * in the demonstration of Spring's PortletWrappingController. View the * bean definitions in welcome-portlet.xml for details. * * @author John A. Lewis * @author Mark Fisher * @author Juergen Hoeller */ public class WelcomePortlet extends GenericPortlet { public void doView(RenderRequest request, RenderResponse response) throws PortletException, IOException { response.setContentType("text/html"); PrintWriter out = response.getWriter(); out.println("<h1>Welcome to the Pet Portal!"); if(request.getWindowState().equals(WindowState.MAXIMIZED)) { out.println("<p>This portlet delegates to an existing JSR-168 portlet via a HandlerAdapter"); out.println("<p>(see WEB-INF/context/welcome-context.xml for the details)."); out.println("<p>Portlet Name: " + this.getPortletName() + ""); out.println("<p>Init Parameters:
Other Spring Framework examples (source code examples)Here is a short list of links related to this Spring Framework WelcomePortlet.java source code file: |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.