- Sort Score
- Result 10 results
- Languages All
Results 521 - 530 of 1,205 for Exceptions (0.06 sec)
-
FessFunctions.java
L85: public Long load(final String key) throws Exception { L86: try { L87: final Path path = Paths.get(LaServletContextUtil.getServletContext().getRealPath(key)); L88: if (Files.isRegularFile(path)) { L89: return Files.getLastModifiedTime(path).toMillis(); L90: } L91: } catch (final Exception e) { L92: logger.debug("Failed to access...github.com/codelibs/fess/src/main/java/org/code...Thu Feb 22 01:53:18 UTC 2024 16.9K bytes -
AbstractLoadingCacheTest.java
L28: L29:/** L30: * Unit test for {@link AbstractLoadingCache}. L31: * L32: * @author Charles Fry L33: */ L34:public class AbstractLoadingCacheTest extends TestCase { L35: L36: public void testGetUnchecked_checked() { L37: final Exception cause = new Exception(); L38: final AtomicReference<Object> valueRef = new AtomicReference<>(); L39: LoadingCache<Object, Object> cache = L40: new AbstractLoadingCache<Object, Object>() { L41: @Override L42: public Object get(Object...github.com/google/guava/android/guava-tests/tes...Wed Sep 06 17:04:31 UTC 2023 5K bytes -
AdminBackupAction.java
java.util.function.Consumer; L44:import java.util.stream.Collectors; L45: L46:import org.apache.commons.text.StringEscapeUtils; L47:import org.apache.logging.log4j.LogManager; L48:import org.apache.logging.log4j.Logger; L49:import org.codelibs.core.exception.IORuntimeException; L50:import org.codelibs.core.io.CopyUtil; L51:import org.codelibs.core.lang.StringUtil; L52:import org.codelibs.core.misc.Pair; L53:import org.codelibs.curl.CurlResponse; L54:import org.codelibs.fess.Constants; L55:import org...github.com/codelibs/fess/src/main/java/org/code...Sat Oct 12 01:54:46 UTC 2024 28.5K bytes -
FuturesGetDoneTest.java
); L35: } L36: L37: public void testSuccessfulNull() throws ExecutionException { L38: assertThat(getDone(Futures.<@Nullable String>immediateFuture(null))).isEqualTo(null); L39: } L40: L41: public void testFailed() { L42: Exception failureCause = new Exception(); L43: ExecutionException expected = L44: assertThrows(ExecutionException.class, () -> getDone(immediateFailedFuture(failureCause))); L45: assertThat(expected).hasCauseThat().isEqualTo(failureCause); L46: } L47: L48:...github.com/google/guava/guava-tests/test/com/go...Mon Oct 21 15:41:36 UTC 2024 2.3K bytes -
AbstractFuture.java
L257: try { L258: pendingDescription = pendingToString(); L259: } catch (RuntimeException e) { L260: // Don't call getMessage or toString() on the exception, in case the exception thrown by the L261: // subclass is implemented with bugs similar to the subclass. L262: pendingDescription = "Exception thrown from implementation: " + e.getClass(); L263: } L264: // The future may complete during or before the call to getPendingToString, so we use null L265:...github.com/google/guava/guava-gwt/src-super/com...Mon Jan 22 19:37:41 UTC 2024 12.3K bytes -
AsynchronousGet.java
okhttp3.OkHttpClient; L23:import okhttp3.Request; L24:import okhttp3.Response; L25:import okhttp3.ResponseBody; L26: L27:public final class AsynchronousGet { L28: private final OkHttpClient client = new OkHttpClient(); L29: L30: public void run() throws Exception { L31: Request request = new Request.Builder() L32: .url("http://publicobject.com/helloworld.txt") L33: .build(); L34: L35: client.newCall(request).enqueue(new Callback() { L36: @Override public void onFailure(Call call,...github.com/square/okhttp/samples/guide/src/main...Sun May 22 01:29:42 UTC 2016 1.9K bytes -
ParseResponseWithMoshi.java
{ L27: private final OkHttpClient client = new OkHttpClient(); L28: private final Moshi moshi = new Moshi.Builder().build(); L29: private final JsonAdapter<Gist> gistJsonAdapter = moshi.adapter(Gist.class); L30: L31: public void run() throws Exception { L32: Request request = new Request.Builder() L33: .url("https://api.github.com/gists/c2a7c39532239ff261be") L34: .build(); L35: try (Response response = client.newCall(request).execute()) { L36: if (!response.isSuccessful())...github.com/square/okhttp/samples/guide/src/main...Sun May 22 01:29:42 UTC 2016 1.8K bytes -
ClassLoaderIteratorTest.java
L23:import java.net.URL; L24:import java.net.URLClassLoader; L25: L26:import org.junit.Test; L27: L28:/** L29: * @author koichik L30: */ L31:public class ClassLoaderIteratorTest { L32: L33: /** L34: * @throws Exception L35: */ L36: @Test L37: public void test() throws Exception { L38: final ClassLoader cl1 = new URLClassLoader(new URL[] { new URL("file:/foo") }, null); L39: final ClassLoader cl2 = new URLClassLoader(new URL[] { new URL("file:/bar") }, cl1); L40: final...github.com/codelibs/corelib/src/test/java/org/c...Thu Mar 07 01:59:08 UTC 2024 1.7K bytes -
Service.java
be called on the {@link Listener}. L283: * L284: * @param from The previous state that is being transitioned from. Failure can occur in any L285: * state with the exception of {@linkplain State#NEW NEW} or {@linkplain State#TERMINATED L286: * TERMINATED}. L287: * @param failure The exception that caused the failure. L288: */ L289: public void failed(State from, Throwable failure) {} L290: } L291:}...github.com/google/guava/guava/src/com/google/co...Tue Apr 04 09:45:04 UTC 2023 12.1K bytes -
ImmutableCollection.java
L250: */ L251: int internalArrayEnd() { L252: throw new UnsupportedOperationException(); L253: } L254: L255: @Override L256: public abstract boolean contains(@CheckForNull Object object); L257: L258: /** L259: * Guaranteed to throw an exception and leave the collection unmodified. L260: * L261: * @throws UnsupportedOperationException always L262: * @deprecated Unsupported operation. L263: */ L264: @CanIgnoreReturnValue L265: @Deprecated L266: @Override L267: @DoNotCall("Always...github.com/google/guava/guava/src/com/google/co...Mon Aug 12 16:59:15 UTC 2024 18.8K bytes