Rhino.Tools.Debugger.Dim.DimIProxy.Run C# (CSharp) Метод

Run() публичный Метод

Performs the action given by type .
public Run ( Context cx ) : object
cx Rhino.Context
Результат object
			public virtual object Run(Context cx)
			{
				switch (type)
				{
					case IPROXY_COMPILE_SCRIPT:
					{
						cx.CompileString(text, url, 1, null);
						break;
					}

					case IPROXY_EVAL_SCRIPT:
					{
						Scriptable scope = null;
						if (dim.scopeProvider != null)
						{
							scope = dim.scopeProvider.GetScope();
						}
						if (scope == null)
						{
							scope = new ImporterTopLevel(cx);
						}
						cx.EvaluateString(scope, text, url, 1, null);
						break;
					}

					case IPROXY_STRING_IS_COMPILABLE:
					{
						booleanResult = cx.StringIsCompilableUnit(text);
						break;
					}

					case IPROXY_OBJECT_TO_STRING:
					{
						if (@object == Undefined.instance)
						{
							stringResult = "undefined";
						}
						else
						{
							if (@object == null)
							{
								stringResult = "null";
							}
							else
							{
								if (@object is NativeCall)
								{
									stringResult = "[object Call]";
								}
								else
								{
									stringResult = Context.ToString(@object);
								}
							}
						}
						break;
					}

					case IPROXY_OBJECT_PROPERTY:
					{
						objectResult = dim.GetObjectPropertyImpl(cx, @object, id);
						break;
					}

					case IPROXY_OBJECT_IDS:
					{
						objectArrayResult = dim.GetObjectIdsImpl(cx, @object);
						break;
					}

					default:
					{
						throw Kit.CodeBug();
					}
				}
				return null;
			}