APISonar


def.js.Date.Date

> def > js > Date > Date
def APIs js APIs Date APIs Date APIs

Example 1
public void initDate() {
		if (this.initialDate == null) {
			this.initialDate = new Date();
		}
	}
Example 2
public static void main(String[] args) {

		double JANUARY = 0;
		Date d = new Date(Date.UTC(2020, JANUARY, 01, 0, 0, 0));

		String localeString = d.toLocaleString("fr", new DateTimeFormatOptions() {
			{
			}
		});

		System.out.println(localeString);
		$export("localeString", localeString);
	}
Example 3
public static void animate() {
		GameArea area = gm.getCurrentLevel();
		if (!gm.isPaused()) {
			if (!area.finished) {
				area.currentDate = new Date();
				area.render();
				area.calculateNextPositions();
				window.requestAnimationFrame((time) -> {
					animate();
				});
			} else {
				gm.onLevelEnded();
			}
		}
	}
Example 4
public static void main(String[] args) {
		new MyFinalClass<String>();
		MyFinalClass<String> o = new MyFinalClass<String>(99);
		o.overloaded("s1");
		o.overloaded(99, "s2");
		o.overloaded(true);
		o.overloaded(new Date());
		o.overloaded2();
		o.overloaded2(6);
		o.overloaded3(100, new Date());
		new Test2().o1(null);
		new Test2().o2(null);
		$export("trace", trace.join(","));
	}
Example 5
public static void main(String[] args) {
		m(union("test"));
		m(union(true)); // wrong
		Union<String, Integer> u1 = union("test");
		Union<String, Integer> u2 = union(false); // wrong
		Union3<String, Integer, Function> u3 = union(false); // wrong
		u1 = union("test");
		u2 = union(false); // wrong
		u3 = union("test");
		u3 = union(new Date()); // wrong
	}