/**
         * This method first retrieve from the context the tree (ModelTask) that is
         * going to be emulated by this task. Then, it creates its corresponding
         * executor and finally spawns it. If the tree cannot be found in the
         * context, does nothing.
         *
         * @see jbt.execution.core.ExecutionTask#internalSpawn()
         */
        protected override void InternalSpawn()
        {
            /* Retrieve the tree to run from the context. */
            treeToRun = Context.GetBT(
                ((ModelSubtreeLookup)ModelTask).TreeName);

            if (treeToRun == null)
            {
                treeRetrieved = false;
                /*
             * Must request to be inserted into the list of tickable nodes,
             * since no tree has been retrieved and as a result it must be the
             * task the one continuin the work.
             */
                Executor.RequestInsertionIntoList(BTExecutor.BTExecutorList.Tickable, this);
                //			System.err.println("Could not retrieve tree "
                //					+ ((ModelSubtreeLookup) this.getModelTask()).getTreeName()
                //					+ " from the context. Check if the context has been properly initialized.");
            }
            else
            {
                treeRetrieved = true;
                /* Compute positions for the retrieved tree. */
                treeToRun.ComputePositions();

                executionTree = treeToRun.CreateExecutor(Executor, this);
                executionTree.AddTaskListener(this);
                executionTree.Spawn(Context);
            }
        }