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

win.doyto.query.test.menu.MenuQuery Maven / Gradle / Ivy

// Generated by delombok at Sat Jan 27 04:38:03 UTC 2024
/*
 * Copyright © 2019-2024 Forb Yuan
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package win.doyto.query.test.menu;

import win.doyto.query.annotation.DomainPath;
import win.doyto.query.core.PageQuery;
import win.doyto.query.test.user.UserQuery;

/**
 * MenuQuery
 *
 * @author f0rb on 2019-05-28
 */
public class MenuQuery extends PageQuery {
    // many-to-one
    @DomainPath(value = "menu", localField = "parentId")
    private MenuQuery parent;
    // one-to-many
    @DomainPath(value = "menu", foreignField = "parentId")
    private MenuQuery children;
    @DomainPath({"menu", "~", "perm", "~", "role", "~", "user"})
    private UserQuery user;
    private Long id;
    private String nameLike;
    private Boolean valid;


    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public static abstract class MenuQueryBuilder> extends PageQuery.PageQueryBuilder {
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private MenuQuery parent;
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private MenuQuery children;
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private UserQuery user;
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private Long id;
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private String nameLike;
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private Boolean valid;

        @java.lang.Override
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        protected abstract B self();

        @java.lang.Override
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public abstract C build();

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B parent(final MenuQuery parent) {
            this.parent = parent;
            return self();
        }

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B children(final MenuQuery children) {
            this.children = children;
            return self();
        }

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B user(final UserQuery user) {
            this.user = user;
            return self();
        }

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B id(final Long id) {
            this.id = id;
            return self();
        }

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B nameLike(final String nameLike) {
            this.nameLike = nameLike;
            return self();
        }

        /**
         * @return {@code this}.
         */
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public B valid(final Boolean valid) {
            this.valid = valid;
            return self();
        }

        @java.lang.Override
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public java.lang.String toString() {
            return "MenuQuery.MenuQueryBuilder(super=" + super.toString() + ", parent=" + this.parent + ", children=" + this.children + ", user=" + this.user + ", id=" + this.id + ", nameLike=" + this.nameLike + ", valid=" + this.valid + ")";
        }
    }


    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    private static final class MenuQueryBuilderImpl extends MenuQuery.MenuQueryBuilder {
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        private MenuQueryBuilderImpl() {
        }

        @java.lang.Override
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        protected MenuQuery.MenuQueryBuilderImpl self() {
            return this;
        }

        @java.lang.Override
        @java.lang.SuppressWarnings("all")
        @lombok.Generated
        public MenuQuery build() {
            return new MenuQuery(this);
        }
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    protected MenuQuery(final MenuQuery.MenuQueryBuilder b) {
        super(b);
        this.parent = b.parent;
        this.children = b.children;
        this.user = b.user;
        this.id = b.id;
        this.nameLike = b.nameLike;
        this.valid = b.valid;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public static MenuQuery.MenuQueryBuilder builder() {
        return new MenuQuery.MenuQueryBuilderImpl();
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public MenuQuery getParent() {
        return this.parent;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public MenuQuery getChildren() {
        return this.children;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public UserQuery getUser() {
        return this.user;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public Long getId() {
        return this.id;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public String getNameLike() {
        return this.nameLike;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public Boolean getValid() {
        return this.valid;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setParent(final MenuQuery parent) {
        this.parent = parent;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setChildren(final MenuQuery children) {
        this.children = children;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setUser(final UserQuery user) {
        this.user = user;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setId(final Long id) {
        this.id = id;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setNameLike(final String nameLike) {
        this.nameLike = nameLike;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public void setValid(final Boolean valid) {
        this.valid = valid;
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public MenuQuery() {
    }

    @java.lang.SuppressWarnings("all")
    @lombok.Generated
    public MenuQuery(final MenuQuery parent, final MenuQuery children, final UserQuery user, final Long id, final String nameLike, final Boolean valid) {
        this.parent = parent;
        this.children = children;
        this.user = user;
        this.id = id;
        this.nameLike = nameLike;
        this.valid = valid;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy