.Net Round-trip Types

Posted by Fujiy on Stack Overflow See other posts from Stack Overflow or by Fujiy
Published on 2010-06-02T10:47:11Z Indexed on 2010/06/02 10:54 UTC
Read the original article Hit count: 189

Filed under:
|
|
|

I making a method that generate a unique string key for some parameters. But the same key if call with same values.

I just accept primitive types, string, DateTime, Guid, and Nullable(since I append types together, I can distinguish who is int and who is int?), because I can convert all to string without lost values or precision.(for float and double a use ToString("R"), to DateTime ToString("O")).

Exists a easy way to know which types I can transform in strings without conflict? And how do this transform(how I said before, float, double and datetime have specific ways)

Thanks

© Stack Overflow or respective owner

Related posts about .NET

Related posts about string