Package org.apache.isis.applib.util

Examples of org.apache.isis.applib.util.ReasonBuffer


        this.specifications = specifications;
    }

    @Override
    public String satisfies(final Object obj) {
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            final String reasonNotSatisfiedIfAny = specification.satisfies(obj);
            buf.append(reasonNotSatisfiedIfAny);
        }
        return buf.getReason(); // may be null if all were satisfied.
    }
View Full Code Here


        this.specifications = specifications;
    }

    @Override
    public String satisfies(final Object obj) {
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            final String reasonNotSatisfiedIfAny = specification.satisfies(obj);
            if (reasonNotSatisfiedIfAny == null) {
                // at least one is ok, so all is ok.
                return null;
            }
            buf.append(reasonNotSatisfiedIfAny);
        }
        return buf.getReason(); // may be null if all were satisfied.
    }
View Full Code Here

        final ObjectAdapter targetNO = proposedHolder.getProposed();
        if(targetNO == null) {
            return null;
        }
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

        final ObjectAdapter targetNO = proposedHolder.getProposed();
        if(targetNO == null) {
            return null;
        }
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

            return null;
        }
        final ProposedHolder proposedHolder = (ProposedHolder) validityContext;
        final ObjectAdapter targetNO = proposedHolder.getProposed();
        final Object targetObject = targetNO.getObject();
        final ReasonBuffer buf = new ReasonBuffer();
        for (final Specification specification : specifications) {
            buf.append(specification.satisfies(targetObject));
        }
        return buf.getReason();
    }
View Full Code Here

TOP

Related Classes of org.apache.isis.applib.util.ReasonBuffer

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.