C# Класс LSharp.Environment

Наследование: IEnumerable
Показать файл Открыть проект Примеры использования класса

Открытые методы

Метод Описание
AssignLocal ( LSharp.Symbol symbol, object value ) : object

Asssigns value to a local variable symbol in this local environment (irrespective of whether symbol is defined in any parent environments).

Contains ( LSharp.Symbol symbol ) : bool

Determines whether the environment contains a definition for a variable with the given symbol

Contents ( ) : string

Returns the contents of the environment as a string suitable for use in a debugger or IDE.

Environment ( ) : System.Collections
Environment ( Environment environment ) : System.Collections

Creates a new environment which has access to a previous environment

GetEnumerator ( ) : IEnumerator

Make environment enumerable so that they are convenient to use from within LSharp itself

GetValue ( LSharp.Symbol symbol ) : object
GlobalReset ( ) : void
Set ( LSharp.Symbol symbol, object value ) : object

Sets a variable with given symbol to a given value

Приватные методы

Метод Описание
GetEnvironment ( LSharp.Symbol symbol ) : Environment

Returns the environment in which a given variable is defined, or null

Описание методов

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

Asssigns value to a local variable symbol in this local environment (irrespective of whether symbol is defined in any parent environments).
public AssignLocal ( LSharp.Symbol symbol, object value ) : object
symbol LSharp.Symbol
value object
Результат object

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

Determines whether the environment contains a definition for a variable with the given symbol
public Contains ( LSharp.Symbol symbol ) : bool
symbol LSharp.Symbol
Результат bool

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

Returns the contents of the environment as a string suitable for use in a debugger or IDE.
public Contents ( ) : string
Результат string

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

public Environment ( ) : System.Collections
Результат System.Collections

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

Creates a new environment which has access to a previous environment
public Environment ( Environment environment ) : System.Collections
environment Environment
Результат System.Collections

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

Make environment enumerable so that they are convenient to use from within LSharp itself
public GetEnumerator ( ) : IEnumerator
Результат IEnumerator

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

public GetValue ( LSharp.Symbol symbol ) : object
symbol LSharp.Symbol
Результат object

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

public GlobalReset ( ) : void
Результат void

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

Sets a variable with given symbol to a given value
public Set ( LSharp.Symbol symbol, object value ) : object
symbol LSharp.Symbol
value object
Результат object