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

org.hibernate.validator.internal.properties.javabean.JavaBeanConstructor Maven / Gradle / Ivy

There is a newer version: 8.0.1.Final
Show newest version
/*
 * Hibernate Validator, declare and validate application constraints
 *
 * License: Apache License, Version 2.0
 * See the license.txt file in the root directory or .
 */
package org.hibernate.validator.internal.properties.javabean;

import java.lang.reflect.Constructor;
import java.lang.reflect.TypeVariable;

import org.hibernate.validator.internal.metadata.raw.ConstrainedElement.ConstrainedElementKind;

/**
 * @author Guillaume Smet
 */
public class JavaBeanConstructor extends JavaBeanExecutable> {

	public JavaBeanConstructor(Constructor executable) {
		super( executable, true );
	}

	@Override
	public String getName() {
		return getDeclaringClass().getSimpleName();
	}

	@Override
	public ConstrainedElementKind getConstrainedElementKind() {
		return ConstrainedElementKind.CONSTRUCTOR;
	}

	@Override
	public TypeVariable[] getTypeParameters() {
		return executable.getDeclaringClass().getTypeParameters();
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy