Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement alterCSLinearUnit for CompoundCRS #3325

Merged
merged 1 commit into from
Sep 15, 2022

Conversation

jjimenezshaw
Copy link
Contributor

  • Tests added
  • Added clear title that can be used to generate release notes

For completeness, this PR implements alterCSLinearUnit for CompoundCRS, applying alterCSLinearUnit on every component.

auto crs =
createCompoundCRS()->alterCSLinearUnit(UnitOfMeasure("my unit", 2));
EXPECT_TRUE(createCompoundCRS()->isEquivalentTo(crs.get()));
auto compoundCRS = dynamic_cast<CompoundCRS *>(crs.get());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for the sake of completness, and test line 393 of crs.cpp, we'd need a test on a type of CRS that has no implementation of alterCSLinearUnit(). For example a temporal or parametric CRS

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

done

@jjimenezshaw jjimenezshaw force-pushed the alterCSLinearUnit-compound branch from dfa1ebe to a48a69e Compare September 14, 2022 22:30
@rouault rouault added this to the 9.2.0 milestone Sep 15, 2022
@rouault rouault merged commit cb29e99 into OSGeo:master Sep 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants