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

Add emptyArray and newArray to KiwiReflection2 #276

Merged
merged 1 commit into from
Jun 15, 2023

Conversation

sleberknight
Copy link
Owner

These methods allow you to easily create an array of a given type without needing to cast. One creates an empty array while the other creates an array with a given length, and which contains only null values.

The javadocs and initial version of the tests were "written" by ChatGPT. I modified them slightly, and added a few more tests. For example, a ValueSource can be used instead of a MethodSource when there is only one test parameter. I also had to slightly correct the text in the throws explanations in the javadoc, plus I added additional text including the "see" references and the implNote text.

These methods allow you to easily create an array of a given type
without needing to cast. One creates an empty array while the other
creates an array with a given length, and which contains only null
values.

The javadocs and initial version of the tests were "written" by ChatGPT.
I modified them slightly, and added a few more tests. For example, a
ValueSource can be used instead of a MethodSource when there is only one
test parameter. I also had to slightly correct the text in the throws
explanations in the javadoc, plus I added additional text including the
"see" references and the implNote text.
@sleberknight sleberknight added the new feature A new feature such as a new class, method, package, group of classes, etc. label Jun 15, 2023
@sleberknight sleberknight added this to the 0.4.0 milestone Jun 15, 2023
@sleberknight sleberknight self-assigned this Jun 15, 2023
@sleberknight sleberknight requested a review from dsingley June 15, 2023 20:04
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

100.0% 100.0% Coverage
0.0% 0.0% Duplication

@github-actions
Copy link

Qodana

It seems all right 👌

No new problems found according to the checks applied
💡 Qodana analysis was run in the pull request mode: only the changed files were checked
☁️ View the detailed Qodana report

Contact Qodana team

Contact us at qodana-support@jetbrains.com

@sleberknight sleberknight merged commit 626c9c9 into main Jun 15, 2023
@sleberknight sleberknight deleted the add-emptyArray-methods-to-KiwiReflection2 branch June 15, 2023 20:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new feature A new feature such as a new class, method, package, group of classes, etc.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants