Removed extra indentation from code on get-involved/develop/applications

This commit is contained in:
str4d
2013-04-25 05:01:54 +00:00
parent f2bb84c45f
commit ecc2af4ebe

View File

@@ -303,14 +303,14 @@ In addition, we will ask the I2PSocketManager for an I2PSession, so we can find
{%- endtrans %}</p> {%- endtrans %}</p>
<div class="box"> <div class="box">
{% highlight lang='java' %} {% highlight lang='java' %}
package i2p.echoserver; package i2p.echoserver;
import net.i2p.client.I2PSession; import net.i2p.client.I2PSession;
import net.i2p.client.streaming.I2PServerSocket; import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocketManager; import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.client.streaming.I2PSocketManagerFactory; import net.i2p.client.streaming.I2PSocketManagerFactory;
public class Main { public class Main {
public static void main(String[] args) { public static void main(String[] args) {
//Initialize application //Initialize application
@@ -321,7 +321,7 @@ In addition, we will ask the I2PSocketManager for an I2PSession, so we can find
//The additional main method code comes here... //The additional main method code comes here...
} }
} }
{% endhighlight %} {% endhighlight %}
<p style="text-align:center">{{ _('Code example 1: initializing the server application.') }}</p> <p style="text-align:center">{{ _('Code example 1: initializing the server application.') }}</p>
</div> </div>
@@ -336,23 +336,23 @@ The bold code is the new code we add.
<div class="box"> <div class="box">
{% highlight lang='java', {% highlight lang='java',
hl_lines=[3,4,5,6,7,8,9,10,25,26,27,28,29,32,34,35,36,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,65,67] %} hl_lines=[3,4,5,6,7,8,9,10,25,26,27,28,29,32,34,35,36,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,65,67] %}
package i2p.echoserver; package i2p.echoserver;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.io.OutputStream; import java.io.OutputStream;
import java.net.ConnectException; import java.net.ConnectException;
import java.net.SocketTimeoutException; import java.net.SocketTimeoutException;
import net.i2p.I2PException; import net.i2p.I2PException;
import net.i2p.client.streaming.I2PSocket; import net.i2p.client.streaming.I2PSocket;
import net.i2p.util.I2PThread; import net.i2p.util.I2PThread;
import net.i2p.client.I2PSession; import net.i2p.client.I2PSession;
import net.i2p.client.streaming.I2PServerSocket; import net.i2p.client.streaming.I2PServerSocket;
import net.i2p.client.streaming.I2PSocketManager; import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.client.streaming.I2PSocketManagerFactory; import net.i2p.client.streaming.I2PSocketManagerFactory;
public class Main { public class Main {
public static void main(String[] args) { public static void main(String[] args) {
I2PSocketManager manager = I2PSocketManagerFactory.createManager(); I2PSocketManager manager = I2PSocketManagerFactory.createManager();
@@ -404,7 +404,7 @@ hl_lines=[3,4,5,6,7,8,9,10,25,26,27,28,29,32,34,35,36,38,39,40,41,42,43,44,45,46
} }
} }
{% endhighlight %} {% endhighlight %}
<p style="text-align:center">{{ _('Code example 2: accepting connections from clients and handling messages.') }}</p> <p style="text-align:center">{{ _('Code example 2: accepting connections from clients and handling messages.') }}</p>
</div> </div>
@@ -438,27 +438,27 @@ Once we have an I2PSocket, we can start sending and receiving data to and from t
{%- endtrans %}</p> {%- endtrans %}</p>
<div class="box"> <div class="box">
{% highlight lang='java' %} {% highlight lang='java' %}
package i2p.echoclient; package i2p.echoclient;
import java.io.BufferedReader; import java.io.BufferedReader;
import java.io.BufferedWriter; import java.io.BufferedWriter;
import java.io.IOException; import java.io.IOException;
import java.io.InputStreamReader; import java.io.InputStreamReader;
import java.io.InterruptedIOException; import java.io.InterruptedIOException;
import java.io.OutputStream; import java.io.OutputStream;
import java.io.OutputStreamWriter; import java.io.OutputStreamWriter;
import java.net.ConnectException; import java.net.ConnectException;
import java.net.NoRouteToHostException; import java.net.NoRouteToHostException;
import java.util.logging.Level; import java.util.logging.Level;
import java.util.logging.Logger; import java.util.logging.Logger;
import net.i2p.I2PException; import net.i2p.I2PException;
import net.i2p.client.streaming.I2PSocket; import net.i2p.client.streaming.I2PSocket;
import net.i2p.client.streaming.I2PSocketManager; import net.i2p.client.streaming.I2PSocketManager;
import net.i2p.client.streaming.I2PSocketManagerFactory; import net.i2p.client.streaming.I2PSocketManagerFactory;
import net.i2p.data.DataFormatException; import net.i2p.data.DataFormatException;
import net.i2p.data.Destination; import net.i2p.data.Destination;
public class Main { public class Main {
public static void main(String[] args) { public static void main(String[] args) {
I2PSocketManager manager = I2PSocketManagerFactory.createManager(); I2PSocketManager manager = I2PSocketManagerFactory.createManager();
@@ -507,7 +507,7 @@ Once we have an I2PSocket, we can start sending and receiving data to and from t
} }
} }
} }
{% endhighlight %} {% endhighlight %}
<p style="text-align:center">{{ _('Code example 3: starting the client and connecting it to the server application.') }}</p> <p style="text-align:center">{{ _('Code example 3: starting the client and connecting it to the server application.') }}</p>
</div> </div>