org.geotools.xsd.XSD.qName()方法的使用及代码示例

x33g5p2x  于2022-02-03 转载在 其他  
字(3.3k)|赞(0)|评价(0)|浏览(85)

本文整理了Java中org.geotools.xsd.XSD.qName()方法的一些代码示例,展示了XSD.qName()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XSD.qName()方法的具体详情如下:
包路径:org.geotools.xsd.XSD
类名称:XSD
方法名:qName

XSD.qName介绍

[英]Returns the qualified name for the specified local part.
[中]返回指定局部零件的限定名称。

代码示例

代码示例来源:origin: geotools/geotools

public static QName qName(String local) {
    return gml.qName(local);
  }
}

代码示例来源:origin: geotools/geotools

public Object GeometryPropertyType_getProperty(
    Geometry geometry, QName name, boolean includeAbstractGeometry, boolean makeEmpty) {
  if (name.equals(gml.qName("Point"))
      || name.equals(gml.qName("LineString"))
      || name.equals(gml.qName("Polygon"))
      || name.equals(gml.qName("MultiPoint"))
      || name.equals(gml.qName("MultiLineString"))
      || name.equals(gml.qName("MultiPolygon"))
      || name.equals(gml.qName("MultiSurface"))
      || name.equals(gml.qName("AbstractSurface"))
      || name.equals(gml.qName("_Surface"))
      || name.equals(gml.qName("_Curve"))
      || name.equals(gml.qName("AbstractCurve"))
      || name.equals(gml.qName("MultiCurve"))
      || (includeAbstractGeometry
          && (name.equals(gml.qName("_Geometry"))
              || name.equals(gml.qName("AbstractGeometry"))))) {

代码示例来源:origin: geotools/geotools

/**
 * Return the first XSD type definition found in the schema index for the provided GML types
 * names. NULL is returned if no XSD type definition is found.
 */
private XSDTypeDefinition searchType(SchemaIndex schemaIndex, String... typesNames) {
  for (String typeName : typesNames) {
    XSDTypeDefinition type = schemaIndex.getTypeDefinition(gml.qName(typeName));
    if (type != null) {
      // we found a matching XSD type
      return type;
    }
  }
  // no matching XSD type found
  LOGGER.fine(
      String.format(
          "No type definition found for types [%s].",
          Arrays.stream(typesNames).collect(Collectors.joining(", "))));
  return null;
}

代码示例来源:origin: geotools/geotools

protected FeatureCollectionEncoderDelegate(
    SimpleFeatureCollection features, Encoder encoder, GMLDelegate gml) {
  this.features = features;
  this.gml = gml;
  this.encoder = encoder;
  this.namespaces = encoder.getNamespaces();
  this.encoder = encoder;
  this.geometryEncoders = new HashMap<Class, GeometryEncoder>();
  this.boundedBy = gml.getSchema().qName("boundedBy");
  this.name = gml.getSchema().qName("name");
  gml.registerGeometryEncoders(geometryEncoders, encoder);
}

代码示例来源:origin: geotools/geotools

type.setName(featureType.getTypeName() + "Type");
type.setDerivationMethod(XSDDerivationMethod.EXTENSION_LITERAL);
type.setBaseTypeDefinition(schemaIndex.getTypeDefinition(gml.qName("AbstractFeatureType")));
    if (Point.class.isAssignableFrom(binding)) {
      element.setTypeDefinition(
          schemaIndex.getTypeDefinition(gml.qName("PointPropertyType")));
    } else if (LineString.class.isAssignableFrom(binding)) {
    } else if (MultiPoint.class.isAssignableFrom(binding)) {
      element.setTypeDefinition(
          schemaIndex.getTypeDefinition(gml.qName("MultiPointPropertyType")));
    } else if (MultiLineString.class.isAssignableFrom(binding)) {
    } else {
      element.setTypeDefinition(
          schemaIndex.getTypeDefinition(gml.qName("GeometryPropertyType")));

代码示例来源:origin: geotools/geotools

if (gml.qName("boundedBy")
    .equals(new QName(attribute.getTargetNamespace(), attribute.getName()))) {
  BoundingBox bounds = getBoundedBy(feature, configuration);

相关文章