Package xtc.typical

Examples of xtc.typical.Tuple$T1


            dialogStage.initModality(Modality.WINDOW_MODAL);
            dialogStage.initOwner(primaryStage);
            Scene scene = new Scene(page);
            dialogStage.setScene(scene);
           
            AboutUsDialogController controller = loader.getController();
            controller.setDialogStage(dialogStage);
           
            dialogStage.showAndWait();
           
   
        }catch (IOException e){
View Full Code Here


        try {
            // Load person overview.
            FXMLLoader loader = new FXMLLoader();
            loader.setLocation(MainQuizCreator.class.getResource("view/D2LQuizCreatorMain.fxml"));
            AnchorPane D2LQuizCreatorMain = (AnchorPane) loader.load();
            D2LQuizCreatorMainController controller;
            controller = loader.getController();
            controller.setMainQuizCreator(this);
            // Set person overview into the center of root layout.
            rootLayout.setCenter(D2LQuizCreatorMain);
            primaryStage.setMaximized(false);
        } catch (IOException e) {
            e.printStackTrace();
View Full Code Here

        try {
            // Load quiz options view.
            FXMLLoader loader = new FXMLLoader();
            loader.setLocation(MainQuizCreator.class.getResource("view/QuestionRootLayout.fxml"));
            questionRootLayout = (BorderPane) loader.load();
            QuestionRootLayoutController controller;
            controller = loader.getController();
            controller.setMainQuizCreator(this);
            primaryStage.setMaximized(true);
           
          
           
            // Set person overview into the center of root layout.
View Full Code Here

            try {
                // Load quiz options view.
                FXMLLoader loader = new FXMLLoader();
                loader.setLocation(MainQuizCreator.class.getResource("view/QuizOptionsScene.fxml"));
                AnchorPane QuizOptionsScene = (AnchorPane) loader.load();
                QuizOptionsController controller;
                controller = loader.getController();
                controller.setMainQuizCreator(this);
                if(quiz != null) {
                    //showing quiz private BorderPane rootLayout;
                    controller.setQuizName(QuizFactory.getQuizTitle(quiz));
                    controller.setFields(quiz);
                }
                // Set person overview into the center of root layout.
                rootLayout.setCenter(QuizOptionsScene);
                primaryStage.setMaximized(false);
            } catch (IOException e) {
View Full Code Here

        try {
            // Load root layout from fxml file.
            FXMLLoader loader = new FXMLLoader();
            loader.setLocation(MainQuizCreator.class.getResource("view/RootLayout.fxml"));
            rootLayout = (BorderPane) loader.load();
            RootLayoutController rootController = loader.getController();
            rootController.setMainQuizCreator(this);
            // Show the scene containing the root layout.
            Scene scene = new Scene(rootLayout, WIDTH, HEIGHT);
            primaryStage.setScene(scene);
            primaryStage.show();
        } catch (IOException e) {
View Full Code Here

    }
   
    public static void testReadFromZip()
    {
        ZipReader<Manifest> reader = new ZipReader<Manifest>(EXAMPLE_READ_ZIP, Manifest.class);
        Manifest man = reader.getObjectFromXML(Manifest.FILE_NAME);
        List<ManifestResource> res = man.getResources();
       
        for(ManifestResource r: res)
        {       
          System.out.println(r.getTitle());
        }
View Full Code Here

    }
   
    public static void testWriteToZip()
    {
        ManifestResource res = new ManifestResource("123", "Example quiz");
        Manifest man = new Manifest("D2L_321", res);
        ZipWriter<Manifest> writer = new ZipWriter<Manifest>(EXAMPLE_WRITE_ZIP, Manifest.class);
        writer.writeObjectToXML(man);
        System.out.println("Done");
    }
View Full Code Here

        //Create the ZipReaders that will read the files
        ZipReader<Manifest> manReader = new ZipReader<>(EXAMPLE_READ_ZIP, Manifest.class);
        ZipReader<Quiz> quizReader = new ZipReader<>(EXAMPLE_READ_ZIP, Quiz.class);
       
        //Get the Manifest contained within the zip
        Manifest man = manReader.getObjectFromXML(Manifest.FILE_NAME);
        manReader.closeStreams();//make sure to close the streams before continuing
       
        List<ManifestResource> manRes = man.getResources();//All the ManifestResources within a imsmanifest.xml specified by <resource> tag
        String quizFiles[] = new String[manRes.size()];//Will hold the name of the quiz Xml files within the zip
        Quiz quizzes[] = new Quiz[manRes.size()];//Holds the Quiz objects
        for(int i = 0; i < quizFiles.length; i++)
        {
            quizFiles[i] = manRes.get(i).getHref();//Get the fileNames contained within the zip
View Full Code Here

        fileChooser.setInitialDirectory(new File(System.getProperty("user.home")));
        zipFile = fileChooser.showOpenDialog(null);
        //Passes zip file to Zip file reader/ manifest reader
         if(zipFile != null){
             ZipReader<Manifest> reader = new ZipReader<>(zipFile,Manifest.class);
             Manifest manifest = reader.getObjectFromXML(Manifest.FILE_NAME);
             String quizFile = manifest.getResources().get(0).getHref();
            
             ZipReader<Quiz> quizReader = new ZipReader<>(zipFile, Quiz.class);
             Quiz quiz = quizReader.getObjectFromXML(quizFile);
             showQuizOptions(quiz);
         }
View Full Code Here

        fileChooser.setInitialDirectory(new File(System.getProperty("user.home")));
        zipFile = fileChooser.showOpenDialog(null);
        //Passes zip file to Zip file reader/ manifest reader
         if(zipFile != null){
             ZipReader<Manifest> reader = new ZipReader<>(zipFile,Manifest.class);
             Manifest manifest = reader.getObjectFromXML(Manifest.FILE_NAME);
             String quizFile = manifest.getResources().get(0).getHref();
            
             ZipReader<Quiz> quizReader = new ZipReader<>(zipFile, Quiz.class);
             Quiz quiz = quizReader.getObjectFromXML(quizFile);
             showQuizOptions(quiz);
         }
View Full Code Here

TOP

Related Classes of xtc.typical.Tuple$T1

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.