Browsing 7239 questions and answers with Jon Skeet
Firstly, this doesn't sound like the right thing to do in a JSON converter. If you're accepting user input directly in your JSON, that should be treated as a string, and parsed later, IMO. JSON is a machine-to-machine format, not a... more 9/7/2016 6:04:16 AM
I would strongly recommend that you refactor your database to be more amenable to querying - you don't want to be having to parse the string values for every row, on every query. Additionally, you can add an extra field to indicate that... more 9/6/2016 1:36:45 PM
This is nearly an ISO-8601 formatted date/time, but not quite... the UTC offset doesn't have a colon in it. It looks like Chrome and Firefox aren't being quite as picky with their ISO-8601 parsing as IE. If you change the code to: new... more 9/6/2016 10:40:35 AM
A mixture of oversight and avoiding massive overloading, basically. It would certainly make logical sense to have such a constructor in LocalDateTime. ZonedDateTime and OffsetDateTime don't have constructors accepting individual... more 9/6/2016 6:48:16 AM
This local value: datetime(2016,10,30,2,0,0) is ambiguous. 2am happens twice on October 30th 2016 in Berlin - once at 2016-10-30T00:00:00Z (with a UTC offset of +2), then once again at 2016-10-30T01:00:00Z (with a UTC offset of... more 9/5/2016 2:46:41 PM
Suppose you have a variable o referring to an instance of Outer, and you want to create an instance of Inner with its enclosing instance being the value of o. You could call: Outer.Inner inner = o.new Outer.Inner(); It's rarely seen in... more 9/5/2016 11:57:24 AM
Well Noda Time doesn't have any kind of server-based functionality - and even if it did, that would be likely to be NTP. Matt Johnson has a separate NodaTime.NetworkClock package, which is an IClock implementation for NTP. Now, does your... more 9/5/2016 6:00:25 AM
The query expression is translated into: var numbers = someStrings.Where(s => int.TryParse(s, out i)) .Select(s => i); Now, we know that the delegate created from the lambda expression for the Where call... more 9/4/2016 3:28:03 PM
Precisely because it's self-contained... it contains the whole of .NET Core, or at least as much as is required to run your application. While .NET Core is cross-platform, that doesn't mean that you can use the Linux x64 CLR binary on a... more 9/3/2016 8:20:51 PM
This is the problem: synchronized(x) { x=10; x.notifyAll(); } It's important to understand that you don't synchronize on a variable - you synchronize on an object. So you're modify the value of x to refer to a different Integer... more 9/3/2016 12:41:51 PM