当前位置: 首页>>代码示例>>C#>>正文


C# IronRuby.SetConstant方法代码示例

本文整理汇总了C#中IronRuby.SetConstant方法的典型用法代码示例。如果您正苦于以下问题:C# IronRuby.SetConstant方法的具体用法?C# IronRuby.SetConstant怎么用?C# IronRuby.SetConstant使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在IronRuby的用法示例。


在下文中一共展示了IronRuby.SetConstant方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: LoadMarshal_Constants

 private static void LoadMarshal_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("MAJOR_VERSION", IronRuby.Builtins.RubyMarshal.MAJOR_VERSION);
     module.SetConstant("MINOR_VERSION", IronRuby.Builtins.RubyMarshal.MINOR_VERSION);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:5,代码来源:Initializers.Generated.cs

示例2: LoadBigDecimal_Constants

 private static void LoadBigDecimal_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("BASE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.BASE);
     module.SetConstant("EXCEPTION_ALL", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_ALL);
     module.SetConstant("EXCEPTION_INFINITY", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_INFINITY);
     module.SetConstant("EXCEPTION_NaN", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_NaN);
     module.SetConstant("EXCEPTION_OVERFLOW", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_OVERFLOW);
     module.SetConstant("EXCEPTION_UNDERFLOW", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_UNDERFLOW);
     module.SetConstant("EXCEPTION_ZERODIVIDE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.EXCEPTION_ZERODIVIDE);
     module.SetConstant("ROUND_CEILING", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_CEILING);
     module.SetConstant("ROUND_DOWN", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_DOWN);
     module.SetConstant("ROUND_FLOOR", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_FLOOR);
     module.SetConstant("ROUND_HALF_DOWN", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_HALF_DOWN);
     module.SetConstant("ROUND_HALF_EVEN", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_HALF_EVEN);
     module.SetConstant("ROUND_HALF_UP", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_HALF_UP);
     module.SetConstant("ROUND_MODE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_MODE);
     module.SetConstant("ROUND_UP", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.ROUND_UP);
     module.SetConstant("SIGN_NaN", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_NaN);
     module.SetConstant("SIGN_NEGATIVE_FINITE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_NEGATIVE_FINITE);
     module.SetConstant("SIGN_NEGATIVE_INFINITE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_NEGATIVE_INFINITE);
     module.SetConstant("SIGN_NEGATIVE_ZERO", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_NEGATIVE_ZERO);
     module.SetConstant("SIGN_POSITIVE_FINITE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_POSITIVE_FINITE);
     module.SetConstant("SIGN_POSITIVE_INFINITE", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_POSITIVE_INFINITE);
     module.SetConstant("SIGN_POSITIVE_ZERO", IronRuby.StandardLibrary.BigDecimal.BigDecimalOps.SIGN_POSITIVE_ZERO);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:25,代码来源:Initializers.Generated.cs

示例3: LoadFloat_Instance

 private void LoadFloat_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("DIG", IronRuby.Builtins.FloatOps.DIG);
     module.SetConstant("EPSILON", IronRuby.Builtins.FloatOps.EPSILON);
     module.SetConstant("MANT_DIG", IronRuby.Builtins.FloatOps.MANT_DIG);
     module.SetConstant("MAX", IronRuby.Builtins.FloatOps.MAX);
     module.SetConstant("MAX_10_EXP", IronRuby.Builtins.FloatOps.MAX_10_EXP);
     module.SetConstant("MAX_EXP", IronRuby.Builtins.FloatOps.MAX_EXP);
     module.SetConstant("MIN", IronRuby.Builtins.FloatOps.MIN);
     module.SetConstant("MIN_10_EXP", IronRuby.Builtins.FloatOps.MIN_10_EXP);
     module.SetConstant("MIN_EXP", IronRuby.Builtins.FloatOps.MIN_EXP);
     module.SetConstant("RADIX", IronRuby.Builtins.FloatOps.RADIX);
     module.SetConstant("ROUNDS", IronRuby.Builtins.FloatOps.ROUNDS);
     
     module.DefineLibraryMethod("-", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Subtract),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Subtract),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Subtract),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Subtract),
     });
     
     module.DefineLibraryMethod("%", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Modulo),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Modulo),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Modulo),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.ModuloOp),
     });
     
     module.DefineLibraryMethod("*", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Multiply),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Multiply),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Multiply),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Multiply),
     });
     
     module.DefineLibraryMethod("**", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Power),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Power),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Power),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Power),
     });
     
     module.DefineLibraryMethod("/", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Divide),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Divide),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Divide),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Divide),
     });
     
     module.DefineLibraryMethod("+", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Int32, System.Double>(IronRuby.Builtins.FloatOps.Add),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Double>(IronRuby.Builtins.FloatOps.Add),
         new System.Func<System.Double, System.Double, System.Double>(IronRuby.Builtins.FloatOps.Add),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Add),
     });
     
     module.DefineLibraryMethod("<", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Boolean>(IronRuby.Builtins.FloatOps.LessThan),
         new System.Func<System.Double, System.Int32, System.Boolean>(IronRuby.Builtins.FloatOps.LessThan),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Boolean>(IronRuby.Builtins.FloatOps.LessThan),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Boolean>(IronRuby.Builtins.FloatOps.LessThan),
     });
     
     module.DefineLibraryMethod("<=", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Boolean>(IronRuby.Builtins.FloatOps.LessThanOrEqual),
         new System.Func<System.Double, System.Int32, System.Boolean>(IronRuby.Builtins.FloatOps.LessThanOrEqual),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Boolean>(IronRuby.Builtins.FloatOps.LessThanOrEqual),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Boolean>(IronRuby.Builtins.FloatOps.LessThanOrEqual),
     });
     
     module.DefineLibraryMethod("<=>", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Object>(IronRuby.Builtins.FloatOps.Compare),
         new System.Func<System.Double, System.Int32, System.Object>(IronRuby.Builtins.FloatOps.Compare),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Object>(IronRuby.Builtins.FloatOps.Compare),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Object>(IronRuby.Builtins.FloatOps.Compare),
     });
     
     module.DefineLibraryMethod("==", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Boolean>(IronRuby.Builtins.FloatOps.Equal),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Boolean>(IronRuby.Builtins.FloatOps.Equal),
     });
     
     module.DefineLibraryMethod(">", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThan),
         new System.Func<System.Double, System.Int32, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThan),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThan),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThan),
     });
     
     module.DefineLibraryMethod(">=", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThanOrEqual),
         new System.Func<System.Double, System.Int32, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThanOrEqual),
         new System.Func<System.Double, Microsoft.Scripting.Math.BigInteger, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThanOrEqual),
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.BinaryOpStorage, IronRuby.Runtime.RubyContext, System.Double, System.Object, System.Boolean>(IronRuby.Builtins.FloatOps.GreaterThanOrEqual),
     });
     
     module.DefineLibraryMethod("abs", 0x51, new System.Delegate[] {
         new System.Func<System.Double, System.Double>(IronRuby.Builtins.FloatOps.Abs),
     });
     
     module.DefineLibraryMethod("ceil", 0x51, new System.Delegate[] {
//.........这里部分代码省略.........
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:101,代码来源:Initializers.Generated.cs

示例4: LoadOpenSSL_Constants

 private static void LoadOpenSSL_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("OPENSSL_VERSION", IronRuby.StandardLibrary.OpenSsl.OpenSsl.OPENSSL_VERSION);
     module.SetConstant("OPENSSL_VERSION_NUMBER", IronRuby.StandardLibrary.OpenSsl.OpenSsl.OPENSSL_VERSION_NUMBER);
     module.SetConstant("VERSION", IronRuby.StandardLibrary.OpenSsl.OpenSsl.VERSION);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:6,代码来源:Initializers.Generated.cs

示例5: LoadZlib__GzipReader_Constants

 private static void LoadZlib__GzipReader_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("OSES", IronRuby.StandardLibrary.Zlib.Zlib.GZipReader.OSES);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:4,代码来源:Initializers.Generated.cs

示例6: LoadRegexp_Constants

 private static void LoadRegexp_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("EXTENDED", IronRuby.Builtins.RegexpOps.EXTENDED);
     module.SetConstant("IGNORECASE", IronRuby.Builtins.RegexpOps.IGNORECASE);
     module.SetConstant("MULTILINE", IronRuby.Builtins.RegexpOps.MULTILINE);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:6,代码来源:Initializers.Generated.cs

示例7: LoadThreadGroup_Constants

 private static void LoadThreadGroup_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("Default", IronRuby.Builtins.ThreadGroup.Default);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:4,代码来源:Initializers.Generated.cs

示例8: LoadThreadGroup_Instance

 private void LoadThreadGroup_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("Default", IronRuby.Builtins.ThreadGroup.Default);
     
     module.DefineLibraryMethod("add", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.ThreadGroup, System.Threading.Thread, IronRuby.Builtins.ThreadGroup>(IronRuby.Builtins.ThreadGroup.Add),
     });
     
     module.DefineLibraryMethod("list", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.ThreadGroup, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.ThreadGroup.List),
     });
     
 }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:12,代码来源:Initializers.Generated.cs

示例9: LoadSocket_Instance

 private void LoadSocket_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("AF_APPLETALK", IronRuby.StandardLibrary.Sockets.RubySocket.AF_APPLETALK);
     module.SetConstant("AF_ATM", IronRuby.StandardLibrary.Sockets.RubySocket.AF_ATM);
     module.SetConstant("AF_CCITT", IronRuby.StandardLibrary.Sockets.RubySocket.AF_CCITT);
     module.SetConstant("AF_CHAOS", IronRuby.StandardLibrary.Sockets.RubySocket.AF_CHAOS);
     module.SetConstant("AF_DATAKIT", IronRuby.StandardLibrary.Sockets.RubySocket.AF_DATAKIT);
     module.SetConstant("AF_DLI", IronRuby.StandardLibrary.Sockets.RubySocket.AF_DLI);
     module.SetConstant("AF_ECMA", IronRuby.StandardLibrary.Sockets.RubySocket.AF_ECMA);
     module.SetConstant("AF_HYLINK", IronRuby.StandardLibrary.Sockets.RubySocket.AF_HYLINK);
     module.SetConstant("AF_IMPLINK", IronRuby.StandardLibrary.Sockets.RubySocket.AF_IMPLINK);
     module.SetConstant("AF_INET", IronRuby.StandardLibrary.Sockets.RubySocket.AF_INET);
     module.SetConstant("AF_IPX", IronRuby.StandardLibrary.Sockets.RubySocket.AF_IPX);
     module.SetConstant("AF_ISO", IronRuby.StandardLibrary.Sockets.RubySocket.AF_ISO);
     module.SetConstant("AF_LAT", IronRuby.StandardLibrary.Sockets.RubySocket.AF_LAT);
     module.SetConstant("AF_MAX", IronRuby.StandardLibrary.Sockets.RubySocket.AF_MAX);
     module.SetConstant("AF_NETBIOS", IronRuby.StandardLibrary.Sockets.RubySocket.AF_NETBIOS);
     module.SetConstant("AF_NS", IronRuby.StandardLibrary.Sockets.RubySocket.AF_NS);
     module.SetConstant("AF_OSI", IronRuby.StandardLibrary.Sockets.RubySocket.AF_OSI);
     module.SetConstant("AF_PUP", IronRuby.StandardLibrary.Sockets.RubySocket.AF_PUP);
     module.SetConstant("AF_SNA", IronRuby.StandardLibrary.Sockets.RubySocket.AF_SNA);
     module.SetConstant("AF_UNIX", IronRuby.StandardLibrary.Sockets.RubySocket.AF_UNIX);
     module.SetConstant("AF_UNSPEC", IronRuby.StandardLibrary.Sockets.RubySocket.AF_UNSPEC);
     module.SetConstant("AI_ADDRCONFIG", IronRuby.StandardLibrary.Sockets.RubySocket.AI_ADDRCONFIG);
     module.SetConstant("AI_ALL", IronRuby.StandardLibrary.Sockets.RubySocket.AI_ALL);
     module.SetConstant("AI_CANONNAME", IronRuby.StandardLibrary.Sockets.RubySocket.AI_CANONNAME);
     module.SetConstant("AI_DEFAULT", IronRuby.StandardLibrary.Sockets.RubySocket.AI_DEFAULT);
     module.SetConstant("AI_MASK", IronRuby.StandardLibrary.Sockets.RubySocket.AI_MASK);
     module.SetConstant("AI_NUMERICHOST", IronRuby.StandardLibrary.Sockets.RubySocket.AI_NUMERICHOST);
     module.SetConstant("AI_PASSIVE", IronRuby.StandardLibrary.Sockets.RubySocket.AI_PASSIVE);
     module.SetConstant("AI_V4MAPPED", IronRuby.StandardLibrary.Sockets.RubySocket.AI_V4MAPPED);
     module.SetConstant("AI_V4MAPPED_CFG", IronRuby.StandardLibrary.Sockets.RubySocket.AI_V4MAPPED_CFG);
     module.SetConstant("EAI_ADDRFAMILY", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_ADDRFAMILY);
     module.SetConstant("EAI_AGAIN", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_AGAIN);
     module.SetConstant("EAI_BADFLAGS", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_BADFLAGS);
     module.SetConstant("EAI_BADHINTS", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_BADHINTS);
     module.SetConstant("EAI_FAIL", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_FAIL);
     module.SetConstant("EAI_FAMILY", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_FAMILY);
     module.SetConstant("EAI_MAX", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_MAX);
     module.SetConstant("EAI_MEMORY", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_MEMORY);
     module.SetConstant("EAI_NODATA", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_NODATA);
     module.SetConstant("EAI_NONAME", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_NONAME);
     module.SetConstant("EAI_PROTOCOL", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_PROTOCOL);
     module.SetConstant("EAI_SERVICE", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_SERVICE);
     module.SetConstant("EAI_SOCKTYPE", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_SOCKTYPE);
     module.SetConstant("EAI_SYSTEM", IronRuby.StandardLibrary.Sockets.RubySocket.EAI_SYSTEM);
     module.SetConstant("INADDR_ALLHOSTS_GROUP", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_ALLHOSTS_GROUP);
     module.SetConstant("INADDR_ANY", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_ANY);
     module.SetConstant("INADDR_BROADCAST", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_BROADCAST);
     module.SetConstant("INADDR_LOOPBACK", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_LOOPBACK);
     module.SetConstant("INADDR_MAX_LOCAL_GROUP", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_MAX_LOCAL_GROUP);
     module.SetConstant("INADDR_NONE", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_NONE);
     module.SetConstant("INADDR_UNSPEC_GROUP", IronRuby.StandardLibrary.Sockets.RubySocket.INADDR_UNSPEC_GROUP);
     module.SetConstant("IPPORT_RESERVED", IronRuby.StandardLibrary.Sockets.RubySocket.IPPORT_RESERVED);
     module.SetConstant("IPPORT_USERRESERVED", IronRuby.StandardLibrary.Sockets.RubySocket.IPPORT_USERRESERVED);
     module.SetConstant("IPPROTO_GGP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_GGP);
     module.SetConstant("IPPROTO_ICMP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_ICMP);
     module.SetConstant("IPPROTO_IDP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_IDP);
     module.SetConstant("IPPROTO_IGMP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_IGMP);
     module.SetConstant("IPPROTO_IP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_IP);
     module.SetConstant("IPPROTO_MAX", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_MAX);
     module.SetConstant("IPPROTO_ND", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_ND);
     module.SetConstant("IPPROTO_PUP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_PUP);
     module.SetConstant("IPPROTO_RAW", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_RAW);
     module.SetConstant("IPPROTO_TCP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_TCP);
     module.SetConstant("IPPROTO_UDP", IronRuby.StandardLibrary.Sockets.RubySocket.IPPROTO_UDP);
     module.SetConstant("MSG_DONTROUTE", IronRuby.StandardLibrary.Sockets.RubySocket.MSG_DONTROUTE);
     module.SetConstant("MSG_OOB", IronRuby.StandardLibrary.Sockets.RubySocket.MSG_OOB);
     module.SetConstant("MSG_PEEK", IronRuby.StandardLibrary.Sockets.RubySocket.MSG_PEEK);
     module.SetConstant("NI_DGRAM", IronRuby.StandardLibrary.Sockets.RubySocket.NI_DGRAM);
     module.SetConstant("NI_MAXHOST", IronRuby.StandardLibrary.Sockets.RubySocket.NI_MAXHOST);
     module.SetConstant("NI_MAXSERV", IronRuby.StandardLibrary.Sockets.RubySocket.NI_MAXSERV);
     module.SetConstant("NI_NAMEREQD", IronRuby.StandardLibrary.Sockets.RubySocket.NI_NAMEREQD);
     module.SetConstant("NI_NOFQDN", IronRuby.StandardLibrary.Sockets.RubySocket.NI_NOFQDN);
     module.SetConstant("NI_NUMERICHOST", IronRuby.StandardLibrary.Sockets.RubySocket.NI_NUMERICHOST);
     module.SetConstant("NI_NUMERICSERV", IronRuby.StandardLibrary.Sockets.RubySocket.NI_NUMERICSERV);
     module.SetConstant("PF_APPLETALK", IronRuby.StandardLibrary.Sockets.RubySocket.PF_APPLETALK);
     module.SetConstant("PF_ATM", IronRuby.StandardLibrary.Sockets.RubySocket.PF_ATM);
     module.SetConstant("PF_CCITT", IronRuby.StandardLibrary.Sockets.RubySocket.PF_CCITT);
     module.SetConstant("PF_CHAOS", IronRuby.StandardLibrary.Sockets.RubySocket.PF_CHAOS);
     module.SetConstant("PF_DATAKIT", IronRuby.StandardLibrary.Sockets.RubySocket.PF_DATAKIT);
     module.SetConstant("PF_DLI", IronRuby.StandardLibrary.Sockets.RubySocket.PF_DLI);
     module.SetConstant("PF_ECMA", IronRuby.StandardLibrary.Sockets.RubySocket.PF_ECMA);
     module.SetConstant("PF_HYLINK", IronRuby.StandardLibrary.Sockets.RubySocket.PF_HYLINK);
     module.SetConstant("PF_IMPLINK", IronRuby.StandardLibrary.Sockets.RubySocket.PF_IMPLINK);
     module.SetConstant("PF_INET", IronRuby.StandardLibrary.Sockets.RubySocket.PF_INET);
     module.SetConstant("PF_IPX", IronRuby.StandardLibrary.Sockets.RubySocket.PF_IPX);
     module.SetConstant("PF_ISO", IronRuby.StandardLibrary.Sockets.RubySocket.PF_ISO);
     module.SetConstant("PF_LAT", IronRuby.StandardLibrary.Sockets.RubySocket.PF_LAT);
     module.SetConstant("PF_MAX", IronRuby.StandardLibrary.Sockets.RubySocket.PF_MAX);
     module.SetConstant("PF_NS", IronRuby.StandardLibrary.Sockets.RubySocket.PF_NS);
     module.SetConstant("PF_OSI", IronRuby.StandardLibrary.Sockets.RubySocket.PF_OSI);
     module.SetConstant("PF_PUP", IronRuby.StandardLibrary.Sockets.RubySocket.PF_PUP);
     module.SetConstant("PF_SNA", IronRuby.StandardLibrary.Sockets.RubySocket.PF_SNA);
     module.SetConstant("PF_UNIX", IronRuby.StandardLibrary.Sockets.RubySocket.PF_UNIX);
     module.SetConstant("PF_UNSPEC", IronRuby.StandardLibrary.Sockets.RubySocket.PF_UNSPEC);
     module.SetConstant("SHUT_RD", IronRuby.StandardLibrary.Sockets.RubySocket.SHUT_RD);
     module.SetConstant("SHUT_RDWR", IronRuby.StandardLibrary.Sockets.RubySocket.SHUT_RDWR);
     module.SetConstant("SHUT_WR", IronRuby.StandardLibrary.Sockets.RubySocket.SHUT_WR);
     module.SetConstant("SO_ACCEPTCONN", IronRuby.StandardLibrary.Sockets.RubySocket.SO_ACCEPTCONN);
     module.SetConstant("SO_BROADCAST", IronRuby.StandardLibrary.Sockets.RubySocket.SO_BROADCAST);
//.........这里部分代码省略.........
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:101,代码来源:Initializers.Generated.cs

示例10: LoadRegexp_Instance

 private void LoadRegexp_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("EXTENDED", IronRuby.Builtins.RegexpOps.EXTENDED);
     module.SetConstant("IGNORECASE", IronRuby.Builtins.RegexpOps.IGNORECASE);
     module.SetConstant("MULTILINE", IronRuby.Builtins.RegexpOps.MULTILINE);
     
     module.DefineLibraryMethod("~", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.ConversionStorage<IronRuby.Builtins.MutableString>, IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyRegex, System.Object>(IronRuby.Builtins.RegexpOps.ImplicitMatch),
     });
     
     module.DefineLibraryMethod("=~", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString, System.Object>(IronRuby.Builtins.RegexpOps.MatchIndex),
     });
     
     module.DefineLibraryMethod("==", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, System.Object, System.Boolean>(IronRuby.Builtins.RegexpOps.Equals),
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex, System.Boolean>(IronRuby.Builtins.RegexpOps.Equals),
     });
     
     module.DefineLibraryMethod("===", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString, System.Boolean>(IronRuby.Builtins.RegexpOps.CaseCompare),
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyRegex, System.Object, System.Boolean>(IronRuby.Builtins.RegexpOps.CaseCompare),
     });
     
     module.DefineLibraryMethod("casefold?", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, System.Boolean>(IronRuby.Builtins.RegexpOps.IsCaseInsensitive),
     });
     
     module.DefineLibraryMethod("eql?", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, System.Object, System.Boolean>(IronRuby.Builtins.RegexpOps.Equals),
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex, System.Boolean>(IronRuby.Builtins.RegexpOps.Equals),
     });
     
     module.DefineLibraryMethod("hash", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, System.Int32>(IronRuby.Builtins.RegexpOps.GetHash),
     });
     
     module.DefineLibraryMethod("initialize", 0x52, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex>(IronRuby.Builtins.RegexpOps.Reinitialize),
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex, System.Int32, System.Object, IronRuby.Builtins.RubyRegex>(IronRuby.Builtins.RegexpOps.Reinitialize),
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.RubyRegex, System.Object, System.Object, IronRuby.Builtins.RubyRegex>(IronRuby.Builtins.RegexpOps.Reinitialize),
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString, System.Int32, IronRuby.Builtins.MutableString, IronRuby.Builtins.RubyRegex>(IronRuby.Builtins.RegexpOps.Reinitialize),
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString, System.Object, IronRuby.Builtins.MutableString, IronRuby.Builtins.RubyRegex>(IronRuby.Builtins.RegexpOps.Reinitialize),
     });
     
     module.DefineLibraryMethod("inspect", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RegexpOps.Inspect),
     });
     
     module.DefineLibraryMethod("kcode", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RegexpOps.GetEncoding),
     });
     
     module.DefineLibraryMethod("match", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString, IronRuby.Builtins.MatchData>(IronRuby.Builtins.RegexpOps.Match),
     });
     
     module.DefineLibraryMethod("options", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, System.Int32>(IronRuby.Builtins.RegexpOps.GetOptions),
     });
     
     module.DefineLibraryMethod("source", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RegexpOps.Source),
     });
     
     module.DefineLibraryMethod("to_s", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyRegex, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RegexpOps.ToS),
     });
     
 }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:69,代码来源:Initializers.Generated.cs

示例11: LoadStruct_Instance

 private void LoadStruct_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     #if !SILVERLIGHT
     module.SetConstant("Tms", IronRuby.Builtins.RubyStructOps.CreateTmsClass(module));
     #endif
     
     module.DefineLibraryMethod("[]", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Int32, System.Object>(IronRuby.Builtins.RubyStructOps.GetValue),
         new System.Func<IronRuby.Builtins.RubyStruct, Microsoft.Scripting.SymbolId, System.Object>(IronRuby.Builtins.RubyStructOps.GetValue),
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.MutableString, System.Object>(IronRuby.Builtins.RubyStructOps.GetValue),
         new System.Func<IronRuby.Runtime.ConversionStorage<System.Int32>, IronRuby.Builtins.RubyStruct, System.Object, System.Object>(IronRuby.Builtins.RubyStructOps.GetValue),
     });
     
     module.DefineLibraryMethod("[]=", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Int32, System.Object, System.Object>(IronRuby.Builtins.RubyStructOps.SetValue),
         new System.Func<IronRuby.Builtins.RubyStruct, Microsoft.Scripting.SymbolId, System.Object, System.Object>(IronRuby.Builtins.RubyStructOps.SetValue),
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.MutableString, System.Object, System.Object>(IronRuby.Builtins.RubyStructOps.SetValue),
         new System.Func<IronRuby.Runtime.ConversionStorage<System.Int32>, IronRuby.Builtins.RubyStruct, System.Object, System.Object, System.Object>(IronRuby.Builtins.RubyStructOps.SetValue),
     });
     
     module.DefineLibraryMethod("==", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.BinaryOpStorage, IronRuby.Builtins.RubyStruct, System.Object, System.Boolean>(IronRuby.Builtins.RubyStructOps.Equals),
     });
     
     module.DefineLibraryMethod("each", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyStruct, System.Object>(IronRuby.Builtins.RubyStructOps.Each),
     });
     
     module.DefineLibraryMethod("each_pair", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyStruct, System.Object>(IronRuby.Builtins.RubyStructOps.EachPair),
     });
     
     module.DefineLibraryMethod("eql?", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Object, System.Boolean>(IronRuby.Builtins.RubyStructOps.Equal),
     });
     
     module.DefineLibraryMethod("hash", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Int32>(IronRuby.Builtins.RubyStructOps.Hash),
     });
     
     module.DefineLibraryMethod("initialize", 0x52, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyStruct, System.Object[]>(IronRuby.Builtins.RubyStructOps.Reinitialize),
     });
     
     module.DefineLibraryMethod("initialize_copy", 0x52, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyStruct>(IronRuby.Builtins.RubyStructOps.InitializeCopy),
     });
     
     module.DefineLibraryMethod("inspect", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RubyStructOps.Inspect),
     });
     
     module.DefineLibraryMethod("length", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Int32>(IronRuby.Builtins.RubyStructOps.GetSize),
     });
     
     module.DefineLibraryMethod("members", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyStructOps.GetMembers),
     });
     
     module.DefineLibraryMethod("select", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.CallSiteStorage<System.Func<System.Runtime.CompilerServices.CallSite, IronRuby.Runtime.RubyContext, System.Object, IronRuby.Builtins.Proc, System.Object>>, IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyStructOps.Select),
     });
     
     module.DefineLibraryMethod("size", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, System.Int32>(IronRuby.Builtins.RubyStructOps.GetSize),
     });
     
     module.DefineLibraryMethod("to_a", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyStructOps.Values),
     });
     
     module.DefineLibraryMethod("to_s", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RubyStructOps.Inspect),
     });
     
     module.DefineLibraryMethod("values", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyStruct, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyStructOps.Values),
     });
     
     module.DefineLibraryMethod("values_at", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.ConversionStorage<System.Int32>, IronRuby.Builtins.RubyStruct, System.Object[], IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyStructOps.ValuesAt),
     });
     
 }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:84,代码来源:Initializers.Generated.cs

示例12: LoadObject_Instance

 private void LoadObject_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("FALSE", IronRuby.Builtins.ObjectOps.FALSE);
     module.SetConstant("NIL", IronRuby.Builtins.ObjectOps.NIL);
     module.SetConstant("TRUE", IronRuby.Builtins.ObjectOps.TRUE);
     
     module.DefineLibraryMethod("initialize", 0x5a, new System.Delegate[] {
         new System.Action<System.Object>(IronRuby.Builtins.ObjectOps.Reinitialize),
     });
     
 }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:10,代码来源:Initializers.Generated.cs

示例13: LoadMath_Instance

 private void LoadMath_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("E", IronRuby.Builtins.RubyMath.E);
     module.SetConstant("PI", IronRuby.Builtins.RubyMath.PI);
     
     module.DefineLibraryMethod("acos", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Acos),
     });
     
     module.DefineLibraryMethod("acosh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Acosh),
     });
     
     module.DefineLibraryMethod("asin", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Asin),
     });
     
     module.DefineLibraryMethod("asinh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Asinh),
     });
     
     module.DefineLibraryMethod("atan", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Atan),
     });
     
     module.DefineLibraryMethod("atan2", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Atan2),
     });
     
     module.DefineLibraryMethod("atanh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Atanh),
     });
     
     module.DefineLibraryMethod("cos", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Cos),
     });
     
     module.DefineLibraryMethod("cosh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Cosh),
     });
     
     module.DefineLibraryMethod("erf", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Erf),
     });
     
     module.DefineLibraryMethod("erfc", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Erfc),
     });
     
     module.DefineLibraryMethod("exp", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Exp),
     });
     
     module.DefineLibraryMethod("frexp", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, IronRuby.Builtins.RubyArray>(IronRuby.Builtins.RubyMath.Frexp),
     });
     
     module.DefineLibraryMethod("hypot", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Hypot),
     });
     
     module.DefineLibraryMethod("ldexp", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Ldexp),
     });
     
     module.DefineLibraryMethod("log", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Log),
     });
     
     module.DefineLibraryMethod("log10", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Log10),
     });
     
     module.DefineLibraryMethod("sin", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Sin),
     });
     
     module.DefineLibraryMethod("sinh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Sinh),
     });
     
     module.DefineLibraryMethod("sqrt", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Sqrt),
     });
     
     module.DefineLibraryMethod("tan", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Tan),
     });
     
     module.DefineLibraryMethod("tanh", 0x52, new System.Delegate[] {
         new System.Func<System.Object, System.Double, System.Double>(IronRuby.Builtins.RubyMath.Tanh),
     });
     
 }
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:93,代码来源:Initializers.Generated.cs

