Little bit of boilerplate to get around the fact that Scala type parameter inference is either all or nothing.
Little bit of boilerplate to get around the fact that Scala type parameter inference is either all or nothing. See http://stackoverflow.com/questions/10726222/simulate-partial-type-parameter-inference-with-implicits/10734268#10734268 for an explaination of why this is necessary and the sample from which this code is derived from.
the return type
Asserts a new fact in the database
Asserts a new fact in the database
the Datomic Data type
the cardinality of the attribute
the type of the value that you are adding
the entity ID
the assertion of the form Schema.thing -> value
the database connection
the execution context
the Attribute2FactWriter
the database result
See EntityGetter.apply().
See EntityGetter.apply().
the type that you want returned
the EntityGetter
Returns a single entity (the first entity if there are many that match the query) as an option or None
if there
are no results matching the query
Returns a single entity (the first entity if there are many that match the query) as an option or None
if there
are no results matching the query
the executed query
the database - Required to convert the entity ID to the full entity. For consistency, This should be the same database that you used to execute the query.
the reader to convert to the specified entity type
Some(entity)
of there is at lease one result where entity
is the first entity found, or None
if there
are no results
Returns the list of entities chosen by the query tupled with its ID.
Returns the list of entities chosen by the query tupled with its ID.
the Datomic Query
the database - Required to convert the entity ID to the full entity. For consistency, This should be the same database that you used to execute the query.
the reader for the entity
Runs a query and pulls a single page worth of values out.
Runs a query and pulls a single page worth of values out.
the query
the filter
the database - Required to convert the entity ID to the full entity. For consistency, This should be the same database that you used to execute the query.
the entity reader
the Page
Retract an individual attribute for a given entity.
Retract an individual attribute for a given entity. Before issuing the retraction, it first checks that there is a value there to retract. If there is not, this method is simply a NOOP.
the type of the ID
the Datomic Data type
the cardinality of the attribute
the type of the value that you are retracting
the identified for the entity. Can either be an ID, or a lookup ref
the attribute to retract
the database connection
the ExecutionContext
the Attribute2EntityReaderInj
the Attribute2FactWriter
the ID converter
a successful future if all goes well
This is the Datomic equivalent of a delete, except in Datomic, nothing ever gets deleted.
This is the Datomic equivalent of a delete, except in Datomic, nothing ever gets deleted. You can only insert a retraction, that flags the specified entity as ignored.
the type of the ID, can either be a Long or a LookupRef
the ID of the entity to retract
the ExecutionContext
the transaction record specifying whether or not the transaction succeeded or failed
Generate a unique UUID to be used as a lookup-ref.
Generate a unique UUID to be used as a lookup-ref. Abstracting away the fact that we are using Datomic to generate UUIDs. We are using Datomic for reasons specified here: http://docs.datomic.com/identity.html
the UUID
Retrieves the value of a particular field for a particular entity.
Retrieves the value of a particular field for a particular entity. In other words, in the EAVT structure of Datomic this method allows you to specify the id (E), attribute (A), and what you will get in return is the most recent (T) value (V).
the Datomic Data type
the cardinality
the return type (must correspond to the Datomic data type)
the ID of the entity that you want to query
the schema attribute of the field that you want to get
the database
the converter
the field value
Retrieves the optional value of a particular attribute for a particular entity, from a particular database value.
Retrieves the optional value of a particular attribute for a particular entity, from a particular database value. In other words, in the EAVT structure of Datomic this method allows you to specify the id (E), attribute (A), and what you will get in return is the most recent (T) value (V), for the supplied database.
the Datomic Data type
the cardinality
the return type (must correspond to the Datomic data type)
the ID of the entity that you want to query
the schema attribute of the field that you want to get
the database
the converter
the field value
Object abstraction with for interacting with Datomic. Note that this object, is not intended to try and abstract/hide away the fact that we are using Datomic, but rather intends to make it easier to use Datomic the way that we want to use it in this app.