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

src.samples.java.ex.ENMI_Sample Maven / Gradle / Ivy

Go to download

An auxiliary findbugs.sourceforge.net plugin for java bug detectors that fall outside the narrow scope of detectors to be packaged with the product itself.

The newest version!
package ex;

import ex.SPP_Sample.Flap;

public class ENMI_Sample {

    public enum Johnny {
        ONE_NOTE
    }

    private Johnny j;

    public ENMI_Sample() {
    }

    public void improperEnum(boolean b, boolean x) {
        j = null;

        if (b) {
            j = Johnny.ONE_NOTE;
            Johnny other = null;

            if (x) {
                other = Johnny.ONE_NOTE;
            }
        }

    }

    public void equalsOnEnum(Flap f) {
        if (f.equals(Flap.Jack)) {
            System.out.println("Flap Jacks");
        }
    }
}

enum ENMIFP {
    C1 {
    },
    C2 {
    }
}

enum ENMISingletonFP {
    INSTANCE {
        public void doIt() {
        };
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy