-
Notifications
You must be signed in to change notification settings - Fork 382
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
* #5586 Added support for wildcard in classpath. * #5477 Print message after succesfully added classpath by magic command. * #5477 Inform only if we added new classpath. * #5477 %classpath message are print right now on stdout. * #5477: print * 5477: print * #5477 Fixed case where we got multiple magic commands and single code.
- Loading branch information
1 parent
e686363
commit 9d7150b
Showing
12 changed files
with
186 additions
and
100 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -72,4 +72,4 @@ static Path createJupyterTempFolder() { | |
void resetEnvironment(); | ||
|
||
void removeImport(ImportPath anImport); | ||
} | ||
} |
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
44 changes: 44 additions & 0 deletions
44
...ain/java/com/twosigma/beakerx/kernel/commands/item/MagicCommandItemWithResultAndCode.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,44 @@ | ||
package com.twosigma.beakerx.kernel.commands.item; | ||
|
||
import com.twosigma.beakerx.kernel.CodeWithoutCommand; | ||
import com.twosigma.beakerx.message.Message; | ||
import java.util.Optional; | ||
|
||
public class MagicCommandItemWithResultAndCode implements MagicCommandItem { | ||
|
||
private Message resultMessage; | ||
private Message replyMessage; | ||
private CodeWithoutCommand code; | ||
|
||
public MagicCommandItemWithResultAndCode(Message resultMessage, | ||
Message replyMessage, CodeWithoutCommand code) { | ||
this.resultMessage = resultMessage; | ||
this.replyMessage = replyMessage; | ||
this.code = code; | ||
} | ||
|
||
@Override | ||
public boolean hasCodeToExecute() { | ||
return getCode().isPresent(); | ||
} | ||
|
||
@Override | ||
public boolean hasResult() { | ||
return getResult().isPresent(); | ||
} | ||
|
||
@Override | ||
public Optional<Message> getResult() { | ||
return Optional.ofNullable(resultMessage); | ||
} | ||
|
||
@Override | ||
public Optional<Message> getReply() { | ||
return Optional.ofNullable(replyMessage); | ||
} | ||
|
||
@Override | ||
public Optional<CodeWithoutCommand> getCode() { | ||
return Optional.ofNullable(code); | ||
} | ||
} |
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.