You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Matt Juntunen (Jira)" <ji...@apache.org> on 2019/12/03 16:24:00 UTC
[jira] [Commented] (GEOMETRY-63) Review "SonarQube" report
[ https://issues.apache.org/jira/browse/GEOMETRY-63?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16987054#comment-16987054 ]
Matt Juntunen commented on GEOMETRY-63:
---------------------------------------
Several of the "critical" code smells are related to my use of generic wildcard return types in the core interfaces. For example, {{SubHyperplane}} contains the following method:
{code:java}
List<? extends ConvexSubHyperplane<P>> toConvex();
{code}
I did this to allow implementation classes to return a list of actual implementation types instead of just {{ConvexSubHyperplane}}. For example, {{ConvexSubPlane}} overrides this method with
{code:java}
public List<ConvexSubPlane> toConvex(){ ... }
{code}
which allows callers immediate access to the convex implementation type without casting. However, I'm not sure how to achieve the same effect without the code smell. Any ideas?
> Review "SonarQube" report
> -------------------------
>
> Key: GEOMETRY-63
> URL: https://issues.apache.org/jira/browse/GEOMETRY-63
> Project: Apache Commons Geometry
> Issue Type: Task
> Reporter: Gilles Sadowski
> Priority: Major
> Labels: pull-request-available
> Time Spent: 20m
> Remaining Estimate: 0h
>
> https://sonarcloud.io/dashboard?id=commons-geometry
--
This message was sent by Atlassian Jira
(v8.3.4#803005)