Java Code Examples for java.lang.reflect.Constructor#getClass()

The following examples show how to use java.lang.reflect.Constructor#getClass() . These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may want to check out the right sidebar which shows the related API usage.
Example 1
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 2
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 3
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 4
Source Project: jdk8u60   File: MemberName.java    License: GNU General Public License v2.0 5 votes vote down vote up
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 5
Source Project: JDKSourceCode1.8   File: MemberName.java    License: MIT License 5 votes vote down vote up
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 6
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 7
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 8
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 9
Source Project: Java8CN   File: MemberName.java    License: Apache License 2.0 5 votes vote down vote up
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 10
Source Project: hottub   File: MemberName.java    License: GNU General Public License v2.0 5 votes vote down vote up
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 11
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 12
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 13
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 14
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 15
Source Project: jdk-1.7-annotated   File: MemberName.java    License: Apache License 2.0 5 votes vote down vote up
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}
 
Example 16
/** Create a name for the given reflected constructor.  The resulting name will be in a resolved state. */
@SuppressWarnings("LeakingThisInConstructor")
public MemberName(Constructor<?> ctor) {
    ctor.getClass();  // NPE check
    // fill in vmtarget, vmindex while we have ctor in hand:
    MethodHandleNatives.init(this, ctor);
    assert(isResolved() && this.clazz != null);
    this.name = CONSTRUCTOR_NAME;
    if (this.type == null)
        this.type = new Object[] { void.class, ctor.getParameterTypes() };
}