001/* 002 * (C) Copyright 2011 Nuxeo SA (http://nuxeo.com/) and others. 003 * 004 * Licensed under the Apache License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.apache.org/licenses/LICENSE-2.0 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 * 016 * Contributors: 017 * Anahide Tchertchian 018 */ 019 020package org.nuxeo.ecm.platform.contentview.jsf; 021 022import java.io.Serializable; 023import java.util.List; 024 025import org.nuxeo.ecm.core.api.DocumentModel; 026import org.nuxeo.ecm.core.api.SortInfo; 027 028/** 029 * Implementations of this interface represent a content view state that can be used to restore a given content view. 030 * <p> 031 * State is restricted to given getters and setters. Some state information is actually taken on the page provider. 032 * 033 * @since 5.4.2 034 */ 035public interface ContentViewState extends Serializable { 036 037 String getContentViewName(); 038 039 void setContentViewName(String contentViewName); 040 041 Long getPageSize(); 042 043 void setPageSize(Long pageSize); 044 045 Long getCurrentPage(); 046 047 void setCurrentPage(Long currentPage); 048 049 Object[] getQueryParameters(); 050 051 void setQueryParameters(Object[] parameters); 052 053 DocumentModel getSearchDocumentModel(); 054 055 void setSearchDocumentModel(DocumentModel searchDocument); 056 057 List<SortInfo> getSortInfos(); 058 059 void setSortInfos(List<SortInfo> sortInfos); 060 061 ContentViewLayout getResultLayout(); 062 063 void setResultLayout(ContentViewLayout resultLayout); 064 065 List<String> getResultColumns(); 066 067 void setResultColumns(List<String> resultColumns); 068 069 /** 070 * @since 7.1 071 */ 072 String getPageProviderName(); 073 074 /** 075 * @since 7.1 076 */ 077 void setPageProviderName(String name); 078 079 /** 080 * @since 8.1 081 */ 082 void setExecuted(boolean executed); 083 084 /** 085 * @since 8.1 086 */ 087 boolean isExecuted(); 088 089}