Fixed to conform to Mono standards for incomplete functionality.
[mono.git] / mcs / class / Microsoft.VisualBasic / Microsoft.VisualBasic / Conversion.cs
index 4390ef678d65996f16b00e864720c9784cbb5c88..7243d68e810169421671d516847077be44afd606 100644 (file)
@@ -1,49 +1,76 @@
-//\r
-// Conversion.cs\r
-//\r
-// Author:\r
-//   Chris J Breisch (cjbreisch@altavista.net)\r
-//\r
-// (C) 2002 Chris J Breisch\r
-//\r
-namespace Microsoft.VisualBasic {\r
-       [Microsoft.VisualBasic.CompilerServices.StandardModuleAttribute] \r
-       [System.Runtime.InteropServices.StructLayoutAttribute(System.Runtime.InteropServices.LayoutKind.Auto)] \r
-       sealed public class Conversion {\r
-               // Declarations\r
-               // Constructors\r
-               // Properties\r
-               // Methods\r
-               public static System.String ErrorToString () { return "";}\r
-               public static System.String ErrorToString (System.Int32 ErrorNumber) { return "";}\r
-               public static System.Int16 Fix (System.Int16 Number) { return 0;}\r
-               public static System.Int32 Fix (System.Int32 Number) { return 0;}\r
-               public static System.Int64 Fix (System.Int64 Number) { return 0;}\r
-               public static System.Double Fix (System.Double Number) { return 0;}\r
-               public static System.Single Fix (System.Single Number) { return 0;}\r
-               public static System.Decimal Fix (System.Decimal Number) { return 0;}\r
-               public static System.Object Fix (System.Object Number) { return null;}\r
-               public static System.Int16 Int (System.Int16 Number) { return 0;}\r
-               public static System.Int32 Int (System.Int32 Number) { return 0;}\r
-               public static System.Int64 Int (System.Int64 Number) { return 0;}\r
-               public static System.Double Int (System.Double Number) { return 0;}\r
-               public static System.Single Int (System.Single Number) { return 0;}\r
-               public static System.Decimal Int (System.Decimal Number) { return 0;}\r
-               public static System.Object Int (System.Object Number) { return null;}\r
-               public static System.String Hex (System.Int16 Number) { return "";}\r
-               public static System.String Hex (System.Byte Number) { return "";}\r
-               public static System.String Hex (System.Int32 Number) { return "";}\r
-               public static System.String Hex (System.Int64 Number) { return "";}\r
-               public static System.String Hex (System.Object Number) { return "";}\r
-               public static System.String Oct (System.Int16 Number) { return "";}\r
-               public static System.String Oct (System.Byte Number) { return "";}\r
-               public static System.String Oct (System.Int32 Number) { return "";}\r
-               public static System.String Oct (System.Int64 Number) { return "";}\r
-               public static System.String Oct (System.Object Number) { return "";}\r
-               public static System.String Str (System.Object Number) { return "";}\r
-               public static System.Double Val (System.String InputStr) { return 0;}\r
-               public static System.Int32 Val (System.Char Expression) { return 0;}\r
-               public static System.Double Val (System.Object Expression) { return 0;}\r
-               // Events\r
-       };\r
-}\r
+//
+// Conversion.cs
+//
+// Author:
+//   Chris J Breisch (cjbreisch@altavista.net) 
+//
+// (C) 2002 Chris J Breisch
+//
+
+using System;
+
+namespace Microsoft.VisualBasic {
+       [Microsoft.VisualBasic.CompilerServices.StandardModuleAttribute] 
+       sealed public class Conversion {
+               // Declarations
+               // Constructors
+               // Properties
+               // Methods
+               [MonoTODO]
+               public static System.String ErrorToString () { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String ErrorToString (System.Int32 ErrorNumber) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Int16 Fix (System.Int16 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Int32 Fix (System.Int32 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Int64 Fix (System.Int64 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Double Fix (System.Double Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Single Fix (System.Single Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Decimal Fix (System.Decimal Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Object Fix (System.Object Number) { throw new NotImplementedException (); }
+               public static System.Int16 Int (System.Int16 Number) { return (System.Int16)Math.Floor(Number); }
+               public static System.Int32 Int (System.Int32 Number) { return (System.Int16)Math.Floor(Number); }
+               public static System.Int64 Int (System.Int64 Number) { return (System.Int16)Math.Floor(Number); }
+               public static System.Double Int (System.Double Number) { return (System.Int16)Math.Floor(Number); }
+               public static System.Single Int (System.Single Number) { return (System.Int16)Math.Floor(Number); }
+               [MonoTODO]
+               public static System.Decimal Int (System.Decimal Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Object Int (System.Object Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Hex (System.Int16 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Hex (System.Byte Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Hex (System.Int32 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Hex (System.Int64 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Hex (System.Object Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Oct (System.Int16 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Oct (System.Byte Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Oct (System.Int32 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Oct (System.Int64 Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Oct (System.Object Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.String Str (System.Object Number) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Double Val (System.String InputStr) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Int32 Val (System.Char Expression) { throw new NotImplementedException (); }
+               [MonoTODO]
+               public static System.Double Val (System.Object Expression) { throw new NotImplementedException (); }
+               // Events
+       };
+}