Examples of ModelDescription


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

     */
    private AdvancedModelWrapper performMerge(AdvancedModelWrapper source, AdvancedModelWrapper target) {
        if (source == null || target == null) {
            return null;
        }
        ModelDescription sourceDesc = source.getModelDescription();
        ModelDescription targetDesc = target.getModelDescription();
        Object transformResult = transformationEngine.performTransformation(sourceDesc, targetDesc,
            source.getUnderlyingModel(), target.getUnderlyingModel());
        AdvancedModelWrapper wrapper = AdvancedModelWrapper.wrap(transformResult);
        wrapper.removeOpenEngSBModelEntry(EDBConstants.MODEL_VERSION);
        return wrapper;
View Full Code Here

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

    public void testIfServiceIsFound_shouldWork() throws Exception {
        assertThat(transformationEngine, notNullValue());
    }

    private ModelDescription getExampleRequestDescription() {
        return new ModelDescription(ExampleRequestModel.class, exampleDomainVersion.toString());
    }
View Full Code Here

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

    private ModelDescription getExampleRequestDescription() {
        return new ModelDescription(ExampleRequestModel.class, exampleDomainVersion.toString());
    }

    private ModelDescription getExampleResponseDescription() {
        return new ModelDescription(ExampleResponseModel.class, exampleDomainVersion.toString());
    }
View Full Code Here

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

    public static void shutdown() {
        graph.shutdown();
    }

    private static ModelDescription getModelADescription() {
        return new ModelDescription(ModelA.class, new Version(1, 0, 0).toString());
    }
View Full Code Here

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

    private static ModelDescription getModelADescription() {
        return new ModelDescription(ModelA.class, new Version(1, 0, 0).toString());
    }

    private static ModelDescription getModelBDescription() {
        return new ModelDescription(ModelB.class, new Version(1, 0, 0).toString());
    }
View Full Code Here

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

    private static ModelDescription getModelBDescription() {
        return new ModelDescription(ModelB.class, new Version(1, 0, 0).toString());
    }

    private static ModelDescription getModelCDescription() {
        return new ModelDescription(ModelC.class, new Version(1, 0, 0).toString());
    }
View Full Code Here

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

     */
    public static Class getClassOfOpenEngSBModel(String clazz,
            String version,
            OsgiUtilsService serviceFinder) throws ClassNotFoundException {
        ModelRegistry registry = serviceFinder.getService(ModelRegistry.class);
        ModelDescription modelDescription = new ModelDescription(clazz, version);
        Class clazzObject = registry.loadModel(modelDescription);  
        return clazzObject;
    }
View Full Code Here

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

    private ModelDescription getSourceModelBDescription() {
        return new ModelDescription(SourceModelB.class, exampleDomainVersion.toString());
    }

    private ModelDescription getEOModelDescription() {
        return new ModelDescription(EOModel.class, exampleDomainVersion.toString());
    }
View Full Code Here

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

        XLinkConnectorRegistration registration = xLinkRegistrations.get(connectorId);
        Collection<XLinkConnectorRegistration> registrations = hostOnly
                ? getXLinkRegistrations(registration.getHostId())
                : xLinkRegistrations.values();

        ModelDescription modelDescription = ModelWrapper.wrap(modelObject).getModelDescription();
        List<XLinkObject> xLinkObjects = new ArrayList<>();
        for (XLinkConnectorRegistration r : registrations) {
            xLinkObjects.addAll(collectXLinkObjects(modelObject, modelDescription, r));
        }
        if (!xLinkObjects.isEmpty()) {
View Full Code Here

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

    @Override
    public String generateXLink(String connectorId, String context, Object modelObject) {
        StringBuilder sb = new StringBuilder(xLinkBaseUrl);
        appendXLinkProperty(sb, '?', XLinkConstants.XLINK_CONTEXTID_KEY, context);

        ModelDescription modelDescription = ModelWrapper.wrap(modelObject).getModelDescription();
        appendXLinkProperty(sb, '&', XLinkConstants.XLINK_MODELCLASS_KEY, modelDescription.getModelClassName());
        appendXLinkProperty(sb, '&', XLinkConstants.XLINK_VERSION_KEY, modelDescription.getVersionString());

        ObjectMapper mapper = new ObjectMapper();
        String objectString = null;
        try {
            objectString = mapper.writeValueAsString(modelObject);
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.