Package net.i2p.client
Class I2PSimpleClient
- java.lang.Object
-
- net.i2p.client.I2PSimpleClient
-
-
Field Summary
-
Fields inherited from interface net.i2p.client.I2PClient
DEFAULT_LISTEN_PORT, DEFAULT_SIGTYPE, PROP_ENABLE_SSL, PROP_FAST_RECEIVE, PROP_GZIP, PROP_PW, PROP_RELIABILITY, PROP_RELIABILITY_BEST_EFFORT, PROP_RELIABILITY_GUARANTEED, PROP_RELIABILITY_NONE, PROP_SIGTYPE, PROP_TCP_HOST, PROP_TCP_PORT, PROP_USER, PROTOCOL_BYTE
-
-
Constructor Summary
Constructors Constructor Description I2PSimpleClient()
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Destination
createDestination(OutputStream destKeyStream)
Deprecated.Don't do thisDestination
createDestination(OutputStream destKeyStream, SigType type)
Deprecated.Don't do thisDestination
createDestination(OutputStream destKeyStream, Certificate cert)
Deprecated.Don't do thisI2PSession
createSession(InputStream destKeyStream, Properties options)
Create a new session (though do not connect it yet)I2PSession
createSession(I2PAppContext context, Properties options)
Create a new session (though do not connect it yet)
-
-
-
Method Detail
-
createDestination
@Deprecated public Destination createDestination(OutputStream destKeyStream) throws I2PException, IOException
Deprecated.Don't do thisDescription copied from interface:I2PClient
Create a new destination with the default certificate creation properties and store it, along with the private encryption and signing keys at the specified location Caller must close stream.- Specified by:
createDestination
in interfaceI2PClient
- Parameters:
destKeyStream
- create a new destination and write out the object to the given stream, formatted as Destination, PrivateKey, and SigningPrivateKey format is specified inPrivateKeyFile
- Returns:
- new destination
- Throws:
UnsupportedOperationException
- alwaysI2PException
IOException
-
createDestination
@Deprecated public Destination createDestination(OutputStream destKeyStream, SigType type) throws I2PException, IOException
Deprecated.Don't do thisDescription copied from interface:I2PClient
Create a destination with the given signature type. It will have a null certificate for DSA 1024/160 and KeyCertificate otherwise. This is not bound to the I2PClient, you must supply the data back again in createSession(). Caller must close stream.- Specified by:
createDestination
in interfaceI2PClient
- Parameters:
destKeyStream
- location to write out the destination, PrivateKey, and SigningPrivateKey, format is specified inPrivateKeyFile
- Throws:
UnsupportedOperationException
- alwaysI2PException
IOException
- Since:
- 0.9.12
-
createDestination
@Deprecated public Destination createDestination(OutputStream destKeyStream, Certificate cert) throws I2PException, IOException
Deprecated.Don't do thisDescription copied from interface:I2PClient
Create a new destination with the given certificate and store it, along with the private encryption and signing keys at the specified location Caller must close stream.- Specified by:
createDestination
in interfaceI2PClient
- Parameters:
destKeyStream
- location to write out the destination, PrivateKey, and SigningPrivateKey, format is specified inPrivateKeyFile
cert
- certificate to tie to the destination- Returns:
- newly created destination
- Throws:
UnsupportedOperationException
- alwaysI2PException
IOException
-
createSession
public I2PSession createSession(InputStream destKeyStream, Properties options) throws I2PSessionException
Create a new session (though do not connect it yet)- Specified by:
createSession
in interfaceI2PClient
- Parameters:
destKeyStream
- location from which to read the Destination, PrivateKey, and SigningPrivateKey from, format is specified inPrivateKeyFile
options
- set of options to configure the router with, if null will use System properties- Returns:
- new session allowing a Destination to recieve all of its messages and send messages to any other Destination.
- Throws:
I2PSessionException
-
createSession
public I2PSession createSession(I2PAppContext context, Properties options) throws I2PSessionException
Create a new session (though do not connect it yet)- Throws:
I2PSessionException
-
-