Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data PermType
- permTypeToCode :: PermType -> Text
- data PermColSpec b
- data PermDef (b :: BackendType) (perm :: BackendType -> Type) = PermDef {
- _pdRole :: RoleName
- _pdPermission :: PermDefPermission b perm
- _pdComment :: Maybe Text
- data PermDefPermission (b :: BackendType) (perm :: BackendType -> Type) where
- SelPerm' :: SelPerm b -> PermDefPermission b SelPerm
- InsPerm' :: InsPerm b -> PermDefPermission b InsPerm
- UpdPerm' :: UpdPerm b -> PermDefPermission b UpdPerm
- DelPerm' :: DelPerm b -> PermDefPermission b DelPerm
- unPermDefPermission :: PermDefPermission b perm -> perm b
- reflectPermDefPermission :: PermDefPermission b a -> PermType
- data QueryRootFieldType
- data SubscriptionRootFieldType
- data InsPerm (b :: BackendType) = InsPerm {
- ipCheck :: BoolExp b
- ipSet :: Maybe (ColumnValues b Value)
- ipColumns :: Maybe (PermColSpec b)
- ipBackendOnly :: Bool
- ipValidateInput :: Maybe (ValidateInput InputWebhook)
- type InsPermDef b = PermDef b InsPerm
- data AllowedRootFields rootFieldType
- = ARFAllowAllRootFields
- | ARFAllowConfiguredRootFields (HashSet rootFieldType)
- isRootFieldAllowed :: Eq rootField => rootField -> AllowedRootFields rootField -> Bool
- data ValidateInputHttpDefinition webhook = ValidateInputHttpDefinition {
- _vihdUrl :: webhook
- _vihdHeaders :: [HeaderConf]
- _vihdTimeout :: Timeout
- _vihdForwardClientHeaders :: Bool
- data ValidateInput webhook = VIHttp (ValidateInputHttpDefinition webhook)
- data SelPerm (b :: BackendType) = SelPerm {}
- type SelPermDef b = PermDef b SelPerm
- data DelPerm (b :: BackendType) = DelPerm {}
- type DelPermDef b = PermDef b DelPerm
- data UpdPerm (b :: BackendType) = UpdPerm {
- ucColumns :: PermColSpec b
- ucSet :: Maybe (ColumnValues b Value)
- ucFilter :: BoolExp b
- ucCheck :: Maybe (BoolExp b)
- ucBackendOnly :: Bool
- ucValidateInput :: Maybe (ValidateInput InputWebhook)
- type UpdPermDef b = PermDef b UpdPerm
- pdRole :: forall b perm. Lens' (PermDef b perm) RoleName
- pdPermission :: forall b perm b perm. Lens (PermDef b perm) (PermDef b perm) (PermDefPermission b perm) (PermDefPermission b perm)
- pdComment :: forall b perm. Lens' (PermDef b perm) (Maybe Text)
Documentation
Instances
FromJSON PermType Source # | |
ToJSON PermType Source # | |
Generic PermType Source # | |
Show PermType Source # | |
NFData PermType Source # | |
Defined in Hasura.RQL.Types.Permission | |
Eq PermType Source # | |
Ord PermType Source # | |
Defined in Hasura.RQL.Types.Permission | |
Hashable PermType Source # | |
FromCol PermType Source # | |
Defined in Hasura.RQL.Types.Permission | |
type Rep PermType Source # | |
Defined in Hasura.RQL.Types.Permission type Rep PermType = D1 ('MetaData "PermType" "Hasura.RQL.Types.Permission" "graphql-engine-1.0.0-inplace" 'False) ((C1 ('MetaCons "PTInsert" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "PTSelect" 'PrefixI 'False) (U1 :: Type -> Type)) :+: (C1 ('MetaCons "PTUpdate" 'PrefixI 'False) (U1 :: Type -> Type) :+: C1 ('MetaCons "PTDelete" 'PrefixI 'False) (U1 :: Type -> Type))) |
permTypeToCode :: PermType -> Text Source #
data PermColSpec b Source #
Instances
data PermDef (b :: BackendType) (perm :: BackendType -> Type) Source #
PermDef | |
|
Instances
data PermDefPermission (b :: BackendType) (perm :: BackendType -> Type) where Source #
The permission data as it appears in a PermDef
.
Since this type is a GADT it facilitates that values which are polymorphic
may re-discover its specific type of permission by case analysis.
The fact that permission types are tracked in types are more accidental than intentional and something we want to move away from, see https://github.com/hasura/graphql-engine-mono/issues/4076.
SelPerm' :: SelPerm b -> PermDefPermission b SelPerm | |
InsPerm' :: InsPerm b -> PermDefPermission b InsPerm | |
UpdPerm' :: UpdPerm b -> PermDefPermission b UpdPerm | |
DelPerm' :: DelPerm b -> PermDefPermission b DelPerm |
Instances
unPermDefPermission :: PermDefPermission b perm -> perm b Source #
reflectPermDefPermission :: PermDefPermission b a -> PermType Source #
data QueryRootFieldType Source #
Instances
data SubscriptionRootFieldType Source #
Instances
data InsPerm (b :: BackendType) Source #
InsPerm | |
|
Instances
type InsPermDef b = PermDef b InsPerm Source #
data AllowedRootFields rootFieldType Source #
ARFAllowAllRootFields | |
ARFAllowConfiguredRootFields (HashSet rootFieldType) |
Instances
isRootFieldAllowed :: Eq rootField => rootField -> AllowedRootFields rootField -> Bool Source #
data ValidateInputHttpDefinition webhook Source #
ValidateInputHttpDefinition | |
|
Instances
data ValidateInput webhook Source #
VIHttp (ValidateInputHttpDefinition webhook) |
Instances
data SelPerm (b :: BackendType) Source #
SelPerm | |
|
Instances
type SelPermDef b = PermDef b SelPerm Source #
data DelPerm (b :: BackendType) Source #
DelPerm | |
|
Instances
type DelPermDef b = PermDef b DelPerm Source #
data UpdPerm (b :: BackendType) Source #
UpdPerm | |
|
Instances
type UpdPermDef b = PermDef b UpdPerm Source #
pdPermission :: forall b perm b perm. Lens (PermDef b perm) (PermDef b perm) (PermDefPermission b perm) (PermDefPermission b perm) Source #