This is an automated email from the ASF dual-hosted git repository.
egonzalez pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-kie-drools.git
The following commit(s) were added to refs/heads/main by this push:
new 179ada77c1 [incubator-kie-issues-1186] Removing fluent interface from
DROOLS kie api (#5923)
179ada77c1 is described below
commit 179ada77c1866651eb84e5ec6f0ab53127b4e742
Author: Enrique <[email protected]>
AuthorDate: Fri May 10 15:18:50 2024 +0200
[incubator-kie-issues-1186] Removing fluent interface from DROOLS kie api
(#5923)
---
.../java/org/kie/api/fluent/ActionNodeBuilder.java | 24 ------
.../kie/api/fluent/BoundaryEventNodeBuilder.java | 34 ---------
.../org/kie/api/fluent/CompositeNodeBuilder.java | 22 ------
.../kie/api/fluent/CompositeNodeOperations.java | 27 -------
.../src/main/java/org/kie/api/fluent/Dialect.java | 30 --------
.../org/kie/api/fluent/DynamicNodeBuilder.java | 24 ------
.../java/org/kie/api/fluent/EndNodeBuilder.java | 26 -------
.../java/org/kie/api/fluent/EventNodeBuilder.java | 23 ------
.../org/kie/api/fluent/EventNodeOperations.java | 32 --------
.../java/org/kie/api/fluent/FaultNodeBuilder.java | 26 -------
.../org/kie/api/fluent/ForEachNodeBuilder.java | 27 -------
.../org/kie/api/fluent/HumanNodeOperations.java | 27 -------
.../org/kie/api/fluent/HumanTaskNodeBuilder.java | 44 -----------
.../java/org/kie/api/fluent/JoinNodeBuilder.java | 26 -------
.../org/kie/api/fluent/MilestoneNodeBuilder.java | 25 ------
.../main/java/org/kie/api/fluent/NodeBuilder.java | 38 ----------
.../org/kie/api/fluent/NodeContainerBuilder.java | 72 ------------------
.../java/org/kie/api/fluent/ProcessBuilder.java | 54 -------------
.../kie/api/fluent/ProcessBuilderFactories.java | 49 ------------
.../org/kie/api/fluent/ProcessBuilderFactory.java | 43 -----------
.../org/kie/api/fluent/RuleSetNodeBuilder.java | 24 ------
.../java/org/kie/api/fluent/SplitNodeBuilder.java | 27 -------
.../java/org/kie/api/fluent/StartNodeBuilder.java | 23 ------
.../org/kie/api/fluent/SubProcessNodeBuilder.java | 33 --------
.../java/org/kie/api/fluent/TimerNodeBuilder.java | 26 -------
.../java/org/kie/api/fluent/TimerOperations.java | 24 ------
.../src/main/java/org/kie/api/fluent/Variable.java | 88 ----------------------
.../org/kie/api/fluent/WorkItemNodeBuilder.java | 34 ---------
.../main/java/org/kie/api/fluent/package-info.java | 82 --------------------
29 files changed, 1034 deletions(-)
diff --git a/kie-api/src/main/java/org/kie/api/fluent/ActionNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/ActionNodeBuilder.java
deleted file mode 100644
index f233f1fe51..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/ActionNodeBuilder.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface ActionNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<ActionNodeBuilder<T>, T> {
-
- ActionNodeBuilder<T> action(Dialect dialect, String code);
-}
diff --git
a/kie-api/src/main/java/org/kie/api/fluent/BoundaryEventNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/BoundaryEventNodeBuilder.java
deleted file mode 100644
index 3ff3f2fbbb..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/BoundaryEventNodeBuilder.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface BoundaryEventNodeBuilder<T extends NodeContainerBuilder<T,
?>> extends EventNodeOperations<BoundaryEventNodeBuilder<T>, T>,
NodeBuilder<BoundaryEventNodeBuilder<T>, T> {
-
- BoundaryEventNodeBuilder<T> attachedTo(long attachedToId);
-
- BoundaryEventNodeBuilder<T> eventType(String prefix, String Suffix);
-
- BoundaryEventNodeBuilder<T> timeCycle(String timeCycle);
-
- BoundaryEventNodeBuilder<T> timeCycle(String timeCycle, Dialect dialect);
-
- BoundaryEventNodeBuilder<T> timeDuration(String timeDuration);
-
- BoundaryEventNodeBuilder<T> cancelActivity(boolean cancelActivity);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeBuilder.java
deleted file mode 100644
index 71ac1db37d..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeBuilder.java
+++ /dev/null
@@ -1,22 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface CompositeNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeContainerBuilder<CompositeNodeBuilder<T>, T>,
CompositeNodeOperations<CompositeNodeBuilder<T>, T> {
-}
diff --git
a/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeOperations.java
b/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeOperations.java
deleted file mode 100644
index 5894c323e5..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/CompositeNodeOperations.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-
-public interface CompositeNodeOperations<T extends NodeContainerBuilder<T, P>,
P extends NodeContainerBuilder<P, ?>> {
-
- T linkIncomingConnections(long nodeId);
-
- T linkOutgoingConnections(long nodeId);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/Dialect.java
b/kie-api/src/main/java/org/kie/api/fluent/Dialect.java
deleted file mode 100644
index 558c66f187..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/Dialect.java
+++ /dev/null
@@ -1,30 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-/**
- * Supported programming languages for action scripts
- */
-public enum Dialect {
- JAVA,
- JAVASCRIPT,
- XPATH,
- MVEL,
- FEEL
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/DynamicNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/DynamicNodeBuilder.java
deleted file mode 100644
index 1e9716e6d1..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/DynamicNodeBuilder.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface DynamicNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeContainerBuilder<DynamicNodeBuilder<T>, T>,
CompositeNodeOperations<DynamicNodeBuilder<T>, T> {
-
- DynamicNodeBuilder<T> autoComplete(boolean autoComplete);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/EndNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/EndNodeBuilder.java
deleted file mode 100644
index 58be4cc469..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/EndNodeBuilder.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-
-public interface EndNodeBuilder<T extends NodeContainerBuilder<T, ?>> extends
NodeBuilder<EndNodeBuilder<T>, T> {
-
- EndNodeBuilder<T> terminate(boolean terminate);
-
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/EventNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/EventNodeBuilder.java
deleted file mode 100644
index c98ac354ab..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/EventNodeBuilder.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface EventNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<EventNodeBuilder<T>, T>,
EventNodeOperations<EventNodeBuilder<T>, T> {
-}
-
diff --git a/kie-api/src/main/java/org/kie/api/fluent/EventNodeOperations.java
b/kie-api/src/main/java/org/kie/api/fluent/EventNodeOperations.java
deleted file mode 100644
index 2b074816ce..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/EventNodeOperations.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-import java.util.function.UnaryOperator;
-
-interface EventNodeOperations<T extends NodeBuilder<T, P>, P extends
NodeContainerBuilder<P, ?>> {
-
- T eventType(String eventType);
-
- T eventTransformer(UnaryOperator<Object> function);
-
- T scope(String scope);
-
- T variableName(String name);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/FaultNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/FaultNodeBuilder.java
deleted file mode 100644
index 0f3c6e316e..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/FaultNodeBuilder.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface FaultNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<FaultNodeBuilder<T>, T> {
-
- FaultNodeBuilder<T> setFaultVariable(String faultVariable);
-
- FaultNodeBuilder<T> setFaultName(String faultName);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/ForEachNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/ForEachNodeBuilder.java
deleted file mode 100644
index e934b49cd0..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/ForEachNodeBuilder.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-
-public interface ForEachNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeContainerBuilder<ForEachNodeBuilder<T>, T>,
CompositeNodeOperations<ForEachNodeBuilder<T>, T> {
-
- ForEachNodeBuilder<T> collectionExpression(String collectionExpression);
-
- ForEachNodeBuilder<T> waitForCompletion(boolean waitForCompletion);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/HumanNodeOperations.java
b/kie-api/src/main/java/org/kie/api/fluent/HumanNodeOperations.java
deleted file mode 100644
index 5f6acfa237..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/HumanNodeOperations.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-
-interface HumanNodeOperations<T extends NodeBuilder<T, P>, P extends
NodeContainerBuilder<P, ?>> extends TimerOperations<T, P> {
-
- T onEntryAction(Dialect dialect, String action);
-
- T onExitAction(Dialect dialect, String action);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/HumanTaskNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/HumanTaskNodeBuilder.java
deleted file mode 100644
index f8c932807b..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/HumanTaskNodeBuilder.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface HumanTaskNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<HumanTaskNodeBuilder<T>, T>,
HumanNodeOperations<HumanTaskNodeBuilder<T>, T> {
-
- HumanTaskNodeBuilder<T> taskName(String taskName);
-
- HumanTaskNodeBuilder<T> actorId(String actorId);
-
- HumanTaskNodeBuilder<T> priority(String priority);
-
- HumanTaskNodeBuilder<T> comment(String comment);
-
- HumanTaskNodeBuilder<T> skippable(boolean skippable);
-
- HumanTaskNodeBuilder<T> content(String content);
-
- HumanTaskNodeBuilder<T> inMapping(String parameterName, String
variableName);
-
- HumanTaskNodeBuilder<T> outMapping(String parameterName, String
variableName);
-
- HumanTaskNodeBuilder<T> waitForCompletion(boolean waitForCompletion);
-
- HumanTaskNodeBuilder<T> swimlane(String swimlane);
-
- HumanTaskNodeBuilder<T> workParameter(String name, Object value);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/JoinNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/JoinNodeBuilder.java
deleted file mode 100644
index 4e5162bbc6..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/JoinNodeBuilder.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface JoinNodeBuilder<T extends NodeContainerBuilder<T, ?>> extends
NodeBuilder<JoinNodeBuilder<T>, T> {
-
- JoinNodeBuilder<T> type(int type);
-
- JoinNodeBuilder<T> type(String type);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/MilestoneNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/MilestoneNodeBuilder.java
deleted file mode 100644
index 0b93a4b4e7..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/MilestoneNodeBuilder.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface MilestoneNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<MilestoneNodeBuilder<T>, T>,
HumanNodeOperations<MilestoneNodeBuilder<T>, T> {
-
- MilestoneNodeBuilder<T> constraint(String constraint);
-}
-
diff --git a/kie-api/src/main/java/org/kie/api/fluent/NodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/NodeBuilder.java
deleted file mode 100644
index 79c04ab833..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/NodeBuilder.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-/**
- * Contains common operations for all nodes, basically naming, metadata and
definition completion.
- *
- * @param <T> concrete node instance
- * @param <P> container parent node
- */
-public interface NodeBuilder<T extends NodeBuilder<T, P>, P extends
NodeContainerBuilder<P, ?>> {
-
- /**
- * Method to notify that definition of this node is done
- * @return container parent node
- */
- P done();
-
- T name(String name);
-
- T setMetadata(String key, Object value);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/NodeContainerBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/NodeContainerBuilder.java
deleted file mode 100644
index 6ae96ca34a..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/NodeContainerBuilder.java
+++ /dev/null
@@ -1,72 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-/**
- * Include operations to define a container node.<br>
- * As it name indicates, a container node contains nodes (a process is also a
container node), so this class defines all methods to create children nodes.<br>
- * A container node also holds variables, exception handlers and establish
connections between nodes.
- * @param <T> Concrete container node
- * @param <P> Parent container node
- */
-public interface NodeContainerBuilder<T extends NodeContainerBuilder<T, P>, P
extends NodeContainerBuilder<P, ?>> extends NodeBuilder<T, P> {
-
- StartNodeBuilder<T> startNode(long id);
-
- EndNodeBuilder<T> endNode(long id);
-
- ActionNodeBuilder<T> actionNode(long id);
-
- MilestoneNodeBuilder<T> milestoneNode(long id);
-
- TimerNodeBuilder<T> timerNode(long id);
-
- HumanTaskNodeBuilder<T> humanTaskNode(long id);
-
- SubProcessNodeBuilder<T> subProcessNode(long id);
-
- SplitNodeBuilder<T> splitNode(long id);
-
- JoinNodeBuilder<T> joinNode(long id);
-
- RuleSetNodeBuilder<T> ruleSetNode(long id);
-
- FaultNodeBuilder<T> faultNode(long id);
-
- EventNodeBuilder<T> eventNode(long id);
-
- BoundaryEventNodeBuilder<T> boundaryEventNode(long id);
-
- CompositeNodeBuilder<T> compositeNode(long id);
-
- ForEachNodeBuilder<T> forEachNode(long id);
-
- DynamicNodeBuilder<T> dynamicNode(long id);
-
- WorkItemNodeBuilder<T> workItemNode(long id);
-
- T exceptionHandler(Class<? extends Throwable> exceptionClass, Dialect
dialect, String code);
-
- T connection(long fromId, long toId);
-
- /**
- * Adds a variable to this container
- */
- <V> T variable(Variable<V> variable);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilder.java
deleted file mode 100644
index bee76f715f..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilder.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-import java.util.Collection;
-import java.util.Map;
-
-import org.kie.api.definition.process.Process;
-
-/**
- * Builder that contains methods to create a process definition.
- * @see ProcessBuilderFactory
- */
-public interface ProcessBuilder extends NodeContainerBuilder<ProcessBuilder,
ProcessBuilder> {
-
- ProcessBuilder dynamic(boolean dynamic);
-
- ProcessBuilder version(String version);
-
- ProcessBuilder packageName(String packageName);
-
- ProcessBuilder imports(Collection<String> imports);
-
- ProcessBuilder functionImports(Collection<String> functionImports);
-
- ProcessBuilder globals(Map<String, String> globals);
-
- ProcessBuilder global(String name, String type);
-
- ProcessBuilder swimlane(String name);
-
- /**
- * Validates and returns process definition.<br>
- * Should be invoked after all other method calls.
- * @return validated process definition
- */
- Process build();
-}
diff --git
a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactories.java
b/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactories.java
deleted file mode 100644
index 21b744befd..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactories.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-import org.slf4j.LoggerFactory;
-
-/**
- * Holds an utility method to retrieve <code>ProcessBuilderFactory</code>
default instance.<br>
- * Default instance returned by <code>get</code> method can be modified by
setting property "org.jbpm.processBuilder.factoryClass"<br>
- * Value should be full class name of a <code>ProcessBuilderFactory</code>
implementation that contains a default public constructor
- */
-public class ProcessBuilderFactories {
-
- private ProcessBuilderFactories() {}
-
- private static ProcessBuilderFactory instance;
-
- public static synchronized ProcessBuilderFactory get() {
- if (instance == null) {
- try {
- instance =
-
Class.forName(System.getProperty("org.jbpm.processBuilder.factoryClass",
-
"org.jbpm.ruleflow.core.RuleFlowProcessFactoryBuilder"))
- .asSubclass(ProcessBuilderFactory.class)
- .newInstance();
- } catch (ReflectiveOperationException e) {
-
LoggerFactory.getLogger(ProcessBuilderFactories.class).error("Unable to
instance ProcessBuilderFactory", e);
- throw new IllegalStateException(e);
- }
- }
- return instance;
- }
-}
diff --git
a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactory.java
b/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactory.java
deleted file mode 100644
index f43fa4cd67..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/ProcessBuilderFactory.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-import org.kie.api.definition.process.Process;
-
-/**
- * Factory to create process builder instance.<br>
- * It is also a convenient place holder for additional utility methods
- */
-public interface ProcessBuilderFactory {
-
- /**
- * Returns a <code>ProcessBuilder</code> that can be used to create a
process definition
- * @param processId the unique id of the process being defined
- * @return builder instance to create process definition
- */
- ProcessBuilder processBuilder(String processId);
-
- /**
- * Converts process definition into an array of bytes.<br>
- * Typically this array will be converted to a Resource for a KIE base
- * @param builder process definition to be converted to byte[]
- * @return byte[] containing process definition
- */
- byte[] toBytes(Process builder);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/RuleSetNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/RuleSetNodeBuilder.java
deleted file mode 100644
index ce54d461dc..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/RuleSetNodeBuilder.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface RuleSetNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<RuleSetNodeBuilder<T>, T>,
TimerOperations<RuleSetNodeBuilder<T>, T> {
-
- RuleSetNodeBuilder<T> ruleFlowGroup(String ruleFlowGroup);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/SplitNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/SplitNodeBuilder.java
deleted file mode 100644
index 0b75e496eb..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/SplitNodeBuilder.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface SplitNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<SplitNodeBuilder<T>, T> {
-
- SplitNodeBuilder<T> type(int type);
-
- SplitNodeBuilder<T> constraint(long toNodeId, String name, String type,
Dialect dialect, String constraint, int priority);
-
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/StartNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/StartNodeBuilder.java
deleted file mode 100644
index a4c629516f..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/StartNodeBuilder.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface StartNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<StartNodeBuilder<T>, T> {
- // TODO event triggers?
-}
diff --git
a/kie-api/src/main/java/org/kie/api/fluent/SubProcessNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/SubProcessNodeBuilder.java
deleted file mode 100644
index 3311e709b3..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/SubProcessNodeBuilder.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface SubProcessNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<SubProcessNodeBuilder<T>, T>,
HumanNodeOperations<SubProcessNodeBuilder<T>, T> {
-
- SubProcessNodeBuilder<T> processId(final String processId);
-
- SubProcessNodeBuilder<T> waitForCompletion(boolean waitForCompletion);
-
- SubProcessNodeBuilder<T> inMapping(String parameterName, String
variableName);
-
- SubProcessNodeBuilder<T> outMapping(String parameterName, String
variableName);
-
- SubProcessNodeBuilder<T> independent(boolean independent);
-
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/TimerNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/TimerNodeBuilder.java
deleted file mode 100644
index 9999c288df..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/TimerNodeBuilder.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface TimerNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<TimerNodeBuilder<T>, T> {
-
- TimerNodeBuilder<T> delay(String delay);
-
- TimerNodeBuilder<T> period(String period);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/TimerOperations.java
b/kie-api/src/main/java/org/kie/api/fluent/TimerOperations.java
deleted file mode 100644
index 5711e62e9b..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/TimerOperations.java
+++ /dev/null
@@ -1,24 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-interface TimerOperations<T extends NodeBuilder<T, P>, P extends
NodeContainerBuilder<P, ?>> {
-
- T timer(String delay, String period, Dialect dialect, String action);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/Variable.java
b/kie-api/src/main/java/org/kie/api/fluent/Variable.java
deleted file mode 100644
index 9f489a248b..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/Variable.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-import java.util.HashMap;
-import java.util.Map;
-
-/**
- * Builder pattern like class used to build a variable.<br>
- * A variable requires a name and a data type.<br>
- * Value and metadata are optional.<br>
- * Usage:
- * <pre>
- * Variable.var("test",String.class)
- * .value("example value")
- * .metadata("readOnly",true).
- * .metadata("required",false)
- * </pre>
- *
- * @param <T> data type of the variable
- * @see NodeContainerBuilder#variable(Variable)
- */
-public class Variable<T> {
-
- private String name;
- private T value;
- private Class<T> type;
- private Map<String, Object> metadata;
-
- private Variable(String name, Class<T> type) {
- this.name = name;
- this.type = type;
- }
-
- public static <T> Variable<T> var(String name, Class<T> type) {
- return new Variable<>(name, type);
- }
-
- public Variable<T> value(T value) {
- this.value = value;
- return this;
- }
-
- public Variable<T> metadata(String key, Object value) {
- if (metadata == null) {
- metadata = new HashMap<>();
- }
- metadata.put(key, value);
- return this;
- }
-
- public String getName() {
- return name;
- }
-
- public T getValue() {
- return value;
- }
-
- public Class<T> getType() {
- return type;
- }
-
- public Map<String, Object> getMetadata() {
- return metadata;
- }
-
- @Override
- public String toString() {
- return "Variable [name=" + name + ", value=" + value + ", type=" +
type + ", metadata=" + metadata + "]";
- }
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/WorkItemNodeBuilder.java
b/kie-api/src/main/java/org/kie/api/fluent/WorkItemNodeBuilder.java
deleted file mode 100644
index c3e92ff5a8..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/WorkItemNodeBuilder.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.kie.api.fluent;
-
-public interface WorkItemNodeBuilder<T extends NodeContainerBuilder<T, ?>>
extends NodeBuilder<WorkItemNodeBuilder<T>, T>,
HumanNodeOperations<WorkItemNodeBuilder<T>, T> {
-
- WorkItemNodeBuilder<T> waitForCompletion(boolean waitForCompletion);
-
- WorkItemNodeBuilder<T> inMapping(String parameterName, String
variableName);
-
- WorkItemNodeBuilder<T> outMapping(String parameterName, String
variableName);
-
- WorkItemNodeBuilder<T> workName(String name);
-
- WorkItemNodeBuilder<T> workParameter(String name, Object value);
-
- WorkItemNodeBuilder<T> workParameterDefinition(String name, Class<?> type);
-}
diff --git a/kie-api/src/main/java/org/kie/api/fluent/package-info.java
b/kie-api/src/main/java/org/kie/api/fluent/package-info.java
deleted file mode 100644
index bd3d74200d..0000000000
--- a/kie-api/src/main/java/org/kie/api/fluent/package-info.java
+++ /dev/null
@@ -1,82 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-/**
- * Process Fluent API allows programmer to build an in memory representation
of a bpmn file.<br>
- * This information can later be used to build a KIE resource and execute the
process .
- * Typical use of fluent API will be:
- * <li> Build a process definition that prints action string in console using
<code>ProcessBuilder</code> several methods</li>
- * <pre>
- // Obtain default ProcessBuilderFactory
- ProcessBuilderFactory factory = ProcessBuilderFactories.get();
- ProcessBuilderFactory factory = ProcessBuilderFactories.get();
- Process process =
- // Create process builder
- factory.processBuilder(processId)
- // package and name
- .packageName("org.jbpm")
- .name("My process")
- // start node
- .startNode(1).name("Start").done()
- // Add variable of type string
- .variable(var("pepe", String.class))
- // Add exception handler
- .exceptionHandler(IllegalArgumentException.class,
Dialect.JAVA, "System.out.println(\"Exception\");")
- // script node in Java language that prints "action"
- .actionNode(2).name("Action")
- .action(Dialect.JAVA,
- "System.out.println(\"Action\");").done()
- // end node
- .endNode(3).name("End").done()
- // connections
- .connection(1,
- 2)
- .connection(2,
- 3)
- .build();
- </pre>
- * <li> Create a resource from the process definition (process needs to be
converted to byte[] using <code>ProcessBuilderFactory</code>)</li>
- * <pre>
- // Build resource from ProcessBuilder
- KieResources resources =
ServiceRegistry.getInstance().get(KieResources.class);
- Resource res = resources
- .newByteArrayResource(factory.toBytes(process))
- .setSourcePath("/tmp/processFactory.bpmn2");
// source path or target path must be set to be added into kbase
- </pre>
- * <li> Build kie base from this resource using KIE API</li>
- * <pre>
- KieServices ks = KieServices.Factory.get();
- KieRepository kr = ks.getRepository();
- KieFileSystem kfs = ks.newKieFileSystem();
- kfs.write(res);
- KieBuilder kb = ks.newKieBuilder(kfs);
- kb.buildAll(); // kieModule is automatically deployed to KieRepository
if successfully built.
- KieContainer kContainer = ks.newKieContainer(kr.getDefaultReleaseId());
- KieBase kbase = kContainer.getKieBase();
- </pre>
- * <li> Create kie session using this kie base and execute the process</li>
- * <pre>
- // Create kie session
- KieSessionConfiguration conf = ...;
- Environment env = ....;
- KieSession ksession = kbase.newKieSession(conf,env);
- // execute process using same process id that was used to obtain
<code>ProcessBuilder</code> instance
- ksession.startProcess(processId);
- *</pre>
- */
-package org.kie.api.fluent;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]