Abstract Syntax

This section gives an overview of MMT’s abstract syntax and the corresponding classes in the MMT API. MMT’s surface syntax is described in detail here.

Abstract Grammar

The (simplified) abstract syntax of MMT is:

Level Symbol Grammar Description
Document Level      
. Doc := (Thy | Mor)* Documents
Module Level      
. Thy := c [:o] = {Dec*} Theories
. Mor := c : o -> o = {Ass*} Views
Symbol Level      
. Dec := c [:o] [=o] [#N] [Declarations]((../../language/declarations.html)
. Ass := c = o Symbol [Assignments]((../../language/declarations.html#constants)
Object Level      
. o := c | x | c( (x[: o])* ; o* ) | c(STRING) Objects/Terms
. N   Notations
. c   URI
. x   Variable

Data Structures

api.Content is the top level datastructure for all of the classes representing the MMT language. For our purposes, it branches into

The following inheritance graph gives an overview of the most relevant data structures in the MMT API:

data structures