Java Code Examples for sun.reflect.generics.tree.TypeTree

The following examples show how to use sun.reflect.generics.tree.TypeTree. 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 check out the related API usage on the sidebar.
Example 1
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 2
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 3
Source Project: jdk8u60   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 4
Source Project: java-n-IDE-for-Android   Source File: ClassRepository.java    License: Apache License 2.0 6 votes vote down vote up
public Type[] getSuperInterfaces(){
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        Type[] sis = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            sis[i] = r.getResult();
        }
        superInterfaces = sis; // cache overall result
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 5
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 6
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 7
Source Project: javaide   Source File: ClassRepository.java    License: GNU General Public License v3.0 6 votes vote down vote up
public Type[] getSuperInterfaces(){
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        Type[] sis = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            sis[i] = r.getResult();
        }
        superInterfaces = sis; // cache overall result
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 8
Source Project: jdk8u-jdk   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 9
Source Project: hottub   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 10
public Type[] getSuperInterfaces(){
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        Type[] sis = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            sis[i] = r.getResult();
        }
        superInterfaces = sis; // cache overall result
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 11
Source Project: openjdk-8   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces(){
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        Type[] sis = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            sis[i] = r.getResult();
        }
        superInterfaces = sis; // cache overall result
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 12
Source Project: jdk8u_jdk   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 13
Source Project: jdk8u-jdk   Source File: ClassRepository.java    License: GNU General Public License v2.0 6 votes vote down vote up
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 14
public Type[] getSuperInterfaces() {
    Type[] superInterfaces = this.superInterfaces;
    if (superInterfaces == null) { // lazily initialize super interfaces
        // first, extract super interface subtree(s) from AST
        TypeTree[] ts  = getTree().getSuperInterfaces();
        // create array to store reified subtree(s)
        superInterfaces = new Type[ts.length];
        // reify all subtrees
        for (int i = 0; i < ts.length; i++) {
            Reifier r = getReifier(); // obtain visitor
            ts[i].accept(r);// reify subtree
            // extract result from visitor and store it
            superInterfaces[i] = r.getResult();
        }
        this.superInterfaces = superInterfaces;
    }
    return superInterfaces.clone(); // return cached result
}
 
Example 15
Source Project: Bytecoder   Source File: ClassRepository.java    License: Apache License 2.0 5 votes vote down vote up
private Type[] computeSuperInterfaces() {
    // first, extract super interface subtree(s) from AST
    TypeTree[] ts = getTree().getSuperInterfaces();
    // create array to store reified subtree(s)
    int length = ts.length;
    Type[] superInterfaces = new Type[length];
    // reify all subtrees
    for (int i = 0; i < length; i++) {
        Reifier r = getReifier(); // obtain visitor
        ts[i].accept(r);// reify subtree
        // extract result from visitor and store it
        superInterfaces[i] = r.getResult();
    }
    return superInterfaces;
}
 
Example 16
Source Project: openjdk-jdk9   Source File: ClassRepository.java    License: GNU General Public License v2.0 5 votes vote down vote up
private Type[] computeSuperInterfaces() {
    // first, extract super interface subtree(s) from AST
    TypeTree[] ts = getTree().getSuperInterfaces();
    // create array to store reified subtree(s)
    int length = ts.length;
    Type[] superInterfaces = new Type[length];
    // reify all subtrees
    for (int i = 0; i < length; i++) {
        Reifier r = getReifier(); // obtain visitor
        ts[i].accept(r);// reify subtree
        // extract result from visitor and store it
        superInterfaces[i] = r.getResult();
    }
    return superInterfaces;
}