cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From anto...@apache.org
Subject cvs commit: cocoon-2.1/src/java/org/apache/cocoon/components/flow/javascript/fom CompilingClassLoader.java
Date Wed, 31 Dec 2003 05:50:12 GMT
antonio     2003/12/30 21:50:12

  Modified:    src/blocks/woody/java/org/apache/cocoon/woody/binding
                        NewJXPathBinding.java CaseJXPathBinding.java
               src/java/org/apache/cocoon/components/flow/javascript/fom
                        CompilingClassLoader.java
  Log:
  Formatting code
  
  Revision  Changes    Path
  1.2       +1 -2      cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/NewJXPathBinding.java
  
  Index: NewJXPathBinding.java
  ===================================================================
  RCS file: /home/cvs//cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/NewJXPathBinding.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- NewJXPathBinding.java	29 Dec 2003 06:14:48 -0000	1.1
  +++ NewJXPathBinding.java	31 Dec 2003 05:50:12 -0000	1.2
  @@ -75,7 +75,6 @@
        * Constructs NewJXPathBinding
        * @param commonAtts 
        * @param widgetId
  -     * @param xpath
        * @param childBindings
        */
       public NewJXPathBinding(JXpathBindingBuilderBase.CommonAttributes commonAtts, String
widgetId, JXPathBindingBase[] childBindings) {
  
  
  
  1.2       +3 -3      cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/CaseJXPathBinding.java
  
  Index: CaseJXPathBinding.java
  ===================================================================
  RCS file: /home/cvs//cocoon-2.1/src/blocks/woody/java/org/apache/cocoon/woody/binding/CaseJXPathBinding.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- CaseJXPathBinding.java	29 Dec 2003 06:14:48 -0000	1.1
  +++ CaseJXPathBinding.java	31 Dec 2003 05:50:12 -0000	1.2
  @@ -92,7 +92,7 @@
        */
       public void doLoad(Widget frmModel, JXPathContext jxpc) {
           Union unionWidget = (Union)frmModel;
  -        if (widgetId.equals((String)unionWidget.getValue())) {
  +        if (widgetId.equals(unionWidget.getValue())) {
               JXPathContext subContext = jxpc.getRelativeContext(jxpc.getPointer(this.xpath));
               Binding[] subBindings = getChildBindings();
               if (subBindings != null) {
  @@ -114,7 +114,7 @@
        */
       public void doSave(Widget frmModel, JXPathContext jxpc) throws BindingException {
           Union unionWidget = (Union)frmModel;
  -        if (widgetId.equals((String)unionWidget.getValue())) {
  +        if (widgetId.equals(unionWidget.getValue())) {
               JXPathContext subContext = jxpc.getRelativeContext(jxpc.getPointer(this.xpath));
               Binding[] subBindings = getChildBindings();
               if (subBindings != null) {
  
  
  
  1.5       +8 -6      cocoon-2.1/src/java/org/apache/cocoon/components/flow/javascript/fom/CompilingClassLoader.java
  
  Index: CompilingClassLoader.java
  ===================================================================
  RCS file: /home/cvs//cocoon-2.1/src/java/org/apache/cocoon/components/flow/javascript/fom/CompilingClassLoader.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- CompilingClassLoader.java	29 Dec 2003 17:51:38 -0000	1.4
  +++ CompilingClassLoader.java	31 Dec 2003 05:50:12 -0000	1.5
  @@ -70,6 +70,10 @@
   import org.tempuri.javac.JavaSourceReaderFactory;
   import org.tempuri.javacImpl.eclipse.JavaCompilerImpl;
   
  +/*
  + * CompilingClassLoader
  + * CVS $Id$
  + */
   public class CompilingClassLoader extends ClassLoader {
   
       SourceResolver sourceResolver;
  @@ -209,7 +213,7 @@
                   }
                   baos.flush();
                   final Reader reader = 
  -                    new BufferedReader(new InputStreamReader(new ByteArrayInputStream(baos.toByteArray())));;
  +                    new BufferedReader(new InputStreamReader(new ByteArrayInputStream(baos.toByteArray())));
                   return new JavaSourceReader() {
                           public Reader getReader() {
                               return reader;
  @@ -241,8 +245,7 @@
           public JavaClassReader 
               getClassReader(final String className) 
   		throws IOException {
  -		final byte[] bytes = 
  -		    (byte[])classRepository.getCompiledClass(className);
  +		final byte[] bytes = classRepository.getCompiledClass(className);
   		if (bytes != null) {
   		    return new JavaClassReader() {
   			    public String getClassName() {
  @@ -341,8 +344,7 @@
   
   	private byte[] compile(String className) 
               throws ClassNotFoundException {
  -	    byte[] result = (byte[])
  -                classRepository.getCompiledClass(className);
  +	    byte[] result = classRepository.getCompiledClass(className);
   	    if (result != null) {
   		return result;
   	    }
  @@ -370,7 +372,7 @@
                       throw new ClassCompilationException(msg);
                       
                   }
  -                return (byte[])classRepository.getCompiledClass(className);
  +                return classRepository.getCompiledClass(className);
               } finally {
                   releaseSource(src);
               }
  
  
  

Mime
View raw message