Package com.hazelcast.management

Examples of com.hazelcast.management.MapConfigAdapter


    @Override
    public void fromJson(JsonObject json) {
        mapName = getString(json, "mapName");
        update = getBoolean(json, "update");
        config = new MapConfigAdapter();
        config.fromJson(getObject(json, "config"));
    }
View Full Code Here


            result.add("updateResult", "success");
        } else {
            MapConfig cfg = (MapConfig) mcs.callOnThis(new GetMapConfigOperation(mapName));
            if (cfg != null) {
                result.add("hasMapConfig", true);
                result.add("mapConfig", new MapConfigAdapter(cfg).toJson());
            } else {
                result.add("hasMapConfig", false);
            }
        }
        root.add("result", result);
View Full Code Here

    public Object readResponse(JsonObject json) {
        update = getBoolean(json, "update", false);
        if (!update) {
            boolean hasMapConfig = getBoolean(json, "hasMapConfig", false);
            if (hasMapConfig) {
                final MapConfigAdapter adapter = new MapConfigAdapter();
                adapter.fromJson(getObject(json, "mapConfig"));
                return adapter.getMapConfig();
            } else {
                return null;
            }
        }
        return getString(json, "updateResult");
View Full Code Here

    @Override
    public void fromJson(JsonObject json) {
        mapName = getString(json, "mapName");
        update = getBoolean(json, "update");
        config = new MapConfigAdapter();
        config.fromJson(getObject(json, "config"));
    }
View Full Code Here

    }

    @Override
    protected void writeInternal(ObjectDataOutput out) throws IOException {
        out.writeUTF(mapName);
        new MapConfigAdapter(mapConfig).writeData(out);
    }
View Full Code Here

    }

    @Override
    protected void readInternal(ObjectDataInput in) throws IOException {
        mapName = in.readUTF();
        MapConfigAdapter adapter = new MapConfigAdapter();
        adapter.readData(in);
        mapConfig = adapter.getMapConfig();
    }
View Full Code Here

TOP

Related Classes of com.hazelcast.management.MapConfigAdapter

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.