Package org.apache.isis.core.metamodel.facets.object.value

Examples of org.apache.isis.core.metamodel.facets.object.value.ValueFacet


        final ObjectAdapter valueAdapter = objectMember.get(objectAdapter);
       
        // use the runtime type if we have a value, else the compile time type of the member otherwise
        final ObjectSpecification spec = valueAdapter != null? valueAdapter.getSpecification(): objectMember.getSpecification();
       
        final ValueFacet valueFacet = spec.getFacet(ValueFacet.class);
        if (valueFacet != null) {
            String format = null;
            final Class<?> specClass = spec.getCorrespondingClass();
            if(specClass == java.math.BigDecimal.class) {
                // look for facet on member, else on the value's spec
View Full Code Here


    public ApplicationAdvice appliesTo(final IModel<?> model) {
        if (!(model instanceof ScalarModel)) {
            return ApplicationAdvice.DOES_NOT_APPLY;
        }
        final ScalarModel scalarModel = (ScalarModel) model;
        final ValueFacet valueFacet = scalarModel.getTypeOfSpecification().getFacet(ValueFacet.class);
        if(valueFacet == null) {
            return ApplicationAdvice.DOES_NOT_APPLY;
        }
        return appliesIf(!scalarModel.hasChoices());
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.core.metamodel.facets.object.value.ValueFacet

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.