func (f GroupFunc) Mutate(ctx context.Context, m ent.Mutation) (ent.Value, error) {
	mv, ok := m.(*ent.GroupMutation)
	if !ok {
		return nil, fmt.Errorf("unexpected mutation type %T. expect *ent.GroupMutation", m)
	}
	return f(ctx, mv)
}
Mutate calls f(ctx, m).
package hook
import (
	"context"
	"fmt"
	"entgo.io/contrib/entproto/internal/todo/ent"
)
type AttachmentFunc func(context.Context, *ent.AttachmentMutation) (ent.Value, error)
func (f AttachmentFunc) Mutate(ctx context.Context, m ent.Mutation) (ent.Value, error) {
	mv, ok := m.(*ent.AttachmentMutation)
	if !ok {
		return nil, fmt.Errorf("unexpected mutation type %T. expect *ent.AttachmentMutation", m)
	}
	return f(ctx, mv)
}
type GroupFunc func(context.Context, *ent.GroupMutation) (ent.Value, error)