chore: Fix compiling error in AsSubscriber.java and FromPublisher.java (#953)

This commit is contained in:
kerr 2024-01-15 11:12:25 +08:00 committed by GitHub
parent c411fa528a
commit 057fe066e8
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 9 deletions

View file

@ -22,9 +22,6 @@ import org.apache.pekko.stream.javadsl.Source;
import org.apache.pekko.stream.javadsl.JavaFlowSupport;
//#imports
import org.apache.commons.lang.NotImplementedException;
public interface AsSubscriber {
// We are 'faking' the JavaFlowSupport API here so we can include the signature as a snippet in the API,
// because we're not publishing those (jdk9+) classes in our API docs yet.
@ -42,13 +39,13 @@ public interface AsSubscriber {
static class Row {
public String getField(String fieldName) {
throw new NotImplementedException();
throw new UnsupportedOperationException("Not implemented in sample");
}
}
static class DatabaseClient {
Publisher<Row> fetchRows() {
throw new NotImplementedException();
throw new UnsupportedOperationException("Not implemented in sample");
}
}

View file

@ -22,8 +22,6 @@ import org.apache.pekko.stream.javadsl.JavaFlowSupport;
//#imports
import org.apache.commons.lang.NotImplementedException;
public interface FromPublisher {
// We are 'faking' the JavaFlowSupport API here so we can include the signature as a snippet in the API,
// because we're not publishing those (jdk9+) classes in our API docs yet.
@ -41,13 +39,13 @@ public interface FromPublisher {
static class Row {
public String getField(String fieldName) {
throw new NotImplementedException();
throw new UnsupportedOperationException("Not implemented in sample");
}
}
static class DatabaseClient {
Publisher<Row> fetchRows() {
throw new NotImplementedException();
throw new UnsupportedOperationException("Not implemented in sample");
}
}