Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 527 for Optional (0.17 sec)

  1. guava/src/com/google/common/base/Optional.java

     */
    @DoNotMock("Use Optional.of(value) or Optional.absent()")
    @GwtCompatible(serializable = true)
    @ElementTypesAreNonnullByDefault
    public abstract class Optional<T> implements Serializable {
      /**
       * Returns an {@code Optional} instance with no contained reference.
       *
       * <p><b>Comparison to {@code java.util.Optional}:</b> this method is equivalent to Java 8's
       * {@code Optional.empty}.
       */
      public static <T> Optional<T> absent() {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 14.6K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/base/Optional.java

     */
    @DoNotMock("Use Optional.of(value) or Optional.absent()")
    @GwtCompatible(serializable = true)
    @ElementTypesAreNonnullByDefault
    public abstract class Optional<T> implements Serializable {
      /**
       * Returns an {@code Optional} instance with no contained reference.
       *
       * <p><b>Comparison to {@code java.util.Optional}:</b> this method is equivalent to Java 8's
       * {@code Optional.empty}.
       */
      public static <T> Optional<T> absent() {
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 13K bytes
    - Viewed (0)
  3. tests/test_security_oauth2_optional.py

    
    def get_current_user(oauth_header: Optional[str] = Security(reusable_oauth2)):
        if oauth_header is None:
            return None
        user = User(username=oauth_header)
        return user
    
    
    @app.post("/login")
    def login(form_data: OAuth2PasswordRequestFormStrict = Depends()):
        return form_data
    
    
    @app.get("/users/me")
    def read_users_me(current_user: Optional[User] = Depends(get_current_user)):
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 10.8K bytes
    - Viewed (0)
  4. tests/test_security_oauth2_optional_description.py

    
    def get_current_user(oauth_header: Optional[str] = Security(reusable_oauth2)):
        if oauth_header is None:
            return None
        user = User(username=oauth_header)
        return user
    
    
    @app.post("/login")
    def login(form_data: OAuth2PasswordRequestFormStrict = Depends()):
        return form_data
    
    
    @app.get("/users/me")
    def read_users_me(current_user: Optional[User] = Depends(get_current_user)):
    Python
    - Registered: Sun Apr 21 07:19:11 GMT 2024
    - Last Modified: Thu Apr 18 19:40:57 GMT 2024
    - 10.9K bytes
    - Viewed (0)
  5. guava-tests/test/com/google/common/base/OptionalTest.java

        assertThat(Optional.presentInstances(optionals)).isEmpty();
      }
    
      public void testPresentInstances_somePresent() {
        List<Optional<String>> optionals =
            ImmutableList.of(Optional.of("a"), Optional.<String>absent(), Optional.of("c"));
        assertThat(Optional.presentInstances(optionals)).containsExactly("a", "c").inOrder();
      }
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Wed Feb 21 18:32:41 GMT 2024
    - 11.2K bytes
    - Viewed (0)
  6. android/guava-tests/test/com/google/common/base/OptionalTest.java

        assertThat(Optional.presentInstances(optionals)).isEmpty();
      }
    
      public void testPresentInstances_somePresent() {
        List<Optional<String>> optionals =
            ImmutableList.of(Optional.of("a"), Optional.<String>absent(), Optional.of("c"));
        assertThat(Optional.presentInstances(optionals)).containsExactly("a", "c").inOrder();
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Feb 21 18:32:41 GMT 2024
    - 10.5K bytes
    - Viewed (0)
  7. android/guava-tests/test/com/google/common/cache/CacheBuilderFactory.java

      }
    
      private static final Function<Object, Optional<?>> NULLABLE_TO_OPTIONAL =
          new Function<Object, Optional<?>>() {
            @Override
            public Optional<?> apply(@Nullable Object obj) {
              return Optional.fromNullable(obj);
            }
          };
    
      private static final Function<Optional<?>, @Nullable Object> OPTIONAL_TO_NULLABLE =
          new Function<Optional<?>, @Nullable Object>() {
            @Override
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 8.1K bytes
    - Viewed (0)
  8. common-protos/k8s.io/api/apps/v1beta1/generated.proto

    message Deployment {
      // Standard object metadata.
      // +optional
      optional k8s.io.apimachinery.pkg.apis.meta.v1.ObjectMeta metadata = 1;
    
      // Specification of the desired behavior of the Deployment.
      // +optional
      optional DeploymentSpec spec = 2;
    
      // Most recently observed status of the Deployment.
      // +optional
      optional DeploymentStatus status = 3;
    }
    
    Plain Text
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Mon Mar 11 18:43:24 GMT 2024
    - 24K bytes
    - Viewed (0)
  9. common-protos/k8s.io/api/autoscaling/v1/generated.proto

      // one status to another
      // +optional
      optional k8s.io.apimachinery.pkg.apis.meta.v1.Time lastTransitionTime = 3;
    
      // reason is the reason for the condition's last transition.
      // +optional
      optional string reason = 4;
    
      // message is a human-readable explanation containing details about
      // the transition
      // +optional
      optional string message = 5;
    }
    
    Plain Text
    - Registered: Wed Apr 24 22:53:08 GMT 2024
    - Last Modified: Mon Mar 11 18:43:24 GMT 2024
    - 22K bytes
    - Viewed (0)
  10. guava-tests/test/com/google/common/cache/CacheBuilderFactory.java

      }
    
      private static final Function<Object, Optional<?>> NULLABLE_TO_OPTIONAL =
          new Function<Object, Optional<?>>() {
            @Override
            public Optional<?> apply(@Nullable Object obj) {
              return Optional.fromNullable(obj);
            }
          };
    
      private static final Function<Optional<?>, @Nullable Object> OPTIONAL_TO_NULLABLE =
          new Function<Optional<?>, @Nullable Object>() {
            @Override
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 20 17:00:05 GMT 2024
    - 8.1K bytes
    - Viewed (0)
Back to top