20 return context.InputNode.Name ==
"bs:while";
40 "Result of 'test' attribute in 'bs:if' node is not a boolean",
51 HtmlAttribute? conditionAttribute = context.
InputNode.Attributes[
"test"];
53 if (conditionAttribute ==
null)
57 "Missing 'test' attribute in 'bs:if' node",
62 if (
string.IsNullOrEmpty(conditionAttribute.Value))
66 "Empty 'test' attribute in 'bs:if' node",
74 while (
Evaluate(context, conditionAttribute, expressions))
85 foreach (HtmlNode? child
in context.
InputNode.ChildNodes)
Implements the Html Context for the Transformation Process.
BadSourcePosition CreateAttributePosition(HtmlAttribute attribute)
Creates the Source Position of the specified Attribute.
BadSourcePosition CreateOuterPosition()
Creates the Source Position of the current Input Nodes Outer Content.
BadHtmlContext CreateChild(HtmlNode inputNode, HtmlNode outputNode, BadExecutionContext? executionContext=null)
Creates a child context with the specified input, output node and optional execution context.
readonly HtmlNode InputNode
The Current Input Node.
readonly BadExecutionContext ExecutionContext
The Execution Context that is used to evaluate badscript code.
readonly HtmlNode OutputNode
The Current Output Node.
BadExpression[] Parse(string code, BadSourcePosition pos)
Parses the specified code and returns the expressions with their positions set to the specified posit...
BadObject Execute(IEnumerable< BadExpression > expressions, BadSourcePosition position)
Executes the specified expressions.
Describes a specific position inside a source file.
Base Implementation for all Expressions used inside the Script.
The Execution Context. Every execution of a script needs a context the script is running in....
BadScope Scope
The Root Scope of the Context.
BadScope CreateChild(string name, BadScope? caller, bool? useVisibility, BadScopeFlags flags=BadScopeFlags.RootScope)
Creates a subscope of the current scope.
Gets thrown by the runtime.
static BadRuntimeException Create(BadScope? scope, string message)
Creates a new BadScriptException.
The Base Class for all BadScript Objects.
Implements the Interface for Native Boolean.
Contains Shared Data Structures and Functionality.
Contains the Expressions for the BadScript2 Language.
Contains the Error Objects for the BadScript2 Language.
Contains the Native Runtime Objects.
Contains the Runtime Objects.
Contains the Runtime Implementation.
BadScopeFlags
Defines Different Behaviours for the Current Scope.