Examples of different()


Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

                    // check for exception, but don't throw if suppressed through thread-local
                    final Version otherVersion = originalOid.getVersion();
                    final Version thisVersion = recreatedOid.getVersion();
                    if(thisVersion != null &&
                       otherVersion != null &&
                       thisVersion.different(otherVersion)) {
                       
                        if(isConcurrencyCheckingGloballyEnabled() && ConcurrencyChecking.isCurrentlyEnabled()) {
                            LOG.info("concurrency conflict detected on " + recreatedOid + " (" + otherVersion + ")");
                            final String currentUser = getAuthenticationSession().getUserName();
                            throw new ConcurrencyException(currentUser, recreatedOid, thisVersion, otherVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

            } finally {
                final Version originalVersion = originalOid.getVersion();
                final Version recreatedVersion = recreatedOid.getVersion();
                if(recreatedVersion != null && (
                        originalVersion == null ||
                        recreatedVersion.different(originalVersion))
                    ) {
                    if(LOG.isDebugEnabled()) {
                        LOG.debug("updating version in oid, on " + originalOid + " (" + originalVersion + ") to (" + recreatedVersion +")");
                    }
                    originalOid.setVersion(recreatedVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

        final Version thisVersion = thisOid.getVersion();
       
        // check for exception, but don't throw if suppressed through thread-local
        if(thisVersion != null &&
           otherVersion != null &&
           thisVersion.different(otherVersion)) {
           
            if(ConcurrencyChecking.isCurrentlyEnabled()) {
                LOG.info("concurrency conflict detected on " + thisOid + " (" + otherVersion + ")");
                final String currentUser = getAuthenticationSession().getUserName();
                throw new ConcurrencyException(currentUser, thisOid, thisVersion, otherVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

                    // check for exception, but don't throw if suppressed through thread-local
                    final Version otherVersion = originalOid.getVersion();
                    final Version thisVersion = recreatedOid.getVersion();
                    if(thisVersion != null &&
                       otherVersion != null &&
                       thisVersion.different(otherVersion)) {
                       
                        if(isConcurrencyCheckingGloballyEnabled() && ConcurrencyChecking.isCurrentlyEnabled()) {
                            LOG.info("concurrency conflict detected on " + recreatedOid + " (" + otherVersion + ")");
                            final String currentUser = getAuthenticationSession().getUserName();
                            throw new ConcurrencyException(currentUser, recreatedOid, thisVersion, otherVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

               
                final Version originalVersion = originalOid.getVersion();
                final Version recreatedVersion = recreatedOid.getVersion();
                if(recreatedVersion != null && (
                        originalVersion == null ||
                        recreatedVersion.different(originalVersion))
                    ) {
                   LOG.info("updating version in oid, on " + originalOid + " (" + originalVersion + ") to (" + recreatedVersion +")");
                   originalOid.setVersion(recreatedVersion);
                }
            }
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

                    // check for exception, but don't throw if suppressed through thread-local
                    final Version otherVersion = originalOid.getVersion();
                    final Version thisVersion = recreatedOid.getVersion();
                    if(thisVersion != null &&
                       otherVersion != null &&
                       thisVersion.different(otherVersion)) {
                       
                        if(isConcurrencyCheckingGloballyEnabled() && ConcurrencyChecking.isCurrentlyEnabled()) {
                            LOG.info("concurrency conflict detected on " + recreatedOid + " (" + otherVersion + ")");
                            final String currentUser = getAuthenticationSession().getUserName();
                            throw new ConcurrencyException(currentUser, recreatedOid, thisVersion, otherVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

            } finally {
                final Version originalVersion = originalOid.getVersion();
                final Version recreatedVersion = recreatedOid.getVersion();
                if(recreatedVersion != null && (
                        originalVersion == null ||
                        recreatedVersion.different(originalVersion))
                    ) {
                    if(LOG.isDebugEnabled()) {
                        LOG.debug("updating version in oid, on " + originalOid + " (" + originalVersion + ") to (" + recreatedVersion +")");
                    }
                    originalOid.setVersion(recreatedVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

        final Version thisVersion = thisOid.getVersion();
       
        // check for exception, but don't throw if suppressed through thread-local
        if(thisVersion != null &&
           otherVersion != null &&
           thisVersion.different(otherVersion)) {
           
            if(ConcurrencyChecking.isCurrentlyEnabled()) {
                LOG.info("concurrency conflict detected on " + thisOid + " (" + otherVersion + ")");
                final String currentUser = getAuthenticationSession().getUserName();
                throw new ConcurrencyException(currentUser, thisOid, thisVersion, otherVersion);
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

            if (!versionString.equals("")) {
                final String user = reader.readUser();
                final String time = reader.readTime();
                version = versionCreator.version(versionString, user, time);
            }
            if (version.different(adapter.getVersion())) {
                // TODO - do we need to CHECK version and update
                LOG.warn("while reading data into " + oidStr + " version was " + version + " when existing adapter was already " + adapter.getVersion());
            }
           
        } else {
View Full Code Here

Examples of org.apache.isis.core.metamodel.adapter.version.Version.different()

            if (!versionString.equals("")) {
                final String user = reader.readUser();
                final String time = reader.readTime();
                version = versionCreator.version(versionString, user, time);
            }
            if (version.different(object.getVersion())) {
                // TODO - do we need to CHECK version and update
                throw new UnexpectedCallException();
            } else {
                return object;
            }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.