[Mono-devel-list] DateTime.cs patch
Philip Van Hoof
spamfrommailing at freax.org
Tue May 20 10:08:47 EDT 2003
Hi there Marcel and Martin
I am mailing you this because I found your E-mail adres in the sources
of Monos DateTime.cs. I've also placed the mono-devel-list E-mail adress
in CC.
I've implemented the following methods of System.DateTime :
public static DateTime FromOADate (double d) {}
public string[] GetDateTimeFormats() { }
public string[] GetDateTimeFormats(char format) { }
I also attached DateTimeTest.cs which is a test-application. This is the
result of that test :
[freax at pluisje freax]$ mcs DateTimeTest.cs
Compilation succeeded
[freax at pluisje freax]$ mono DateTimeTest.exe
09/08/1913 00:00:00
September 08
1913-09-08T00:00:00+01:00
Monday, 08 September 1913 00:00:00
09/08/1913 00:00:00
Mon, 08 Sep 1913 00:00:00 GMT
1913-09-08T00:00:00
1913-09-07 23:00:00Z
Sunday, 07 September 1913 23:00:00
Monday, 08 September 1913 00:00
09/08/1913 00:00
09/08/1913
Monday, 08 September 1913
00:00:00
00:00
September 08
1913 September
[freax at pluisje freax]$
ps. Maybe I will also implement the ToOADate()-method later this day
I used "cvs diff -u DateTime.cs" to create the diff-file that has been
attached.
--
Philip Van Hoof a.k.a. freax
me at freax dot org
http://www.freax.be -- http://www.freax.eu.org -- http://www.freax.org
-------------- next part --------------
A non-text attachment was scrubbed...
Name: DateTime.cs.diff
Type: text/x-patch
Size: 2903 bytes
Desc: not available
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20030520/d3e84a34/attachment.bin
-------------- next part --------------
using System;
public class DateTimeTest {
public static int Main (string[] args)
{
DateTime d = DateTime.FromOADate(5000);
Console.WriteLine(d.ToString());
foreach (string i in d.GetDateTimeFormats('m'))
{
Console.WriteLine(i);
}
foreach (string i in d.GetDateTimeFormats())
{
Console.WriteLine(i);
}
return 1;
}
}
More information about the Mono-devel-list
mailing list