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

org.apache.camel.component.azure.blob.BlobServiceEndpointConfigurer Maven / Gradle / Ivy

/* Generated by org.apache.camel:apt */
package org.apache.camel.component.azure.blob;

import java.util.HashMap;
import java.util.Map;

import org.apache.camel.CamelContext;
import org.apache.camel.spi.GeneratedPropertyConfigurer;
import org.apache.camel.support.component.PropertyConfigurerSupport;

/**
 * Source code generated by org.apache.camel:apt
 */
@SuppressWarnings("unchecked")
public class BlobServiceEndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer {

    @Override
    public boolean configure(CamelContext camelContext, Object endpoint, String name, Object value, boolean ignoreCase) {
        if (ignoreCase) {
            return doConfigureIgnoreCase(camelContext, endpoint, name, value);
        } else {
            return doConfigure(camelContext, endpoint, name, value);
        }
    }

    private static boolean doConfigure(CamelContext camelContext, Object endpoint, String name, Object value) {
        switch (name) {
        case "azureBlobClient": ((BlobServiceEndpoint) endpoint).getConfiguration().setAzureBlobClient(property(camelContext, com.microsoft.azure.storage.blob.CloudBlob.class, value)); return true;
        case "blobType": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobType(property(camelContext, org.apache.camel.component.azure.blob.BlobType.class, value)); return true;
        case "operation": ((BlobServiceEndpoint) endpoint).getConfiguration().setOperation(property(camelContext, org.apache.camel.component.azure.blob.BlobServiceOperations.class, value)); return true;
        case "streamWriteSize": ((BlobServiceEndpoint) endpoint).getConfiguration().setStreamWriteSize(property(camelContext, int.class, value)); return true;
        case "streamReadSize": ((BlobServiceEndpoint) endpoint).getConfiguration().setStreamReadSize(property(camelContext, int.class, value)); return true;
        case "blobMetadata": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobMetadata(property(camelContext, java.util.Map.class, value)); return true;
        case "closeStreamAfterRead": ((BlobServiceEndpoint) endpoint).getConfiguration().setCloseStreamAfterRead(property(camelContext, boolean.class, value)); return true;
        case "closeStreamAfterWrite": ((BlobServiceEndpoint) endpoint).getConfiguration().setCloseStreamAfterWrite(property(camelContext, boolean.class, value)); return true;
        case "fileDir": ((BlobServiceEndpoint) endpoint).getConfiguration().setFileDir(property(camelContext, java.lang.String.class, value)); return true;
        case "blobOffset": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobOffset(property(camelContext, java.lang.Long.class, value)); return true;
        case "dataLength": ((BlobServiceEndpoint) endpoint).getConfiguration().setDataLength(property(camelContext, java.lang.Long.class, value)); return true;
        case "blobPrefix": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobPrefix(property(camelContext, java.lang.String.class, value)); return true;
        case "publicForRead": ((BlobServiceEndpoint) endpoint).getConfiguration().setPublicForRead(property(camelContext, boolean.class, value)); return true;
        case "useFlatListing": ((BlobServiceEndpoint) endpoint).getConfiguration().setUseFlatListing(property(camelContext, boolean.class, value)); return true;
        case "credentials": ((BlobServiceEndpoint) endpoint).getConfiguration().setCredentials(property(camelContext, com.microsoft.azure.storage.StorageCredentials.class, value)); return true;
        case "lazyStartProducer": ((BlobServiceEndpoint) endpoint).setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
        case "bridgeErrorHandler": ((BlobServiceEndpoint) endpoint).setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
        case "exceptionHandler": ((BlobServiceEndpoint) endpoint).setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
        case "exchangePattern": ((BlobServiceEndpoint) endpoint).setExchangePattern(property(camelContext, org.apache.camel.ExchangePattern.class, value)); return true;
        case "synchronous": ((BlobServiceEndpoint) endpoint).setSynchronous(property(camelContext, boolean.class, value)); return true;
        case "basicPropertyBinding": ((BlobServiceEndpoint) endpoint).setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
            default: return false;
        }
    }

    private static boolean doConfigureIgnoreCase(CamelContext camelContext, Object endpoint, String name, Object value) {
        switch (name.toLowerCase()) {
        case "azureblobclient": ((BlobServiceEndpoint) endpoint).getConfiguration().setAzureBlobClient(property(camelContext, com.microsoft.azure.storage.blob.CloudBlob.class, value)); return true;
        case "blobtype": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobType(property(camelContext, org.apache.camel.component.azure.blob.BlobType.class, value)); return true;
        case "operation": ((BlobServiceEndpoint) endpoint).getConfiguration().setOperation(property(camelContext, org.apache.camel.component.azure.blob.BlobServiceOperations.class, value)); return true;
        case "streamwritesize": ((BlobServiceEndpoint) endpoint).getConfiguration().setStreamWriteSize(property(camelContext, int.class, value)); return true;
        case "streamreadsize": ((BlobServiceEndpoint) endpoint).getConfiguration().setStreamReadSize(property(camelContext, int.class, value)); return true;
        case "blobmetadata": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobMetadata(property(camelContext, java.util.Map.class, value)); return true;
        case "closestreamafterread": ((BlobServiceEndpoint) endpoint).getConfiguration().setCloseStreamAfterRead(property(camelContext, boolean.class, value)); return true;
        case "closestreamafterwrite": ((BlobServiceEndpoint) endpoint).getConfiguration().setCloseStreamAfterWrite(property(camelContext, boolean.class, value)); return true;
        case "filedir": ((BlobServiceEndpoint) endpoint).getConfiguration().setFileDir(property(camelContext, java.lang.String.class, value)); return true;
        case "bloboffset": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobOffset(property(camelContext, java.lang.Long.class, value)); return true;
        case "datalength": ((BlobServiceEndpoint) endpoint).getConfiguration().setDataLength(property(camelContext, java.lang.Long.class, value)); return true;
        case "blobprefix": ((BlobServiceEndpoint) endpoint).getConfiguration().setBlobPrefix(property(camelContext, java.lang.String.class, value)); return true;
        case "publicforread": ((BlobServiceEndpoint) endpoint).getConfiguration().setPublicForRead(property(camelContext, boolean.class, value)); return true;
        case "useflatlisting": ((BlobServiceEndpoint) endpoint).getConfiguration().setUseFlatListing(property(camelContext, boolean.class, value)); return true;
        case "credentials": ((BlobServiceEndpoint) endpoint).getConfiguration().setCredentials(property(camelContext, com.microsoft.azure.storage.StorageCredentials.class, value)); return true;
        case "lazystartproducer": ((BlobServiceEndpoint) endpoint).setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
        case "bridgeerrorhandler": ((BlobServiceEndpoint) endpoint).setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
        case "exceptionhandler": ((BlobServiceEndpoint) endpoint).setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
        case "exchangepattern": ((BlobServiceEndpoint) endpoint).setExchangePattern(property(camelContext, org.apache.camel.ExchangePattern.class, value)); return true;
        case "synchronous": ((BlobServiceEndpoint) endpoint).setSynchronous(property(camelContext, boolean.class, value)); return true;
        case "basicpropertybinding": ((BlobServiceEndpoint) endpoint).setBasicPropertyBinding(property(camelContext, boolean.class, value)); return true;
            default: return false;
        }
    }

}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy