intercept

package
v0.0.0-...-c1ffc38 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 2, 2023 License: Apache-2.0 Imports: 30 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppActionFunc

type AppActionFunc func(context.Context, *ent.AppActionQuery) (ent.Value, error)

The AppActionFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppActionFunc) Query

func (f AppActionFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppDictFunc

type AppDictFunc func(context.Context, *ent.AppDictQuery) (ent.Value, error)

The AppDictFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppDictFunc) Query

func (f AppDictFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppDictItemFunc

type AppDictItemFunc func(context.Context, *ent.AppDictItemQuery) (ent.Value, error)

The AppDictItemFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppDictItemFunc) Query

func (f AppDictItemFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppFunc

type AppFunc func(context.Context, *ent.AppQuery) (ent.Value, error)

The AppFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppFunc) Query

func (f AppFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppMenuFunc

type AppMenuFunc func(context.Context, *ent.AppMenuQuery) (ent.Value, error)

The AppMenuFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppMenuFunc) Query

func (f AppMenuFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppPolicyFunc

type AppPolicyFunc func(context.Context, *ent.AppPolicyQuery) (ent.Value, error)

The AppPolicyFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppPolicyFunc) Query

func (f AppPolicyFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppResFunc

type AppResFunc func(context.Context, *ent.AppResQuery) (ent.Value, error)

The AppResFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppResFunc) Query

func (f AppResFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppRoleFunc

type AppRoleFunc func(context.Context, *ent.AppRoleQuery) (ent.Value, error)

The AppRoleFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppRoleFunc) Query

func (f AppRoleFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type AppRolePolicyFunc

type AppRolePolicyFunc func(context.Context, *ent.AppRolePolicyQuery) (ent.Value, error)

The AppRolePolicyFunc type is an adapter to allow the use of ordinary function as a Querier.

func (AppRolePolicyFunc) Query

func (f AppRolePolicyFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type FileFunc

type FileFunc func(context.Context, *ent.FileQuery) (ent.Value, error)

The FileFunc type is an adapter to allow the use of ordinary function as a Querier.

func (FileFunc) Query

func (f FileFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type FileSourceFunc

type FileSourceFunc func(context.Context, *ent.FileSourceQuery) (ent.Value, error)

The FileSourceFunc type is an adapter to allow the use of ordinary function as a Querier.

func (FileSourceFunc) Query

func (f FileSourceFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type Func

type Func func(context.Context, Query) error

The Func type is an adapter that allows ordinary functions to be used as interceptors. Unlike traversal functions, interceptors are skipped during graph traversals. Note that the implementation of Func is different from the one defined in entgo.io/ent.InterceptFunc.

func (Func) Intercept

func (f Func) Intercept(next ent.Querier) ent.Querier

Intercept calls f(ctx, q) and then applied the next Querier.

type OauthClientFunc

type OauthClientFunc func(context.Context, *ent.OauthClientQuery) (ent.Value, error)

The OauthClientFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OauthClientFunc) Query

func (f OauthClientFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgAppFunc

type OrgAppFunc func(context.Context, *ent.OrgAppQuery) (ent.Value, error)

The OrgAppFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgAppFunc) Query

func (f OrgAppFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgFunc

type OrgFunc func(context.Context, *ent.OrgQuery) (ent.Value, error)

The OrgFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgFunc) Query

func (f OrgFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgPolicyFunc

type OrgPolicyFunc func(context.Context, *ent.OrgPolicyQuery) (ent.Value, error)

The OrgPolicyFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgPolicyFunc) Query

func (f OrgPolicyFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgRoleFunc

type OrgRoleFunc func(context.Context, *ent.OrgRoleQuery) (ent.Value, error)

The OrgRoleFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgRoleFunc) Query

func (f OrgRoleFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgRoleUserFunc

type OrgRoleUserFunc func(context.Context, *ent.OrgRoleUserQuery) (ent.Value, error)

The OrgRoleUserFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgRoleUserFunc) Query

func (f OrgRoleUserFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgUserFunc

type OrgUserFunc func(context.Context, *ent.OrgUserQuery) (ent.Value, error)

The OrgUserFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgUserFunc) Query

func (f OrgUserFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type OrgUserPreferenceFunc

type OrgUserPreferenceFunc func(context.Context, *ent.OrgUserPreferenceQuery) (ent.Value, error)

The OrgUserPreferenceFunc type is an adapter to allow the use of ordinary function as a Querier.

func (OrgUserPreferenceFunc) Query

Query calls f(ctx, q).

type PermissionFunc

type PermissionFunc func(context.Context, *ent.PermissionQuery) (ent.Value, error)

The PermissionFunc type is an adapter to allow the use of ordinary function as a Querier.

func (PermissionFunc) Query

func (f PermissionFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type Query

type Query interface {
	// Type returns the string representation of the query type.
	Type() string
	// Limit the number of records to be returned by this query.
	Limit(int)
	// Offset to start from.
	Offset(int)
	// Unique configures the query builder to filter duplicate records.
	Unique(bool)
	// Order specifies how the records should be ordered.
	Order(...func(*sql.Selector))
	// WhereP appends storage-level predicates to the query builder. Using this method, users
	// can use type-assertion to append predicates that do not depend on any generated package.
	WhereP(...func(*sql.Selector))
}

The Query interface represents an operation that queries a graph. By using this interface, users can write generic code that manipulates query builders of different types.

func NewQuery

func NewQuery(q ent.Query) (Query, error)

NewQuery returns the generic Query interface for the given typed query.

type TraverseApp

type TraverseApp func(context.Context, *ent.AppQuery) error

The TraverseApp type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseApp) Intercept

func (f TraverseApp) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseApp) Traverse

func (f TraverseApp) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppAction

type TraverseAppAction func(context.Context, *ent.AppActionQuery) error

The TraverseAppAction type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppAction) Intercept

func (f TraverseAppAction) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppAction) Traverse

func (f TraverseAppAction) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppDict

type TraverseAppDict func(context.Context, *ent.AppDictQuery) error

The TraverseAppDict type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppDict) Intercept

func (f TraverseAppDict) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppDict) Traverse

func (f TraverseAppDict) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppDictItem

type TraverseAppDictItem func(context.Context, *ent.AppDictItemQuery) error

The TraverseAppDictItem type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppDictItem) Intercept

func (f TraverseAppDictItem) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppDictItem) Traverse

func (f TraverseAppDictItem) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppMenu

type TraverseAppMenu func(context.Context, *ent.AppMenuQuery) error

The TraverseAppMenu type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppMenu) Intercept

func (f TraverseAppMenu) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppMenu) Traverse

func (f TraverseAppMenu) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppPolicy

type TraverseAppPolicy func(context.Context, *ent.AppPolicyQuery) error

The TraverseAppPolicy type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppPolicy) Intercept

func (f TraverseAppPolicy) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppPolicy) Traverse

func (f TraverseAppPolicy) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppRes

type TraverseAppRes func(context.Context, *ent.AppResQuery) error

The TraverseAppRes type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppRes) Intercept

func (f TraverseAppRes) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppRes) Traverse

func (f TraverseAppRes) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppRole

type TraverseAppRole func(context.Context, *ent.AppRoleQuery) error

The TraverseAppRole type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppRole) Intercept

func (f TraverseAppRole) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppRole) Traverse

func (f TraverseAppRole) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseAppRolePolicy

type TraverseAppRolePolicy func(context.Context, *ent.AppRolePolicyQuery) error

The TraverseAppRolePolicy type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseAppRolePolicy) Intercept

func (f TraverseAppRolePolicy) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseAppRolePolicy) Traverse

func (f TraverseAppRolePolicy) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseFile

type TraverseFile func(context.Context, *ent.FileQuery) error

The TraverseFile type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseFile) Intercept

func (f TraverseFile) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseFile) Traverse

func (f TraverseFile) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseFileSource

type TraverseFileSource func(context.Context, *ent.FileSourceQuery) error

The TraverseFileSource type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseFileSource) Intercept

func (f TraverseFileSource) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseFileSource) Traverse

func (f TraverseFileSource) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseFunc

type TraverseFunc func(context.Context, Query) error

The TraverseFunc type is an adapter to allow the use of ordinary function as Traverser. If f is a function with the appropriate signature, TraverseFunc(f) is a Traverser that calls f.

func (TraverseFunc) Intercept

func (f TraverseFunc) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseFunc) Traverse

func (f TraverseFunc) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOauthClient

type TraverseOauthClient func(context.Context, *ent.OauthClientQuery) error

The TraverseOauthClient type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOauthClient) Intercept

func (f TraverseOauthClient) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOauthClient) Traverse

func (f TraverseOauthClient) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrg

type TraverseOrg func(context.Context, *ent.OrgQuery) error

The TraverseOrg type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrg) Intercept

func (f TraverseOrg) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrg) Traverse

func (f TraverseOrg) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgApp

type TraverseOrgApp func(context.Context, *ent.OrgAppQuery) error

The TraverseOrgApp type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgApp) Intercept

func (f TraverseOrgApp) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgApp) Traverse

func (f TraverseOrgApp) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgPolicy

type TraverseOrgPolicy func(context.Context, *ent.OrgPolicyQuery) error

