Packages

  • package root
    Definition Classes
    root
  • package info
    Definition Classes
    root
  • package kwarc
    Definition Classes
    info
  • package mmt
    Definition Classes
    kwarc
  • package api

    This is the main package of the MMT API.

    This is the main package of the MMT API.

    It holds subpackages for all data structures, data containers, and the central algorithms and services.

    Classes directly defined in the package

    Some minor classes that are used throughout MMT are defined in this package, in particular:

    • MMT URIs in the class Path and Namespace
    • processing and content errors in the class Error

    The package also contains root classes for certain types that are subclassed throughout the package. Most importantly:

    • StructuralElement: structure-level (= named) parts in the data structures for the MMT language: documents, theories, constants, ...
    • MMTTask: tasks for a single object: parsing, checking, ...
    • Rule: object-level part of the MMT language that is written in Scala

    Subpackages

    Data structures for the MMT language

    The data structures for the MMT languages are defined in 4 packages corresponding to the 4 levels: - documents: Documents and all other NarrativeElements - modules: Modules (= the toplevel declarations), in particular Theorys and Views - symbols: all Declarations inside modules, in particular Constants - objects: all anonymous Objects (e.g., formulas, functions, etc.), in particular Contexts and Terms

    The former 3 levels are jointly called 'structural' levels. All elements subclass StructuralElement, have an MMT URI, and carry an MMT URI referring to their parent in the MMT abstract syntax tree.

    Structural elements are extensible (via DerivedModules and DerivedDeclarations), and the package patterns defines declaration patterns as a built-in extension.

    All structural elements are mutable and implement the ContainerElement interface for changing their children. Objects, by contrast, are represented as immutable inductive types.(except for carrying metadata.Metadata and objects.ClientProperties). The boundary between structural elements and objects is mediated by ComponentContainers: these are mutable, owned by structural elements, and maintain objects.

    A few auxiliary data structures shifted to separate packages: - opaque: external (i.e., informal, computation) content - informal: partially outdated informal data structures - metadata: metadata annotations to all structural elements or objects

    The MMT main class and its internal state

    The package frontend contains the class Controller, which owns all state relevant for running MMT. Typically, each application creates a single instance of this class. The package also defines several other essential classes, most importantly MMT's extension (=plug-in, add-on) interfaces via the Extension class.

    The package libraries maintains the instances of MMT language data structures, in particular the Library class. Controller owns a Library, which stores all structural elements that have been loaded into memory.

    User interfaces

    The package frontend also contains the main executable classes, in particular the Shell class.

    The package gui collects all classes for building graphical user interfaces. This includes auxiliary classes for use in IDE plugins.

    The package web collects all classes for the HTTP interface of MMT.

    Physical storage of the MMT language files

    The package archives defines MMT Archives (= projects) as well as classes for building and working with archives. The latter include in particular the BuildManager and BuildTarget. Build targets include Importers and [Exporter]]s that translate between MMT and other formats.

    The package backend defines classes for maintaining archives and translating between the MMT URIs of structural elements and their physical storage locations.

    The central algorithms for processing MMT content

    The processing model of MMT consists of several major algorithms. - parser: read strings into MMT data structures - checking: check and refine MMT data structures - uom: pure computation on MMT data structures - proving: theorem proving on MMT data structures (in very early state)) - execution: imperative computation (in very, very early state) - presentation: rendering MMT data structures in user-facing formats (including HTML+presentation MathML)

    All algorithms are defined in Extensions coupled with default implementations. Moreover, all algorithms are split into two separate levels, one for structural elements and objects. See LeveledExtension.

    The package notations maintains the common code for parsing and presentation.

    The package valuebases maintains mathematical databases as a part of MMT.

    Other algorithms on the MMT data structures

    The package ontology contains a relational, semantic web-style ontology and query engine for it.

    The package moc contains change management.

    The package refactoring contains refactoring principles.

    General purpose utility functions

    The package utils defines general purpose APIs for files, URIs, HTML building, etc.

    Definition Classes
    mmt
  • package archives

    This package holds all classes related to MMT Archives (= project).

    This package holds all classes related to MMT Archives (= project).

    The BuildManager allows defining BuildTargets to run on archives, including in particular Importers and Exporters.

    Most archives are stored in hub of git repositories such as and MathHub or GitHub. Such hubs are represented by the class LMHHub, which allows for cloning, etc. archives.

    The list of currently open archives (from which MMT will load content if needed) is maintained by the backend.Backend.

    Definition Classes
    api
  • package backend

    This package maintains the interface between MMT content in persistent physical storage and MMT content loaded into memory.

    This package maintains the interface between MMT content in persistent physical storage and MMT content loaded into memory.

    The class Storage is the interface for individual physical storage containers. Most of the time this corresponds to a folder containing an archives.Archive.

    Content is usually stored in OMDoc XML format, which is parsed by the XMLStreamer.

    The class Backend maintains the registered storages and performs conversion between logical MMT URIs and physical locations.

    The frontend.Controller owns an instance of Backend. Any referenced MMT URI is lazily and transparently loaded from the backend into memory and unloaded if MMT runs out of memory.

    Definition Classes
    api
  • package checking

    The algorithm for checking MMT content.

    The algorithm for checking MMT content. See api for an overview of the algorithms.

    The main interfaces are - Checker: the main interface for checkers (combining a structure and an object checker) - StructureChecker: checking structural elements - ObjectChecker: checking objects

    The main implementations are - MMTStructureChecker for structural elements - RuleBasedChecker for objects

    The latter creates a Solver for each judgment, which perform type reconstruction.

    Structure checking is not extensible except through DerivedElements. Object checking is extensible through Rules.

    Definition Classes
    api
  • package documents

    NarrativeElements are all elements that do not have a semantics of their own.

    NarrativeElements are all elements that do not have a semantics of their own.

    The most important case are Documents. Inside, documents a few other other documents may occur.

    Definition Classes
    api
  • package execution

    The algorithm for imperatively executing MMT content.

    The algorithm for imperatively executing MMT content. This is currently very young and immature.

    See api for an overview of the algorithms.

    Definition Classes
    api
  • package frontend

    This package defines several central classes: - Controller is the main MMT class.

    This package defines several central classes: - Controller is the main MMT class. - Shell is the main executable (which will create one controller). - MMTConfig is the MMT configuration data structure. A controller maintains one configuration. - Extension is the addon/plugin interface of MMT. Every extension has access to one controller instance. - Report handles logging, and every instance of Logger has access to a report instance.

    Definition Classes
    api
  • package gui

    GUIPanel and [GUIFrame]] maintain a swing-based graphical interface to the frontend.Controller and its children.

    GUIPanel and [GUIFrame]] maintain a swing-based graphical interface to the frontend.Controller and its children.

    Definition Classes
    api
  • package informal
    Definition Classes
    api
  • package libraries

    Library maintains the structural elements that have been loaded into memory.

    Library maintains the structural elements that have been loaded into memory. That includes the theory diagram and all documents.

    ImplicitGraph maintains the commutative sub-diagram of implicit morphisms.

    Definition Classes
    api
  • package metadata

    MetaDatum is the stateless class that represents metadata items.

    MetaDatum is the stateless class that represents metadata items.

    MetaData statefully maintains a set of MetaDatums.

    Elements that have metadata inherit from HasMetaData.

    Linker and Tagger make setting and getting metadata easier.

    Definition Classes
    api
  • package moc

    Change is the main class statelessly representing differences/changes.

    Change is the main class statelessly representing differences/changes.

    Differ is a differ for MMT data structures.

    Definition Classes
    api
  • package modules

    MMT Modules, i.e., Theorys and Views.

    MMT Modules, i.e., Theorys and Views.

    Link unifies Views and symbols.Structures, the two kinds of atomic theory morphisms.

    ModuleOrLink unifies the two. That class defines most of the state of a module, in particular the body.

    Definition Classes
    api
  • package notations

    This package maintains the common data structures for parsing and presentation.

    This package maintains the common data structures for parsing and presentation.

    TextNotation is the main notation class. It is similar to MMT objects, in particular it is stateless.

    NotationContainer statefully maintains the notations assigned to a declaration. These are owned by StructuralElements to carry notations, akin to how they carry type/definition.

    Definition Classes
    api
  • package objects

    MMT objects are

    MMT objects are

    AnonymousDiagram, AnonymousTheory, and AnonymousMorphism represent anonymous counterparts to libraries.Library modules.Module}.

    This package also contains various auxiliary classes: - Position defines paths within objects - SubstitutionApplier is the main interface for substitution strategies. - Matcher is a simple matcher.

    Definition Classes
    api
  • package ontology

    This package contains a relational ontology and a query engine for it.

    This package contains a relational ontology and a query engine for it.

    The main classes are: - RelationalElement defines the concepts and relation of the ontology (TBox) - RelationalManager extracts the ABox from MMT content - RelStore maintains the model of the ontology (ABox) - RelationGraphExporter allows exporting the ABox as a graph. - Query defines a query language for the ontology - Evaluator implements the query language for a given ABox. - Search maintains classes for faceted search, in particular the facet for MathWebSearch.

    Definition Classes
    api
  • package opaque

    Informal or unknown content that MMT does not process.

    Informal or unknown content that MMT does not process. The main classes are - OpaqueElement: such content - OpaqueElementInterpreter the abstract interface for extensions that interpret it

    Definition Classes
    api
  • package parser

    The algorithm for parsing MMT content (strings to MMT data structures).

    The algorithm for parsing MMT content (strings to MMT data structures). See api for an overview of the algorithms.

    The main interfaces are - Parser: the main interface for parser (combining a structure and an object parser) - StructureParser: parsing structural elements - ObjectParser: parsing objects

    The main implementations are - KeywordBasedParser for structural elements in .mmt files - NotationBasedParser for objects

    The latter creates a Scanner for each string, which applies notations to parse user-defined mixifx syntax.

    Structure parsing is extensible using ParserExtensions. Object parsing is extensible using notations or LexerExtensions.

    Definition Classes
    api
  • ActiveNotation
  • ActiveParsingRule
  • Ambiguous
  • AnnotatedComment
  • AnnotatedCommentToken
  • AnnotatedConstant
  • AnnotatedDPath
  • AnnotatedDelimiter
  • AnnotatedDerived
  • AnnotatedDocument
  • AnnotatedInclude
  • AnnotatedKeyword
  • AnnotatedName
  • AnnotatedNotation
  • AnnotatedOpaque
  • AnnotatedOpaqueText
  • AnnotatedPath
  • AnnotatedTerm
  • AnnotatedTermToken
  • AnnotatedText
  • AnnotatedTheory
  • AsymmetricEscapeLexer
  • BasicTheoryParser
  • BoundName
  • CFExternalToken
  • Child
  • CommentIgnorer
  • DeclarationDelimiter
  • DefaultObjectParser
  • ErrorText
  • EscapeManager
  • ExternalToken
  • ExternalTokenParsingInput
  • FiniteKeywordsLexer
  • FixedLengthLiteralLexer
  • Found
  • FoundArg
  • FoundContent
  • FoundDelim
  • FoundOML
  • FoundSeqArg
  • FoundSeqOML
  • FoundSimpArg
  • FoundSimpSeqArg
  • FoundVar
  • HasParentInfo
  • IsDoc
  • IsMod
  • IsRootDoc
  • IsRootMod
  • KeywordBasedParser
  • LexFunction
  • LexParseExtension
  • LexerExtension
  • LiteralParser
  • MMTPart
  • MMTStructureEstimator
  • MMTURILexer
  • MatchedList
  • MetadataParser
  • ModuleDelimiter
  • NSImportDeclaration
  • NamespaceDeclaration
  • NotationBasedParser
  • NumberLiteralLexer
  • ObjectDelimiter
  • ObjectParser
  • ParentInfo
  • ParseFunction
  • ParseResult
  • Parser
  • ParserContext
  • ParserExtension
  • ParserExtensionArguments
  • ParserState
  • ParsingRule
  • ParsingRuleGroup
  • ParsingRuleTable
  • ParsingStream
  • ParsingUnit
  • PrefixedTokenLexer
  • PrimitiveTokenListElem
  • QuotationLexer
  • QuoteLexer
  • Reader
  • RootInfo
  • Scanner
  • ScannerBacktrack
  • ScannerBacktrackInfo
  • ScannerNoBacktrack
  • SemanticText
  • SemiFormalParser
  • SingleFoundVar
  • SourcePosition
  • SourceRef
  • SourceRegion
  • StringInterpolationLexer
  • StringInterpolationPart
  • StringInterpolationToken
  • StringPart
  • StructureParser
  • StructureParserContinuations
  • SymmetricEscapeLexer
  • Token
  • TokenList
  • TokenListElem
  • TokenSlice
  • UnicodeMap
  • UnicodeReplacer
  • UnmatchedList
  • ViewKey
  • Whitespace
  • WordReplacer
  • package patterns

    Declaration patterns in the sense of Horozal's PhD thesis, realized as two special cases of structural features: - Pattern for the patterns (elaborates to nothing) - Instance for the instances of patterns (elaborates by looking up the pattern)

    Declaration patterns in the sense of Horozal's PhD thesis, realized as two special cases of structural features: - Pattern for the patterns (elaborates to nothing) - Instance for the instances of patterns (elaborates by looking up the pattern)

    Definition Classes
    api
  • package presentation

    The algorithm for presenting MMT content (data structures to user-facing formats).

    The algorithm for presenting MMT content (data structures to user-facing formats). See api for an overview of the algorithms.

    The main interfaces are - Presenter: the main interface for parser (combining a structure and an object parser) - StructurePresenter: presenting structural elements - ObjectPresenter: presenting objects

    The main implementations are (in each case for structural elements and objects) - for OMDoc XML: OMDocPresenter resp. OpenMathPresenter - for plain strings (using the toString methods): TextPresenter resp. ObjectTextPresenter - for nice human-oriented strings: MMTStructurePresenter resp. NotationBasedParser - for HTML: HTMLPresenter resp. MathMLPresenter

    Definition Classes
    api
  • package proving

    The algorithm for proving theorems about MMT content.

    The algorithm for proving theorems about MMT content. This is very premature and experimental.

    See api for an overview of the algorithms.

    The main interfaces are - Prover: object level proving

    Structure level proving does not exist yet.

    The main implementations are - RuleBasedProver for object-level proving

    The latter creates a Searcher for each proving task, which applies search rules to find MMT objects.

    Definition Classes
    api
  • package refactoring
    Definition Classes
    api
  • package symbols

    MMT Declarations are the elements of Modules.

    MMT Declarations are the elements of Modules. The kinds of declarations are documented at Declaration.

    ObjContainer are owned by structural elements, in particular by declarations, to store objects.

    Definition Classes
    api
  • package uom

    The algorithm for immutably computing with MMT content, i.e., simplification (strings to MMT data structures).

    Simplification

    The algorithm for immutably computing with MMT content, i.e., simplification (strings to MMT data structures). See api for an overview of the algorithms.

    The main interfaces are - Simplifier: the main interface for parser (combining a structure and an object simplifier) - StructureSimplifier: simplifying structural elements - ObjectSimplifier: simplifying objects

    The main implementations are - ElaborationBasedSimplifier for structural elements - RuleBasedSimplifier for objects

    Structure simplification is extensible using derived elements. Object simplification is extensible using rules.

    Literals and semantic objects

    This package also contains the classes for using Scala objects as MMT literals.

    SemanticType defines types as sets of Scala objects. SemanticValue defines a distinguished element of such a type. SemanitcOperator defines functions on such types as Scala functions.

    Literals and operations on them are injected into the MMT language by declaring RealizedValue, RealizedType and RealizedOperator rules, which tie a syntactic type/operator (i.e., an MMT term) to a semantic counterpart.

    StandardLiterals defines semantic types for the most important types.

    RealizedTheory represents an MMT theory programmed in Scala, usually as a Scala class.

    Scala companion objects for MMT theories

    TheoryScala and ConstantScala are auxiliary classes that are useful when implementing MMT rules or other logic-specific algorithms.

    Definition Classes
    api
  • package utils

    This package defines various MMT-independent high-level APIs.

    This package defines various MMT-independent high-level APIs. Various basic functions are declared directly in this package object in order to be easily available.

    Most other files in this package are self-contained and independent of the rest of MMT and each other. We describe them in groups below.

    Data structures*

    - Union disjoint union of Scala types - MyList extensions of Scala's lists (via implicit conversions) - HashRelation, HashMapToSet, and HashEquality: hash-related data structures for - While while loops that allow for break and continue

    General purpose utilities

    - Killable tasks that can be notified that they should be canceled. In particular, MMTTasks can be aborted without risking an inconsistent state. - Unparsed for simple parsing of strings - ScalaTo serialization helpers for Scala objects - ValueCache factory methods that introduce structure sharing by resuing previous pointers - XMLToScala framework for conveniently turning a set of case classes into an XML parser for the corresponding schema

    Wrappers for low-level APIs

    MMT provides various APIs that extend or simplify APIs provided Java or Scala: - File file paths and interacting with files - URI URIs - xml various helper function for working with XML and dereferencing URLs (not really a wrapper but fits best here) - ShellCommand commands executed on the system shell

    APIs for external languages

    - Dot the dot languages for graph layouting - JSON the JSON language - HTML API for building HTML pages programmatically

    Definition Classes
    api
  • package valuebases

    This package maintains databases of cocnrete mathematical objects.

    This package maintains databases of cocnrete mathematical objects.

    Concrete objects are special MMT Terms that can be represented as concrete database objects (e.g., JSON). The connection between the two is mediated by Codecs and CodecOerator. The codec-based translation is implemented in the Coder.

    Definition Classes
    api
  • package web

    Server maintains the HTTP interface of MMT.

    Server maintains the HTTP interface of MMT. The server is owned by the frontend.Controller.

    It can be customized by ServerExtensions.

    The REPLServer maintains a set of independent REPL loops for MMT content.

    Definition Classes
    api

