Safe Haskell | None |
---|---|
Language | Haskell2010 |
Data.OpenApi.Compare.Subtree
Contents
Synopsis
- class (Typeable Step, Typeable a, Typeable b, Ord (Step a b), Show (Step a b)) => Steppable (a :: Type) (b :: Type) where
- data TraceRoot
- type Trace = Paths Step TraceRoot
- type Traced a = Traced' a a
- type Traced' a b = Env (Trace a) b
- pattern Traced :: Trace a -> b -> Traced' a b
- traced :: Trace a -> a -> Traced a
- retraced :: (Trace a -> Trace a') -> Traced' a b -> Traced' a' b
- stepTraced :: Steppable a a' => Step a a' -> Traced' a b -> Traced' a' b
- class (Typeable t, Issuable (SubtreeLevel t)) => Subtree (t :: Type) where
- type CheckEnv t :: [Type]
- type SubtreeLevel t :: BehaviorLevel
- checkStructuralCompatibility :: HList (CheckEnv t) -> ProdCons (Traced t) -> StructuralCompatFormula ()
- checkSemanticCompatibility :: HList (CheckEnv t) -> Behavior (SubtreeLevel t) -> ProdCons (Traced t) -> SemanticCompatFormula ()
- checkCompatibility :: forall t xs. (ReassembleHList xs (CheckEnv t), Subtree t) => Behavior (SubtreeLevel t) -> HList xs -> ProdCons (Traced t) -> SemanticCompatFormula ()
- checkSubstructure :: (ReassembleHList xs (CheckEnv t), Subtree t) => HList xs -> ProdCons (Traced t) -> StructuralCompatFormula ()
- newtype CompatM a = CompatM {}
- type CompatFormula' q f r = Compose CompatM (FormulaF q f r)
- type SemanticCompatFormula = CompatFormula' Behave AnIssue 'APILevel
- data ProdCons a = ProdCons {}
- orientProdCons :: Orientation -> ProdCons x -> ProdCons x
- swapProdCons :: SwapEnvRoles xs => (HList xs -> ProdCons x -> CompatFormula' q AnIssue r a) -> HList xs -> ProdCons x -> CompatFormula' q AnIssue r a
- runCompatFormula :: CompatFormula' q f r a -> Either (PathsPrefixTree q f r) a
- issueAt :: Issuable l => Paths q r l -> Issue l -> CompatFormula' q AnIssue r a
- anItem :: AnItem q AnIssue r -> CompatFormula' q AnIssue r a
- anIssue :: Issuable l => Issue l -> AnIssue l
- invertIssueOrientation :: CompatFormula' q AnIssue r a -> CompatFormula' q AnIssue r a
- invertIssueOrientationP :: PathsPrefixTree q AnIssue r -> PathsPrefixTree q AnIssue r
- embedFormula :: Paths q r l -> CompatFormula' q f l a -> CompatFormula' q f r a
- anyOfAt :: Issuable l => Paths q r l -> Issue l -> [CompatFormula' q AnIssue r a] -> CompatFormula' q AnIssue r a
- clarifyIssue :: AnItem q AnIssue r -> CompatFormula' q AnIssue r a -> CompatFormula' q AnIssue r a
- structuralIssue :: StructuralCompatFormula a
- structuralMaybe :: (Subtree a, ReassembleHList xs (CheckEnv a)) => HList xs -> ProdCons (Maybe (Traced a)) -> StructuralCompatFormula ()
- structuralMaybeWith :: (ProdCons a -> StructuralCompatFormula ()) -> ProdCons (Maybe a) -> StructuralCompatFormula ()
- structuralEq :: (Eq a, Comonad w) => ProdCons (w a) -> StructuralCompatFormula ()
- iohmStructural :: (ReassembleHList (k ': xs) (CheckEnv v), Ord k, Subtree v, Hashable k, Typeable k, Show k) => HList xs -> ProdCons (Traced (InsOrdHashMap k v)) -> StructuralCompatFormula ()
- iohmStructuralWith :: (Ord k, Hashable k, Typeable k, Typeable v, Show k) => (k -> ProdCons (Traced v) -> StructuralCompatFormula ()) -> ProdCons (Traced (InsOrdHashMap k v)) -> StructuralCompatFormula ()
- structuralList :: (Subtree a, ReassembleHList xs (CheckEnv a)) => HList xs -> ProdCons [Traced a] -> StructuralCompatFormula ()
- (>>>) :: forall k cat (a :: k) (b :: k) (c :: k). Category cat => cat a b -> cat b c -> cat a c
- (<<<) :: forall k cat (b :: k) (c :: k) (a :: k). Category cat => cat b c -> cat a b -> cat a c
- extract :: Comonad w => w a -> a
- ask :: ComonadEnv e w => w a -> e
- local :: forall e e' (w :: Type -> Type) a. (e -> e') -> EnvT e w a -> EnvT e' w a
- step :: NiceQuiver q a b => q a b -> Paths q a b
- class Typeable (a :: k)
Documentation
class (Typeable Step, Typeable a, Typeable b, Ord (Step a b), Show (Step a b)) => Steppable (a :: Type) (b :: Type) Source #
Instances
Instances
class (Typeable t, Issuable (SubtreeLevel t)) => Subtree (t :: Type) where Source #
Methods
checkStructuralCompatibility :: HList (CheckEnv t) -> ProdCons (Traced t) -> StructuralCompatFormula () Source #
Warning: You should not be calling this directly. Use checkSubstructure
checkSemanticCompatibility :: HList (CheckEnv t) -> Behavior (SubtreeLevel t) -> ProdCons (Traced t) -> SemanticCompatFormula () Source #
Warning: You should not be calling this directly. Use checkCompatibility
Instances
checkCompatibility :: forall t xs. (ReassembleHList xs (CheckEnv t), Subtree t) => Behavior (SubtreeLevel t) -> HList xs -> ProdCons (Traced t) -> SemanticCompatFormula () Source #
checkSubstructure :: (ReassembleHList xs (CheckEnv t), Subtree t) => HList xs -> ProdCons (Traced t) -> StructuralCompatFormula () Source #
Instances
Functor ProdCons Source # | |
Applicative ProdCons Source # | |
Foldable ProdCons Source # | |
Defined in Data.OpenApi.Compare.Subtree Methods fold :: Monoid m => ProdCons m -> m # foldMap :: Monoid m => (a -> m) -> ProdCons a -> m # foldMap' :: Monoid m => (a -> m) -> ProdCons a -> m # foldr :: (a -> b -> b) -> b -> ProdCons a -> b # foldr' :: (a -> b -> b) -> b -> ProdCons a -> b # foldl :: (b -> a -> b) -> b -> ProdCons a -> b # foldl' :: (b -> a -> b) -> b -> ProdCons a -> b # foldr1 :: (a -> a -> a) -> ProdCons a -> a # foldl1 :: (a -> a -> a) -> ProdCons a -> a # elem :: Eq a => a -> ProdCons a -> Bool # maximum :: Ord a => ProdCons a -> a # minimum :: Ord a => ProdCons a -> a # | |
Traversable ProdCons Source # | |
Defined in Data.OpenApi.Compare.Subtree | |
Eq a => Eq (ProdCons a) Source # | |
Ord a => Ord (ProdCons a) Source # | |
Defined in Data.OpenApi.Compare.Subtree | |
Show a => Show (ProdCons a) Source # | |
orientProdCons :: Orientation -> ProdCons x -> ProdCons x Source #
swapProdCons :: SwapEnvRoles xs => (HList xs -> ProdCons x -> CompatFormula' q AnIssue r a) -> HList xs -> ProdCons x -> CompatFormula' q AnIssue r a Source #
runCompatFormula :: CompatFormula' q f r a -> Either (PathsPrefixTree q f r) a Source #
invertIssueOrientation :: CompatFormula' q AnIssue r a -> CompatFormula' q AnIssue r a Source #
invertIssueOrientationP :: PathsPrefixTree q AnIssue r -> PathsPrefixTree q AnIssue r Source #
embedFormula :: Paths q r l -> CompatFormula' q f l a -> CompatFormula' q f r a Source #
anyOfAt :: Issuable l => Paths q r l -> Issue l -> [CompatFormula' q AnIssue r a] -> CompatFormula' q AnIssue r a Source #
clarifyIssue :: AnItem q AnIssue r -> CompatFormula' q AnIssue r a -> CompatFormula' q AnIssue r a Source #
If the given formula contains any issues, add another issue on top. Otherwise succeed.
structuralIssue :: StructuralCompatFormula a Source #
Structural helpers
structuralMaybe :: (Subtree a, ReassembleHList xs (CheckEnv a)) => HList xs -> ProdCons (Maybe (Traced a)) -> StructuralCompatFormula () Source #
structuralMaybeWith :: (ProdCons a -> StructuralCompatFormula ()) -> ProdCons (Maybe a) -> StructuralCompatFormula () Source #
iohmStructural :: (ReassembleHList (k ': xs) (CheckEnv v), Ord k, Subtree v, Hashable k, Typeable k, Show k) => HList xs -> ProdCons (Traced (InsOrdHashMap k v)) -> StructuralCompatFormula () Source #
iohmStructuralWith :: (Ord k, Hashable k, Typeable k, Typeable v, Show k) => (k -> ProdCons (Traced v) -> StructuralCompatFormula ()) -> ProdCons (Traced (InsOrdHashMap k v)) -> StructuralCompatFormula () Source #
structuralList :: (Subtree a, ReassembleHList xs (CheckEnv a)) => HList xs -> ProdCons [Traced a] -> StructuralCompatFormula () Source #
Reexports
(>>>) :: forall k cat (a :: k) (b :: k) (c :: k). Category cat => cat a b -> cat b c -> cat a c infixr 1 #
Left-to-right composition
(<<<) :: forall k cat (b :: k) (c :: k) (a :: k). Category cat => cat b c -> cat a b -> cat a c infixr 1 #
Right-to-left composition
ask :: ComonadEnv e w => w a -> e #
local :: forall e e' (w :: Type -> Type) a. (e -> e') -> EnvT e w a -> EnvT e' w a #
Modifies the environment using the specified function.
step :: NiceQuiver q a b => q a b -> Paths q a b Source #