View Javadoc

1   package com.germinus.merlin.manager.layout;
2   
3   import javax.portlet.RenderRequest;
4   import javax.portlet.RenderResponse;
5   
6   import com.germinus.merlin.page.PagePortletConfiguration;
7   import com.liferay.portal.PortalException;
8   import com.liferay.portal.SystemException;
9   import com.liferay.portal.model.Layout;
10  
11  public interface ILayoutManager {
12  
13  	public static final long DEFAULT_PARENT_LAYOUT_ID = 0;
14  	
15  	/**
16  	 * 
17  	 * @param request
18  	 * @param response
19  	 * @param name
20  	 * @param pagePortletConfiguration
21  	 * @return
22  	 * @throws Exception
23  	 * @author David Jiménez, Germinus XXI
24  	 * @since 1.0
25  	 */
26  	public abstract long addPage(RenderRequest request, RenderResponse response,
27  			PagePortletConfiguration pagePortletConfiguration)
28  			throws Exception;
29  
30  	/**
31  	 * 
32  	 * @param request
33  	 * @param response
34  	 * @param portletId
35  	 * @return
36  	 * @throws Exception
37  	 */
38  	public abstract String addPortlet(RenderRequest request,
39  			RenderResponse response, String portletId) throws Exception;
40  
41  	/**
42  	 * 
43  	 * @param request
44  	 * @param response
45  	 * @return
46  	 * @throws Exception
47  	 */
48  	public abstract long addSubPage(RenderRequest request,
49  			RenderResponse response, 
50  			PagePortletConfiguration pagePortletConfiguration) throws Exception;
51  
52  	/**
53  	 * 
54  	 * @return
55  	 */
56  	public abstract int deletePage(long layoutId);
57  
58  	/**
59  	 * 
60  	 * @param layout
61  	 * @return
62  	 * @throws SystemException
63  	 * @throws PortalException
64  	 * @author David Jiménez, Germinus XXI
65  	 * @since 1.0
66  	 */
67  	@SuppressWarnings("unchecked")
68  	public abstract int listLayoutChildren(Layout layout)
69  			throws SystemException, PortalException;
70  	/**
71  	 * 
72  	 * @return
73  	 * @author David Jiménez, Germinus XXI
74  	 * @since 1.0
75  	 */
76  	public PagePortletConfiguration getPageProperties();
77  	
78  	/**
79  	 * 
80  	 * @param pageProperties
81  	 * @author David Jiménez, Germinus XXI
82  	 * @since 1.0
83  	 */
84  	public void setPageProperties(PagePortletConfiguration pageProperties);
85  }