You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

GridStaticSectionState.java 1.8KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. /*
  2. * Copyright 2000-2022 Vaadin Ltd.
  3. *
  4. * Licensed under the Apache License, Version 2.0 (the "License"); you may not
  5. * use this file except in compliance with the License. You may obtain a copy of
  6. * 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, WITHOUT
  12. * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
  13. * License for the specific language governing permissions and limitations under
  14. * the License.
  15. */
  16. package com.vaadin.v7.shared.ui.grid;
  17. import java.io.Serializable;
  18. import java.util.ArrayList;
  19. import java.util.HashMap;
  20. import java.util.List;
  21. import java.util.Map;
  22. import java.util.Set;
  23. import com.vaadin.shared.Connector;
  24. /**
  25. * Shared state for Grid headers and footers.
  26. *
  27. * @since 7.4
  28. * @author Vaadin Ltd
  29. */
  30. public class GridStaticSectionState implements Serializable {
  31. public static class CellState implements Serializable {
  32. public String text = "";
  33. public String html = "";
  34. public Connector connector = null;
  35. public GridStaticCellType type = GridStaticCellType.TEXT;
  36. public String columnId;
  37. public String styleName = null;
  38. }
  39. public static class RowState implements Serializable {
  40. public List<CellState> cells = new ArrayList<CellState>();
  41. public boolean defaultRow = false;
  42. /**
  43. * Map from column id set to cell state for merged state.
  44. */
  45. public Map<Set<String>, CellState> cellGroups = new HashMap<Set<String>, CellState>();
  46. /**
  47. * The style name for the row. Null if none.
  48. */
  49. public String styleName = null;
  50. }
  51. public List<RowState> rows = new ArrayList<RowState>();
  52. public boolean visible = true;
  53. }