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

com.github.aidensuen.mongo.command.StaticCommandSource Maven / Gradle / Ivy

There is a newer version: 1.1.2
Show newest version
package com.github.aidensuen.mongo.command;

import com.github.aidensuen.mongo.mapping.BoundCommand;
import com.github.aidensuen.mongo.mapping.ParameterHolder;
import com.github.aidensuen.mongo.session.Configuration;


public class StaticCommandSource implements CommandSource {

    private final String command;

    private final Configuration configuration;

    public StaticCommandSource(String command, Configuration configuration) {
        this.command = command;
        this.configuration = configuration;
    }

    @Override
    public BoundCommand getBoundCommand(Object parameterObject) {
        return new BoundCommand(command, new ParameterHolder(this.configuration, parameterObject));
    }

    public String getCommand() {
        return command;
    }

    public Configuration getConfiguration() {
        return configuration;
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy