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

org.apache.camel.component.mongodb.MongoDbEndpointUriFactory Maven / Gradle / Ivy

The newest version!
/* Generated by camel build tools - do NOT edit this file! */
package org.apache.camel.component.mongodb;

import javax.annotation.processing.Generated;
import java.net.URISyntaxException;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
import java.util.Map;
import java.util.Set;

import org.apache.camel.spi.EndpointUriFactory;

/**
 * Generated by camel build tools - do NOT edit this file!
 */
@Generated("org.apache.camel.maven.packaging.GenerateEndpointUriFactoryMojo")
public class MongoDbEndpointUriFactory extends org.apache.camel.support.component.EndpointUriFactorySupport implements EndpointUriFactory {

    private static final String BASE = ":connectionBean";

    private static final Set PROPERTY_NAMES;
    private static final Set SECRET_PROPERTY_NAMES;
    private static final Set MULTI_VALUE_PREFIXES;
    static {
        Set props = new HashSet<>(56);
        props.add("appName");
        props.add("authSource");
        props.add("bridgeErrorHandler");
        props.add("collection");
        props.add("collectionIndex");
        props.add("compressors");
        props.add("connectTimeoutMS");
        props.add("connectionBean");
        props.add("connectionUriString");
        props.add("consumerType");
        props.add("createCollection");
        props.add("cursorRegenerationDelay");
        props.add("database");
        props.add("directConnection");
        props.add("dynamicity");
        props.add("exceptionHandler");
        props.add("exchangePattern");
        props.add("fullDocument");
        props.add("heartbeatFrequencyMS");
        props.add("hosts");
        props.add("lazyStartProducer");
        props.add("loadBalanced");
        props.add("localThresholdMS");
        props.add("maxConnecting");
        props.add("maxIdleTimeMS");
        props.add("maxLifeTimeMS");
        props.add("maxPoolSize");
        props.add("maxStalenessSeconds");
        props.add("minPoolSize");
        props.add("mongoConnection");
        props.add("operation");
        props.add("outputType");
        props.add("password");
        props.add("persistentId");
        props.add("persistentTailTracking");
        props.add("readPreference");
        props.add("readPreferenceTags");
        props.add("replicaSet");
        props.add("retryReads");
        props.add("retryWrites");
        props.add("serverSelectionTimeoutMS");
        props.add("socketTimeoutMS");
        props.add("srvMaxHosts");
        props.add("srvServiceName");
        props.add("streamFilter");
        props.add("tailTrackCollection");
        props.add("tailTrackDb");
        props.add("tailTrackField");
        props.add("tailTrackIncreasingField");
        props.add("tls");
        props.add("tlsAllowInvalidHostnames");
        props.add("username");
        props.add("waitQueueTimeoutMS");
        props.add("writeConcern");
        props.add("writeResultAsHeader");
        props.add("zlibCompressionLevel");
        PROPERTY_NAMES = Collections.unmodifiableSet(props);
        Set secretProps = new HashSet<>(2);
        secretProps.add("password");
        secretProps.add("username");
        SECRET_PROPERTY_NAMES = Collections.unmodifiableSet(secretProps);
        MULTI_VALUE_PREFIXES = Collections.emptySet();
    }

    @Override
    public boolean isEnabled(String scheme) {
        return "mongodb".equals(scheme);
    }

    @Override
    public String buildUri(String scheme, Map properties, boolean encode) throws URISyntaxException {
        String syntax = scheme + BASE;
        String uri = syntax;

        Map copy = new HashMap<>(properties);

        uri = buildPathParameter(syntax, uri, "connectionBean", null, true, copy);
        uri = buildQueryParameters(uri, copy, encode);
        return uri;
    }

    @Override
    public Set propertyNames() {
        return PROPERTY_NAMES;
    }

    @Override
    public Set secretPropertyNames() {
        return SECRET_PROPERTY_NAMES;
    }

    @Override
    public Set multiValuePrefixes() {
        return MULTI_VALUE_PREFIXES;
    }

    @Override
    public boolean isLenientProperties() {
        return false;
    }
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy