use of net.opengis.ows.v_1_0_0.ServiceProvider in project ddf by codice.
the class TestCswEndpoint method verifyServiceProvider.
/**
* Helper method to verify the ServiceProvider section matches the endpoint's definition
*
* @param ct The CapabilitiesType to verify
*/
private void verifyServiceProvider(CapabilitiesType ct) {
ServiceProvider sp = ct.getServiceProvider();
assertThat(sp.getProviderName(), is(CswEndpoint.PROVIDER_NAME));
}
use of net.opengis.ows.v_1_0_0.ServiceProvider in project ddf by codice.
the class CswEndpoint method buildServiceProvider.
/**
* Creates the ServiceProvider portion of the GetCapabilities response TODO: Add more
* DDF-specific information if desired
*
* @return The constructed ServiceProvider object
*/
private ServiceProvider buildServiceProvider() {
ServiceProvider sp = new ServiceProvider();
sp.setProviderName(PROVIDER_NAME);
sp.setProviderSite(new OnlineResourceType());
sp.setServiceContact(new ResponsiblePartySubsetType());
return sp;
}
use of net.opengis.ows.v_1_0_0.ServiceProvider in project ddf by codice.
the class TestCswEndpoint method testGetCapabilitiesTypeServiceProvider.
@Test
public void testGetCapabilitiesTypeServiceProvider() {
// Should only return the ServiceProvider section
GetCapabilitiesType gct = createDefaultGetCapabilitiesType();
SectionsType stv = new SectionsType();
stv.setSection(Arrays.asList(CswEndpoint.SERVICE_PROVIDER));
gct.setSections(stv);
CapabilitiesType ct = null;
try {
ct = csw.getCapabilities(gct);
} catch (CswException e) {
fail("CswException caught during getCapabilities GET request: " + e.getMessage());
}
assertThat(ct, notNullValue());
verifyServiceProvider(ct);
verifyFilterCapabilities(ct);
assertThat(ct.getServiceIdentification(), nullValue());
assertThat(ct.getOperationsMetadata(), nullValue());
}
Aggregations