Package org.openengsb.core.api.model

Examples of org.openengsb.core.api.model.OpenEngSBModel


        commit.setConnectorId("testConnector");
        commit.setDomainId("testDomain");
        commit.setInstanceId("testInstance");
        commit.setRevisionNumber(UUID.fromString("550e8400-e29b-41d4-a716-446655440000"));

        OpenEngSBModel insert1 = new TestModelA();
        OpenEngSBModel insert2 = new TestModelA();
        OpenEngSBModel insert3 = new TestModelB();

        OpenEngSBModel update1 = new TestModelA();
        OpenEngSBModel update2 = new TestModelA();

        OpenEngSBModel delete1 = new TestModelA();
        OpenEngSBModel delete2 = new TestModelB();

        commit.addInsert(insert1).addInsert(insert2).addInsert(insert3);
        commit.addUpdate(update1).addUpdate(update2);
        commit.addDelete(delete1).addDelete(delete2);
View Full Code Here


                        wrapper.getFilename(), String.class);
                } catch (IOException e) {
                    LOGGER.error(e.getMessage());
                }
            } else if (OpenEngSBModel.class.isAssignableFrom(entry.getType())) {
                OpenEngSBModel temp = (OpenEngSBModel) entry.getValue();
                String subOid = convertSubModel(temp, objects, info);
                object.putEDBObjectEntry(entry.getKey(), subOid, String.class);
            } else if (List.class.isAssignableFrom(entry.getType())) {
                List<?> list = (List<?>) entry.getValue();
                if (list == null || list.size() == 0) {
View Full Code Here

     * calculates the differences of this two models.
     */
    public static ModelDiff createModelDiff(OpenEngSBModel updated, String completeModelId,
            EngineeringDatabaseService edbService, EDBConverter edbConverter) {
        EDBObject queryResult = edbService.getObject(completeModelId);
        OpenEngSBModel old = edbConverter.convertEDBObjectToModel(updated.getClass(), queryResult);
        ModelDiff diff = new ModelDiff(old, updated);
        calculateDifferences(diff);
        return diff;
    }
View Full Code Here

TOP

Related Classes of org.openengsb.core.api.model.OpenEngSBModel

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.