Example usage for org.springframework.integration.support.context NamedComponent getComponentType

List of usage examples for org.springframework.integration.support.context NamedComponent getComponentType

Introduction

In this page you can find the example usage for org.springframework.integration.support.context NamedComponent getComponentType.

Prototype

String getComponentType();

Source Link

Usage

From source file:org.springframework.integration.history.MessageHistory.java

private static Properties extractMetadata(NamedComponent component) {
    Entry entry = new Entry();
    String name = component.getComponentName();
    String type = component.getComponentType();
    if (name != null && !name.startsWith("org.springframework.integration")) {
        entry.setName(name);/*from  w w w . j  a va2 s.com*/
        if (type != null) {
            entry.setType(type);
        }
    }
    if (!entry.isEmpty()) {
        entry.setTimestamp(Long.toString(System.currentTimeMillis()));
    }
    return entry;
}