Skip to content

Commit 2c6ae52

Browse files
committed
Added static create methods to BufferOpenings and BufferClosings.
1 parent bf01afa commit 2c6ae52

File tree

1 file changed

+18
-4
lines changed

1 file changed

+18
-4
lines changed

rxjava-core/src/main/java/rx/operators/OperationBuffer.java

Lines changed: 18 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -722,11 +722,25 @@ public interface BufferClosing {
722722
// Tagging interface for objects which can close buffers.
723723
}
724724

725-
public static class BufferOpenings implements BufferOpening {
726-
// Simple class implementing BufferOpening for conveniance.
725+
public static class BufferOpenings {
726+
727+
public static BufferOpening create() {
728+
return new BufferOpening() {};
729+
}
730+
731+
private BufferOpenings() {
732+
// Prevent instantation.
733+
}
727734
}
728-
public static class BufferClosings implements BufferClosing {
729-
// Simple class implementing BufferClosing for conveniance.
735+
public static class BufferClosings {
736+
737+
public static BufferClosing create() {
738+
return new BufferClosing() {};
739+
}
740+
741+
private BufferClosings() {
742+
// Prevent instantation.
743+
}
730744
}
731745

732746
public static class UnitTest {

0 commit comments

Comments
 (0)