| /*=============================================================================# |
| # Copyright (c) 2012, 2021 Stephan Wahlbrink and others. |
| # |
| # This program and the accompanying materials are made available under the |
| # terms of the Eclipse Public License 2.0 which is available at |
| # https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 |
| # which is available at https://www.apache.org/licenses/LICENSE-2.0. |
| # |
| # SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 |
| # |
| # Contributors: |
| # Stephan Wahlbrink <sw@wahlbrink.eu> - initial API and implementation |
| #=============================================================================*/ |
| |
| package org.eclipse.statet.ecommons.waltable.grid.labeled; |
| |
| import org.eclipse.statet.ecommons.waltable.grid.GridRegion; |
| import org.eclipse.statet.ecommons.waltable.grid.layer.GridLayer; |
| import org.eclipse.statet.ecommons.waltable.layer.ILayer; |
| |
| |
| public class ExtGridLayer extends GridLayer { |
| |
| |
| public static final String EXT_COLUMN_HEADER= "EXT_" + GridRegion.COLUMN_HEADER; //$NON-NLS-1$ |
| public static final String EXT_ROW_HEADER= "EXT_" + GridRegion.ROW_HEADER; //$NON-NLS-1$ |
| |
| |
| public ExtGridLayer(final ILayer bodyLayer, final ILayer columnHeaderLayer, final ILayer rowHeaderLayer, final ILayer cornerLayer, final boolean useDefaultConfiguration) { |
| super(bodyLayer, columnHeaderLayer, rowHeaderLayer, cornerLayer, useDefaultConfiguration); |
| } |
| |
| |
| @Override |
| public void setColumnHeaderLayer(final ILayer columnHeaderLayer) { |
| setChildLayer(EXT_COLUMN_HEADER, columnHeaderLayer, 1, 0); |
| } |
| |
| @Override |
| public void setRowHeaderLayer(final ILayer rowHeaderLayer) { |
| setChildLayer(EXT_ROW_HEADER, rowHeaderLayer, 0, 1); |
| } |
| |
| } |