All Downloads are FREE. Search and download functionalities are using the official Maven repository.

net.java.html.lib.PromiseLike Maven / Gradle / Ivy

The newest version!
package net.java.html.lib;
public class PromiseLike extends net.java.html.lib.Objs {
  private final Class type_T;
  protected PromiseLike(net.java.html.lib.Objs.Constructor c, java.lang.Object js) {
    super(c, js);
    this.type_T = java.lang.Object.class;
  }
  protected PromiseLike(net.java.html.lib.Objs.Constructor c, java.lang.Object js, java.lang.reflect.Type type_T) {
    super(c, js);
    this.type_T = (Class)type_T;
  }
  private static final class $Constructor extends net.java.html.lib.Objs.Constructor {
    $Constructor() {
      super(PromiseLike.class);
    }
    @Override
    public PromiseLike create(java.lang.Object obj) {
      return obj == null ? null : new PromiseLike(this, obj);
    }
    @Override
    public PromiseLike create(java.lang.Object obj, java.lang.reflect.Type... typeParameters) {
      return obj == null ? null : new PromiseLike(this, obj, findType(typeParameters, 0));
    }
    private static java.lang.reflect.Type findType(java.lang.reflect.Type[] arr, int index) {
      return arr == null || arr.length <= index || arr[index] == null ? java.lang.Object.class : arr[index];
    }
  };
  private static final $Constructor $AS = new $Constructor();
  public static PromiseLike $as(java.lang.Object obj) {
    return $AS.create(obj);
  }
  public static PromiseLike $as(java.lang.Object obj, java.lang.reflect.Type... typeParameters) {
    return $AS.create(obj, typeParameters);
  }
  public  net.java.html.lib.PromiseLike then(net.java.html.lib.Function.A1>> onfulfilled, net.java.html.lib.Function.A1 onrejected) {
    return (net.java.html.lib.PromiseLike)net.java.html.lib.PromiseLike.$as($Typings$.then$406($js(this), net.java.html.lib.Objs.$js(net.java.html.lib.Function.newFunction(onfulfilled, new Class[] {null})), net.java.html.lib.Objs.$js(net.java.html.lib.Function.newFunction(onrejected, new Class[] {java.lang.Object.class}))), null);
  }
  public  net.java.html.lib.PromiseLike then() {
    return (net.java.html.lib.PromiseLike)net.java.html.lib.PromiseLike.$as($Typings$.then$407($js(this)), null);
  }
  public  net.java.html.lib.PromiseLike then(net.java.html.lib.Function.A1>> onfulfilled) {
    return (net.java.html.lib.PromiseLike)net.java.html.lib.PromiseLike.$as($Typings$.then$408($js(this), net.java.html.lib.Objs.$js(net.java.html.lib.Function.newFunction(onfulfilled, new Class[] {null}))), null);
  }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy