Package org.eclipse.jdt.internal.compiler

Examples of org.eclipse.jdt.internal.compiler.ClassFile


                                handleError(name, error.getSourceLineNumber(), -1, error.getMessage());
                            }
                        } else {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName = classFile.getCompoundName();
                                StringBuffer className = new StringBuffer();
                                for (int j = 0;  j < compoundName.length; j++) {
                                    if (j > 0) {
                                        className.append(".");
                                    }
                                    className.append(compoundName[j]);
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = destDir + "/" +
                                    className.toString().replace('.', '/') + ".class";
                                FileOutputStream fout = new FileOutputStream(outFile);
                                BufferedOutputStream bos = new BufferedOutputStream(fout);
                                bos.write(bytes);
View Full Code Here


                            }
                        }
                        if (problemList.isEmpty()) {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                String className = "";
                                String sep = "";
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    className += sep;
                                    className += new String(compoundName[j]);
                                    sep = ".";
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = outputDir + "/" +
                                    className.replace('.', '/') + ".class";
                                FileOutputStream fout =
                                    new FileOutputStream(outFile);
                                BufferedOutputStream bos =
View Full Code Here

                            }
                        }
                        if (problemList.isEmpty()) {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                String className = "";
                                String sep = "";
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    className += sep;
                                    className += new String(compoundName[j]);
                                    sep = ".";
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = outputDir + "/" +
                                    className.replace('.', '/') + ".class";
                                FileOutputStream fout =
                                    new FileOutputStream(outFile);
                                BufferedOutputStream bos =
View Full Code Here

                                                         problem.getMessage());
                            }
                        } else {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                String className = "";
                                String sep = "";
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    className += sep;
                                    className += new String(compoundName[j]);
                                    sep = ".";
                                }
                                JavaClassWriter writer =
                                    classWriterFactory.getClassWriter(className);
                                byte[] bytes = classFile.getBytes();
                                ByteArrayInputStream bais =
                                    new ByteArrayInputStream(bytes);
                                writer.writeClass(bais);
                            }
                        }
View Full Code Here

                                            problem.getMessage());
                            }
                        } else {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                String className = "";
                                String sep = "";
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    className += sep;
                                    className += new String(compoundName[j]);
                                    sep = ".";
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = destDir + "/" +
                                    className.replace('.', '/') + ".class";
                                FileOutputStream fout =
                                    new FileOutputStream(outFile);
                                BufferedOutputStream bos =
View Full Code Here

                            }
                        }
                        if (problemList.isEmpty()) {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                StringBuilder classFileName = new StringBuilder(outputDir).append('/');
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    if(j > 0)
                                        classFileName.append('/');
                                    classFileName.append(compoundName[j]);
                                }
                                byte[] bytes = classFile.getBytes();
                                classFileName.append(".class");
                                FileOutputStream fout =
                                    new FileOutputStream(classFileName.toString());
                                BufferedOutputStream bos =
                                    new BufferedOutputStream(fout);
View Full Code Here

                            }
                        }
                        if (problemList.isEmpty()) {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName =
                                    classFile.getCompoundName();
                                String className = "";
                                String sep = "";
                                for (int j = 0;
                                     j < compoundName.length; j++) {
                                    className += sep;
                                    className += new String(compoundName[j]);
                                    sep = ".";
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = outputDir + "/" +
                                    className.replace('.', '/') + ".class";
                                FileOutputStream fout =
                                    new FileOutputStream(outFile);
                                BufferedOutputStream bos =
View Full Code Here

                                handleError(name, error.getSourceLineNumber(), -1, error.getMessage());
                            }
                        } else {
                            ClassFile[] classFiles = result.getClassFiles();
                            for (int i = 0; i < classFiles.length; i++) {
                                ClassFile classFile = classFiles[i];
                                char[][] compoundName = classFile.getCompoundName();
                                StringBuffer className = new StringBuffer();
                                for (int j = 0;  j < compoundName.length; j++) {
                                    if (j > 0) {
                                        className.append(".");
                                    }
                                    className.append(compoundName[j]);
                                }
                                byte[] bytes = classFile.getBytes();
                                String outFile = destDir + "/" +
                                    className.toString().replace('.', '/') + ".class";
                                FileOutputStream fout = new FileOutputStream(outFile);
                                BufferedOutputStream bos = new BufferedOutputStream(fout);
                                bos.write(bytes);
View Full Code Here

                    }
                }
                // Something has been compiled
                ClassFile[] clazzFiles = result.getClassFiles();
                for (int i = 0; i < clazzFiles.length; i++) {
                    final ClassFile clazzFile = clazzFiles[i];
                    final char[][] compoundName = clazzFile.getCompoundName();
                    final StringBuffer clazzName = new StringBuffer();
                    for (int j = 0; j < compoundName.length; j++) {
                        if (j != 0) {
                            clazzName.append('.');
                        }
                        clazzName.append(compoundName[j]);
                    }
                    Logger.trace("Compiled %s", clazzName);
                    applicationClasses.getApplicationClass(clazzName.toString()).compiled(clazzFile.getBytes());
                }
            }
        };

        /**
 
View Full Code Here

      }

      // Something has been compiled
      ClassFile[] clazzFiles = result.getClassFiles();
      for (int i = 0; i < clazzFiles.length; i++) {
        final ClassFile clazzFile = clazzFiles[i];
        final char[][] compoundName = clazzFile.getCompoundName();
        final StringBuffer clazzName = new StringBuffer();
        for (int j = 0; j < compoundName.length; j++) {
          if (j != 0) {
            clazzName.append('.');
          }
          clazzName.append(compoundName[j]);
        }
        byte[] bytes = clazzFile.getBytes();
        JapidFlags.debug("compiled: " + clazzName);
        // XXX address anonymous inner class issue!! ....$1...
        String cname = clazzName.toString();
        RendererClass rc = JapidRenderer.japidClasses.get(cname);
        if (rc == null) {
View Full Code Here

TOP

Related Classes of org.eclipse.jdt.internal.compiler.ClassFile

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.