import gnu.java.nio.SelectorProviderImpl;
import java.io.IOException;
+import java.nio.channels.Channel;
import java.nio.channels.DatagramChannel;
import java.nio.channels.Pipe;
import java.nio.channels.ServerSocketChannel;
public abstract SocketChannel openSocketChannel() throws IOException;
/**
+ * Returns the inherited channel of the VM.
+ *
+ * @return the inherited channel of the VM
+ *
+ * @throws IOException If an I/O error occurs
+ * @throws SecurityException If an installed security manager denies access
+ * to RuntimePermission("inheritedChannel")
+ *
+ * @since 1.5
+ */
+ public Channel inheritedChannel()
+ throws IOException
+ {
+ SecurityManager sm = System.getSecurityManager();
+ if (sm != null)
+ {
+ sm.checkPermission(new RuntimePermission("inheritedChannel"));
+ }
+ // Implementation note: The default implementation can't do much more
+ // than return null. If a VM can provide something more useful it should
+ // install its own SelectorProvider (maybe a subclass of this one) to
+ // return something more useful.
+ return null;
+ }
+
+ /**
* Returns the system-wide default selector provider for this invocation
* of the Java virtual machine.
*