Package org.apache.isis.core.metamodel.facetapi

Examples of org.apache.isis.core.metamodel.facetapi.FacetHolder


    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();

        if (type != int.class) {
            return;
        }
        addFacets(new IntPrimitiveValueSemanticsProvider(holder, getConfiguration(), getContext()));
View Full Code Here


    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();

        if (type != org.apache.isis.applib.value.Time.class) {
            return;
        }
        addFacets(new TimeValueSemanticsProvider(holder, getConfiguration(), getContext()));
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> cls = processClassContext.getCls();
        final FacetHolder facetHolder = processClassContext.getFacetHolder();

        final List<Facet> facets = new ArrayList<Facet>();
        final List<Method> methods = new ArrayList<Method>();

        Method method = null;
        method = MethodFinderUtils.findMethod(cls, MethodScope.OBJECT, MethodPrefixConstants.REMOVING_PREFIX, void.class, NO_PARAMETERS_TYPES);
        if (method != null) {
            methods.add(method);
            final RemovingCallbackFacet facet = facetHolder.getFacet(RemovingCallbackFacet.class);
            if (facet == null) {
                facets.add(new RemovingCallbackFacetViaMethod(method, facetHolder));
            } else {
                facet.addMethod(method);
            }
        }

        method = MethodFinderUtils.findMethod(cls, MethodScope.OBJECT, MethodPrefixConstants.REMOVED_PREFIX, void.class, NO_PARAMETERS_TYPES);
        if (method != null) {
            methods.add(method);
            final RemovedCallbackFacet facet = facetHolder.getFacet(RemovedCallbackFacet.class);
            if (facet == null) {
                facets.add(new RemovedCallbackFacetViaMethod(method, facetHolder));
            } else {
                facet.addMethod(method);
            }
View Full Code Here

        if (method == null) {
            return;
        }
        processMethodContext.removeMethod(method);

        final FacetHolder property = processMethodContext.getFacetHolder();
        FacetUtil.addFacet(new PropertyValidateFacetViaMethod(method, property));
    }
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();

        if (type != java.net.URL.class) {
            return;
        }
        addFacets(new URLValueSemanticsProvider(holder, getConfiguration(), getContext()));
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();

        if (type != java.sql.Time.class) {
            return;
        }
        addFacets(new JavaSqlTimeValueSemanticsProvider(holder, getConfiguration(), getContext()));
View Full Code Here

        final ObjectCategorization categorization = ObjectCategorization.parse(configuredValue);
        if(categorization == ObjectCategorization.NONE) {
            return;
        }
        final Class<?> cls = processClassContext.getCls();
        final FacetHolder facetHolder = processClassContext.getFacetHolder();
       
        if(facetHolder.containsDoOpFacet(AuditableFacet.class)) {
            // do not replace
            return;
        }
        if(HasTransactionId.class.isAssignableFrom(cls)) {
            // do not install on any implementation of HasTransactionId
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> cls = processClassContext.getCls();
        final FacetHolder facetHolder = processClassContext.getFacetHolder();

        final List<Facet> facets = new ArrayList<Facet>();
        final List<Method> methods = new ArrayList<Method>();

        Method method = null;
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();

        if (type != org.apache.isis.applib.value.Percentage.class) {
            return;
        }
        addFacets(new PercentageValueSemanticsProvider(holder, getConfiguration(), getContext()));
View Full Code Here

    }

    @Override
    public void process(final ProcessClassContext processClassContext) {
        final Class<?> type = processClassContext.getCls();
        final FacetHolder holder = processClassContext.getFacetHolder();
        if (type != BigInteger.class) {
            return;
        }
        addFacets(new BigIntegerValueSemanticsProvider(holder, getConfiguration(), getContext()));
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.core.metamodel.facetapi.FacetHolder

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.