Package com.volantis.mcs.migrate.api.notification

Examples of com.volantis.mcs.migrate.api.notification.Notification


        // ==================================================================
        // Do the test.
        // ==================================================================

        LogDispatcherNotificationReporter reporter = new LogDispatcherNotificationReporter(loggerMock);
        Notification notification = new SimpleMessageNotification(NotificationType.ERROR, "message");
        reporter.reportNotification(notification);
    }
View Full Code Here


        // ==================================================================
        // Do the test.
        // ==================================================================

        LogDispatcherNotificationReporter reporter = new LogDispatcherNotificationReporter(loggerMock);
        Notification notification = new SimpleMessageNotification(NotificationType.INFO, "message");
        reporter.reportNotification(notification);
    }
View Full Code Here

                        File outputChild = new File(outputFile, fileName);
                        migrateImpl(inputChild, outputChild,
                                path + "/" + fileName, migrator);
                    }
                } else {
                    Notification note = notificationFactory.
                            createLocalizedNotification(
                                    NotificationType.ERROR, "cannot-create-dir",
                                    outputFile.getAbsolutePath());
                    reporter.reportNotification(note);
                }
            } else {
                InputStream in = new FileInputStream(inputFile);
                OutputCreator out = new FileOutputCreator(outputFile);
                try {
                    InputMetadata inputMeta =
                            frameworkFactory.createInputMetadata(path, true);
                    migrator.migrate(inputMeta, in, out);
                } catch (ResourceMigrationException me) {
                    reporter.reportNotification(
                            notificationFactory.createThrowableNotification(
                                    NotificationType.ERROR, me));
                }
            }
        } else {
            Notification note = notificationFactory.createLocalizedNotification(
                    NotificationType.ERROR, "file-missing",
                    inputFile.getAbsolutePath());
            reporter.reportNotification(note);
        }
    }
View Full Code Here

                    outputSchemaValidator.validate(content);
                } catch (SAXException e) {
                    if (inputError) {
                        // Validation errors are informational since we are not
                        // sure if they are a result of dodgy input or not.
                        Notification notification =
                            notificationFactory.createLocalizedNotification(
                                    NotificationType.ERROR,
                                    "unexpected-exception", e);
                        reporter.reportNotification(notification);
                    } else {
View Full Code Here

TOP

Related Classes of com.volantis.mcs.migrate.api.notification.Notification

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.