Esri / Esri/geometry-api-java

Signatures of Point3D sub and mul does not match behavior of Point2D

未关闭
#77 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
主要语言
Java
星标
710
派生
269
平均合并
7 天 23 小时
30 天内合并 PR
1

描述

Point2D and Point3D should have the same behavior in use and in method signatures. For example, Point2D's sub method does a minus-equals on the coordinates, whereas Point3D's sub method returns a new object of the subtracted result:

public void sub(Point2D other) { x -= other.x; y -= other.y; }
public Point3D sub(Point3D other) { return new Point3D(x - other.x, y - other.y, z - other.z); }

This could lead to mistakes when coding against the api.

贡献指南

打开贡献指南

调研方向

首先定位 Point2D 和 Point3D,并比较 sub 和 mul 的声明与实现。检查现有调用方或测试,了解它们在变异与返回值方面的行为。完成的标准是两个点类型具有匹配的签名和一致的行为,并且已根据现有用法验证预期的 API 选择。

由索引模型根据 Issue 内容生成。

评估

技术栈
java
领域
api
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。