Module org.newsclub.net.unix.vsock
Package org.newsclub.net.unix.vsock
Class AFVSOCKSocketFactory.FixedAddress
java.lang.Object
javax.net.SocketFactory
org.newsclub.net.unix.AFSocketFactory<org.newsclub.net.unix.AFVSOCKSocketAddress>
org.newsclub.net.unix.vsock.AFVSOCKSocketFactory
org.newsclub.net.unix.vsock.AFVSOCKSocketFactory.FixedAddress
- All Implemented Interfaces:
org.newsclub.net.unix.AFSocketAddressFromHostname<org.newsclub.net.unix.AFVSOCKSocketAddress>
- Enclosing class:
AFVSOCKSocketFactory
Always connects sockets to the given VSOCK type and instance.
- Author:
- Christian Kohlschütter
-
Nested Class Summary
Nested classes/interfaces inherited from class org.newsclub.net.unix.vsock.AFVSOCKSocketFactory
AFVSOCKSocketFactory.FixedAddress
Nested classes/interfaces inherited from class org.newsclub.net.unix.AFSocketFactory
org.newsclub.net.unix.AFSocketFactory.FixedAddressSocketFactory
-
Constructor Summary
ConstructorDescriptionFixedAddress
(int port, int cid) Creates anAFVSOCKSocketFactory
that always uses the given VSOCK address.FixedAddress
(org.newsclub.net.unix.AFVSOCKSocketAddress addr) Creates anAFVSOCKSocketFactory
that always uses the given VSOCK address. -
Method Summary
Modifier and TypeMethodDescriptionorg.newsclub.net.unix.AFVSOCKSocketAddress
addressFromHost
(String host, int javaPort) Methods inherited from class org.newsclub.net.unix.vsock.AFVSOCKSocketFactory
configure, connectTo, createSocket
Methods inherited from class org.newsclub.net.unix.AFSocketFactory
createSocket, createSocket, createSocket, createSocket, isInetAddressSupported
Methods inherited from class javax.net.SocketFactory
getDefault
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.newsclub.net.unix.AFSocketAddressFromHostname
isHostnameSupported
-
Constructor Details
-
FixedAddress
Creates anAFVSOCKSocketFactory
that always uses the given VSOCK address.- Parameters:
port
- The VSOCK port.cid
- The VSOCK CID.- Throws:
SocketException
- on internal error.
-
FixedAddress
public FixedAddress(org.newsclub.net.unix.AFVSOCKSocketAddress addr) Creates anAFVSOCKSocketFactory
that always uses the given VSOCK address.- Parameters:
addr
- The address.
-
-
Method Details
-
addressFromHost
public org.newsclub.net.unix.AFVSOCKSocketAddress addressFromHost(String host, int javaPort) throws SocketException - Throws:
SocketException
-