The TraverseOrgPolicy type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgPolicy) Intercept

func (f TraverseOrgPolicy) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgPolicy) Traverse

func (f TraverseOrgPolicy) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgRole

type TraverseOrgRole func(context.Context, *ent.OrgRoleQuery) error

The TraverseOrgRole type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgRole) Intercept

func (f TraverseOrgRole) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgRole) Traverse

func (f TraverseOrgRole) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgRoleUser

type TraverseOrgRoleUser func(context.Context, *ent.OrgRoleUserQuery) error

The TraverseOrgRoleUser type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgRoleUser) Intercept

func (f TraverseOrgRoleUser) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgRoleUser) Traverse

func (f TraverseOrgRoleUser) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgUser

type TraverseOrgUser func(context.Context, *ent.OrgUserQuery) error

The TraverseOrgUser type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgUser) Intercept

func (f TraverseOrgUser) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgUser) Traverse

func (f TraverseOrgUser) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseOrgUserPreference

type TraverseOrgUserPreference func(context.Context, *ent.OrgUserPreferenceQuery) error

The TraverseOrgUserPreference type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseOrgUserPreference) Intercept

func (f TraverseOrgUserPreference) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseOrgUserPreference) Traverse

Traverse calls f(ctx, q).

type TraversePermission

type TraversePermission func(context.Context, *ent.PermissionQuery) error

The TraversePermission type is an adapter to allow the use of ordinary function as Traverser.

func (TraversePermission) Intercept

func (f TraversePermission) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraversePermission) Traverse

func (f TraversePermission) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseUser

type TraverseUser func(context.Context, *ent.UserQuery) error

The TraverseUser type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseUser) Intercept

func (f TraverseUser) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseUser) Traverse

func (f TraverseUser) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseUserDevice

type TraverseUserDevice func(context.Context, *ent.UserDeviceQuery) error

The TraverseUserDevice type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseUserDevice) Intercept

func (f TraverseUserDevice) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseUserDevice) Traverse

func (f TraverseUserDevice) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseUserIdentity

type TraverseUserIdentity func(context.Context, *ent.UserIdentityQuery) error

The TraverseUserIdentity type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseUserIdentity) Intercept

func (f TraverseUserIdentity) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseUserIdentity) Traverse

func (f TraverseUserIdentity) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type TraverseUserLoginProfile

type TraverseUserLoginProfile func(context.Context, *ent.UserLoginProfileQuery) error

The TraverseUserLoginProfile type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseUserLoginProfile) Intercept

func (f TraverseUserLoginProfile) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseUserLoginProfile) Traverse

Traverse calls f(ctx, q).

type TraverseUserPassword

type TraverseUserPassword func(context.Context, *ent.UserPasswordQuery) error

The TraverseUserPassword type is an adapter to allow the use of ordinary function as Traverser.

func (TraverseUserPassword) Intercept

func (f TraverseUserPassword) Intercept(next ent.Querier) ent.Querier

Intercept is a dummy implementation of Intercept that returns the next Querier in the pipeline.

func (TraverseUserPassword) Traverse

func (f TraverseUserPassword) Traverse(ctx context.Context, q ent.Query) error

Traverse calls f(ctx, q).

type UserDeviceFunc

type UserDeviceFunc func(context.Context, *ent.UserDeviceQuery) (ent.Value, error)

The UserDeviceFunc type is an adapter to allow the use of ordinary function as a Querier.

func (UserDeviceFunc) Query

func (f UserDeviceFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type UserFunc

type UserFunc func(context.Context, *ent.UserQuery) (ent.Value, error)

The UserFunc type is an adapter to allow the use of ordinary function as a Querier.

func (UserFunc) Query

func (f UserFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type UserIdentityFunc

type UserIdentityFunc func(context.Context, *ent.UserIdentityQuery) (ent.Value, error)

The UserIdentityFunc type is an adapter to allow the use of ordinary function as a Querier.

func (UserIdentityFunc) Query

func (f UserIdentityFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

type UserLoginProfileFunc

type UserLoginProfileFunc func(context.Context, *ent.UserLoginProfileQuery) (ent.Value, error)

The UserLoginProfileFunc type is an adapter to allow the use of ordinary function as a Querier.

func (UserLoginProfileFunc) Query

Query calls f(ctx, q).

type UserPasswordFunc

type UserPasswordFunc func(context.Context, *ent.UserPasswordQuery) (ent.Value, error)

The UserPasswordFunc type is an adapter to allow the use of ordinary function as a Querier.

func (UserPasswordFunc) Query

func (f UserPasswordFunc) Query(ctx context.Context, q ent.Query) (ent.Value, error)

Query calls f(ctx, q).

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL