Commit Graph

29 Commits

Author SHA1 Message Date
Jens Schauder
38f50e3da8 Remove Eclipse Non-Javadoc comments.
Closes #2522
2022-01-13 18:51:02 +01:00
Mark Paluch
c735b58607 Migrate code to Java 17 style.
Use var instead of explicit local types where applicable. Use pattern variable instead instanceof and cast. Prefer loops and nullable types over Stream and Optional. Convert classes to records where applicable.

See #2465
2022-01-13 18:49:07 +01:00
Mark Paluch
9fbf39154f Fix Javadoc.
Fix invalid links. Replace Javadoc links to JSR-305 with code annotations.

Replace self-enclosing tags with simple ones.

See #2423
2021-09-21 11:11:30 +02:00
Mark Paluch
c24ba262ca Polishing.
Use Spring's nullability annotations where used as part of API nullability indicators.

See #2385
2021-06-17 09:03:00 +02:00
Mark Paluch
8bd2f9bf34 Update copyright year to 2021.
Closes #2268.
2021-01-07 13:42:27 +01:00
Mark Paluch
4be5aae181 DATACMNS-1726 - Delombok source files. 2020-05-15 08:46:58 +02:00
Mark Paluch
eed7658ce5 DATACMNS-1643 - Update copyright years to 2020. 2020-01-07 08:32:25 +01:00
Spring Operator
48c9297118 DATACMNS-1500 - URL Cleanup.
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* [ ] http://www.apache.org/licenses/ with 1 occurrences migrated to:
  https://www.apache.org/licenses/ ([https](https://www.apache.org/licenses/) result 200).
* [ ] http://www.apache.org/licenses/LICENSE-2.0 with 701 occurrences migrated to:
  https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200).

Original Pull Request: #387
2019-03-22 11:00:44 +01:00
Mark Paluch
1969f4bcdc DATACMNS-1459 - Update copyright years to 2019. 2019-01-02 12:12:19 +01:00
Mark Paluch
4d9329fab8 DATACMNS-1249 - Fix line endings to LF. 2018-01-24 12:32:29 +01:00
Mark Paluch
51e7e1b7f5 DATACMNS-1240 - Update copyright years to 2018.
Also, remove some trailing whitespaces and align outdated license header format.
2018-01-08 16:04:34 +01:00
Oliver Gierke
049970874d DATACMNS-1114 - Introduced usage of nullable annotations for API validation.
Marked all packages with Spring Frameworks @NonNullApi. Added Spring's @Nullable to methods, parameters and fields that take or produce null values. Adapted using code to make sure the IDE can evaluate the null flow properly. Fixed Javadoc in places where an invalid null handling policy was advertised. Strengthened null requirements for types that expose null-instances.

Removed null handling from converters for JodaTime and ThreeTenBP. Introduced factory methods Page.empty() and Page.empty(Pageable). Introduced default methods getRequiredGetter(), …Setter() and …Field() on PersistentProperty to allow non-nullable lookups of members. The same for TypeInformation.getrequiredActualType(), …SuperTypeInformation().

Tweaked PersistentPropertyCreator.addPropertiesForRemainingDescriptors() to filter unsuitable PropertyDescriptors before actually trying to create a Property instance from them as the new stronger nullability requirements would cause exceptions downstream.

Lazy.get() now expects a non-null return value. Clients being able to cope with null need to call ….orElse(…).

Original pull request: #232.
2017-07-24 10:47:28 +02:00
Oliver Gierke
d9b16d8a27 DATACMNS-1085 - Fixed typos in Javadoc.
Original pull request: #229.
2017-07-24 10:32:19 +02:00
Christoph Strobl
be347eaaab DATACMNS-867 - Additional Java 8 language feature cleanup.
Make use of lambdas and method references though out the codebase. Remove no longer required generic type parameters.
Additionally remove unused imports and replace single element list initialization with dedicated singletonList.
Use Assertion overloads taking Supplier for dynamic assertion error messages.
2017-03-24 08:00:43 +01:00
Oliver Gierke
d4811e29d9 DATACMNS-867 - Second draft. 2017-03-24 08:00:23 +01:00
Christoph Strobl
3e048a6dca DATACMNS-985 - Remove references to single-argument assertion methods. 2017-01-31 18:10:40 +01:00
Oliver Gierke
71fdf8646e DATACMNS-826 - Fixed JavaDoc for GeoModule. 2016-03-15 13:20:24 +01:00
David Syer
a597549c4e DATACMNS-736 - Fixed validation error message in PointFormatter.
PointFormatter error message now states it's expecting comma separated values. Previously it erroneously reported expecting a semicolon.

