Constructor.getExceptionTypes
Code IndexAdd Codota to your IDE (free)

Best Java code snippets using java.lang.reflect.Constructor.getExceptionTypes (Showing top 20 results out of 1,242)

  • Common ways to obtain Constructor
private void myMethod () {
Constructor c =
  • Class clazz;Class[] parameterTypes;clazz.getConstructor(parameterTypes)
  • Class clazz;clazz.getConstructor()
  • Class clazz;Class[] parameterTypes;clazz.getDeclaredConstructor(parameterTypes)
  • Smart code suggestions by Codota
}
origin: redisson/redisson

/**
 * {@inheritDoc}
 */
public int size() {
  return constructor.getExceptionTypes().length;
}
origin: google/j2objc

public Class[] getExceptionTypes() {
  return ((Constructor)member).getExceptionTypes();
}
origin: oldmanpushcart/greys-anatomy

@Override
public Class<?>[] getExceptionTypes() {
  return target.getExceptionTypes();
}
origin: org.easymock/easymock

public Class[] getExceptionTypes() {
  return ((Constructor)member).getExceptionTypes();
}
origin: robovm/robovm

/**
 * Returns the exception types as an array of {@code Class} instances. If
 * this constructor has no declared exceptions, an empty array will be
 * returned.
 *
 * @return the declared exception classes
 */
public Class<?>[] getExceptionTypes() {
  return getExceptionTypes(true);
}
Class<?>[] getExceptionTypes(boolean copy) {
origin: alibaba/jvm-sandbox

@Override
public Class<?>[] getExceptionTypes() {
  return target.getExceptionTypes();
}
origin: cglib/cglib

public Class[] getExceptionTypes() {
  return ((Constructor)member).getExceptionTypes();
}
origin: spring-projects/spring-loaded

public static Class[] callGetExceptionTypes(Constructor thiz) {
  return thiz.getExceptionTypes();
}
origin: spring-projects/spring-framework

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method) member).getExceptionTypes());
  }
  else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor) member).getExceptionTypes());
  }
  else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
origin: redisson/redisson

/**
 * {@inheritDoc}
 */
public TypeDescription.Generic get(int index) {
  return new OfConstructorExceptionTypes.TypeProjection(constructor, index, constructor.getExceptionTypes());
}
origin: redisson/redisson

/**
 * {@inheritDoc}
 */
public TypeList asErasures() {
  return new TypeList.ForLoadedTypes(constructor.getExceptionTypes());
}
origin: google/j2objc

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method)member).getExceptionTypes());
  } else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor)member).getExceptionTypes());
  } else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
  
origin: org.springframework/spring-core

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method) member).getExceptionTypes());
  }
  else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor) member).getExceptionTypes());
  }
  else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
origin: org.easymock/easymock

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method)member).getExceptionTypes());
  } else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor)member).getExceptionTypes());
  } else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
  
origin: cglib/cglib

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method)member).getExceptionTypes());
  } else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor)member).getExceptionTypes());
  } else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
  
origin: cglib/cglib

public static Type[] getExceptionTypes(Member member) {
  if (member instanceof Method) {
    return TypeUtils.getTypes(((Method)member).getExceptionTypes());
  } else if (member instanceof Constructor) {
    return TypeUtils.getTypes(((Constructor)member).getExceptionTypes());
  } else {
    throw new IllegalArgumentException("Cannot get exception types of a field");
  }
}
  
origin: robovm/robovm

@SuppressWarnings("unchecked")
private synchronized void initGenericTypes() {
  if (!genericTypesAreInitialized) {
    String signatureAttribute = getSignatureAttribute();
    GenericSignatureParser parser = new GenericSignatureParser(
        getDeclaringClass().getClassLoader());
    parser.parseForConstructor(this, signatureAttribute, getExceptionTypes());
    formalTypeParameters = parser.formalTypeParameters;
    genericParameterTypes = parser.parameterTypes;
    genericExceptionTypes = parser.exceptionTypes;
    genericTypesAreInitialized = true;
  }
}

origin: nutzam/nutz

void addConstructors() {
  for (Constructor<?> constructor : constructors) {
    String[] expClasses = convertExp(constructor.getExceptionTypes());
    String desc = Type.getConstructorDescriptor(constructor);
    int access = getAccess(constructor.getModifiers());
    MethodVisitor mv = cw.visitMethod(access, "<init>", desc, null, expClasses);
    new ChangeToChildConstructorMethodAdapter(mv, desc, access, enhancedSuperName).visitCode();
  }
}
origin: alibaba/jvm-sandbox

private BehaviorStructure newBehaviorStructure(final Constructor constructor) {
  return new BehaviorStructure(
      new AccessImplByJDKBehavior(constructor),
      "<init>",
      this,
      this,
      newInstances(constructor.getParameterTypes()),
      newInstances(constructor.getExceptionTypes()),
      newInstances(getAnnotationTypeArray(constructor.getDeclaredAnnotations()))
  );
}
origin: jenkinsci/jenkins

Class[] et = c.getExceptionTypes();
String[] exceptions = new String[et.length];
for (int i = 0; i < et.length; i++)
java.lang.reflectConstructorgetExceptionTypes

Javadoc

Returns the exception types as an array of Class instances. If this constructor has no declared exceptions, an empty array will be returned.

Popular methods of Constructor

  • newInstance
    Uses the constructor represented by this Constructor object to create and initialize a new instance
  • getParameterTypes
  • setAccessible
  • getDeclaringClass
    Returns the Class object representing the class that declares the constructor represented by this Co
  • getModifiers
    Returns the Java language modifiers for the constructor represented by this Constructor object, as
  • getParameterAnnotations
    Returns an array of arrays that represent the annotations of the formal parameters of this construct
  • getGenericParameterTypes
    Returns the generic parameter types as an array of Typeinstances, in declaration order. If this cons
  • isAccessible
  • getAnnotation
  • getName
    Returns the name of this constructor, as a string. This is always the same as the simple name of the
  • isVarArgs
    Indicates whether or not this constructor takes a variable number of arguments.
  • getParameterCount
  • isVarArgs,
  • getParameterCount,
  • isAnnotationPresent,
  • toString,
  • getParameters,
  • getGenericExceptionTypes,
  • getTypeParameters,
  • getDeclaredAnnotations,
  • equals

Popular in Java

  • Making http requests using okhttp
  • scheduleAtFixedRate (Timer)
  • getResourceAsStream (ClassLoader)
  • getContentResolver (Context)
  • ObjectMapper (com.fasterxml.jackson.databind)
    ObjectMapper provides functionality for reading and writing JSON, either to and from basic POJOs (Pl
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • BufferedWriter (java.io)
    Wraps an existing Writer and buffers the output. Expensive interaction with the underlying reader is
  • DecimalFormat (java.text)
    A concrete subclass of NumberFormat that formats decimal numbers. It has a variety of features desig
  • ThreadPoolExecutor (java.util.concurrent)
    An ExecutorService that executes each submitted task using one of possibly several pooled threads, n
  • Option (scala)

For IntelliJ IDEA,
Android Studio or Eclipse

  • Search for JavaScript code betaCodota IntelliJ IDEA pluginCodota Android Studio pluginCode IndexSign in
  • EnterpriseFAQAboutBlogContact Us
  • Plugin user guideTerms of usePrivacy policyCodeboxFind Usages
Add Codota to your IDE (free)