Examples of Main


Examples of com.sun.jdo.api.persistence.enhancer.generator.Main

    private Collection generatePC(IASEjbCMPEntityDescriptor ejbcmp,
        File srcout, File classout)
        throws IOException {

        ArrayList fileList = new ArrayList();
        Main gen = new Main(ejbModel, srcout);
        String className = nameMapper.getPersistenceClassForEjbName(ejbcmp.getName());

        if (className != null) {
            // generate PC class
            //@olsen, 4653156: the enhancer-generator deals with class names
            // in JVM format, i.e., with '/' for '.' as separator
            String jvmClassName = className.replace('.', '/');
            File file = gen.generate(jvmClassName);
            fileList.add(file);

            // write mapping file
            MappingClassElement mappingClass
                = model.getMappingClass(className);
View Full Code Here

Examples of com.sun.tools.javac.Main

                } else {
                    try {
                        ByteArrayOutputStream bos =
                            new ByteArrayOutputStream();
                        PrintWriter pw = new PrintWriter(bos);
                        Main compiler = new Main();
                        int ret = compiler.compile(cmds, pw);
                        if (ret != 0) {
                            byte[] errorBytes = bos.toByteArray();
                            String errorString = new String(errorBytes);
                            throw new JavaCompilerException(
                                "java_compiler.error", "Native compiler returned an error: {0}\nError messages are: {1}", new Object[] { new Integer (ret), errorString } );
View Full Code Here

Examples of com.sun.tools.javac.main.Main

            if (fileManager == null)
                fileManager = getStandardFileManager(diagnosticListener, null, null);
            fileManager = ccw.wrap(fileManager);
            context.put(JavaFileManager.class, fileManager);
            processOptions(context, fileManager, options);
            Main compiler = new Main("javacTask", context.get(Log.outKey));
            return new JavacTaskImpl(compiler, options, context, classes, compilationUnits);
        } catch (ClientCodeException ex) {
            throw new RuntimeException(ex.getCause());
        }
    }
View Full Code Here

Examples of com.tizianobasile.androiddrawablefactory.gui.Main

  public static final String[] DENSITIES = {"ldpi", "mdpi", "hdpi", "xhdpi", "xxhdpi", "xxxhdpi"};
  public static final double[] DENSITY_MULTIPLIERS = {.75, 1, 1.5, 2, 3, 4};
  public static void main(String... args)
  {
    initLaF();
    Main mainWindow = new Main();
    mainWindow.pack();
    mainWindow.setTitle("Android Drawable Factory");
    mainWindow.setLocationRelativeTo(null);
    mainWindow.setResizable(false);
    mainWindow.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    mainWindow.setVisible(true);
  }
View Full Code Here

Examples of de.innovationgate.ext.org.mozilla.javascript.tools.debugger.Main

    private void openDebugger(ContextFactory factory) {
       
        try {
            UIManager.setLookAndFeel(MetalLookAndFeel.class.getName());
        _debugger = new Main("TMLScript Debugger");
        _debugger.attachTo(factory);
        _debugger.setExitAction(null);
        _debugger.pack();
        _debugger.setSize(600, 460);
        _debugger.setVisible(true);
View Full Code Here

Examples of de.sciss.meloncillo.Main

    public void actionPerformed( ActionEvent e )
    {
      AppWindow filterFrame = (AppWindow) getApplication().getComponent( Main.COMP_FILTER );
   
      if( filterFrame == null ) {
        final Main root = (Main) AbstractApplication.getApplication();
        filterFrame = new FilterDialog( root, doc );
      }
      filterFrame.setVisible( true );
      filterFrame.toFront();
    }
View Full Code Here

Examples of easysm.executors.Main

  Name stTino;

  @Before
  public void setUp()
  {
    main = new Main(false);
    Name name = null;
    try {
      name = new Name("Test");
      stPino = new Name("Pino");
      stGino = new Name("Gino");
View Full Code Here

Examples of edu.spbstu.hoteldb.Main

  public void create(List<Object> args) {   
    this.setHgap(10);
    this.setVgap(10);
   
    final TextArea results = (TextArea)args.get(0);
    final Main main = (Main)args.get(1);
   
    Label llogin = new Label("Login: ");
    TextField tflogin = new TextField();
    tflogin.addEventHandler(KeyEvent.KEY_TYPED, new NameFilter());
    tflogin.setPromptText("3-16 symbols");
    Label lemail = new Label("Email: ");
    TextField tfemail = new TextField();
    tfemail.addEventHandler(KeyEvent.KEY_TYPED, new NameFilter());
    tfemail.setPromptText("Required");
    Label lpass = new Label("Password: ");
    PasswordField tfpass = new PasswordField();
    tfpass.addEventHandler(KeyEvent.KEY_TYPED, new NameFilter());
    tfpass.setPromptText("Required");
    Label lname = new Label("Name: ");
    TextField tfname = new TextField();
    tfname.setPromptText("Required");
    tfname.addEventHandler(KeyEvent.KEY_TYPED, new NameFilter());
    Label lcountry = new Label("Country: ");
    ChoiceBox<String> cbcountry = new ChoiceBox<String>(
        FXCollections.observableArrayList("Russia", "Spain", "USA",
            "UK"));
    Label llang = new Label("Language: ");
    ChoiceBox<String> cblang = new ChoiceBox<String>(
        FXCollections.observableArrayList("ru", "es", "en", "ger"));
    Button btnthis = new Button("Register");
    List<Node> hargs = new ArrayList<Node>(6);
    hargs.add(0, tflogin);
    hargs.add(1, tfemail);
    hargs.add(2, tfpass);
    hargs.add(3, tfname);
    hargs.add(4, cbcountry);
    hargs.add(5, cblang);
    btnthis.setOnAction(new RegisterQueryEventHandler(connect, results,
        main, hargs));
    Button btnback = new Button("Back");
    btnback.setOnAction(new EventHandler<ActionEvent>() {
      @Override
      public void handle(ActionEvent event) {
        main.setPanel(PanelType.LoginPanel, null);
      }
    });
    this.add(llogin, 0, 0);
    this.add(tflogin, 1, 0);
    this.add(lpass, 0, 1);
View Full Code Here

Examples of io.hawt.embedded.Main

        Object val = System.getProperty("hawtio.authenticationEnabled");
        if (val == null) {
            System.setProperty("hawtio.authenticationEnabled", "false");
        }

        Main main = new Main();

        try {
            String virtualMachineClass = "com.sun.tools.attach.VirtualMachine";
            try {
                Class<?> aClass = loadClass(virtualMachineClass, App.class.getClassLoader(), Thread.currentThread().getContextClassLoader());
                //System.out.println("Found " + aClass + " on the classpath!");
            } catch (Exception e) {
                // lets try find the tools.jar instead
                Set<String> paths = new HashSet<String>();
                String javaHome = System.getProperty("java.home", ".");
                addPath(paths, javaHome);

                // now lets try the JAVA_HOME environment variable just in case
                javaHome = System.getenv("JAVA_HOME");
                if (javaHome != null && javaHome.length() > 0) {
                    addPath(paths, javaHome);
                }

                boolean found = false;
                for (String path : paths) {
                    File file = new File(path, "lib/tools.jar");
                    if (file.exists()) {
                        found = true;
                        String url = file.toURI().toURL().toString();
                        main.setExtraClassPath(url);
                        break;
                    }
                }
                if (!found) {
                    System.out.println("Failed to load class " + virtualMachineClass
                            + " and find tools.jar in directories " + paths + ". " + e);
                }
            }

            ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
            URL resource = classLoader.getResource(WAR_FILENAME);
            if (resource == null) {
                System.err.println("Could not find the " + WAR_FILENAME + " on classpath!");
                System.exit(1);
            }
            File warFile = File.createTempFile("hawtio-", ".war");
            //System.out.println("Extracting " + WAR_FILENAME + " to " + warFile + " ...");
            writeStreamTo(resource.openStream(), new FileOutputStream(warFile), 64 * KB);

            String warPath = warFile.getCanonicalPath();
            main.setWar(warPath);
        } catch (Exception e) {
            System.out.println("Failed to create hawtio: " + e.getMessage());
            e.printStackTrace();
            return;
        }

        if (!main.parseArguments(args) || main.isHelp()) {
            main.showOptions();
        } else {
            try {
                main.run();
                if (Desktop.isDesktopSupported()) {
                    int port = main.getPort();
                    String url = "http://localhost:" +  port + main.getContextPath();
                    try {
                        Desktop.getDesktop().browse(new URI(url));
                    } catch (Exception e) {
                        System.out.println("Failed to open browser session, to access hawtio visit \"" + url + "\"");
                    }
View Full Code Here

Examples of jp.sf.amateras.stepcounter.diffcount.Main

    }

    try {
      File basedir = getProject().getBaseDir();

      Main main = new Main();
      main.setFormat(format);
      if(output != null && output.length() != 0){
        main.setOutput(new FileOutputStream(output));
      }
      main.setEncoding(encoding);
      main.setSrcdir(new File(basedir, srcdir));
      main.setOlddir(new File(basedir, olddir));

      main.executeCount();

      if(output!=null && !output.equals("")){
        System.out.println(new File(output).getAbsolutePath() + "�ɃJ�E���g���ʂ��o�͂��܂����B");
      }
    } catch(Throwable t){
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.