napkin-runtime-2.0.0
Safe HaskellNone
LanguageGHC2024

Napkin.Spec.Graph

Synopsis

Documentation

data ApplyQueryTransformers #

Constructors

ApplyQueryTransformers

ApplyQueryTransformers is not used (as unmanaged tables spec names are lost, and they are needed for table selectors), but is possible to use them to construct DAG graph.

NotApplyTblRenames

Useful for dump command, so query transformers are applied to dumped queries

NotApplyQueryTransformers

Used for run command where we just dependencies discover is needed, so transformers are not needed at all

toDependency :: Specs b -> Ref Table -> SpecDependency #

This is what we want to use when packing a SpecDependency. programDependenciesAndQueries will return a Dependencies :: Set (Ref Table), and without more information it is impossible to tell if these are managed or unmanaged. However, taken with a Specs this can be deduced. If the packed table ref is not a member of the specsTables found in the Specs then it is UnManaged, and should be marked as such. Otherwise it is managed and can safely be packed using Managed . SpecTableName. Use of constructor is necessary here.