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

rooklyn-core.0.6.0-M1.source-code.StrangeGetFields Maven / Gradle / Ivy

There is a newer version: 0.7.0-M1
Show newest version
//package brooklyn.entity.basic;

import java.util.Arrays;

public class StrangeGetFields {

    public interface MySuperInterface {
        public static final String ON_INTERFACE = "oninterface";
    }
    
    public static class MySuperClass implements MySuperInterface {
    }
    
    public static class MySubClass extends MySuperClass {
    }
    
    public static class MySubClass2 extends MySuperClass implements MySuperInterface {
    }
    
    public static void main(String[] args) {
        System.out.println("MySubClass: "+Arrays.toString(MySubClass.class.getFields()));
        System.out.println("MySuperInterface: "+Arrays.toString(MySuperInterface.class.getFields()));
        System.out.println("MySuperClass: "+Arrays.toString(MySuperClass.class.getFields()));
        System.out.println("MySubClass2: "+Arrays.toString(MySubClass2.class.getFields()));
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy