Dantzig.ConstraintMetadata (Danztig v0.2.0)
View SourceConstraint metadata for debugging purposes.
Summary
Functions
Create a metadata struct from an environment (e.g. __ENV__
, __CALLER__
),
and some extra attributes.
Converts constraint metadata into a comment in the .lp
file format.
Updates a metadata struct withn extra attributes.
Types
Functions
Create a metadata struct from an environment (e.g. __ENV__
, __CALLER__
),
and some extra attributes.
Supports the following extra attributes:
:tags
(optional, default: []):attrs
(optional, default: [])
Converts constraint metadata into a comment in the .lp
file format.
Supports nil
as an argument, so it can be used for constraints without metadata.
Updates a metadata struct withn extra attributes.
Supports the following extra attributes:
:tags
(optional, default: []):attrs
(optional, default: [])
If the :app
field isn't present, the function will attempt
to get the :app
value from the given :module
.
If the metadata was created from an environment,
sometimes the application name can't be deduced at
compile time, and if this function runs at runtime,
it will pretty much always be able to get the application
from the module name.