@Override public AttributionInfo getAttribution() { return delegate.getAttribution(); }
result = prime * result + ((lg.getAttribution() == null) ? 0 : lg.getAttribution().hashCode()); result = prime * result
} else if (!lg.getRootLayerStyle().equals(other.getRootLayerStyle())) return false; if (lg.getAttribution() == null) { if (other.getAttribution() != null) return false; } else if (!lg.getAttribution().equals(other.getAttribution())) return false;
@Test public void testLoadNestedLayerGroups() throws Exception { GeoServerResourceLoader resources = GeoServerExtensions.bean(GeoServerResourceLoader.class); assertSame(catalog.getResourceLoader(), resources); loader.readCatalog(catalog, xp); LayerGroupInfo simpleLayerGroup = catalog.getLayerGroupByName("topp", "simplegroup"); assertNotNull(simpleLayerGroup); assertEquals(101, simpleLayerGroup.getAttribution().getLogoWidth()); assertEquals(102, simpleLayerGroup.getAttribution().getLogoHeight()); assertEquals(2, simpleLayerGroup.getMetadataLinks().size()); assertEquals( "http://my/metadata/link/1", simpleLayerGroup.getMetadataLinks().get(0).getContent()); assertEquals("text/html", simpleLayerGroup.getMetadataLinks().get(0).getType()); LayerGroupInfo nestedLayerGroup = catalog.getLayerGroupByName("topp", "nestedgroup"); assertNotNull(nestedLayerGroup); assertNotNull(nestedLayerGroup.getLayers()); assertEquals(2, nestedLayerGroup.getLayers().size()); assertTrue(nestedLayerGroup.getLayers().get(0) instanceof LayerGroupInfo); assertNotNull(((LayerGroupInfo) nestedLayerGroup.getLayers().get(0)).getLayers()); assertTrue(nestedLayerGroup.getLayers().get(1) instanceof LayerInfo); }
assertEquals("polygon", lg.getStyles().get(0).getName()); assertEquals("line", lg.getStyles().get(1).getName()); assertEquals(101, lg.getAttribution().getLogoWidth()); assertEquals(102, lg.getAttribution().getLogoHeight()); assertEquals(2, lg.getMetadataLinks().size());
builder.calculateLayerGroupBounds(lg, CRS.decode("EPSG:4326")); lg.setAttribution(getCatalog().getFactory().createAttribution()); lg.getAttribution().setTitle("My Attribution"); MetadataLinkInfo info = getCatalog().getFactory().createMetadataLink(); info.setType("text/html");
builder.calculateLayerGroupBounds(lg, CRS.decode("EPSG:4326")); lg.setAttribution(getCatalog().getFactory().createAttribution()); lg.getAttribution().setTitle("My Attribution"); MetadataLinkInfo info = getCatalog().getFactory().createMetadataLink(); info.setType("text/html");