/* Generated by camel build tools - do NOT edit this file! */
package org.apache.camel.component.ignite.cache;

import java.util.Map;

import org.apache.camel.CamelContext;
import org.apache.camel.spi.ExtendedPropertyConfigurerGetter;
import org.apache.camel.spi.PropertyConfigurerGetter;
import org.apache.camel.spi.ConfigurerStrategy;
import org.apache.camel.spi.GeneratedPropertyConfigurer;
import org.apache.camel.util.CaseInsensitiveMap;
import org.apache.camel.support.component.PropertyConfigurerSupport;

/**
 * Generated by camel build tools - do NOT edit this file!
 */
@SuppressWarnings("unchecked")
public class IgniteCacheEndpointConfigurer extends PropertyConfigurerSupport implements GeneratedPropertyConfigurer, PropertyConfigurerGetter {

    @Override
    public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
        IgniteCacheEndpoint target = (IgniteCacheEndpoint) obj;
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "autounsubscribe":
        case "autoUnsubscribe": target.setAutoUnsubscribe(property(camelContext, boolean.class, value)); return true;
        case "bridgeerrorhandler":
        case "bridgeErrorHandler": target.setBridgeErrorHandler(property(camelContext, boolean.class, value)); return true;
        case "cachepeekmode":
        case "cachePeekMode": target.setCachePeekMode(property(camelContext, org.apache.ignite.cache.CachePeekMode.class, value)); return true;
        case "exceptionhandler":
        case "exceptionHandler": target.setExceptionHandler(property(camelContext, org.apache.camel.spi.ExceptionHandler.class, value)); return true;
        case "exchangepattern":
        case "exchangePattern": target.setExchangePattern(property(camelContext, org.apache.camel.ExchangePattern.class, value)); return true;
        case "failifinexistentcache":
        case "failIfInexistentCache": target.setFailIfInexistentCache(property(camelContext, boolean.class, value)); return true;
        case "fireexistingqueryresults":
        case "fireExistingQueryResults": target.setFireExistingQueryResults(property(camelContext, boolean.class, value)); return true;
        case "lazystartproducer":
        case "lazyStartProducer": target.setLazyStartProducer(property(camelContext, boolean.class, value)); return true;
        case "oneexchangeperupdate":
        case "oneExchangePerUpdate": target.setOneExchangePerUpdate(property(camelContext, boolean.class, value)); return true;
        case "operation": target.setOperation(property(camelContext, org.apache.camel.component.ignite.cache.IgniteCacheOperation.class, value)); return true;
        case "pagesize":
        case "pageSize": target.setPageSize(property(camelContext, int.class, value)); return true;
        case "propagateincomingbodyifnoreturnvalue":
        case "propagateIncomingBodyIfNoReturnValue": target.setPropagateIncomingBodyIfNoReturnValue(property(camelContext, boolean.class, value)); return true;
        case "query": target.setQuery(property(camelContext, org.apache.ignite.cache.query.Query.class, value)); return true;
        case "remotefilter":
        case "remoteFilter": target.setRemoteFilter(property(camelContext, org.apache.ignite.cache.CacheEntryEventSerializableFilter.class, value)); return true;
        case "timeinterval":
        case "timeInterval": target.setTimeInterval(property(camelContext, long.class, value)); return true;
        case "treatcollectionsascacheobjects":
        case "treatCollectionsAsCacheObjects": target.setTreatCollectionsAsCacheObjects(property(camelContext, boolean.class, value)); return true;
        default: return false;
        }
    }

    @Override
    public Class<?> getOptionType(String name, boolean ignoreCase) {
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "autounsubscribe":
        case "autoUnsubscribe": return boolean.class;
        case "bridgeerrorhandler":
        case "bridgeErrorHandler": return boolean.class;
        case "cachepeekmode":
        case "cachePeekMode": return org.apache.ignite.cache.CachePeekMode.class;
        case "exceptionhandler":
        case "exceptionHandler": return org.apache.camel.spi.ExceptionHandler.class;
        case "exchangepattern":
        case "exchangePattern": return org.apache.camel.ExchangePattern.class;
        case "failifinexistentcache":
        case "failIfInexistentCache": return boolean.class;
        case "fireexistingqueryresults":
        case "fireExistingQueryResults": return boolean.class;
        case "lazystartproducer":
        case "lazyStartProducer": return boolean.class;
        case "oneexchangeperupdate":
        case "oneExchangePerUpdate": return boolean.class;
        case "operation": return org.apache.camel.component.ignite.cache.IgniteCacheOperation.class;
        case "pagesize":
        case "pageSize": return int.class;
        case "propagateincomingbodyifnoreturnvalue":
        case "propagateIncomingBodyIfNoReturnValue": return boolean.class;
        case "query": return org.apache.ignite.cache.query.Query.class;
        case "remotefilter":
        case "remoteFilter": return org.apache.ignite.cache.CacheEntryEventSerializableFilter.class;
        case "timeinterval":
        case "timeInterval": return long.class;
        case "treatcollectionsascacheobjects":
        case "treatCollectionsAsCacheObjects": return boolean.class;
        default: return null;
        }
    }

    @Override
    public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
        IgniteCacheEndpoint target = (IgniteCacheEndpoint) obj;
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "autounsubscribe":
        case "autoUnsubscribe": return target.isAutoUnsubscribe();
        case "bridgeerrorhandler":
        case "bridgeErrorHandler": return target.isBridgeErrorHandler();
        case "cachepeekmode":
        case "cachePeekMode": return target.getCachePeekMode();
        case "exceptionhandler":
        case "exceptionHandler": return target.getExceptionHandler();
        case "exchangepattern":
        case "exchangePattern": return target.getExchangePattern();
        case "failifinexistentcache":
        case "failIfInexistentCache": return target.isFailIfInexistentCache();
        case "fireexistingqueryresults":
        case "fireExistingQueryResults": return target.isFireExistingQueryResults();
        case "lazystartproducer":
        case "lazyStartProducer": return target.isLazyStartProducer();
        case "oneexchangeperupdate":
        case "oneExchangePerUpdate": return target.isOneExchangePerUpdate();
        case "operation": return target.getOperation();
        case "pagesize":
        case "pageSize": return target.getPageSize();
        case "propagateincomingbodyifnoreturnvalue":
        case "propagateIncomingBodyIfNoReturnValue": return target.isPropagateIncomingBodyIfNoReturnValue();
        case "query": return target.getQuery();
        case "remotefilter":
        case "remoteFilter": return target.getRemoteFilter();
        case "timeinterval":
        case "timeInterval": return target.getTimeInterval();
        case "treatcollectionsascacheobjects":
        case "treatCollectionsAsCacheObjects": return target.isTreatCollectionsAsCacheObjects();
        default: return null;
        }
    }

    @Override
    public Object getCollectionValueType(Object target, String name, boolean ignoreCase) {
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "query": return javax.cache.Cache.Entry.class;
        case "remotefilter":
        case "remoteFilter": return java.lang.Object.class;
        default: return null;
        }
    }
}