示例14: LoadIO_Instance

 private void LoadIO_Instance(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("SEEK_CUR", IronRuby.Builtins.RubyIOOps.SEEK_CUR);
     module.SetConstant("SEEK_END", IronRuby.Builtins.RubyIOOps.SEEK_END);
     module.SetConstant("SEEK_SET", IronRuby.Builtins.RubyIOOps.SEEK_SET);
     
     module.DefineLibraryMethod("<<", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyIO, System.Object, IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Output),
     });
     
     module.DefineLibraryMethod("binmode", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Binmode),
     });
     
     module.DefineLibraryMethod("close", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Close),
     });
     
     module.DefineLibraryMethod("close_read", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.CloseReader),
     });
     
     module.DefineLibraryMethod("close_write", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.CloseWriter),
     });
     
     module.DefineLibraryMethod("closed?", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Boolean>(IronRuby.Builtins.RubyIOOps.Closed),
     });
     
     module.DefineLibraryMethod("each", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Runtime.RubyContext, IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Each),
         new System.Func<IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyIO, IronRuby.Builtins.MutableString, System.Object>(IronRuby.Builtins.RubyIOOps.Each),
     });
     
     module.DefineLibraryMethod("each_byte", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyIO, System.Object>(IronRuby.Builtins.RubyIOOps.EachByte),
     });
     
     module.DefineLibraryMethod("each_line", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Runtime.RubyContext, IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Each),
         new System.Func<IronRuby.Runtime.BlockParam, IronRuby.Builtins.RubyIO, IronRuby.Builtins.MutableString, System.Object>(IronRuby.Builtins.RubyIOOps.Each),
     });
     
     module.DefineLibraryMethod("eof", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Boolean>(IronRuby.Builtins.RubyIOOps.Eof),
     });
     
     module.DefineLibraryMethod("eof?", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Boolean>(IronRuby.Builtins.RubyIOOps.Eof),
     });
     
     module.DefineLibraryMethod("external_encoding", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, IronRuby.Builtins.RubyEncoding>(IronRuby.Builtins.RubyIOOps.GetExternalEncoding),
     });
     
     module.DefineLibraryMethod("fcntl", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Int32, IronRuby.Builtins.MutableString, System.Int32>(IronRuby.Builtins.RubyIOOps.FileControl),
         new System.Func<IronRuby.Builtins.RubyIO, System.Int32, System.Int32, System.Int32>(IronRuby.Builtins.RubyIOOps.FileControl),
     });
     
     module.DefineLibraryMethod("fileno", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Int32>(IronRuby.Builtins.RubyIOOps.FileNo),
     });
     
     module.DefineLibraryMethod("flush", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Flush),
     });
     
     module.DefineLibraryMethod("fsync", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.Flush),
     });
     
     module.DefineLibraryMethod("getc", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Object>(IronRuby.Builtins.RubyIOOps.Getc),
     });
     
     module.DefineLibraryMethod("gets", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyIO, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RubyIOOps.Gets),
         new System.Func<IronRuby.Runtime.RubyScope, IronRuby.Builtins.RubyIO, IronRuby.Builtins.MutableString, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RubyIOOps.Gets),
     });
     
     module.DefineLibraryMethod("initialize", 0x52, new System.Delegate[] {
         new System.Action<IronRuby.Builtins.RubyIO>(IronRuby.Builtins.RubyIOOps.CreateIO),
         new System.Action<IronRuby.Builtins.RubyIO, System.Int32, IronRuby.Builtins.MutableString>(IronRuby.Builtins.RubyIOOps.CreateIO),
     });
     
     module.DefineLibraryMethod("internal_encoding", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, IronRuby.Builtins.RubyEncoding>(IronRuby.Builtins.RubyIOOps.GetInternalEncoding),
     });
     
     module.DefineLibraryMethod("isatty", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Builtins.RubyIO, System.Boolean>(IronRuby.Builtins.RubyIOOps.IsAtty),
     });
     
     module.DefineLibraryMethod("lineno", 0x51, new System.Delegate[] {
         new System.Func<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyIO, System.Int32>(IronRuby.Builtins.RubyIOOps.GetLineNo),
     });
     
     module.DefineLibraryMethod("lineno=", 0x51, new System.Delegate[] {
         new System.Action<IronRuby.Runtime.RubyContext, IronRuby.Builtins.RubyIO, System.Int32>(IronRuby.Builtins.RubyIOOps.SetLineNo),
//.........这里部分代码省略.........
开发者ID:aslakhellesoy,项目名称:ironruby,代码行数:101,代码来源:Initializers.Generated.cs

示例15: LoadMath_Constants

 private static void LoadMath_Constants(IronRuby.Builtins.RubyModule/*!*/ module) {
     module.SetConstant("E", IronRuby.Builtins.RubyMath.E);
     module.SetConstant("PI", IronRuby.Builtins.RubyMath.PI);
     
 }
开发者ID:MiguelMadero,项目名称:ironruby,代码行数:5,代码来源:Initializers.Generated.cs


注:本文中的IronRuby.SetConstant方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。