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

org.nakedobjects.noa.reflect.checks.CheckNakedObjectNotBounded Maven / Gradle / Ivy

The newest version!
package org.nakedobjects.noa.reflect.checks;

import org.nakedobjects.noa.adapter.Naked;
import org.nakedobjects.noa.adapter.NakedObject;
import org.nakedobjects.noa.annotations.BoundedAnnotation;

/**
 * Checks that the {@link NakedObject} is not annotated with the
 * @Bounded annotation (or equivalent).
 * 
 */
public class CheckNakedObjectNotBounded extends AbstractCheckNakedObject {
    
    public CheckNakedObjectNotBounded(
            NakedObject nakedObject) {
        super(nakedObject);
    }

    public String check(Naked[] values) {
//        final int features = getNakedObject().getSpecification().getFeatures();
//        return (features & NakedObjectSpecification.BOUNDED) == 0;
        return hasAnnotation(getNakedObject(), BoundedAnnotation.class)?"Bounded":null;
    }

    
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy