All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.yulichang.toolkit.JoinWrappers Maven / Gradle / Ivy

There is a newer version: 1.5.2
Show newest version
package com.github.yulichang.toolkit;

import com.github.yulichang.query.MPJQueryWrapper;
import com.github.yulichang.wrapper.DeleteJoinWrapper;
import com.github.yulichang.wrapper.MPJLambdaWrapper;
import com.github.yulichang.wrapper.UpdateJoinWrapper;

/**
 * @author yulichang
 * @since 1.4.4
 */
@SuppressWarnings("unused")
public class JoinWrappers {

    /**
     * JoinWrappers.query()
     */
    public static  MPJQueryWrapper query() {
        return new MPJQueryWrapper<>();
    }

    /**
     * JoinWrappers.query(User.class)
     */
    public static  MPJQueryWrapper query(Class clazz) {
        return new MPJQueryWrapper<>(clazz);
    }

    /**
     * JoinWrappers.query(user)
     */
    public static  MPJQueryWrapper query(T entity) {
        return new MPJQueryWrapper<>(entity);
    }

    /**
     * JoinWrappers.lambda()
     */
    public static  MPJLambdaWrapper lambda() {
        return new MPJLambdaWrapper<>();
    }

    /**
     * JoinWrappers.lambda("t")
     */
    public static  MPJLambdaWrapper lambda(String alias) {
        return new MPJLambdaWrapper<>(alias);
    }

    /**
     * JoinWrappers.lambda(User.class)
     */
    public static  MPJLambdaWrapper lambda(Class clazz) {
        return new MPJLambdaWrapper<>(clazz);
    }

    /**
     * JoinWrappers.lambda("t", User.class)
     */
    public static  MPJLambdaWrapper lambda(String alias, Class clazz) {
        return new MPJLambdaWrapper<>(clazz, alias);
    }

    /**
     * JoinWrappers.lambda(user)
     */
    public static  MPJLambdaWrapper lambda(T entity) {
        return new MPJLambdaWrapper<>(entity);
    }

    /**
     * JoinWrappers.lambda("t", user)
     */
    public static  MPJLambdaWrapper lambda(String alias, T entity) {
        return new MPJLambdaWrapper<>(entity, alias);
    }

    /**
     * JoinWrappers.delete(User.class)
     */
    public static  DeleteJoinWrapper delete(Class clazz) {
        return new DeleteJoinWrapper<>(clazz);
    }

    /**
     * JoinWrappers.delete("t", User.class)
     */
    public static  DeleteJoinWrapper delete(String alias, Class clazz) {
        return new DeleteJoinWrapper<>(clazz, alias);
    }

    /**
     * JoinWrappers.update(User.class)
     */
    public static  UpdateJoinWrapper update(Class clazz) {
        return new UpdateJoinWrapper<>(clazz);
    }

    /**
     * JoinWrappers.update("t", User.class)
     */
    public static  UpdateJoinWrapper update(String alias, Class clazz) {
        return new UpdateJoinWrapper<>(clazz, alias);
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy