Esempio n. 1
0
        public TestCaller()
        {
            string temp = "Hello";

            Dict = new Dictionary <string, Action <CallModel, object> >();
            Type type = typeof(CallModel);

            CallerManagement.AddType(type);
            DictHandler      = DictOperator.CreateFromType(type);
            FuzzyDictHandler = FuzzyDictOperator.CreateFromType(type);
            HashDictHandler  = HashDictOperator.CreateFromType(type);
            LinkHandler      = LinkOperator.CreateFromType(type);
            FuzzyLinkHandler = FuzzyLinkOperator.CreateFromType(type);
            HashLinkHandler  = HashLinkOperator.CreateFromType(type);
            Model            = new CallModel();
            Dynamic          = new CallModel();
            DictModel        = new CallModel();
            DictHandler.New();
            FuzzyDictHandler.New();
            HashDictHandler.New();
            LinkHandler.New();
            FuzzyLinkHandler.New();
            HashLinkHandler.New();
            Dict["Name"] = NDelegate.DefaultDomain().Action <CallModel, object>("arg1.Name=(string)arg2;");
        }
Esempio n. 2
0
 public TestCaller()
 {
     NatashaInitializer.InitializeAndPreheating();
     string temp = "Hello";
     Dict = new Dictionary<string, Action<CallModel, object>>();
     Type type = typeof(CallModel);
     PrecisionDict = PrecisionDictOperator.CreateFromType(type);
     FuzzyDict = FuzzyDictOperator.CreateFromType(type);
     HashDict = HashDictOperator.CreateFromType(type);
     //LinkHandler = LinkOperator.CreateFromType(type);
     //FuzzyLinkHandler = FuzzyLinkOperator.CreateFromType(type);
     //HashLinkHandler = HashLinkOperator.CreateFromType(type);
     Model = new CallModel();
     Dynamic = new CallModel();
     DictModel = new CallModel();
     PrecisionDict.New();
     FuzzyDict.New();
     HashDict.New();
     Dict["Name"] = NDelegate.DefaultDomain().Action<CallModel, object>("arg1.Name=(string)arg2;");
     for (int i = 0; i < 3000; i++)
     {
         Model.Name = "Hello";
         Dynamic.Name = "Hello";
         Dict["Name"](DictModel, "Hello");
         PrecisionDict.Set("Name", "Hello");
     }
 }