Skip to content

Commit

Permalink
Added Classes to match additional specs
Browse files Browse the repository at this point in the history
  • Loading branch information
alimiladi committed Mar 20, 2017
1 parent eed54a6 commit ab0a441
Show file tree
Hide file tree
Showing 3 changed files with 56 additions and 1 deletion.
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
package ch.heigvd.res.stpatrick;

import java.io.IOException;
import java.io.Reader;

/**
* Created by ALi on 20.03.2017.
*/
public class ARemoverReader extends Reader {

@Override
public int read(char[] cbuf, int off, int len) throws IOException {
for (int i = off ; i<off+len; i++){
if(cbuf[i]=='a'||cbuf[i]=='A'){
i++;
}
}
return 0;
}

@Override
public void close() throws IOException {

}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
package ch.heigvd.res.stpatrick;

import java.io.IOException;
import java.io.Writer;

/**
* Created by ALi on 20.03.2017.
*/
public class ARemoverWriter extends Writer {
@Override
public void write(char[] cbuf, int off, int len) throws IOException {

}

@Override
public void flush() throws IOException {

}

@Override
public void close() throws IOException {

}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
package ch.heigvd.res.stpatrick;


import java.io.FileReader;
import java.io.InputStreamReader;
import java.io.Reader;
import java.io.Writer;

/**
*
* @author Olivier Liechti
Expand All @@ -14,6 +19,7 @@ public IStreamProcessorsFactory getStreamProcessorsFactory() {
}

IStreamDecoratorController getStreamDecoratorController() {
return null;
return new StreamDecoratorController();

}
}

0 comments on commit ab0a441

Please sign in to comment.