Browsing 7239 questions and answers with Jon Skeet
It will entirely depend on the implementation of the resource itself. The try-with-resource statement is "just" syntactic sugar (but oh so sweet) for calling close() within a finally block (and preserving exceptions etc). So long as the... more 1/21/2014 9:54:20 AM
You're weakening the security by reducing the number of possible strings that will be encoded. Any time your hash ends up being an invalid UTF-8 sequence, you'll end up with U+FFFD as the output character (the Unicode "replacement"... more 1/21/2014 7:05:42 AM
What is causing it? You're declaring a method with the same name as an event declared in a base class. That hides the event within the derived class, which isn't a good idea in general. Two options: Use new as the compiler... more 1/20/2014 9:29:10 PM
You can use BitConverter.GetBytes(float) or use a BinaryWriter wrapping a MemoryStream and use BinaryWriter.Write(float). It's not clear exactly what you did with a MemoryStream before, but you don't want to use StreamWriter - that's for... more 1/20/2014 9:17:35 PM
To be immutable and include cyclic references, you'd need something like this: public sealed class Parent { private readonly IEnumerable<Child> children; private readonly string name; // Just for example public... more 1/20/2014 3:50:13 PM
Looking at the java.util sources I see that the files there are with ".class" extension, not ".java" That just means you're looking at the source file attached to the classes rather than a source file in your project. The source... more 1/20/2014 3:06:26 PM
I suspect this is just a matter of XML escaping for <, as you can't use < directly within an attribute value. Try: <Button Content="<< Précédent" ...> ... and please provide more details in your next... more 1/20/2014 2:50:00 PM
I doubt that you can do that within the query that's sent to SQL Server. Instead, use AsEnumerable to change context to perform the final step on the .NET side: var query = from s in dc.UserWebSites join zk in dc.ZeekUsers on... more 1/20/2014 2:10:47 PM
No. From the documentation of UUID.toString() The UUID string representation is as described by this BNF: UUID = <time_low> "-" <time_mid> "-" <time_high_and_version>... more 1/20/2014 11:56:30 AM
my datetime objects are all in this format "dd/MM/yyyy HH:mm:ss" No, they're not. At least not if you're talking about .NET DateTime values or database fields. Neither of those implicitly have formats - they're just values. You... more 1/20/2014 11:42:43 AM