You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@commons.apache.org by Thomas Neidhart <th...@gmail.com> on 2015/01/04 18:37:25 UTC

Re: svn commit: r1649362 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/

On 01/04/2015 06:07 PM, britter@apache.org wrote:
> Author: britter
> Date: Sun Jan  4 17:07:51 2015
> New Revision: 1649362
> 
> URL: http://svn.apache.org/r1649362
> Log:
> ScanlineFilter really is an interface

there is usually a good reason to use an abstract class instead of an
interface in case the type is public.

This makes it possible to extend the interface even in minor interfaces.

Maybe this is not necessary in this case, but should be kept in mind
when doing such changes.

Thomas

> Modified:
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
>     commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java Sun Jan  4 17:07:51 2015
> @@ -20,7 +20,9 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public abstract class ScanlineFilter {
> -    public abstract void unfilter(byte[] src, byte[] dst, byte[] up)
> +public interface ScanlineFilter {
> +
> +    void unfilter(byte[] src, byte[] dst, byte[] up)
>              throws ImageReadException, IOException;
> +
>  }
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java Sun Jan  4 17:07:51 2015
> @@ -20,14 +20,13 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public class ScanlineFilterAverage extends ScanlineFilter {
> +public class ScanlineFilterAverage implements ScanlineFilter {
>      private final int bytesPerPixel;
>  
>      public ScanlineFilterAverage(final int bytesPerPixel) {
>          this.bytesPerPixel = bytesPerPixel;
>      }
>  
> -    @Override
>      public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
>              throws ImageReadException, IOException {
>          for (int i = 0; i < src.length; i++) {
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java Sun Jan  4 17:07:51 2015
> @@ -20,8 +20,8 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public class ScanlineFilterNone extends ScanlineFilter {
> -    @Override
> +public class ScanlineFilterNone implements ScanlineFilter {
> +
>      public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
>              throws ImageReadException, IOException {
>          System.arraycopy(src, 0, dst, 0, src.length);
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java Sun Jan  4 17:07:51 2015
> @@ -20,7 +20,7 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public class ScanlineFilterPaeth extends ScanlineFilter {
> +public class ScanlineFilterPaeth implements ScanlineFilter {
>      private final int bytesPerPixel;
>  
>      public ScanlineFilterPaeth(final int bytesPerPixel) {
> @@ -44,7 +44,6 @@ public class ScanlineFilterPaeth extends
>          }
>      }
>  
> -    @Override
>      public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
>              throws ImageReadException, IOException {
>          for (int i = 0; i < src.length; i++) {
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java Sun Jan  4 17:07:51 2015
> @@ -20,14 +20,13 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public class ScanlineFilterSub extends ScanlineFilter {
> +public class ScanlineFilterSub implements ScanlineFilter {
>      private final int bytesPerPixel;
>  
>      public ScanlineFilterSub(final int bytesPerPixel) {
>          this.bytesPerPixel = bytesPerPixel;
>      }
>  
> -    @Override
>      public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
>              throws ImageReadException, IOException {
>          for (int i = 0; i < src.length; i++) {
> 
> Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> ==============================================================================
> --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java (original)
> +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java Sun Jan  4 17:07:51 2015
> @@ -20,8 +20,8 @@ import java.io.IOException;
>  
>  import org.apache.commons.imaging.ImageReadException;
>  
> -public class ScanlineFilterUp extends ScanlineFilter {
> -    @Override
> +public class ScanlineFilterUp implements ScanlineFilter {
> +
>      public void unfilter(final byte[] src, final byte[] dst, final byte[] up)
>              throws ImageReadException, IOException {
>          for (int i = 0; i < src.length; i++) {
> 
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: svn commit: r1649362 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/

Posted by Thomas Neidhart <th...@gmail.com>.
On 01/04/2015 08:27 PM, Benedikt Ritter wrote:
> 2015-01-04 19:56 GMT+01:00 Thomas Neidhart <th...@gmail.com>:
> 
>> On 01/04/2015 07:48 PM, Benedikt Ritter wrote:
>>> Hello Thomas,
>>>
>>> 2015-01-04 18:37 GMT+01:00 Thomas Neidhart <th...@gmail.com>:
>>>
>>>> On 01/04/2015 06:07 PM, britter@apache.org wrote:
>>>>> Author: britter
>>>>> Date: Sun Jan  4 17:07:51 2015
>>>>> New Revision: 1649362
>>>>>
>>>>> URL: http://svn.apache.org/r1649362
>>>>> Log:
>>>>> ScanlineFilter really is an interface
>>>>
>>>> there is usually a good reason to use an abstract class instead of an
>>>> interface in case the type is public.
>>>>
>>>
>>> Yes, if the abstract class has some logic, which subclasses can leverage.
>>> This was not the case here.
>>>
>>>
>>>>
>>>> This makes it possible to extend the interface even in minor interfaces.
>>>>
>>>
>>> I don't understand what you mean. Can you give an example?
>>
>> If you define a public interface that classes implement, you can not
>> change the interface during minor releases as this would potentially
>> break client code.
>>
>> Thus there are cases where it is better to use an abstract base class
>> instead of an interface, especially if it is highly unlikely that
>> implementing classes will extend or implement other types.
>>
>> In math we have several examples of this pattern, as it is much easier
>> to add new features considering the release policy in commons.
>>
>> The pattern is more or less obsolete with java 8, as there you have the
>> possibility of default methods in interfaces, but as long as the minimum
>> required version is < java 8 you have to keep this in mind.
>>
>>>>
>>>> Maybe this is not necessary in this case, but should be kept in mind
>>>> when doing such changes.
>>>>
>>>
>>> As long as an abstract class does not define logic, it doesn't make any
>>> sense to define it as a class, rather than as an interface. Using
>>> interfaces has an important advantage: you can only extend one class, but
>>> can implement more than one interface. So we should really only define
>>> abstract classes, if they have logic that justifies their existence.
>>
>> well it depends on your use-case imho. From a clean object-oriented POV,
>> you are totally right, but you also have to consider the maintainability
>> aspect.
>>
> 
> I understand your point now. I've never thought about it this way and your
> right from an "evolving API" POV. Since we're currently designing the 1.0
> API, I'd like to leave it this way for now. Or would you rather like to see
> this commit reverted?

I think changes like these should at least be discussed on the ml so
that developers who worked on it for a longer time can comment. The 1.0
release is actually quite critical, as it will most likely remain the
stable branch for quite some time.

Thomas

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: svn commit: r1649362 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/

Posted by Benedikt Ritter <br...@apache.org>.
2015-01-04 19:56 GMT+01:00 Thomas Neidhart <th...@gmail.com>:

> On 01/04/2015 07:48 PM, Benedikt Ritter wrote:
> > Hello Thomas,
> >
> > 2015-01-04 18:37 GMT+01:00 Thomas Neidhart <th...@gmail.com>:
> >
> >> On 01/04/2015 06:07 PM, britter@apache.org wrote:
> >>> Author: britter
> >>> Date: Sun Jan  4 17:07:51 2015
> >>> New Revision: 1649362
> >>>
> >>> URL: http://svn.apache.org/r1649362
> >>> Log:
> >>> ScanlineFilter really is an interface
> >>
> >> there is usually a good reason to use an abstract class instead of an
> >> interface in case the type is public.
> >>
> >
> > Yes, if the abstract class has some logic, which subclasses can leverage.
> > This was not the case here.
> >
> >
> >>
> >> This makes it possible to extend the interface even in minor interfaces.
> >>
> >
> > I don't understand what you mean. Can you give an example?
>
> If you define a public interface that classes implement, you can not
> change the interface during minor releases as this would potentially
> break client code.
>
> Thus there are cases where it is better to use an abstract base class
> instead of an interface, especially if it is highly unlikely that
> implementing classes will extend or implement other types.
>
> In math we have several examples of this pattern, as it is much easier
> to add new features considering the release policy in commons.
>
> The pattern is more or less obsolete with java 8, as there you have the
> possibility of default methods in interfaces, but as long as the minimum
> required version is < java 8 you have to keep this in mind.
>
> >>
> >> Maybe this is not necessary in this case, but should be kept in mind
> >> when doing such changes.
> >>
> >
> > As long as an abstract class does not define logic, it doesn't make any
> > sense to define it as a class, rather than as an interface. Using
> > interfaces has an important advantage: you can only extend one class, but
> > can implement more than one interface. So we should really only define
> > abstract classes, if they have logic that justifies their existence.
>
> well it depends on your use-case imho. From a clean object-oriented POV,
> you are totally right, but you also have to consider the maintainability
> aspect.
>

I understand your point now. I've never thought about it this way and your
right from an "evolving API" POV. Since we're currently designing the 1.0
API, I'd like to leave it this way for now. Or would you rather like to see
this commit reverted?

Benedikt


>
> > Benedikt
> >
> > P.S.: Nice to know, that someone is reviewing my commits in [imaging] :-)
>
> Usually I am quiet but I read a lot ;-).
>
> Thomas
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


-- 
http://people.apache.org/~britter/
http://www.systemoutprintln.de/
http://twitter.com/BenediktRitter
http://github.com/britter

Re: svn commit: r1649362 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/

Posted by Thomas Neidhart <th...@gmail.com>.
On 01/04/2015 07:48 PM, Benedikt Ritter wrote:
> Hello Thomas,
> 
> 2015-01-04 18:37 GMT+01:00 Thomas Neidhart <th...@gmail.com>:
> 
>> On 01/04/2015 06:07 PM, britter@apache.org wrote:
>>> Author: britter
>>> Date: Sun Jan  4 17:07:51 2015
>>> New Revision: 1649362
>>>
>>> URL: http://svn.apache.org/r1649362
>>> Log:
>>> ScanlineFilter really is an interface
>>
>> there is usually a good reason to use an abstract class instead of an
>> interface in case the type is public.
>>
> 
> Yes, if the abstract class has some logic, which subclasses can leverage.
> This was not the case here.
> 
> 
>>
>> This makes it possible to extend the interface even in minor interfaces.
>>
> 
> I don't understand what you mean. Can you give an example?

If you define a public interface that classes implement, you can not
change the interface during minor releases as this would potentially
break client code.

Thus there are cases where it is better to use an abstract base class
instead of an interface, especially if it is highly unlikely that
implementing classes will extend or implement other types.

In math we have several examples of this pattern, as it is much easier
to add new features considering the release policy in commons.

The pattern is more or less obsolete with java 8, as there you have the
possibility of default methods in interfaces, but as long as the minimum
required version is < java 8 you have to keep this in mind.

>>
>> Maybe this is not necessary in this case, but should be kept in mind
>> when doing such changes.
>>
> 
> As long as an abstract class does not define logic, it doesn't make any
> sense to define it as a class, rather than as an interface. Using
> interfaces has an important advantage: you can only extend one class, but
> can implement more than one interface. So we should really only define
> abstract classes, if they have logic that justifies their existence.

well it depends on your use-case imho. From a clean object-oriented POV,
you are totally right, but you also have to consider the maintainability
aspect.

> Benedikt
> 
> P.S.: Nice to know, that someone is reviewing my commits in [imaging] :-)

Usually I am quiet but I read a lot ;-).

Thomas

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Re: svn commit: r1649362 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/

Posted by Benedikt Ritter <br...@apache.org>.
Hello Thomas,

2015-01-04 18:37 GMT+01:00 Thomas Neidhart <th...@gmail.com>:

> On 01/04/2015 06:07 PM, britter@apache.org wrote:
> > Author: britter
> > Date: Sun Jan  4 17:07:51 2015
> > New Revision: 1649362
> >
> > URL: http://svn.apache.org/r1649362
> > Log:
> > ScanlineFilter really is an interface
>
> there is usually a good reason to use an abstract class instead of an
> interface in case the type is public.
>

Yes, if the abstract class has some logic, which subclasses can leverage.
This was not the case here.


>
> This makes it possible to extend the interface even in minor interfaces.
>

I don't understand what you mean. Can you give an example?


>
> Maybe this is not necessary in this case, but should be kept in mind
> when doing such changes.
>

As long as an abstract class does not define logic, it doesn't make any
sense to define it as a class, rather than as an interface. Using
interfaces has an important advantage: you can only extend one class, but
can implement more than one interface. So we should really only define
abstract classes, if they have logic that justifies their existence.

Benedikt

P.S.: Nice to know, that someone is reviewing my commits in [imaging] :-)


>
> Thomas
>
> > Modified:
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
> >
>  commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilter.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,7 +20,9 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public abstract class ScanlineFilter {
> > -    public abstract void unfilter(byte[] src, byte[] dst, byte[] up)
> > +public interface ScanlineFilter {
> > +
> > +    void unfilter(byte[] src, byte[] dst, byte[] up)
> >              throws ImageReadException, IOException;
> > +
> >  }
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterAverage.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,14 +20,13 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public class ScanlineFilterAverage extends ScanlineFilter {
> > +public class ScanlineFilterAverage implements ScanlineFilter {
> >      private final int bytesPerPixel;
> >
> >      public ScanlineFilterAverage(final int bytesPerPixel) {
> >          this.bytesPerPixel = bytesPerPixel;
> >      }
> >
> > -    @Override
> >      public void unfilter(final byte[] src, final byte[] dst, final
> byte[] up)
> >              throws ImageReadException, IOException {
> >          for (int i = 0; i < src.length; i++) {
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterNone.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,8 +20,8 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public class ScanlineFilterNone extends ScanlineFilter {
> > -    @Override
> > +public class ScanlineFilterNone implements ScanlineFilter {
> > +
> >      public void unfilter(final byte[] src, final byte[] dst, final
> byte[] up)
> >              throws ImageReadException, IOException {
> >          System.arraycopy(src, 0, dst, 0, src.length);
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterPaeth.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,7 +20,7 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public class ScanlineFilterPaeth extends ScanlineFilter {
> > +public class ScanlineFilterPaeth implements ScanlineFilter {
> >      private final int bytesPerPixel;
> >
> >      public ScanlineFilterPaeth(final int bytesPerPixel) {
> > @@ -44,7 +44,6 @@ public class ScanlineFilterPaeth extends
> >          }
> >      }
> >
> > -    @Override
> >      public void unfilter(final byte[] src, final byte[] dst, final
> byte[] up)
> >              throws ImageReadException, IOException {
> >          for (int i = 0; i < src.length; i++) {
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterSub.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,14 +20,13 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public class ScanlineFilterSub extends ScanlineFilter {
> > +public class ScanlineFilterSub implements ScanlineFilter {
> >      private final int bytesPerPixel;
> >
> >      public ScanlineFilterSub(final int bytesPerPixel) {
> >          this.bytesPerPixel = bytesPerPixel;
> >      }
> >
> > -    @Override
> >      public void unfilter(final byte[] src, final byte[] dst, final
> byte[] up)
> >              throws ImageReadException, IOException {
> >          for (int i = 0; i < src.length; i++) {
> >
> > Modified:
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> > URL:
> http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java?rev=1649362&r1=1649361&r2=1649362&view=diff
> >
> ==============================================================================
> > ---
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> (original)
> > +++
> commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/png/scanlinefilters/ScanlineFilterUp.java
> Sun Jan  4 17:07:51 2015
> > @@ -20,8 +20,8 @@ import java.io.IOException;
> >
> >  import org.apache.commons.imaging.ImageReadException;
> >
> > -public class ScanlineFilterUp extends ScanlineFilter {
> > -    @Override
> > +public class ScanlineFilterUp implements ScanlineFilter {
> > +
> >      public void unfilter(final byte[] src, final byte[] dst, final
> byte[] up)
> >              throws ImageReadException, IOException {
> >          for (int i = 0; i < src.length; i++) {
> >
> >
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
> For additional commands, e-mail: dev-help@commons.apache.org
>
>


-- 
http://people.apache.org/~britter/
http://www.systemoutprintln.de/
http://twitter.com/BenediktRitter
http://github.com/britter