1 /* 2 * Copyright 2004 Sun Microsystems, Inc. All rights reserved. 3 * SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms. 4 */ 5 6 package com.sun.corba.se.spi.orbutil.threadpool; 7 8 9 public interface ThreadPoolChooser 10 { 11 /** 12 * This method is used to return an instance of ThreadPool based on the 13 * strategy/policy implemented in the ThreadPoolChooser from the set of 14 * ThreadPools allowed to be used by the ORB. Typically, the set of 15 * ThreadPools would be specified by passing the threadpool-ids 16 * configured in the ORB element of the domain.xml of the appserver. 17 */ 18 public ThreadPool getThreadPool(); 19 20 /** 21 * This method is used to return an instance of ThreadPool that is obtained 22 * by using the id argument passed to it. This method will be used in 23 * situations where the threadpool id is known to the caller e.g. by the 24 * connection object or looking at the high order bits of the request id 25 */ 26 public ThreadPool getThreadPool(int id); 27 28 /** 29 * This method is a convenience method to see what threadpool-ids are being 30 * used by the ThreadPoolChooser 31 */ 32 public String[] getThreadPoolIds(); 33 } 34