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

cn.featherfly.hammer.expression.query.NamedFieldImpl Maven / Gradle / Ivy

The newest version!

/*
 * All rights Reserved, Designed By zhongj
 * @Description:
 * @author: zhongj
 * @date: 2023-11-21 13:32:21
 * @Copyright: 2023 www.featherfly.cn Inc. All rights reserved.
 */
package cn.featherfly.hammer.expression.query;

import java.util.function.BiConsumer;

import cn.featherfly.common.operator.Function;
import cn.featherfly.common.repository.QueryableField;

/**
 * NamedFieldImpl.
 *
 * @author zhongj
 */
public class NamedFieldImpl extends AbstractFetchField implements NamedField {

    /**
     * Instantiates a new named field impl.
     *
     * @param index    the index
     * @param consumer the consumer
     * @param name     the name
     */
    public NamedFieldImpl(int index, BiConsumer consumer, String name) {
        super(index, consumer, name);
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public NamedAliasedField alias(String alias) {
        return new NamedAliasedFieldImpl(getIndex(), getConsumer(), name(), alias);
    }

    /**
     * {@inheritDoc}
     */
    @Override
    public NamedDistinctedField distinct(boolean distinct) {
        return new NamedDistinctedFieldImpl(getIndex(), getConsumer(), name(), distinct);
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy