示例#1
0
        public Form1()
        {
            Form1._me = this;
            _debuggerLogDelegate = new DebuggerLog(DebuggerLogMethod);

            InitializeComponent();
            m_debugger = new ktDebug();
            m_debugger.Enable();
            m_debugger.OnDebug += m_debugger_OnDebug;

            ktModule mainLib = new ktMainLib.ktMain();
            new ktIDEContext(mainLib.GetContext("Main"));

            m_Talker = new ktMainLib.ktTalker("URI=localhost/kacTalk_PHP;PROTO=HTTP;KEY=658B8C89-BA37-42D6-8D02-7119A5FA613A");
            m_Talker.Initiate();

            m_Talker.AddExtraParameter("ID", "u1234455");

            m_Talker.GetObject("kto");
            m_Talker.RunMethod("kto");

            m_KT = new kacTalk(false);
            m_KT.AllowMissingEOL = true;
            m_KT.MathMode = true;
            m_KT.AddModule( mainLib );
            //m_KT.AddModule( new ktIDEModule() );
            m_KT.AddDefaultValues();

            LoadExample(2);
        }
示例#2
0
 /// <summary>
 /// Main constructor for kactalkClass,
 /// it takes the kacTalk object/interpreter it should wrap/represent
 /// </summary>
 public kactalkClass(kacTalk Value)
     : this()
 {
     m_Value = Value;
     m_IsClass = false;
 }
示例#3
0
 /// <summary>
 /// Default constructor for kactalkClass
 /// </summary>
 public kactalkClass()
     : base("kactalk", null, null, false, true)
 {
     m_Value = null;
 }
示例#4
0
 public ktBlock(kacTalk Main)
     : this()
 {
     SetMain(Main);
 }/*
示例#5
0
 public bool SetMain(kacTalk Main)
 {
     m_Main = Main;
     return true;
 }
示例#6
0
        /// <summary>
        /// Main constructor for kacTalk,
        /// takes a parameter that decides if the default libraries/modules etc should be loaded
        /// </summary>
        public kacTalk(bool LoadDefs)
            : base("kactalk", 0)
        {
            m_Tokens = null;
            m_Lines = null;
            m_TokenStack = null;
            m_LineStack = null;
            m_CurLine = 0;

            m_MainBlock = null;

            if (LoadDefs)
            {
                LoadDefaults();
                AddDefaultValues();
                //ktDebug.Log( "===============\n"+ m_Modules.Get_R() );
            }
            m_MainKT = this;
        }