Skip to content

Instantly share code, notes, and snippets.

/* extracted from https://www.bottlecaps.de/rr/ui on Wed Oct 20, 2021, 23:49 (UTC+01)
*/
DRLJ ::= Rule*
Rule
::= SimpleRule | WithParamsAndCustomisedTypeRule | CustomReturnTypeRule | NoReturnTypeRule
/**
String a = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
"@JsType\n" +
"public class A {\n",
" public String getMessage() {\n",
" return \"Hello from Java!\";\n",
" }\n",
"}");
String b = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
<properties>
<!-- Plugin dependencies versions-->
<maven.version>3.3.9</maven.version>
<maven.resolver.version>1.3.1</maven.resolver.version>
<maven.enforcer.plugin.version>1.4.1</maven.enforcer.plugin.version>
<maven.source.plugin.version>3.0.1</maven.source.plugin.version>
<maven.javadoc.plugin.version>3.0.1</maven.javadoc.plugin.version>
<maven.gpg.plugin.version>1.6</maven.gpg.plugin.version>
<!-- Builder dependencies versions -->
package net.cardosi.mojo;
import java.io.File;
import java.lang.reflect.Method;
import java.nio.file.Files;
import java.util.Arrays;
import java.util.List;
import java.util.Map;
import org.apache.maven.DefaultMaven;
A.build.map
- sources
A
A.java
/private/var/tmp/_bazel_mdproctor/94fe6331e7827fec37a32e75ce5a85ba/execroot/com_google_j2cl/_tmp/cb3001ce7e843c32a8bd751b1c8155d6/transpile_tester94239387860308966/input/A.java
A.native.js
- interfaces
I1.java
- dependencies
test/A.java
test.A
/var/folders/0b/54kqd29n7lq70q_9c9tyl2h40000gn/T/tester442413923107770649/input/test/A.java
/var/folders/0b/54kqd29n7lq70q_9c9tyl2h40000gn/T/tester442413923107770649/input/test/A.native_js
- extend/impl
- deps
- src
test/B.java
test.B
@Test
public void testABC() throws IOException {
String a = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
"public class A {",
" public A a = new A();",
" public void foo() {}",
" @JsMethod\n",
" public static native String goodbyeWorld();",
"}");
String a = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
"public class A {",
" public void foo() {}",
"}");
String b = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
"public class B extends A{",
"}");
String c = code("import jsinterop.annotations.JsType;import jsinterop.annotations.JsMethod;import jsinterop.annotations.JsProperty;",
package org.drools.compiler.simulation;
import org.drools.compiler.Message;
import org.drools.core.command.RequestContextImpl;
import org.drools.core.fluent.impl.FluentBuilderImpl;
import org.drools.core.fluent.impl.PsuedoClockRunner;
import org.kie.internal.fluent.runtime.FluentBuilder;
import org.junit.Test;
import org.kie.api.KieServices;
import org.kie.api.builder.KieModule;
@mdproctor
mdproctor / gist:7853901
Last active December 30, 2015 16:19
simple DRL DSL
package org.drools.java8;
import java.util.List;
import java.util.ArrayList;
import java.util.function.Predicate;
public class Java8Example {
Rule rule1 = new Rule()
.setWhen((CTuple1<Person>) (Person person) -> person.getAge() >= 18,