Welcome | Get started | Dive | Contribute | Topics | Reference | Changes | More
lino.api¶
The lino.api package exposes Lino functionalities commonly used by
application developers. It has one module for each of the three startup phases
used when writing application code:
lino.ad contains classes and functions that are available already before your Lino application gets initialized. You use it to define your overall application structure (in your
settings.pyfiles and in the__init__.pyfiles of your plugins).The lino.api.dd module (database design) is for when you are describing your database schema in your
models.pymodules.The lino.api.rt module (runtime) contains functions and classes that are commonly used “at runtime”, i.e. when the Lino application has been initialized. You may import it at the global namespace of a
models.pyfile, but you can use most of it only when thestartup()function has been called.
Recommended usage is to import these modules as follows:
from lino.api import ad, dd, rt, _
The modules in lino.api don’t define anything on their own but just
import things that are commonly used in these different contexts.