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

org.apache.camel.component.zendesk.ZendeskConfigurationConfigurer Maven / Gradle / Ivy

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

import javax.annotation.processing.Generated;
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.component.zendesk.ZendeskConfiguration;

/**
 * Generated by camel build tools - do NOT edit this file!
 */
@Generated("org.apache.camel.maven.packaging.GenerateConfigurerMojo")
@SuppressWarnings("unchecked")
public class ZendeskConfigurationConfigurer extends org.apache.camel.support.component.PropertyConfigurerSupport implements GeneratedPropertyConfigurer, ExtendedPropertyConfigurerGetter {

    private static final Map ALL_OPTIONS;
    static {
        Map map = new CaseInsensitiveMap();
        map.put("MethodName", org.apache.camel.component.zendesk.internal.ZendeskApiMethod.class);
        map.put("OauthToken", java.lang.String.class);
        map.put("Password", java.lang.String.class);
        map.put("ServerUrl", java.lang.String.class);
        map.put("Token", java.lang.String.class);
        map.put("Username", java.lang.String.class);
        ALL_OPTIONS = map;
    }

    @Override
    public boolean configure(CamelContext camelContext, Object obj, String name, Object value, boolean ignoreCase) {
        org.apache.camel.component.zendesk.ZendeskConfiguration target = (org.apache.camel.component.zendesk.ZendeskConfiguration) obj;
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "methodname":
        case "methodName": target.setMethodName(property(camelContext, org.apache.camel.component.zendesk.internal.ZendeskApiMethod.class, value)); return true;
        case "oauthtoken":
        case "oauthToken": target.setOauthToken(property(camelContext, java.lang.String.class, value)); return true;
        case "password": target.setPassword(property(camelContext, java.lang.String.class, value)); return true;
        case "serverurl":
        case "serverUrl": target.setServerUrl(property(camelContext, java.lang.String.class, value)); return true;
        case "token": target.setToken(property(camelContext, java.lang.String.class, value)); return true;
        case "username": target.setUsername(property(camelContext, java.lang.String.class, value)); return true;
        default: return false;
        }
    }

    @Override
    public Map getAllOptions(Object target) {
        return ALL_OPTIONS;
    }

    @Override
    public Class getOptionType(String name, boolean ignoreCase) {
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "methodname":
        case "methodName": return org.apache.camel.component.zendesk.internal.ZendeskApiMethod.class;
        case "oauthtoken":
        case "oauthToken": return java.lang.String.class;
        case "password": return java.lang.String.class;
        case "serverurl":
        case "serverUrl": return java.lang.String.class;
        case "token": return java.lang.String.class;
        case "username": return java.lang.String.class;
        default: return null;
        }
    }

    @Override
    public Object getOptionValue(Object obj, String name, boolean ignoreCase) {
        org.apache.camel.component.zendesk.ZendeskConfiguration target = (org.apache.camel.component.zendesk.ZendeskConfiguration) obj;
        switch (ignoreCase ? name.toLowerCase() : name) {
        case "methodname":
        case "methodName": return target.getMethodName();
        case "oauthtoken":
        case "oauthToken": return target.getOauthToken();
        case "password": return target.getPassword();
        case "serverurl":
        case "serverUrl": return target.getServerUrl();
        case "token": return target.getToken();
        case "username": return target.getUsername();
        default: return null;
        }
    }
}





© 2015 - 2025 Weber Informatics LLC | Privacy Policy