package valuebases
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.
- Source
- package.scala
- Alphabetic
- By Inheritance
- valuebases
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
class
BigIntCodec extends LiteralsCodec[BigInt, JSON]
encodes positive integers as list of (sign * number of digits) :: (digits most to least) relative to base 2^31
encodes positive integers as list of (sign * number of digits) :: (digits most to least) relative to base 2^31
Note that this encoding has the property that <= on integers corresponds to lexicographic ordering on lists.
-
class
BigIntSplitter extends AnyRef
auxiliary class for transforming integer into different bases
-
abstract
class
Codec[Code] extends AnyRef
encodes/decodes terms of a certain type
-
abstract
class
CodecOperator[Code, C <: Codec[Code]] extends AnyRef
encodes/decodes terms whose type is of the form T = OMA(OMS(tp), pars)
-
class
Coder[Code, C <: Codec[Code]] extends AnyRef
encodes/decodes terms using a set of Codecs and CodecOperators
-
class
EmbedJSONToScala extends Embedding[JSON, Any]
embeds JSON codecs into codecs that use Scala values as codes
-
class
EmbedStringToJSON extends Embedding[String, JSON]
embeds string encodings into JSON encodings
-
abstract
class
Embedding[From, To] extends Codec[To]
lifts an embedding between code types to a functor on codecs
lifts an embedding between code types to a functor on codecs
This is particularly useful to use AtomicStringCodec to code literals as strings and then lift the strings into the desired code type.
-
abstract
class
ListCodec[Code] extends CodecOperator[Code, Codec[Code]]
codes a list
-
class
LiteralsAsStringsCodec[Rep] extends Codec[String]
turns a realized type into the corresponding codec using the toString/fromString functions of the semantic type
-
abstract
class
LiteralsCodec[Rep, Code] extends Codec[Code]
encodes/decodes literals
encodes/decodes literals
the abstract methods must handle the toString/fromString for type Rep
- Rep
the underlying type of the literals
- Code
the target type of the codecs
Value Members
- object CodecNotApplicable extends Throwable with Product with Serializable