Package org.zanata.webtrans.shared.rpc

Examples of org.zanata.webtrans.shared.rpc.TransUnitUpdated


                        previousVersionNum, previousState);

        CacheValue context =
                updateContext.getIfPresent(new CacheKey(transUnit.getId(),
                        transUnit.getLocaleId()));
        TransUnitUpdated updated;
        if (context != null) {
            updated =
                    new TransUnitUpdated(updateInfo, context.editorClientId,
                            context.updateType);
            log.debug("about to publish trans unit updated event {}", updated);
        } else if (ServletContexts.instance().getRequest() != null) {

            String sessionId =
                    ServletContexts.instance().getRequest().getSession()
                            .getId();
            EditorClientId editorClientId = new EditorClientId(sessionId, -1);
            updated =
                    new TransUnitUpdated(updateInfo, editorClientId,
                            TransUnitUpdated.UpdateType.NonEditorSave);
        } else {
            updated =
                    new TransUnitUpdated(updateInfo, new EditorClientId(
                            "unknown", -1),
                            TransUnitUpdated.UpdateType.NonEditorSave);
        }
        if (Events.exists()) {
            Events.instance().raiseTransactionSuccessEvent(
View Full Code Here

TOP

Related Classes of org.zanata.webtrans.shared.rpc.TransUnitUpdated

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.