当前位置: 首页>>代码示例>>Java>>正文


Java IntrospectionSupport.getProperties方法代码示例

本文整理汇总了Java中org.apache.camel.util.IntrospectionSupport.getProperties方法的典型用法代码示例。如果您正苦于以下问题:Java IntrospectionSupport.getProperties方法的具体用法?Java IntrospectionSupport.getProperties怎么用?Java IntrospectionSupport.getProperties使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.camel.util.IntrospectionSupport的用法示例。


在下文中一共展示了IntrospectionSupport.getProperties方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: configureSalesforceOnDeleteComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-on-delete-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceOnDeleteComponent configureSalesforceOnDeleteComponent()
        throws Exception {
    SalesforceOnDeleteComponent connector = new SalesforceOnDeleteComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceOnDeleteComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-on-delete.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-on-delete.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:syndesis,代码行数:37,代码来源:SalesforceOnDeleteConnectorAutoConfiguration.java

示例2: configureActiveMQRequestTextComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "activemq-request-text-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public ActiveMQRequestTextComponent configureActiveMQRequestTextComponent()
        throws Exception {
    ActiveMQRequestTextComponent connector = new ActiveMQRequestTextComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<ActiveMQRequestTextComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.activemq-request-text.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.activemq-request-text.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:37,代码来源:ActiveMQRequestTextConnectorAutoConfiguration.java

示例3: configureSalesforceUpdateSObjectComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-update-sobject-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceUpdateSObjectComponent configureSalesforceUpdateSObjectComponent()
        throws Exception {
    SalesforceUpdateSObjectComponent connector = new SalesforceUpdateSObjectComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceUpdateSObjectComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-update-sobject.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-update-sobject.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:syndesis,代码行数:37,代码来源:SalesforceUpdateSObjectConnectorAutoConfiguration.java

示例4: configureSalesforceOnCreateComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-on-create-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceOnCreateComponent configureSalesforceOnCreateComponent()
        throws Exception {
    SalesforceOnCreateComponent connector = new SalesforceOnCreateComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceOnCreateComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-on-create.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-on-create.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:syndesis,代码行数:37,代码来源:SalesforceOnCreateConnectorAutoConfiguration.java

示例5: configureTradeInsightTopComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "trade-insight-top-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public TradeInsightTopComponent configureTradeInsightTopComponent()
        throws Exception {
    TradeInsightTopComponent connector = new TradeInsightTopComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<TradeInsightTopComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator.evaluate(
                            applicationContext.getEnvironment(),
                            "camel.connector.customizer",
                            "camel.connector.trade-insight-top.customizer",
                            ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator.evaluate(
                            applicationContext.getEnvironment(),
                            "camel.connector.customizer",
                            "camel.connector.trade-insight-top.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:36,代码来源:TradeInsightTopConnectorAutoConfiguration.java

示例6: configureSalesforceDeleteSObjectWithIdComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-delete-sobject-with-id-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceDeleteSObjectWithIdComponent configureSalesforceDeleteSObjectWithIdComponent()
        throws Exception {
    SalesforceDeleteSObjectWithIdComponent connector = new SalesforceDeleteSObjectWithIdComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceDeleteSObjectWithIdComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-delete-sobject-with-id.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-delete-sobject-with-id.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:syndesis,代码行数:37,代码来源:SalesforceDeleteSObjectWithIdConnectorAutoConfiguration.java

示例7: configureSalesforceDeleteSObjectComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-delete-sobject-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceDeleteSObjectComponent configureSalesforceDeleteSObjectComponent()
        throws Exception {
    SalesforceDeleteSObjectComponent connector = new SalesforceDeleteSObjectComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceDeleteSObjectComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-delete-sobject.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-delete-sobject.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:37,代码来源:SalesforceDeleteSObjectConnectorAutoConfiguration.java

示例8: configureSalesforceGetSObjectComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "salesforce-get-sobject-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SalesforceGetSObjectComponent configureSalesforceGetSObjectComponent()
        throws Exception {
    SalesforceGetSObjectComponent connector = new SalesforceGetSObjectComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SalesforceGetSObjectComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-get-sobject.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-get-sobject.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:37,代码来源:SalesforceGetSObjectConnectorAutoConfiguration.java

示例9: configureHttpPostComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "http-post-connector-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public HttpPostComponent configureHttpPostComponent() throws Exception {
    HttpPostComponent connector = new HttpPostComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<HttpPostComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.http-post-connector.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.http-post-connector.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:36,代码来源:HttpPostConnectorAutoConfiguration.java

示例10: configureSqlStoredStartConnectorComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@Lazy
@Bean(name = "sql-stored-start-connector-component")
@ConditionalOnClass(CamelContext.class)
@ConditionalOnMissingBean
public SqlStoredStartConnectorComponent configureSqlStoredStartConnectorComponent()
        throws Exception {
    SqlStoredStartConnectorComponent connector = new SqlStoredStartConnectorComponent();
    connector.setCamelContext(camelContext);
    Map<String, Object> parameters = new HashMap<>();
    IntrospectionSupport.getProperties(configuration, parameters, null,
            false);
    CamelPropertiesHelper.setCamelProperties(camelContext, connector,
            parameters, false);
    connector.setOptions(parameters);
    if (ObjectHelper.isNotEmpty(customizers)) {
        for (ConnectorCustomizer<SqlStoredStartConnectorComponent> customizer : customizers) {
            boolean useCustomizer = (customizer instanceof HasId)
                    ? HierarchicalPropertiesEvaluator
                            .evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.sql-stored-start-connector.customizer",
                                    ((HasId) customizer).getId())
                    : HierarchicalPropertiesEvaluator
                            .evaluate(applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.sql-stored-start-connector.customizer");
            if (useCustomizer) {
                LOGGER.debug("Configure connector {}, with customizer {}",
                        connector, customizer);
                customizer.customize(connector);
            }
        }
    }
    return connector;
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:37,代码来源:SqlStoredStartConnectorConnectorAutoConfiguration.java

示例11: postConstructSqlStoredStartConnectorComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@PostConstruct
public void postConstructSqlStoredStartConnectorComponent() {
    Map<String, Object> parameters = new HashMap<>();
    for (Map.Entry<String, SqlStoredStartConnectorConnectorConfigurationCommon> entry : configuration
            .getConfigurations().entrySet()) {
        parameters.clear();
        SqlStoredStartConnectorComponent connector = new SqlStoredStartConnectorComponent();
        connector.setCamelContext(camelContext);
        try {
            IntrospectionSupport.getProperties(entry.getValue(),
                    parameters, null, false);
            CamelPropertiesHelper.setCamelProperties(camelContext,
                    connector, parameters, false);
            connector.setOptions(parameters);
            if (ObjectHelper.isNotEmpty(customizers)) {
                for (ConnectorCustomizer<SqlStoredStartConnectorComponent> customizer : customizers) {
                    boolean useCustomizer = (customizer instanceof HasId)
                            ? HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.sql-stored-start-connector."
                                            + entry.getKey()
                                            + ".customizer",
                                    ((HasId) customizer).getId())
                            : HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.sql-stored-start-connector."
                                            + entry.getKey()
                                            + ".customizer");
                    if (useCustomizer) {
                        LOGGER.debug(
                                "Configure connector {}, with customizer {}",
                                connector, customizer);
                        customizer.customize(connector);
                    }
                }
            }
            camelContext.addComponent(entry.getKey(), connector);
        } catch (Exception e) {
            throw new BeanCreationException(entry.getKey(), e.getMessage(),
                    e);
        }
    }
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:46,代码来源:SqlStoredStartConnectorConnectorAutoConfiguration.java

示例12: postConstructActiveMQRequestBytesComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@PostConstruct
public void postConstructActiveMQRequestBytesComponent() {
    Map<String, Object> parameters = new HashMap<>();
    for (Map.Entry<String, ActiveMQRequestBytesConnectorConfigurationCommon> entry : configuration
            .getConfigurations().entrySet()) {
        parameters.clear();
        ActiveMQRequestBytesComponent connector = new ActiveMQRequestBytesComponent();
        connector.setCamelContext(camelContext);
        try {
            IntrospectionSupport.getProperties(entry.getValue(),
                    parameters, null, false);
            CamelPropertiesHelper.setCamelProperties(camelContext,
                    connector, parameters, false);
            connector.setOptions(parameters);
            if (ObjectHelper.isNotEmpty(customizers)) {
                for (ConnectorCustomizer<ActiveMQRequestBytesComponent> customizer : customizers) {
                    boolean useCustomizer = (customizer instanceof HasId)
                            ? HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.activemq-request-bytes."
                                            + entry.getKey()
                                            + ".customizer",
                                    ((HasId) customizer).getId())
                            : HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.activemq-request-bytes."
                                            + entry.getKey()
                                            + ".customizer");
                    if (useCustomizer) {
                        LOGGER.debug(
                                "Configure connector {}, with customizer {}",
                                connector, customizer);
                        customizer.customize(connector);
                    }
                }
            }
            camelContext.addComponent(entry.getKey(), connector);
        } catch (Exception e) {
            throw new BeanCreationException(entry.getKey(), e.getMessage(),
                    e);
        }
    }
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:46,代码来源:ActiveMQRequestBytesConnectorAutoConfiguration.java

示例13: postConstructTwitterSearchComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@PostConstruct
public void postConstructTwitterSearchComponent() {
    Map<String, Object> parameters = new HashMap<>();
    for (Map.Entry<String, TwitterSearchConnectorConfigurationCommon> entry : configuration
            .getConfigurations().entrySet()) {
        parameters.clear();
        TwitterSearchComponent connector = new TwitterSearchComponent();
        connector.setCamelContext(camelContext);
        try {
            IntrospectionSupport.getProperties(entry.getValue(),
                    parameters, null, false);
            CamelPropertiesHelper.setCamelProperties(camelContext,
                    connector, parameters, false);
            connector.setOptions(parameters);
            if (ObjectHelper.isNotEmpty(customizers)) {
                for (ConnectorCustomizer<TwitterSearchComponent> customizer : customizers) {
                    boolean useCustomizer = (customizer instanceof HasId)
                            ? HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.twitter-search-connector."
                                            + entry.getKey()
                                            + ".customizer",
                                    ((HasId) customizer).getId())
                            : HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.twitter-search-connector."
                                            + entry.getKey()
                                            + ".customizer");
                    if (useCustomizer) {
                        LOGGER.debug(
                                "Configure connector {}, with customizer {}",
                                connector, customizer);
                        customizer.customize(connector);
                    }
                }
            }
            camelContext.addComponent(entry.getKey(), connector);
        } catch (Exception e) {
            throw new BeanCreationException(entry.getKey(), e.getMessage(),
                    e);
        }
    }
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:46,代码来源:TwitterSearchConnectorAutoConfiguration.java

示例14: postConstructSalesforceCreateSObjectComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@PostConstruct
public void postConstructSalesforceCreateSObjectComponent() {
    Map<String, Object> parameters = new HashMap<>();
    for (Map.Entry<String, SalesforceCreateSObjectConnectorConfigurationCommon> entry : configuration
            .getConfigurations().entrySet()) {
        parameters.clear();
        SalesforceCreateSObjectComponent connector = new SalesforceCreateSObjectComponent();
        connector.setCamelContext(camelContext);
        try {
            IntrospectionSupport.getProperties(entry.getValue(),
                    parameters, null, false);
            CamelPropertiesHelper.setCamelProperties(camelContext,
                    connector, parameters, false);
            connector.setOptions(parameters);
            if (ObjectHelper.isNotEmpty(customizers)) {
                for (ConnectorCustomizer<SalesforceCreateSObjectComponent> customizer : customizers) {
                    boolean useCustomizer = (customizer instanceof HasId)
                            ? HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-create-sobject."
                                            + entry.getKey()
                                            + ".customizer",
                                    ((HasId) customizer).getId())
                            : HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.salesforce-create-sobject."
                                            + entry.getKey()
                                            + ".customizer");
                    if (useCustomizer) {
                        LOGGER.debug(
                                "Configure connector {}, with customizer {}",
                                connector, customizer);
                        customizer.customize(connector);
                    }
                }
            }
            camelContext.addComponent(entry.getKey(), connector);
        } catch (Exception e) {
            throw new BeanCreationException(entry.getKey(), e.getMessage(),
                    e);
        }
    }
}
 
开发者ID:syndesisio,项目名称:connectors,代码行数:46,代码来源:SalesforceCreateSObjectConnectorAutoConfiguration.java

示例15: postConstructDayTradePlaceComponent

import org.apache.camel.util.IntrospectionSupport; //导入方法依赖的package包/类
@PostConstruct
public void postConstructDayTradePlaceComponent() {
    Map<String, Object> parameters = new HashMap<>();
    for (Map.Entry<String, DayTradePlaceConnectorConfigurationCommon> entry : configuration
            .getConfigurations().entrySet()) {
        parameters.clear();
        DayTradePlaceComponent connector = new DayTradePlaceComponent(
                entry.getKey());
        connector.setCamelContext(camelContext);
        try {
            IntrospectionSupport.getProperties(entry.getValue(),
                    parameters, null, false);
            CamelPropertiesHelper.setCamelProperties(camelContext,
                    connector, parameters, false);
            connector.setOptions(parameters);
            if (ObjectHelper.isNotEmpty(customizers)) {
                for (ConnectorCustomizer<DayTradePlaceComponent> customizer : customizers) {
                    boolean useCustomizer = (customizer instanceof HasId)
                            ? HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.day-trade-place."
                                            + entry.getKey()
                                            + ".customizer",
                                    ((HasId) customizer).getId())
                            : HierarchicalPropertiesEvaluator.evaluate(
                                    applicationContext.getEnvironment(),
                                    "camel.connector.customizer",
                                    "camel.connector.day-trade-place."
                                            + entry.getKey()
                                            + ".customizer");
                    if (useCustomizer) {
                        LOGGER.debug(
                                "Configure connector {}, with customizer {}",
                                connector, customizer);
                        customizer.customize(connector);
                    }
                }
            }
            camelContext.addComponent(entry.getKey(), connector);
        } catch (Exception e) {
            throw new BeanCreationException(entry.getKey(), e.getMessage(),
                    e);
        }
    }
}
 
开发者ID:syndesisio,项目名称:syndesis,代码行数:47,代码来源:DayTradePlaceConnectorAutoConfiguration.java


注:本文中的org.apache.camel.util.IntrospectionSupport.getProperties方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。