Search Options

Display Count
Sort
Preferred Language
Advanced Search

Results 1071 - 1080 of 2,371 for Try (0.03 seconds)

  1. compat/maven-builder-support/src/test/java/org/apache/maven/building/StringSourceTest.java

    import static org.junit.jupiter.api.Assertions.assertEquals;
    
    class StringSourceTest {
        @Test
        void testGetInputStream() throws Exception {
            StringSource source = new StringSource("Hello World!");
    
            try (InputStream is = source.getInputStream();
                    Scanner scanner = new Scanner(is)) {
                assertEquals("Hello World!", scanner.nextLine());
            }
        }
    
        @Test
        void testGetLocation() {
    Created: Sun Apr 05 03:35:12 GMT 2026
    - Last Modified: Fri Oct 25 12:31:46 GMT 2024
    - 1.8K bytes
    - Click Count (0)
  2. src/test/java/org/codelibs/fess/crawler/transformer/FessXpathTransformerTest.java

            };
    
            final ResponseData responseData = new ResponseData();
            responseData.setUrl("http://example.com/");
            responseData.addMetaData("X-Robots-Tag", "noindex,nofollow");
    
            try {
                transformer.processXRobotsTag(responseData, new ResultData());
                fail();
            } catch (ChildUrlsException e) {
                assertTrue(e.getChildUrlList().isEmpty());
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Fri Mar 13 23:01:26 GMT 2026
    - 62.9K bytes
    - Click Count (0)
  3. src/main/java/org/codelibs/fess/app/web/admin/reqheader/AdminReqheaderAction.java

            validate(form, messages -> {}, this::asEditHtml);
            verifyToken(this::asEditHtml);
            getRequestHeader(form).ifPresent(entity -> {
                try {
                    requestHeaderService.store(entity);
                    saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL));
                } catch (final Exception e) {
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Thu Nov 20 13:56:35 GMT 2025
    - 17.7K bytes
    - Click Count (0)
  4. src/main/java/org/codelibs/fess/app/web/admin/fileauth/AdminFileauthAction.java

            validate(form, messages -> {}, this::asEditHtml);
            verifyToken(this::asEditHtml);
            getFileAuthentication(form).ifPresent(entity -> {
                try {
                    fileAuthenticationService.store(entity);
                    saveInfo(messages -> messages.addSuccessCrudCreateCrudTable(GLOBAL));
                } catch (final Exception e) {
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Thu Nov 20 13:56:35 GMT 2025
    - 18.7K bytes
    - Click Count (0)
  5. guava-tests/test/com/google/common/eventbus/PackageSanityTests.java

        }
    
        SubscriberExceptionContext toContext() {
          return new SubscriberExceptionContext(eventBus, new Object(), this, subscriberMethod());
        }
    
        private static Method subscriberMethod() {
          try {
            return DummySubscriber.class.getMethod("handle", Object.class);
          } catch (NoSuchMethodException e) {
            throw new AssertionError(e);
          }
        }
      }
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Sun Dec 22 03:38:46 GMT 2024
    - 2K bytes
    - Click Count (0)
  6. android/guava-tests/test/com/google/common/reflect/ClassPathTest.java

      @AndroidIncompatible // ClassPath is documented as not supporting Android
    
      public void testScan_classPathCycle() throws IOException {
        File jarFile = File.createTempFile("with_circular_class_path", ".jar");
        try {
          writeSelfReferencingJarFile(jarFile, "test.txt");
          assertThat(
                  new ClassPath.LocationInfo(jarFile, ClassPathTest.class.getClassLoader())
                      .scanResources())
              .hasSize(1);
    Created: Fri Apr 03 12:43:13 GMT 2026
    - Last Modified: Thu Mar 12 17:47:10 GMT 2026
    - 23.1K bytes
    - Click Count (0)
  7. fess-crawler-opensearch/src/main/java/org/codelibs/fess/crawler/client/FesenClient.java

                    get(c -> c.admin().cluster().prepareHealth(indices).setWaitForYellowStatus().execute());
            if (!healthResponse.isTimedOut()) {
                onConnectListenerList.forEach(l -> {
                    try {
                        l.onConnect();
                    } catch (final Exception e) {
                        logger.warn("Failed to invoke onConnect listener: listener={}", l.getClass().getName(), e);
                    }
    Created: Sun Apr 12 03:50:13 GMT 2026
    - Last Modified: Sun Nov 23 02:01:26 GMT 2025
    - 26.2K bytes
    - Click Count (0)
  8. tests/test_dependency_after_yield_websockets.py

                    yield item
                else:
                    raise ValueError("Session closed")
    
    
    @contextmanager
    def acquire_session() -> Generator[Session, None, None]:
        session = Session()
        try:
            yield session
        finally:
            session.open = False
    
    
    def dep_session() -> Any:
        with acquire_session() as s:
            yield s
    
    
    def broken_dep_session() -> Any:
    Created: Sun Apr 05 07:19:11 GMT 2026
    - Last Modified: Wed Dec 17 21:25:59 GMT 2025
    - 2K bytes
    - Click Count (0)
  9. src/test/java/org/codelibs/fess/helper/CoordinatorHelperTest.java

            };
            ComponentUtil.register(mockCurlHelper, "curlHelper");
            ComponentUtil.register(new SystemHelper(), "systemHelper");
    
            final CoordinatorHelper helper = new CoordinatorHelper();
            try {
                final Field field = CoordinatorHelper.class.getDeclaredField("instanceId");
                field.setAccessible(true);
                field.set(helper, testInstanceId);
            } catch (final Exception e) {
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Sat Mar 28 06:59:19 GMT 2026
    - 58.6K bytes
    - Click Count (0)
  10. src/main/java/org/codelibs/fess/job/AggregateLogJob.java

         */
        public String execute() {
            final SearchLogHelper searchLogHelper = ComponentUtil.getSearchLogHelper();
    
            final StringBuilder resultBuf = new StringBuilder();
    
            try {
                searchLogHelper.storeSearchLog();
            } catch (final Exception e) {
                logger.error("Failed to store a search log.", e);
                resultBuf.append(e.getMessage()).append("\n");
            }
    
    Created: Tue Mar 31 13:07:34 GMT 2026
    - Last Modified: Thu Jul 17 08:28:31 GMT 2025
    - 1.9K bytes
    - Click Count (0)
Back to Top