package org.implab.gradle.common.utils;

import java.util.Map;

import org.gradle.api.plugins.ExtensionAware;

public class ExtraProps {

    public static Map<String, Object> of(Object target) {
        return switch (target) {
            case ExtensionAware ext -> ext.getExtensions().getExtraProperties().getProperties();
            default -> Map.of();
        };
    }

}
