forked from apache/incubator-kie-kogito-runtimes
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[incubator-kie-issues-1110] Add capability to store that node instance (
apache#3488) * [incubator-kie-issues-1110] Add capability to store that node instance
- Loading branch information
1 parent
0a93241
commit 23b1355
Showing
45 changed files
with
2,187 additions
and
815 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
45 changes: 45 additions & 0 deletions
45
...-serialization-protobuf/src/main/java/org/jbpm/flow/serialization/NodeInstanceReader.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
/* | ||
* 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.jbpm.flow.serialization; | ||
|
||
import org.kie.api.runtime.process.NodeInstance; | ||
|
||
import com.google.protobuf.Any; | ||
import com.google.protobuf.GeneratedMessageV3; | ||
|
||
public interface NodeInstanceReader extends Comparable<NodeInstanceReader> { | ||
Integer DEFAULT_ORDER = 10; | ||
|
||
default Integer order() { | ||
return DEFAULT_ORDER; | ||
} | ||
|
||
@Override | ||
default int compareTo(NodeInstanceReader that) { | ||
return this.order().compareTo(that.order()); | ||
} | ||
|
||
Class<? extends GeneratedMessageV3> type(); | ||
|
||
default boolean accept(Any value) { | ||
return value.is(type()); | ||
} | ||
|
||
NodeInstance read(MarshallerReaderContext context, Any value); | ||
} |
41 changes: 41 additions & 0 deletions
41
...-serialization-protobuf/src/main/java/org/jbpm/flow/serialization/NodeInstanceWriter.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
* 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.jbpm.flow.serialization; | ||
|
||
import org.kie.api.runtime.process.NodeInstance; | ||
|
||
import com.google.protobuf.GeneratedMessageV3; | ||
|
||
public interface NodeInstanceWriter extends Comparable<NodeInstanceWriter> { | ||
Integer DEFAULT_ORDER = 10; | ||
|
||
default Integer order() { | ||
return DEFAULT_ORDER; | ||
} | ||
|
||
@Override | ||
default int compareTo(NodeInstanceWriter that) { | ||
return this.order().compareTo(that.order()); | ||
} | ||
|
||
boolean accept(NodeInstance value); | ||
|
||
GeneratedMessageV3.Builder<?> write(MarshallerWriterContext writer, NodeInstance value); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.