aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs
diff options
context:
space:
mode:
authorMW2007-05-24 12:35:32 +0000
committerMW2007-05-24 12:35:32 +0000
commitf95b6081cba084d1b067acea99c0effa2b3bf42c (patch)
tree7a7ab4aa037f75afa54f403c701a735acb101575 /OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs
parentDie ServiceManager! (Not really Gareth, just the old directory, new directory... (diff)
downloadopensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.zip
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.gz
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.bz2
opensim-SC_OLD-f95b6081cba084d1b067acea99c0effa2b3bf42c.tar.xz
Renamed the new Directories. (removed the "-Source" from the end of them)
Diffstat (limited to 'OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs')
-rw-r--r--OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs88
1 files changed, 0 insertions, 88 deletions
diff --git a/OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs b/OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs
deleted file mode 100644
index 436949c..0000000
--- a/OpenSim-Source/OpenSim.Scripting/EmbeddedJVM/Thread.cs
+++ /dev/null
@@ -1,88 +0,0 @@
1using System;
2using System.Collections.Generic;
3using System.Text;
4using OpenSim.Scripting.EmbeddedJVM.Types;
5using OpenSim.Scripting.EmbeddedJVM.Types.PrimitiveTypes;
6using OpenSim.Framework;
7using OpenSim.Framework.Interfaces;
8
9namespace OpenSim.Scripting.EmbeddedJVM
10{
11 public partial class Thread
12 {
13 public static MainMemory GlobalMemory;
14 public static IScriptAPI OpenSimScriptAPI;
15 private int PC = 0;
16 private Stack stack;
17 private Interpreter mInterpreter;
18 public ClassRecord currentClass;
19 public ClassInstance currentInstance;
20 private StackFrame currentFrame;
21 public int excutionCounter = 0;
22 public bool running = false;
23 public uint EntityId = 0;
24
25 public Thread()
26 {
27 this.mInterpreter = new Interpreter(this);
28 this.stack = new Stack();
29 }
30
31 public void SetPC(int methodpointer)
32 {
33 //Console.WriteLine("Thread PC has been set to " + methodpointer);
34 PC = methodpointer;
35 }
36
37 public void StartMethod(ClassRecord rec, string methName)
38 {
39 currentFrame = new StackFrame();
40 this.stack.StackFrames.Push(currentFrame);
41 this.currentClass = rec;
42 currentClass.StartMethod(this, methName);
43 }
44
45 public void StartMethod( string methName)
46 {
47 currentFrame = new StackFrame();
48 this.stack.StackFrames.Push(currentFrame);
49 currentClass.StartMethod(this, methName);
50 }
51
52 public void JumpToStaticVoidMethod(string methName, int returnPC)
53 {
54 currentFrame = new StackFrame();
55 currentFrame.ReturnPC = returnPC;
56 this.stack.StackFrames.Push(currentFrame);
57 currentClass.StartMethod(this, methName);
58 }
59
60 public void JumpToStaticParamMethod(string methName, string param, int returnPC)
61 {
62 if (param == "I")
63 {
64 BaseType bs1 = currentFrame.OpStack.Pop();
65 currentFrame = new StackFrame();
66 currentFrame.ReturnPC = returnPC;
67 this.stack.StackFrames.Push(currentFrame);
68 currentFrame.LocalVariables[0] = ((Int)bs1);
69 currentClass.StartMethod(this, methName);
70 }
71 if (param == "F")
72 {
73
74 }
75 }
76
77 public void JumpToClassStaticVoidMethod(string className, string methName, int returnPC)
78 {
79
80 }
81
82 public bool Excute()
83 {
84 excutionCounter++;
85 return this.mInterpreter.Excute();
86 }
87 }
88}