コード例 #1
0
        static int _g_get_Conventions(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);

                MongoDB.Bson.Serialization.Conventions.ConventionPack gen_to_be_invoked = (MongoDB.Bson.Serialization.Conventions.ConventionPack)translator.FastGetCSObj(L, 1);
                translator.PushAny(L, gen_to_be_invoked.Conventions);
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
            return(1);
        }
コード例 #2
0
        static int __CreateInstance(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);
                if (LuaAPI.lua_gettop(L) == 1)
                {
                    MongoDB.Bson.Serialization.Conventions.ConventionPack gen_ret = new MongoDB.Bson.Serialization.Conventions.ConventionPack();
                    translator.Push(L, gen_ret);

                    return(1);
                }
            }
            catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
            return(LuaAPI.luaL_error(L, "invalid arguments to MongoDB.Bson.Serialization.Conventions.ConventionPack constructor!"));
        }
コード例 #3
0
        static int _m_GetEnumerator(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                MongoDB.Bson.Serialization.Conventions.ConventionPack gen_to_be_invoked = (MongoDB.Bson.Serialization.Conventions.ConventionPack)translator.FastGetCSObj(L, 1);



                {
                    System.Collections.Generic.IEnumerator <MongoDB.Bson.Serialization.Conventions.IConvention> gen_ret = gen_to_be_invoked.GetEnumerator(  );
                    translator.PushAny(L, gen_ret);



                    return(1);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
コード例 #4
0
        static int _m_Add(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                MongoDB.Bson.Serialization.Conventions.ConventionPack gen_to_be_invoked = (MongoDB.Bson.Serialization.Conventions.ConventionPack)translator.FastGetCSObj(L, 1);



                {
                    MongoDB.Bson.Serialization.Conventions.IConvention _convention = (MongoDB.Bson.Serialization.Conventions.IConvention)translator.GetObject(L, 2, typeof(MongoDB.Bson.Serialization.Conventions.IConvention));

                    gen_to_be_invoked.Add(_convention);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
コード例 #5
0
        static int _m_Remove(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                MongoDB.Bson.Serialization.Conventions.ConventionPack gen_to_be_invoked = (MongoDB.Bson.Serialization.Conventions.ConventionPack)translator.FastGetCSObj(L, 1);



                {
                    string _name = LuaAPI.lua_tostring(L, 2);

                    gen_to_be_invoked.Remove(_name);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }
コード例 #6
0
        static int _m_AddClassMapConvention(RealStatePtr L)
        {
            try {
                ObjectTranslator translator = ObjectTranslatorPool.Instance.Find(L);


                MongoDB.Bson.Serialization.Conventions.ConventionPack gen_to_be_invoked = (MongoDB.Bson.Serialization.Conventions.ConventionPack)translator.FastGetCSObj(L, 1);



                {
                    string _name = LuaAPI.lua_tostring(L, 2);
                    System.Action <MongoDB.Bson.Serialization.BsonClassMap> _action = translator.GetDelegate <System.Action <MongoDB.Bson.Serialization.BsonClassMap> >(L, 3);

                    gen_to_be_invoked.AddClassMapConvention(_name, _action);



                    return(0);
                }
            } catch (System.Exception gen_e) {
                return(LuaAPI.luaL_error(L, "c# exception:" + gen_e));
            }
        }