-
Notifications
You must be signed in to change notification settings - Fork 10
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Expose PDAL Mesh API * Make Native Autoclosable * Add CHANGELOG.md, fix codestyle to avoid syntax deprecated in Dotty * Update PDAL-Scala reader types * DSL expressions rename & DSL implicits reorganization * Update PDAL filters up to 2.0.0
- Loading branch information
Showing
45 changed files
with
4,438 additions
and
361 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,94 @@ | ||
# Changelog | ||
All notable changes to this project will be documented in this file. | ||
|
||
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | ||
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). | ||
|
||
## [Unreleased] | ||
|
||
## [2.1.2] - 2020-03-02 | ||
### Added | ||
- Expose PDAL Mesh API [#27](https://github.com/PDAL/java/pull/27) | ||
- [CHANGELOG](/CHANGELOG.md) | ||
|
||
### Changed | ||
- **Breaking change** // Rename Scala DSL case classes [#28](https://github.com/PDAL/java/issues/28) | ||
- **Breaking change** // Renamed dispose method to close [#27](https://github.com/PDAL/java/pull/27) | ||
- Update Scala DSL up to PDAL 2.0 [#29](https://github.com/PDAL/java/issues/29) | ||
|
||
## [2.0.0] - 2020-01-14 | ||
### Changed | ||
- PDAL 2.0 compatible release. | ||
- Added Scala 2.13 support. | ||
|
||
## [1.9.0] - 2019-05-15 | ||
### Changed | ||
- Release process improvements. | ||
|
||
## [1.8.6] - 2019-04-26 | ||
### Changed | ||
- Release process improvements. | ||
|
||
## [1.8.5] - 2019-04-15 | ||
### Changed | ||
- PDAL JNI Bindings thread safety [#19](https://github.com/PDAL/java/issues/19) | ||
|
||
### Fixed | ||
- PythonFilter gives invalid syntax [#9](https://github.com/PDAL/java/issues/9) | ||
- Option in filter.Python seems to be misspelled [#8](https://github.com/PDAL/java/issues/8) | ||
|
||
## [1.8.4] - 2019-04-09 | ||
### Changed | ||
- Make Exceptions Handling better [#17](https://github.com/PDAL/java/pull/17) | ||
|
||
## [1.8.3] - 2019-04-09 | ||
### Fixed | ||
- CSV files read issues [#15](https://github.com/PDAL/java/issues/15) | ||
|
||
## [1.8.2] - 2019-03-27 | ||
### Fixed | ||
- Fix dimName calls to be better, otherwise CSV reads wont work [#14](https://github.com/PDAL/java/pull/14) | ||
|
||
## [1.8.1] - 2019-03-25 | ||
### Changed | ||
- Update JTS to make it GeoTrellis compatible [#13](https://github.com/PDAL/java/pull/13) | ||
|
||
## [1.7.0-RC4] - 2019-01-14 | ||
### Changed | ||
- Scala version update up to 2.12.6. | ||
- Update dependencies and base PDAL version. | ||
- Release process improvements. | ||
|
||
### Fixed | ||
- Fix matlab reader ReaderType [#10](https://github.com/PDAL/java/pull/10) | ||
- Fix typo in GdalWrite [#11](https://github.com/PDAL/java/pull/11) | ||
|
||
## [1.7.0-RC3] - 2018-04-16 | ||
### Changed | ||
- Release process improvements. | ||
|
||
## [1.7.0-RC2] - 2018-04-15 | ||
### Added | ||
- An [examples](https://github.com/PDAL/java/tree/1.7.0-RC2/examples/pdal-jni) project. | ||
|
||
### Changed | ||
- Release process improvements. | ||
|
||
## [1.7.0-RC1] - 2018-04-15 | ||
### Changed | ||
- Moved from the PDAL repo and established own lifecycle. | ||
|
||
[Unreleased]: https://github.com/PDAL/java/compare/2.1.2...HEAD | ||
[2.1.2]: https://github.com/PDAL/java/compare/2.0.0...2.1.2 | ||
[2.0.0]: https://github.com/PDAL/java/compare/1.9.0...2.0.0 | ||
[1.9.0]: https://github.com/PDAL/java/compare/1.8.6...1.9.0 | ||
[1.8.6]: https://github.com/PDAL/java/compare/1.8.5...1.8.6 | ||
[1.8.5]: https://github.com/PDAL/java/compare/1.8.4...1.8.5 | ||
[1.8.4]: https://github.com/PDAL/java/compare/1.8.3...1.8.4 | ||
[1.8.3]: https://github.com/PDAL/java/compare/1.8.2...1.8.3 | ||
[1.8.2]: https://github.com/PDAL/java/compare/1.8.1...1.8.2 | ||
[1.8.1]: https://github.com/PDAL/java/compare/1.7.0-RC4...1.8.1 | ||
[1.7.0-RC4]: https://github.com/PDAL/java/compare/1.7.0-RC3...1.7.0-RC4 | ||
[1.7.0-RC3]: https://github.com/PDAL/java/compare/1.7.0-RC2...1.7.0-RC3 | ||
[1.7.0-RC2]: https://github.com/PDAL/java/compare/1.7.0-RC1...1.7.0-RC2 | ||
[1.7.0-RC1]: https://github.com/PDAL/java/compare/1.7.0-RC1...1.7.0-RC1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
55 changes: 55 additions & 0 deletions
55
core-scala/src/main/scala/io/pdal/pipeline/PipelineConstructor.scala
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,55 @@ | ||
/* | ||
* Copyright 2020 Azavea | ||
* | ||
* Licensed under the Apache License, Version 2.0 (the "License"); | ||
* you may not use this file except in compliance with the License. | ||
* You may obtain a copy of the License at | ||
* | ||
* http://www.apache.org/licenses/LICENSE-2.0 | ||
* | ||
* Unless required by applicable law or agreed to in writing, software | ||
* distributed under the License is distributed on an "AS IS" BASIS, | ||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
* See the License for the specific language governing permissions and | ||
* limitations under the License. | ||
*/ | ||
|
||
package io.pdal.pipeline | ||
|
||
import io.pdal.Pipeline | ||
|
||
import io.circe.{Decoder, Encoder, Json} | ||
import io.circe.syntax._ | ||
|
||
case class PipelineConstructor(list: List[PipelineExpr]) { | ||
def ~(e: PipelineExpr): PipelineConstructor = | ||
e match { | ||
case ENil => this | ||
case _ => PipelineConstructor(list :+ e) | ||
} | ||
def ~(e: Option[PipelineExpr]): PipelineConstructor = e.fold(this)(this ~ _) | ||
def map[B](f: PipelineExpr => B): List[B] = list.map(f) | ||
def toPipeline: Pipeline = Pipeline(this.asJson.noSpaces) | ||
} | ||
|
||
object PipelineConstructor { | ||
implicit val pipelineConstructorEncoder: Encoder[PipelineConstructor] = Encoder.instance { constructor => | ||
Json.obj( | ||
"pipeline" -> constructor.list.flatMap { | ||
_.list.flatMap { | ||
case RawExpr(json) => json.asObject | ||
case expr => expr.asJson.asObject | ||
}.map { | ||
_.remove("class_type") // remove type | ||
.filter { case (_, value) => !value.isNull } // cleanup options | ||
} | ||
}.asJson | ||
) | ||
} | ||
implicit val pipelineConstructorDecoder: Decoder[PipelineConstructor] = Decoder.instance { | ||
_.downField("pipeline").as[PipelineConstructor] | ||
} | ||
|
||
implicit def pipelineConstructorToJson(expr: PipelineConstructor): Json = expr.asJson | ||
implicit def pipelineConstructorToString(expr: PipelineConstructor): String = expr.asJson.noSpaces | ||
} |
Oops, something went wrong.