package parser

The algorithm for parsing MMT content (strings to MMT data structures). See api for an overview of the algorithms.

The main interfaces are - Parser: the main interface for parser (combining a structure and an object parser) - StructureParser: parsing structural elements - ObjectParser: parsing objects

The main implementations are - KeywordBasedParser for structural elements in .mmt files - NotationBasedParser for objects

The latter creates a Scanner for each string, which applies notations to parse user-defined mixifx syntax.

Structure parsing is extensible using ParserExtensions. Object parsing is extensible using notations or LexerExtensions.

Source
package.scala
Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. parser
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. class ActiveNotation extends ActiveParsingRule

    An ActiveNotation is a notation whose firstDelimToken has been scanned An ActiveNotation maintains state about the found and still-expected markers

  2. abstract class ActiveParsingRule extends AnyRef

    meant to replace ActiveNotation as a more general interface in Scanner and related classes That would computational notations.

  3. case class Ambiguous(notations: List[ParsingRule]) extends Error with Product with Serializable
  4. class AnnotatedComment extends AnnotatedText with Child
  5. class AnnotatedCommentToken extends AnnotatedText with Child
  6. class AnnotatedConstant extends SemanticText with Child
  7. class AnnotatedDPath extends AnnotatedPath
  8. abstract class AnnotatedDelimiter extends AnnotatedText with Child
  9. class AnnotatedDerived extends SemanticText with Child
  10. class AnnotatedDocument extends SemanticText
  11. class AnnotatedInclude extends AnnotatedText with Child
  12. class AnnotatedKeyword extends AnnotatedText with Child
  13. class AnnotatedName extends AnnotatedText with Child
  14. class AnnotatedNotation extends AnnotatedText with Child
  15. class AnnotatedOpaque extends SemanticText with Child
  16. class AnnotatedOpaqueText extends SemanticText with Child
  17. abstract class AnnotatedPath extends AnnotatedText with Child
  18. class AnnotatedTerm[A <: Obj] extends AnnotatedText with Child
  19. class AnnotatedTermToken extends AnnotatedText with Child
  20. abstract class AnnotatedText extends AnyRef
  21. class AnnotatedTheory extends SemanticText with Child
  22. class AsymmetricEscapeLexer extends LexFunction

    an EscapeHandler that detects tokens delimited by begin and end

    an EscapeHandler that detects tokens delimited by begin and end

    nested escapes are allowed

    typical example: AsymmetricEscapeHandler(/*, */)

  23. abstract class BasicTheoryParser extends Parser

    parses input streams as theory bodies, i.e., without MMT style module system

    parses input streams as theory bodies, i.e., without MMT style module system

    the stream is parsed into a single DeclaredTheory the URI of the stream is split such that the last part (e.g., the file name) becomes the theory name, the rest (e.g., the path to the folder) becomes the namespace

  24. case class BoundName(name: LocalName, isOML: Boolean) extends Product with Serializable

    names are locally meaningful: variables bound in the contexts (to be parsed as OMV), fields of dependent OML sequences (to be parsed as OML)

  25. case class CFExternalToken(text: String, firstPosition: SourcePosition, term: Term) extends ExternalToken with Product with Serializable

    A convenience class for an ExternalToken whose parsing is context-free so that it can be parsed immediately

    A convenience class for an ExternalToken whose parsing is context-free so that it can be parsed immediately

    term

    the result of parsing

  26. trait Child extends AnnotatedText
  27. class DeclarationDelimiter extends AnnotatedDelimiter
  28. class ErrorText extends AnnotatedText with Child
  29. class EscapeManager extends AnyRef

    An EscapeManager handles escaping between languages during tokenization

  30. abstract class ExternalToken extends PrimitiveTokenListElem

    An ExternalToken can be anything produced by a LexerExtension

  31. case class ExternalTokenParsingInput(outer: ParsingUnit, boundNames: List[BoundName], parser: ObjectParser, errorCont: ErrorHandler) extends Product with Serializable

    bundles arguments passed into ExternalToken

  32. case class FiniteKeywordsLexer(keys: List[String]) extends LexFunction with Product with Serializable
  33. class FixedLengthLiteralLexer extends LexerExtension
  34. sealed abstract class Found extends AnyRef

    Objects of type Found represent TokenSlices that were found in the input

    Objects of type Found represent TokenSlices that were found in the input

    The subclasses correspond to the subclasses of Marker.

  35. sealed abstract class FoundArg extends FoundContent

    represents a notations.Arg that was found

  36. sealed abstract class FoundContent extends Found

    anything but a delimiter

  37. case class FoundDelim(pos: Int, delim: Delimiter) extends Found with Product with Serializable

    represents a notations.Delimiter that was found

  38. case class FoundOML(slice: TokenSlice, number: Int, info: LabelInfo) extends FoundArg with Product with Serializable
  39. sealed abstract class FoundSeqArg extends FoundContent

    represents an notations.SeqArg that was found

  40. case class FoundSeqOML(number: Int, args: List[FoundOML], info: LabelInfo) extends FoundSeqArg with Product with Serializable
  41. case class FoundSimpArg(slice: TokenSlice, number: Int) extends FoundArg with Product with Serializable
  42. case class FoundSimpSeqArg(number: Int, args: List[FoundSimpArg]) extends FoundSeqArg with Product with Serializable
  43. class FoundVar extends FoundContent

    represents a notations.Var that was found

    represents a notations.Var that was found

    the sequence variable parser is a state machine

                                           |---------------- next delim -----------------------------------------|
    state:  0                       1      |                             2                                   -1  V
    expect: name --- pick name ---> type, sep., next delim --- else ---> sep, next delim --- next delim ---> skip delim, end
      ^                                    | sep                     sep |   | else ^
      | ------------ skip sep -------------|------------------------------   |------|
  44. sealed abstract class HasParentInfo extends ParentInfo

    abstraction to unify operations inside a document and inside a module

  45. case class IsDoc(docParent: DPath) extends HasParentInfo with Product with Serializable

    the content is located inside a document

  46. case class IsMod(modParent: MPath, relDocParent: LocalName) extends HasParentInfo with Product with Serializable

    the content is located inside a ModuleOrLink

    the content is located inside a ModuleOrLink

    modParent

    the parent module

    relDocParent

    the path of the parent document relative to the parent module

  47. case class IsRootDoc(path: DPath) extends RootInfo with Product with Serializable

    the content is a root document

  48. case class IsRootMod(path: MPath) extends RootInfo with Product with Serializable

    the content is a root module

  49. class KeywordBasedParser extends Parser

    A StructureParser reads MMT declarations (but not objects) and defers to continuation functions for the found StructuralElement, ParsingUnits, and SourceErrors.

    A StructureParser reads MMT declarations (but not objects) and defers to continuation functions for the found StructuralElement, ParsingUnits, and SourceErrors.

    This class provides 3 things

    1) High-level read methods that read MMT-related entities from a stream, which implementing classes can use. These methods throw do not read more than necessary from the stream and throw SourceError where appropriate.

    2) It is stateless and maintains the parse state via an implicit argument of type ParserState in most functions.

    3) It leaves processing of MMT entities application-independently via high-level continuation functions.

  50. abstract class LexFunction extends AnyRef

    the lexing part of a LexParseExtension

  51. class LexParseExtension extends LexerExtension

    A LexParseExtension is a LexerExtension with a lex and a parse component.

  52. abstract class LexerExtension extends Rule

    A LexerExtension bypasses the default lexing algorithm

  53. class LiteralParser extends ParseFunction
  54. case class MMTPart(unparsed: String, reg: SourceRegion, term: Term) extends StringInterpolationPart with Product with Serializable
  55. trait MMTStructureEstimator extends AnyRef

    estimates the archives.BuildResult of an mmt Interpreter by using the StructureParser superficially

  56. class MatchedList extends TokenListElem

    A MatchedList is a SubTermToken resulting by reducing a sublist using a notation

    A MatchedList is a SubTermToken resulting by reducing a sublist using a notation

    invariant: every FoundArg (including nested ones) found when traversing an.getFound corresponds to one TokenListElem in tokens

    TokenSlice's in an.getFound are invalid.

  57. class ModuleDelimiter extends AnnotatedDelimiter
  58. class NSImportDeclaration extends SemanticText with Child
  59. class NamespaceDeclaration extends SemanticText with Child
  60. class NotationBasedParser extends ObjectParser

    A notation based parser

  61. class NumberLiteralLexer extends LexFunction

    A LexerExtension that lexes undelimited number literals

    A LexerExtension that lexes undelimited number literals

    always accepts digit* after non-(letter or connector)

  62. class ObjectDelimiter extends AnnotatedDelimiter
  63. trait ObjectParser extends FormatBasedExtension

    an ObjectParser handles ParsingUnits

    an ObjectParser handles ParsingUnits

    Instances are maintained by the ExtensionManager and retrieved and called by the structural parser.

    see also Parser

  64. sealed abstract class ParentInfo extends AnyRef

    passed to Parsers and checking.Interpreters to indicate the place inside a larger element the input is located

  65. abstract class ParseFunction extends AnyRef

    the parsing part of a LexParseExtension

  66. case class ParseResult(unknown: Context, free: Context, term: Term) extends Product with Serializable

    encapsulates the output of an ObjectParser

    encapsulates the output of an ObjectParser

    unknown

    the unknown variables that must be solved

  67. abstract class Parser extends StructureParser with ObjectParser with LeveledExtension

    the designated super class for all parsers

  68. case class ParserContext(state: ParserState, docContext: List[InterpretationInstruction]) extends Product with Serializable
  69. abstract class ParserExtension extends Extension

    classes implementing InDocParser may be registered with a StructureParser to extend MMT's concrete syntax with new keywords

  70. case class ParserExtensionArguments(parser: KeywordBasedParser, state: ParserState, se: StructuralElement, keyword: String, context: Context = Context.empty) extends Product with Serializable

    arguments passed to a ParserExtension

    arguments passed to a ParserExtension

    se

    the current structural element (Document, DeclaredModule, or Constant)

    keyword

    the keyword that was read

  71. class ParserState extends AnyRef

    This class bundles all state that is maintained by a StructureParser

  72. case class ParsingRule(name: ContentPath, alias: List[LocalName], notation: TextNotation) extends Product with Serializable

    couples an identifier with its notation

  73. case class ParsingRuleGroup(precedence: Precedence, rules: List[ParsingRule]) extends Product with Serializable

    a set of parsing rules with the same precedence, see NotationOrder

  74. case class ParsingRuleTable(groups: List[ParsingRuleGroup]) extends Product with Serializable

    a set of parsing rule groups, ordered by increasing precedence, used by NotationBasedParser to apply notations in precedence-order

  75. case class ParsingStream(source: URI, parentInfo: ParentInfo, nsMap: NamespaceMap, format: String, stream: BufferedReader) extends MMTTask with Product with Serializable

    ParsingStream encapsulates the input of a StructureParser

    ParsingStream encapsulates the input of a StructureParser

    source

    the URI of the stream

    parentInfo

    information about the parent (if any) of the content in the stream (which - if given - must exist)

    nsMap

    defined namespaces

    format

    the format of the stream

    stream

    the stream to parse

  76. case class ParsingUnit(source: SourceRef, context: Context, term: String, iiContext: InterpretationInstructionContext, top: Option[ParsingRule] = None) extends MMTTask with Product with Serializable

    ParsingUnit encapsulates the input of an ObjectParser

    ParsingUnit encapsulates the input of an ObjectParser

    the top parameter can be used to parse a term that is known/required to have a certain form

    source

    the source reference of the string to parse

    context

    the context against which to parse

    term

    the term to parse

    top

    an optional notation that the whole input must match;

  77. abstract class PrefixedTokenLexer extends LexerExtension

    a LexerExtension that detects id (letter sequences) Tokens prefixed by delim

  78. abstract class PrimitiveTokenListElem extends TokenListElem

    subtype of TokenListElem that defines some methods generally

  79. class QuotationLexer extends StringInterpolationLexer

    quotation of MMT terms

  80. class Reader extends AnyRef

    a Java-style reader that provides MMT-specific read methods

  81. sealed abstract class RootInfo extends ParentInfo

    abstraction to unify operations inside a root document or module

  82. class Scanner extends Logger

    scans a TokenList against some notations

  83. case class ScannerBacktrack(currentIndex: Int, numCurrentTokens: Int) extends ScannerBacktrackInfo with Product with Serializable
  84. abstract class ScannerBacktrackInfo extends AnyRef

    remembers the relevant Scanner state at the time when an ActiveNotation was created

  85. abstract class SemanticText extends AnnotatedText
  86. class SemiFormalParser extends ParseFunction
  87. case class SingleFoundVar(pos: Int, name: Token, tp: Option[FoundArg]) extends Product with Serializable

    helper class for representing a single found variable

    helper class for representing a single found variable

    pos

    first Token

    name

    the variable name

    tp

    the optional type

  88. case class SourcePosition(offset: Int, line: Int, column: Int) extends Product with Serializable

    position in a source block; both one and two-dimensional coordinates are maintained

    position in a source block; both one and two-dimensional coordinates are maintained

    offset

    one-dimensional coordinate, -1 if omitted

    line

    vertical two-dimensional coordinate

    column

    horizontal two-dimensional coordinate all coordinates start from 0 Unicode code points above FFFF count as 2 characters. Arguably that is wrong. But it corresponds to the implementation in Java Strings (see http://docs.oracle.com/javase/6/docs/api/java/lang/Character.html#unicode). Therefore, the current source references work better with, e.g., jEdit.

  89. case class SourceRef(container: URI, region: SourceRegion) extends Product with Serializable

    region in an identified source block

    region in an identified source block

    container

    URI of the source document

    region

    in that document

  90. case class SourceRegion(start: SourcePosition, end: SourcePosition) extends Product with Serializable

    region in a source block

    region in a source block

    start

    inclusive start position

    end

    inclusive end position

  91. abstract class StringInterpolationLexer extends LexerExtension

    A LexerExtension for string interpolation.

  92. abstract class StringInterpolationPart extends AnyRef

    auxiliary class for StringInterpolationToken: part of the interpolated string

  93. case class StringInterpolationToken(text: String, firstPosition: SourcePosition, parts: List[StringInterpolationPart], lexer: StringInterpolationLexer) extends ExternalToken with Product with Serializable

    the result of a StringInterpolationLexer, carrying the continuation for parsing

  94. case class StringPart(text: String, reg: SourceRegion, ref: SourceRef) extends StringInterpolationPart with Product with Serializable
  95. trait StructureParser extends FormatBasedExtension

    the type of structural parsers

    the type of structural parsers

    see also Parser

  96. class StructureParserContinuations extends AnyRef

    continuations that may be called by StructureParsers

  97. class SymmetricEscapeLexer extends LexFunction

    an EscapeHandler that detects tokens delimited by delim

  98. case class Token(word: String, firstPosition: SourcePosition, whitespaceBefore: Boolean, text: Option[String] = None) extends PrimitiveTokenListElem with Product with Serializable

    A Token is the basic TokenListElem

    A Token is the basic TokenListElem

    word

    the characters making up the Token (excluding whitespace)

    firstPosition

    the SourcePosition of the first character

    whitespaceBefore

    true iff the Token was preceded by whitespace (true for the first Token, too)

    text

    the text lexed into this token, if different from word

  99. class TokenList extends AnyRef

    A TokenList is a wrapper for a mutable list of TokenListElem with a few special methods for parsing

    A TokenList is a wrapper for a mutable list of TokenListElem with a few special methods for parsing

    TokenListElem's are always indexed starting from 0.

  100. trait TokenListElem extends AnyRef

    the type of objects that may occur in a info.kwarc.mmt.api.parser.TokenList

  101. case class TokenSlice(tokens: TokenList, start: Int, next: Int) extends Product with Serializable

    A reference to a sublist of a TokenList that does not copy the element

    A reference to a sublist of a TokenList that does not copy the element

    tokens

    the underlying TokenList

    start

    the first Token (inclusive)

    next

    the last Token (exclusive)

  102. class UnmatchedList extends TokenListElem

    An UnmatchedList is a SubTermToken resulting by reducing a sublist without using a notation

    An UnmatchedList is a SubTermToken resulting by reducing a sublist without using a notation

    Other notations have determined that this sublist must be parsed into a subtree, but it is not known (yet) which notation should be used.

  103. class Whitespace extends AnnotatedText with Child
  104. abstract class WordReplacer extends LexerExtension

    replaces words during lexing

Value Members

  1. object ActiveNotation

    a helper object

  2. object AnnotatedText
  3. object BoundName extends Serializable
  4. object CommentIgnorer extends ParserExtension
  5. object DefaultObjectParser extends ObjectParser

    A default parser that parses any string into an OMSemiFormal object.

  6. object FoundVar

    helper object

  7. object MMTURILexer extends PrefixedTokenLexer
  8. object MetadataParser extends ParserExtension

    A parser component for the keywords 'tag', 'meta', and 'link' to be parsed into the corresponding MetaDatum classes

    A parser component for the keywords 'tag', 'meta', and 'link' to be parsed into the corresponding MetaDatum classes

    It also treats various keys starting with @_ as abbreviations of the respective Dublin core keys

    The parse results are added directly to the containing element

  9. object ObjectParser

    helper object

  10. object ParseResult extends Serializable
  11. object ParsingStream extends Serializable
  12. object QuoteLexer extends LexParseExtension
  13. object Reader

    helper object

  14. object ScannerNoBacktrack extends ScannerBacktrackInfo with Product with Serializable

    cut, i.e, fail if this notation is not applicable

  15. object SourcePosition extends Serializable

    helper object

  16. object SourceRef extends Linker[SourceRef] with Serializable
  17. object SourceRegion extends Serializable

    helper object

  18. object TokenList

    helper object

  19. object UnicodeMap
  20. object UnicodeReplacer extends WordReplacer

    replaces typical multi-ascii-symbol operators (e.g., arrows and double brackets) with the corresponding Unicode symbol defined by the file

  21. object ViewKey

    matches the keyword for a view

Inherited from AnyRef

Inherited from Any

Ungrouped