Package org.jitterbit.integration.server.engine.json

Examples of org.jitterbit.integration.server.engine.json.JsonEngine


    private static JsonEngine engine;

    private static synchronized JsonEngine getEngine() {
        if (engine == null) {
            engine = new JsonEngine(JsonEngineConfig.LOG);
            ServerConfig.addConfigurationListener(new ServerConfigListener() {

                @Override
                public void configReloaded() {
                    JsonEngineConfig.updateLogLevel();
View Full Code Here


    }

    @Override
    public WsStartNewJsonSessionResult startNewJsonSession(String userName, String md5Pwd) throws RemoteException {
        try {
            JsonEngine engine = getEngine();
            JsonSession session = engine.newSession(userName, md5Pwd);
            return new WsStartNewJsonSessionResult(session.getId().toString(), createForSuccess());
        } catch (Exception e) {
            return new WsStartNewJsonSessionResult(null, createForException(-1, e, "startNewSession"));
        }
    }
View Full Code Here

    }

    @Override
    public WsJsonError jsonToXml(WsJsonSessionId wsSessionId, WsConversionParams wsParams) throws RemoteException {
        try {
            JsonEngine engine = getEngine();
            JsonSessionCredentials credentials = createSessionCredentials(wsSessionId);
            ConversionParams conversionParams = createConversionParams(wsParams);
            engine.jsonToXml(credentials, conversionParams);
            return createForSuccess();
        } catch (Exception e) {
            return createForException(-1, e, "jsonToXml");
        }
    }
View Full Code Here

    }

    @Override
    public WsJsonError xmlToJson(WsJsonSessionId wsSessionId, WsConversionParams wsParams) throws RemoteException {
        try {
            JsonEngine engine = getEngine();
            JsonSessionCredentials credentials = createSessionCredentials(wsSessionId);
            ConversionParams conversionParams = createConversionParams(wsParams);
            engine.xmlToJson(credentials, conversionParams);
            return createForSuccess();
        } catch (Exception e) {
            return createForException(-1, e, "jsonToXml");
        }
    }
View Full Code Here

    }

    @Override
    public WsJsonError closeJsonSession(WsJsonSessionId wsSessionId) throws java.rmi.RemoteException {
        try {
            JsonEngine engine = getEngine();
            JsonSessionCredentials credentials = createSessionCredentials(wsSessionId);
            engine.closeSession(credentials);
            return createForSuccess();
        } catch (Exception e) {
            return createForException(-1, e, "closeSession");
        }
    }
View Full Code Here

TOP

Related Classes of org.jitterbit.integration.server.engine.json.JsonEngine

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.