1 /* 2 * Copyright 2014 James Pether Sörling 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 * 16 * $Id$ 17 * $HeadURL$ 18 */ 19 package com.hack23.cia.web.impl.ui.application.views.common.gridfactory.api; 20 21 import com.hack23.cia.web.impl.ui.application.views.common.converters.ListPropertyConverter; 22 import com.hack23.cia.web.impl.ui.application.views.pageclicklistener.AbstractPageItemRendererClickListener; 23 import com.vaadin.data.Container.Indexed; 24 import com.vaadin.ui.AbstractOrderedLayout; 25 26 /** 27 * A factory for creating Grid objects. 28 */ 29 public interface GridFactory { 30 31 /** 32 * Creates a new Grid object. 33 * 34 * @param panelContent 35 * the panel content 36 * @param datasource 37 * the datasource 38 * @param caption 39 * the caption 40 * @param columnOrder 41 * the column order 42 * @param hideColumns 43 * the hide columns 44 * @param listener 45 * the listener 46 * @param actionId 47 * the action id 48 * @param collectionPropertyConverters 49 * the collection property converters 50 */ 51 void createBasicBeanItemGrid(AbstractOrderedLayout panelContent, Indexed datasource, String caption, Object[] columnOrder, 52 Object[] hideColumns, AbstractPageItemRendererClickListener<?> listener, String actionId, ListPropertyConverter[] collectionPropertyConverters); 53 54 /** 55 * Creates a new Grid object. 56 * 57 * @param panelContent 58 * the panel content 59 * @param datasource 60 * the datasource 61 * @param caption 62 * the caption 63 * @param nestedProperties 64 * the nested properties 65 * @param columnOrder 66 * the column order 67 * @param hideColumns 68 * the hide columns 69 * @param listener 70 * the listener 71 * @param actionId 72 * the action id 73 * @param collectionPropertyConverters 74 * the collection property converters 75 */ 76 void createBasicBeanItemNestedPropertiesGrid(AbstractOrderedLayout panelContent,Indexed datasource, String caption, String[] nestedProperties,Object[] columnOrder, Object[] hideColumns, 77 AbstractPageItemRendererClickListener<?> listener, String actionId, ListPropertyConverter[] collectionPropertyConverters); 78 79 }