-
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.
- Loading branch information
1 parent
2f1e825
commit 6ffbe40
Showing
4 changed files
with
98 additions
and
8 deletions.
There are no files selected for viewing
22 changes: 22 additions & 0 deletions
22
java/core/src/main/java/kr/jclab/sipc/exception/SipcProcessDeadException.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,22 @@ | ||
package kr.jclab.sipc.exception; | ||
|
||
public class SipcProcessDeadException extends SipcHandshakeException { | ||
public SipcProcessDeadException() { | ||
} | ||
|
||
public SipcProcessDeadException(String message) { | ||
super(message); | ||
} | ||
|
||
public SipcProcessDeadException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
public SipcProcessDeadException(Throwable cause) { | ||
super(cause); | ||
} | ||
|
||
public SipcProcessDeadException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) { | ||
super(message, cause, enableSuppression, writableStackTrace); | ||
} | ||
} |
15 changes: 15 additions & 0 deletions
15
java/core/src/main/java/kr/jclab/sipc/internal/Process9Helper.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,15 @@ | ||
package kr.jclab.sipc.internal; | ||
|
||
import javax.annotation.Nullable; | ||
import java.lang.reflect.Method; | ||
import java.util.concurrent.CompletableFuture; | ||
|
||
public class Process9Helper { | ||
public static @Nullable CompletableFuture<Process> onExitIfAvailable(Process process) { | ||
try { | ||
Method method = Process.class.getMethod("onExit"); | ||
return (CompletableFuture<Process>) method.invoke(process); | ||
} catch (Exception e) {} | ||
return null; | ||
} | ||
} |
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