All Downloads are FREE. Search and download functionalities are using the official Maven repository.

stalkr.html.parser.FieldParser Maven / Gradle / Ivy

There is a newer version: 0.3.1
Show newest version
package stalkr.html.parser;

import java.lang.annotation.Annotation;
import java.lang.reflect.Field;
import java.util.List;

import lombok.RequiredArgsConstructor;
import lombok.val;

@RequiredArgsConstructor( staticName = "of" )
public class FieldParser {

	final Class annotation;
	final SetterConstructor constructor;

	public void parse( final List list, final Field field ) {
		val textAnnotation = field.getAnnotation( annotation );
		if ( textAnnotation != null )
			list.add( constructor.construct( field, textAnnotation ) );
	}
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy