本文整理了Java中org.deegree.geometry.Geometry.isWithin()
方法的一些代码示例,展示了Geometry.isWithin()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Geometry.isWithin()
方法的具体详情如下:
包路径:org.deegree.geometry.Geometry
类名称:Geometry
方法名:isWithin
[英]tests whether the value of a geometric is topological located within this geometry. This method is the opposite of #contains(Geometry) method
[中]测试几何图形的值是否位于该几何图形中。此方法与#包含(几何)方法相反
代码示例来源:origin: deegree/deegree3
@Override
public boolean isWithin( Geometry geometry ) {
return getReferencedObject().isWithin( geometry );
}
代码示例来源:origin: deegree/deegree3
public <T> boolean evaluate( T obj, XPathEvaluator<T> xpathEvaluator )
throws FilterEvaluationException {
for ( TypedObjectNode paramValue : propName.evaluate( obj, xpathEvaluator ) ) {
Geometry geom = checkGeometryOrNull( paramValue );
if ( geom != null ) {
Geometry transformedLiteral = getCompatibleGeometry( geom, geometry );
return geom.isWithin( transformedLiteral );
}
}
return false;
}
代码示例来源:origin: deegree/deegree3
private void evaluateValidDomain( ICRS crs, Geometry geometry, String handle )
throws OWSException {
double[] validDomain = crs.getValidDomain();
if ( validDomain == null ) {
LOG.warn( "Valid domain of crs {} is not available. Check if geometry is inside the valid "
+ "domain not possible. The check is skipped and insert processed.", crs.getAlias() );
return;
}
Envelope validDomainBbox = GEOM_FACTORY.createEnvelope( validDomain[0], validDomain[1], validDomain[2],
validDomain[3], crs );
if ( !geometry.isWithin( validDomainBbox ) ) {
String message = "At least one geometry is not in the valid domain of the srs.";
if ( handle == null || "".equals( handle ) )
handle = "Transaction";
throw new OWSException( message, OWSException.OPERATION_PROCESSING_FAILED, handle );
}
}
内容来源于网络,如有侵权,请联系作者删除!