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


Java MultiLineString.getLineStrings方法代码示例

本文整理汇总了Java中mil.nga.wkb.geom.MultiLineString.getLineStrings方法的典型用法代码示例。如果您正苦于以下问题:Java MultiLineString.getLineStrings方法的具体用法?Java MultiLineString.getLineStrings怎么用?Java MultiLineString.getLineStrings使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在mil.nga.wkb.geom.MultiLineString的用法示例。


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

示例1: convertMultiLineString

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Test the MultiLineString conversion
 * 
 * @param converter
 * @param multiLineString
 */
private static void convertMultiLineString(
		GoogleMapShapeConverter converter, MultiLineString multiLineString) {

	MultiPolylineOptions polylines = converter.toPolylines(multiLineString);
	TestCase.assertNotNull(polylines);
	TestCase.assertFalse(polylines.getPolylineOptions().isEmpty());

	List<LineString> lineStrings = multiLineString.getLineStrings();
	compareLineStringsAndPolylines(converter, lineStrings,
			polylines.getPolylineOptions());

	MultiLineString multiLineString2 = converter
			.toMultiLineStringFromOptions(polylines);
	compareLineStrings(lineStrings, multiLineString2.getLineStrings());
}
 
开发者ID:ngageoint,项目名称:geopackage-android-map,代码行数:22,代码来源:GoogleMapShapeConverterUtils.java

示例2: toPolylines

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Convert a {@link MultiLineString} to a {@link MultiPolylineOptions}
 *
 * @param multiLineString
 * @return
 */
public MultiPolylineOptions toPolylines(MultiLineString multiLineString) {

    MultiPolylineOptions polylines = new MultiPolylineOptions();

    for (LineString lineString : multiLineString.getLineStrings()) {
        PolylineOptions polyline = toPolyline(lineString);
        polylines.add(polyline);
    }

    return polylines;
}
 
开发者ID:ngageoint,项目名称:geopackage-android-map,代码行数:18,代码来源:GoogleMapShapeConverter.java

示例3: validateMultiLineString

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Validate Multi Line String
 * 
 * @param topGeometry
 * @param multiLineString
 */
private static void validateMultiLineString(Geometry topGeometry,
		MultiLineString multiLineString) {

	TestCase.assertEquals(GeometryType.MULTILINESTRING,
			multiLineString.getGeometryType());

	validateZAndM(topGeometry, multiLineString);

	for (LineString lineString : multiLineString.getLineStrings()) {
		validateLineString(topGeometry, lineString);
	}

}
 
开发者ID:ngageoint,项目名称:geopackage-android,代码行数:20,代码来源:FeatureUtils.java

示例4: transform

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Transform the projected multi line string
 * 
 * @param multiLineString
 * @return projected multi line string
 */
public MultiLineString transform(MultiLineString multiLineString) {

	MultiLineString to = new MultiLineString(multiLineString.hasZ(),
			multiLineString.hasM());

	for (LineString lineString : multiLineString.getLineStrings()) {
		LineString toLineString = transform(lineString);
		to.addLineString(toLineString);
	}

	return to;
}
 
开发者ID:ngageoint,项目名称:geopackage-core-java,代码行数:19,代码来源:GeometryProjectionTransform.java

示例5: addMultiLineStringMessage

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Add MultiLineString
 * 
 * @param envelope
 * @param multiLineString
 */
private static void addMultiLineStringMessage(GeometryEnvelope envelope,
		MultiLineString multiLineString) {

	updateHasZandM(envelope, multiLineString);

	List<LineString> lineStrings = multiLineString.getLineStrings();
	for (LineString lineString : lineStrings) {
		addLineStringMessage(envelope, lineString);
	}
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:17,代码来源:GeometryEnvelopeBuilder.java

示例6: addMultiLineStringMessage

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Add MultiLineString message
 * 
 * @param message
 * @param multiLineString
 */
private static void addMultiLineStringMessage(StringBuilder message,
		MultiLineString multiLineString) {
	message.append(LineString.class.getSimpleName() + "s: "
			+ multiLineString.numLineStrings());
	List<LineString> lineStrings = multiLineString.getLineStrings();
	for (int i = 0; i < lineStrings.size(); i++) {
		LineString lineString = lineStrings.get(i);
		message.append("\n\n");
		message.append(LineString.class.getSimpleName() + " " + (i + 1));
		message.append("\n");
		addLineStringMessage(message, lineString);
	}
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:20,代码来源:GeometryPrinter.java

示例7: getMultiLineString

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Get MultiLineString object
 * 
 * @param multiLineString
 * @return multi line string object
 */
private static Object getMultiLineString(MultiLineString multiLineString) {
	List<Object> jsonObject = new ArrayList<>();
	List<LineString> lineStrings = multiLineString.getLineStrings();
	for (int i = 0; i < lineStrings.size(); i++) {
		LineString lineString = lineStrings.get(i);
		jsonObject.add(getLineString(lineString));
	}
	return jsonObject;
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:16,代码来源:GeometryJSONCompatible.java

示例8: writeMultiLineString

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Write a Multi Line String
 * 
 * @param writer
 * @param multiLineString
 * @throws IOException
 */
public static void writeMultiLineString(ByteWriter writer,
		MultiLineString multiLineString) throws IOException {

	writer.writeInt(multiLineString.numLineStrings());

	for (LineString lineString : multiLineString.getLineStrings()) {
		writeGeometry(writer, lineString);
	}
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:17,代码来源:WkbGeometryWriter.java

示例9: toPolylines

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Convert a {@link MultiLineString} to a {@link MultiPolylineOptions}
 *
 * @param multiLineString
 * @return
 */
public List<Polyline> toPolylines(MultiLineString multiLineString) {

    List<Polyline> lines = new ArrayList<>();

    for (LineString lineString : multiLineString.getLineStrings()) {
        Polyline polyline = toPolyline(lineString);
        lines.add(polyline);
    }

    return lines;
}
 
开发者ID:osmdroid,项目名称:osmdroid,代码行数:18,代码来源:OsmMapShapeConverter.java

示例10: minimize

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Minimize the multi line string
 * 
 * @param multiLineString
 *            multi line string
 * @param maxX
 *            max positive x value in the geometry projection
 */
private static void minimize(MultiLineString multiLineString, double maxX) {

	List<LineString> lineStrings = multiLineString.getLineStrings();
	for (LineString lineString : lineStrings) {
		minimize(lineString, maxX);
	}
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:16,代码来源:GeometryUtils.java

示例11: normalize

import mil.nga.wkb.geom.MultiLineString; //导入方法依赖的package包/类
/**
 * Normalize the multi line string
 * 
 * @param multiLineString
 *            multi line string
 * @param maxX
 *            max positive x value in the geometry projection
 */
private static void normalize(MultiLineString multiLineString, double maxX) {

	List<LineString> lineStrings = multiLineString.getLineStrings();
	for (LineString lineString : lineStrings) {
		normalize(lineString, maxX);
	}
}
 
开发者ID:ngageoint,项目名称:geopackage-wkb-java,代码行数:16,代码来源:GeometryUtils.java


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