Search in sources :

Example 1 with AsterixExtension

use of org.apache.asterix.common.config.AsterixExtension in project asterixdb by apache.

the class ConfigUtil method toAsterixExtension.

public static AsterixExtension toAsterixExtension(Extension ext) {
    String className = ext.getExtensionClassName();
    ArrayList<Pair<String, String>> args = new ArrayList<>();
    for (Property property : ext.getProperty()) {
        args.add(new Pair<>(property.getName(), property.getValue()));
    }
    return new AsterixExtension(className, args);
}
Also used : AsterixExtension(org.apache.asterix.common.config.AsterixExtension) ArrayList(java.util.ArrayList) Property(org.apache.asterix.common.configuration.Property) Pair(org.apache.hyracks.algebricks.common.utils.Pair)

Aggregations

ArrayList (java.util.ArrayList)1 AsterixExtension (org.apache.asterix.common.config.AsterixExtension)1 Property (org.apache.asterix.common.configuration.Property)1 Pair (org.apache.hyracks.algebricks.common.utils.Pair)1