-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathpydevd_vm_type.py
More file actions
41 lines (31 loc) · 1.53 KB
/
pydevd_vm_type.py
File metadata and controls
41 lines (31 loc) · 1.53 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import sys
#=======================================================================================================================
# PydevdVmType
#=======================================================================================================================
class PydevdVmType:
PYTHON = 'python'
JYTHON = 'jython'
vm_type = None
#=======================================================================================================================
# SetVmType
#=======================================================================================================================
def SetVmType(vm_type):
PydevdVmType.vm_type = vm_type
#=======================================================================================================================
# GetVmType
#=======================================================================================================================
def GetVmType():
if PydevdVmType.vm_type is None:
SetupType()
return PydevdVmType.vm_type
#=======================================================================================================================
# SetupType
#=======================================================================================================================
def SetupType(str=None):
if str is not None:
PydevdVmType.vm_type = str
return
if sys.platform.startswith("java"):
PydevdVmType.vm_type = PydevdVmType.JYTHON
else:
PydevdVmType.vm_type = PydevdVmType.PYTHON