Example usage for org.apache.commons.collections.list TransformedList decorate

List of usage examples for org.apache.commons.collections.list TransformedList decorate

Introduction

In this page you can find the example usage for org.apache.commons.collections.list TransformedList decorate.

Prototype

public static List decorate(List list, Transformer transformer) 

Source Link

Document

Factory method to create a transforming list.

Usage

From source file:info.evanchik.eclipse.karaf.core.features.Features.java

@SuppressWarnings("unchecked")
public List<Repository> getRepositories() {
    final List<Repository> rawList = new ArrayList<Repository>();
    final List<Repository> transformedList = TransformedList.decorate(rawList, new ElementTransformer());
    transformedList.addAll(element.getChildren());

    return Collections
            .unmodifiableList(KarafCorePluginUtils.filterList(transformedList, new RepositoryOnlyPredicate()));
}

From source file:info.evanchik.eclipse.karaf.core.features.Feature.java

@SuppressWarnings("unchecked")
public List<Bundle> getBundles() {
    final List<Bundle> rawList = new ArrayList<Bundle>();
    final List<Bundle> transformedList = TransformedList.decorate(rawList, new ElementTransformer());
    transformedList.addAll(element.getChildren());

    return Collections
            .unmodifiableList(KarafCorePluginUtils.filterList(transformedList, new BundleOnlyPredicate()));
}

From source file:info.evanchik.eclipse.karaf.core.features.Feature.java

@SuppressWarnings("unchecked")
public List<Feature> getFeatures() {
    final List<Feature> rawList = new ArrayList<Feature>();
    final List<Feature> transformedList = TransformedList.decorate(rawList, new ElementTransformer());
    transformedList.addAll(element.getChildren());

    return Collections
            .unmodifiableList(KarafCorePluginUtils.filterList(transformedList, new FeatureOnlyPredicate()));
}