test_class.declarator: SCRIPT_URL = URL.valueOf("condition://0.0.0.0/com.foo.BarService")
test_class.modifier: private
test_class.original_string: private URL SCRIPT_URL = URL.valueOf("condition://0.0.0.0/com.foo.BarService");
test_class.type: URL
test_class.var_name: SCRIPT_URL
test_class.file: dubbo-cluster/src/test/java/org/apache/dubbo/rpc/cluster/directory/StaticDirectoryTest.java
test_class.identifier: StaticDirectoryTest
test_case.body: @Test
      public void testStaticDirectory() {
          Router router = new ConditionRouterFactory().getRouter(getRouteUrl(" => " + " host = " + NetUtils.getLocalHost()));
          List<Router> routers = new ArrayList<Router>();
          routers.add(router);
          List<Invoker<String>> invokers = new ArrayList<Invoker<String>>();
          Invoker<String> invoker1 = new MockInvoker<String>(URL.valueOf("dubbo://10.20.3.3:20880/com.foo.BarService"));
          Invoker<String> invoker2 = new MockInvoker<String>(URL.valueOf("dubbo://" + NetUtils.getLocalHost() + ":20880/com.foo.BarService"));
          Invoker<String> invoker3 = new MockInvoker<String>(URL.valueOf("dubbo://" + NetUtils.getLocalHost() + ":20880/com.foo.BarService"));
          invokers.add(invoker1);
          invokers.add(invoker2);
          invokers.add(invoker3);
          List<Invoker<String>> filteredInvokers = router.route(invokers, URL.valueOf("consumer://" + NetUtils.getLocalHost() + "/com.foo.BarService"), new RpcInvocation());
          StaticDirectory<String> staticDirectory = new StaticDirectory<>(filteredInvokers);
          boolean isAvailable = staticDirectory.isAvailable();
          Assertions.assertTrue(!isAvailable);
          List<Invoker<String>> newInvokers = staticDirectory.list(new MockDirInvocation());
          Assertions.assertTrue(newInvokers.size() > 0);
          staticDirectory.destroy();
          Assertions.assertEquals(0, newInvokers.size());
      }
test_case.class_method_signature: StaticDirectoryTest.testStaticDirectory()
test_case.full_signature: @Test public void testStaticDirectory()
test_case.identifier: testStaticDirectory
test_case.invocations: getRouter getRouteUrl getLocalHost add valueOf valueOf getLocalHost valueOf getLocalHost add add add route valueOf getLocalHost isAvailable assertTrue list assertTrue size destroy assertEquals size
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testStaticDirectory()
focal_class.declarator: logger = LoggerFactory.getLogger(StaticDirectory.class)
focal_class.modifier: private static final
focal_class.original_string: private static final Logger logger = LoggerFactory.getLogger(StaticDirectory.class);
focal_class.type: Logger
focal_class.var_name: logger
focal_class.declarator: invokers
focal_class.modifier: private final
focal_class.original_string: private final List<Invoker<T>> invokers;
focal_class.type: List<Invoker<T>>
focal_class.var_name: invokers
focal_class.file: dubbo-cluster/src/main/java/org/apache/dubbo/rpc/cluster/directory/StaticDirectory.java
focal_class.identifier: StaticDirectory
focal_class.class_method_signature: StaticDirectory.StaticDirectory(List<Invoker<T>> invokers)
focal_class.full_signature: public  StaticDirectory(List<Invoker<T>> invokers)
focal_class.identifier: StaticDirectory
focal_class.modifiers: public
focal_class.parameters: (List<Invoker<T>> invokers)
focal_class.signature:  StaticDirectory(List<Invoker<T>> invokers)
focal_class.class_method_signature: StaticDirectory.StaticDirectory(List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.full_signature: public  StaticDirectory(List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.identifier: StaticDirectory
focal_class.modifiers: public
focal_class.parameters: (List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.signature:  StaticDirectory(List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.class_method_signature: StaticDirectory.StaticDirectory(URL url, List<Invoker<T>> invokers)
focal_class.full_signature: public  StaticDirectory(URL url, List<Invoker<T>> invokers)
focal_class.identifier: StaticDirectory
focal_class.modifiers: public
focal_class.parameters: (URL url, List<Invoker<T>> invokers)
focal_class.signature:  StaticDirectory(URL url, List<Invoker<T>> invokers)
focal_class.class_method_signature: StaticDirectory.StaticDirectory(URL url, List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.full_signature: public  StaticDirectory(URL url, List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.identifier: StaticDirectory
focal_class.modifiers: public
focal_class.parameters: (URL url, List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.signature:  StaticDirectory(URL url, List<Invoker<T>> invokers, RouterChain<T> routerChain)
focal_class.class_method_signature: StaticDirectory.getInterface()
focal_class.full_signature: @Override public Class<T> getInterface()
focal_class.identifier: getInterface
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: Class<T>
focal_class.signature: Class<T> getInterface()
focal_class.class_method_signature: StaticDirectory.getAllInvokers()
focal_class.full_signature: @Override public List<Invoker<T>> getAllInvokers()
focal_class.identifier: getAllInvokers
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: List<Invoker<T>>
focal_class.signature: List<Invoker<T>> getAllInvokers()
focal_class.class_method_signature: StaticDirectory.isAvailable()
focal_class.full_signature: @Override public boolean isAvailable()
focal_class.identifier: isAvailable
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isAvailable()
focal_class.class_method_signature: StaticDirectory.destroy()
focal_class.full_signature: @Override public void destroy()
focal_class.identifier: destroy
focal_class.modifiers: @Override public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void destroy()
focal_class.class_method_signature: StaticDirectory.buildRouterChain()
focal_class.full_signature: public void buildRouterChain()
focal_class.identifier: buildRouterChain
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void buildRouterChain()
focal_class.class_method_signature: StaticDirectory.doList(Invocation invocation)
focal_class.full_signature: @Override protected List<Invoker<T>> doList(Invocation invocation)
focal_class.identifier: doList
focal_class.modifiers: @Override protected
focal_class.parameters: (Invocation invocation)
focal_class.return: List<Invoker<T>>
focal_class.signature: List<Invoker<T>> doList(Invocation invocation)
focal_class.superclass: extends AbstractDirectory<T>
focal_method.body: public StaticDirectory(List<Invoker<T>> invokers) {
          this(null, invokers, null);
      }
focal_method.class_method_signature: StaticDirectory.StaticDirectory(List<Invoker<T>> invokers)
focal_method.full_signature: public  StaticDirectory(List<Invoker<T>> invokers)
focal_method.identifier: StaticDirectory
focal_method.modifiers: public
focal_method.parameters: (List<Invoker<T>> invokers)
focal_method.signature:  StaticDirectory(List<Invoker<T>> invokers)