Original pull request: #134.
2015-07-21 16:52:44 +02:00
Thomas Darimont
6f7d8489bf DATACMNS-654 - Polishing.
Added missing documentation for geospatial return types.
Fixed typo in GeoResult JavaDoc.
2015-03-23 11:13:36 +01:00
Oliver Gierke
2d75cf2c43 DATACMNS-651 - Introduced a Range value type.
Primarily intended to be used with Distance instances, we introduce a Range value type. Distance now has factory methods to create Range instances between two distances. To support this, Distance now implements comparable based on the normalized value of it.

Tiny refactoring in TypeDiscoverer to avoid code duplication between the lookup of parameter type information for constructors and methods.
2015-03-04 17:34:32 +01:00
Oliver Gierke
23cad97b9a DATACMNS-626 - Added formatters for Point and Distance.
Ported Spring Data REST's converters for Distance and Point and turned them into Formatter instances. Extended Metric interface to return an abbreviation. Added getUnit() to Distance and tweaked Jackson setup to ignore the additional property.

We now automatically register the news introduced Formatters when using @EnableSpringDataWebSupport so that Point and Distance values can be parsed and printed from and to Strings out of the box.
2015-01-04 16:42:05 +01:00
Oliver Gierke
e1b38faee9 DATACMNS-601 - Fixes for most of the SonarQube warnings. 2014-11-26 09:25:14 +01:00
Thomas Darimont
a30068c02d DATACMNS-482 - Added serialization support for Geospatial Types.
Added Serializable marker interface to Shape to make all geospatial types serializable. Changed equals implementation in GeoResults to use equals(…) instead of reference equality.

Original pull request: #77.
2014-03-31 11:42:03 +02:00
Thomas Darimont
b882d33d7b DATACMNS-474 - Allow conversion of Distance into other Metrics.
Added support for distance conversion via Distance.in(Metric).
2014-03-21 13:42:40 +01:00
Oliver Gierke
176be042c9 DATACMNS-475 - Added Jackson 2 module to (de)serialize new geo types.
Newly introduced GeoModule contains mixins for Distance, Point, Circle, Box and Polygon.
2014-03-21 13:36:15 +01:00
Thomas Darimont
f6348a1bbe DATACMNS-437 - String representations should be locale independent.
We now use a fixed english locale for the rendering of toString() representations of Point objects.
2014-03-10 08:21:44 +01:00
Oliver Gierke
4c5012f637 DATACMNS-437 - Polishing of newly introduced geo value objects.
Polished JavaDoc. Simplified equals(…) and hashCode() methods where possible. Added additional null checks where appropriate. Removed obsolete generics in Polygon and switched to an immutable collection for the Points making up the Polygon. Added missing toString() method to Polygon.
Added test cases for String representations.

Related pull request: #68.
2014-03-07 10:22:37 +01:00
Oliver Gierke
94db475afe DATACMNS-437 - Polishing of newly introduced geo value objects.
Polished JavaDoc. Simplified equals(…) and hashCode() methods where possible. Added additional null checks where appropriate. Removed obsolete generics in Polygon and switched to an immutable collection for the Points making up the Polygon.

Related pull request: #68.
2014-03-07 08:59:58 +01:00
Thomas Darimont
e4dfda29a3 DATACMNS-437 - Introduce reusable value objects for geo concepts.
Moved and retro-fitted the basic geo structures from SD MongoDB into SD Commons. This will serve as the foundation for more reusable geo spatial functionality in other SD modules. 

Adjusted equals methods to support subtypes in other SD modules. Added convenience constructor to Polygon. Renamed spanning points of Box to be first and second because some stores could have a different meaning of the spanning points. Changed radius field of circle to be a Distance (value + metric). Added additional mitigation constructor to Circle.

Original pull request: #68.
2014-03-07 08:59:23 +01:00