Class Semirings
java.lang.Object
com.darkcollective.relix.provenance.Semirings
Resolves a
Semiring by name — the lookup the surfacing layer uses to turn a
--provenance=<name> request into a concrete semiring without the caller
hard-wiring the singletons.
It answers from SemiringCatalog.installed(), so the names it resolves are the
bundled six plus every semiring an installed SemiringLibrary offers.
Names are case-insensitive, and each bundled semiring carries a friendly alias:
set → boolean, bag/natural → counting,
shortest-path → tropical, lattice → security,
polynomial/why → lineage, best-path → cheapest-route.
Use SemiringCatalog directly to read a semiring's description, to assemble a
catalog of your own, or to re-run discovery.
-
Method Summary
-
Method Details
-
byName
Resolves an installed semiring by (case-insensitive) name or alias.- Parameters:
name- the semiring name or alias; may benull- Returns:
- the matching semiring, or empty if
nameis null or unknown
-
names
Returns the canonical names of every installed semiring. Aliases are omitted; this is the list to show in help and error messages.- Returns:
- the canonical names of every installed semiring
-