当前位置: 首页>>代码示例>>Java>>正文


Java ProcessPropertyType类代码示例

本文整理汇总了Java中net.opengis.om.x10.ProcessPropertyType的典型用法代码示例。如果您正苦于以下问题:Java ProcessPropertyType类的具体用法?Java ProcessPropertyType怎么用?Java ProcessPropertyType使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


ProcessPropertyType类属于net.opengis.om.x10包,在下文中一共展示了ProcessPropertyType类的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: testGetObservationIoosSweEncoding

import net.opengis.om.x10.ProcessPropertyType; //导入依赖的package包/类
@Test
public void testGetObservationIoosSweEncoding() throws OwsExceptionReport, XmlException {
    XmlObject getObsResponse = sendGetObservation1RequestViaPox(NETWORK_OFFERING, IoosSosConstants.OM_PROFILE_M10,
            ImmutableList.of(STATION_ASSET.getAssetId()), ImmutableList.of(OBS_PROP),null).asXmlObject();
    assertNotNull(getObsResponse);
    assertThat(getObsResponse, is(instanceOf(ObservationCollectionDocument.class)));
    ObservationCollectionDocument obsCollectionDoc = (ObservationCollectionDocument) getObsResponse;
    ObservationCollectionType obsCollection = obsCollectionDoc.getObservationCollection();

    //TODO verify
    BoundingShapeType boundedBy = obsCollection.getBoundedBy();

    //TODO verify
    LocationPropertyType location = obsCollection.getLocation();

    assertThat(obsCollection.getMemberArray().length, is(1));
    ObservationPropertyType observationProperty = obsCollection.getMemberArray()[0];
    ObservationType observation = observationProperty.getObservation();
    assertThat(observation, notNullValue());

    //TODO verify
    FeaturePropertyType featureOfInterest = observation.getFeatureOfInterest();
    AbstractFeatureType feature = featureOfInterest.getFeature();

    //TODO verify
    ProcessPropertyType procedure = observation.getProcedure();
    AbstractProcessType process = procedure.getProcess();

    XmlObject result = observation.getResult();
    assertThat(result, notNullValue());

    //TODO verify
    DataRecordDocument swe2DataRecordDocument = castXmlAnyToClass(result, DataRecordDocument.class);
    DataRecordType swe2DataRecord = swe2DataRecordDocument.getDataRecord();

    //observationRecord definition
    assertThat(swe2DataRecord.getDefinition(), is(IoosSweConstants.OBSERVATION_RECORD_DEF));

    Field[] fields = swe2DataRecord.getFieldArray();
    Field stationsField = fields[0];
    assertThat(stationsField.getName(), is(IoosSweConstants.STATIONS));

    AbstractDataComponentType stationsAbstractDataComponent = stationsField.getAbstractDataComponent();
    assertThat(stationsAbstractDataComponent, is(instanceOf(DataRecordType.class)));
    DataRecordType stationsDataRecord = (DataRecordType) stationsAbstractDataComponent;
    assertThat(stationsDataRecord.getDefinition(), is(IoosSweConstants.STATIONS_DEF));
}
 
开发者ID:ioos,项目名称:i52n-sos,代码行数:48,代码来源:IoosGetObservationIntegrationTest.java


注:本文中的net.opengis.om.x10.ProcessPropertyType类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。