diff src/org/eclipse/jetty/io/BufferUtil.java @ 1059:013939bfc9e8

remove JBuffer.poke()
author Franklin Schmidt <fschmidt@gmail.com>
date Tue, 08 Nov 2016 05:39:33 -0700
parents 7d872cc72ec2
children 158d1e6ac17f
line wrap: on
line diff
--- a/src/org/eclipse/jetty/io/BufferUtil.java	Tue Nov 08 04:17:22 2016 -0700
+++ b/src/org/eclipse/jetty/io/BufferUtil.java	Tue Nov 08 05:39:33 2016 -0700
@@ -118,44 +118,6 @@
 		}
 	}
 
-	/* ------------------------------------------------------------ */
-	/**
-	 * Add hex integer BEFORE current getIndex.
-	 * @param buffer
-	 * @param n
-	 */
-	public static void prependHexInt(JBuffer buffer, int n)
-	{
-		if (n==0)
-		{
-			int gi=buffer.getIndex();
-			buffer.poke(--gi,(byte)'0');
-			buffer.setGetIndex(gi);
-		}
-		else
-		{
-			boolean minus=false;
-			if (n<0)
-			{
-				minus=true;
-				n=-n;
-			}
-
-			int gi=buffer.getIndex();
-			while(n>0)
-			{
-				int d = 0xf&n;
-				n=n>>4;
-				buffer.poke(--gi,DIGIT[d]);
-			}
-			
-			if (minus)
-				buffer.poke(--gi,(byte)'-');
-			buffer.setGetIndex(gi);
-		}
-	}
-	
-
 	public static void putDecLong(JBuffer buffer, long n)
 	{
 		if (n < 0)