forge44
JCHJava Community | Help. Code. Learn.
•Created by Jflash on 10/21/2024 in #java-help
having issues with Cannot invoke "java.util.ArrayList.size()" because "this.listOfMicronutrients" is
Since that’s how Reference Types work.
16 replies
JCHJava Community | Help. Code. Learn.
•Created by Jflash on 10/21/2024 in #java-help
having issues with Cannot invoke "java.util.ArrayList.size()" because "this.listOfMicronutrients" is
Or if both objects are set equal to one another, both will only reference the same object (or in this case null value) as long as one isn’t set to a new object using the new keyword (or set = to some other object), in which case they’ll no longer reference the same object.
16 replies
JCHJava Community | Help. Code. Learn.
•Created by Jflash on 10/21/2024 in #java-help
having issues with Cannot invoke "java.util.ArrayList.size()" because "this.listOfMicronutrients" is
But yea Kyo’s right
16 replies
JCHJava Community | Help. Code. Learn.
•Created by Jflash on 10/21/2024 in #java-help
having issues with Cannot invoke "java.util.ArrayList.size()" because "this.listOfMicronutrients" is
Are you familiar with how scope works? Initializing it in one class doesn’t mean you have access in another, even if they have the same name.. hard to glean much from a couple of screenshots.
16 replies
✅ Unit Testing in Rider not working
I think I downloaded Nuget before the issue happened, and manually added it into my windows path/environment variable, so I'm guessing that Rider was mistakenly using the wrong version of Nuget somehow or caused some issue I don't understand.
I'm re-adding it to my path/environment system variable to recreate the issue, and restarting Rider- weird, it still works, maybe that wasn't the issue.
Here's what I did before it was solved:
1. remove nuget from both path variables
2. (probably incorrect step): remove dotnet from both path variables
3. use command:
dotnet add package NUnit
from CMD, inside an NUnit project (the CMD might've been opened before removing dotnet from path, hence why the dotnet command worked)
Then it was solved even inside newly created Solutions.
I've been re-installing Rider a few times, maybe if I re-install Rider when Nuget is set in my environment variables it'll recreate the issue.
I don't know.91 replies