changeset 1008:b664624a4423

remove BuffersFactory
author Franklin Schmidt <fschmidt@gmail.com>
date Sun, 23 Oct 2016 17:43:49 -0600
parents 945568ee77ac
children c3a04bded909
files src/org/eclipse/jetty/io/BuffersFactory.java src/org/eclipse/jetty/server/Connector.java
diffstat 2 files changed, 3 insertions(+), 32 deletions(-) [+]
line wrap: on
line diff
--- a/src/org/eclipse/jetty/io/BuffersFactory.java	Sun Oct 23 17:40:20 2016 -0600
+++ /dev/null	Thu Jan 01 00:00:00 1970 +0000
@@ -1,29 +0,0 @@
-//
-//  ========================================================================
-//  Copyright (c) 1995-2014 Mort Bay Consulting Pty. Ltd.
-//  ------------------------------------------------------------------------
-//  All rights reserved. This program and the accompanying materials
-//  are made available under the terms of the Eclipse Public License v1.0
-//  and Apache License v2.0 which accompanies this distribution.
-//
-//      The Eclipse Public License is available at
-//      http://www.eclipse.org/legal/epl-v10.html
-//
-//      The Apache License v2.0 is available at
-//      http://www.opensource.org/licenses/apache2.0.php
-//
-//  You may elect to redistribute this code under either of these licenses.
-//  ========================================================================
-//
-
-package org.eclipse.jetty.io;
-
-public class BuffersFactory
-{
-	public static Buffers newBuffers(Buffers.Type headerType, int headerSize, Buffers.Type bufferType, int bufferSize,int maxSize)
-	{
-		if (maxSize<0)
-			throw new RuntimeException();
-		return new PooledBuffers(headerType,headerSize,bufferType,bufferSize,maxSize);
-	}
-}
--- a/src/org/eclipse/jetty/server/Connector.java	Sun Oct 23 17:40:20 2016 -0600
+++ b/src/org/eclipse/jetty/server/Connector.java	Sun Oct 23 17:43:49 2016 -0600
@@ -29,7 +29,7 @@
 import javax.servlet.ServletRequest;
 
 import org.eclipse.jetty.io.Buffers;
-import org.eclipse.jetty.io.BuffersFactory;
+import org.eclipse.jetty.io.PooledBuffers;
 import org.eclipse.jetty.io.EndPoint;
 import org.eclipse.jetty.io.EofException;
 import org.eclipse.jetty.util.component.AggregateLifeCycle;
@@ -251,8 +251,8 @@
 	private void startBuffers()
 		throws Exception
 	{
-		_requestBuffers = BuffersFactory.newBuffers(Buffers.Type.INDIRECT,_requestHeaderSize,_requestBufferType,_requestBufferSize,_maxBuffers);
-		_responseBuffers = BuffersFactory.newBuffers(Buffers.Type.INDIRECT,_responseHeaderSize,_responseBufferType,_responseBufferSize,_maxBuffers);
+		_requestBuffers = new PooledBuffers(Buffers.Type.INDIRECT,_requestHeaderSize,_requestBufferType,_requestBufferSize,_maxBuffers);
+		_responseBuffers = new PooledBuffers(Buffers.Type.INDIRECT,_responseHeaderSize,_responseBufferType,_responseBufferSize,_maxBuffers);
 		super.doStart();
 	}