You searched for exceptions
. We found 168
results in 0.053 seconds.
The answer lies in the documentation - emphasis mine: (A structural modification is any operation that adds or deletes one or more elements, or explicitly resizes the backing array; merely setting the value of an element is not a... more
Well, you're getting an EOFException because you're reading forever - you never change the value of done. The reason it's appearing in the middle of the text instead of at the end is that you're using System.err to print in the... more
This is the problem: pl.add(this); You're adding the same reference (this) again and again. The value of this is just a reference to the "current" object - and you're modifying the contents of that object in the loop. In each iteration... more
This line is the problem: var generic = methodInfo.MakeGenericMethod(toProp.GetType()); You're calling GetType() on toProp - that will return some type derived from PropertyInfo. You actually want the property type, so just change it... more
One option would be to wrap all but the doNormalThing method call in another method that returns whether or not to execute doNormalThing afterwards: void myMethod(String arg1) { if (myMethodInternal(arg1)) { doNormalThing(); ... more
Typically null objects aren't created on demand - instead, they're shared. They're typically immutable implementations of some other abstraction (with no-op methods or whatever is suitable) - so they can be shared very easily. At that... more
Okay, I think I see at least one potential problem (and definitely code to be avoided)... Every time you evaluate the AllDatabases property, you add all the files to the collection. Property fetches shouldn't do that - they shouldn't... more
How would I go about letting them execute in parallel and join the results as they complete? The simplest approach is just to create all the tasks and then await them: var task1 = myService.GetData(source1); var task2 =... more
If you want to be able to save the scores again, using getResourceAsStream isn't really a good idea - that's meant for resources which are bundled with the application, often within a jar file, and often read-only. You might want to... more
You're only actually populating a single array - and overwriting it every time you call getCol. So the values of cola1 and cola2 end up referring to the same array, whereas you want them to refer to different arrays. You should probably... more