TMQL (Time Machine Query Language) is a query language that allows user to search through available application states within given recording. The first iteration of this language uses C# 6.0 syntax.
TMQL query is compiled using build-in .NET 4.0 compiler (CodeDom). Expressions used within this query can reference any types and methods, that are defined within .NET 4.0 System.dll and System.Core.dll libraries.
TMQL query dialog can be opened either through RevDeBug menu:
RevDeBug marker view toolbar:
Or by executing Find usages / Find executions commands:
Additionally, if you use Find usages/Find executions command, query dialog will already have query generated based on selected command.
BaseState provides access to basic information about a single application state.
VariableState is a specific application state that is linked to an expression, that can be evaluated (variable, member access, function invocation, etc.).
Available fields (besides those, that are inherited from BaseState):
Each application state is linked with a single statement, providing additional information about this state’s context. Statements can describe any syntax structure available: from variable assignments and binary expressions, to class declarations.
Current state and statement
User can reference current application state within TMQL query using “Current” prefix.
• Return all application states created after “2017-02-07 10:21:36.5”:
new DateTime($BaseState.Timestamp) > DateTime.Parse(“2017-02-07 10:21:36.5”)
• Return application states with a DeclarationId same as current:
$CurrentVariableState.DeclarationId == $VariableState.DeclarationId
• Return application states with Value equal to “3”:
$VariableState.Value == “3”