Package ru.aristar.jnuget.common

Examples of ru.aristar.jnuget.common.CollectionGenericType.type()


     * @return коллекция значений.
     * @throws Exception ошибка преобразования.
     */
    private Collection getCollectionValue(Method method, Class<?> valueType, Collection<String> values) throws Exception {
        CollectionGenericType annotation = method.getAnnotation(CollectionGenericType.class);
        Class<?> elementType = annotation == null ? String.class : annotation.type();
        @SuppressWarnings("unchecked")
        Collection<? super Object> result = (Collection) valueType.getConstructor().newInstance();
        for (String stringValue : values) {
            stringValue = OptionConverter.replaceVariables(stringValue);
            Object value = getValueFromString(elementType, stringValue);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.