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
public interface UICommand | |
{ | |
public UICommandID getId(); | |
public void initializeUI(UIContext context) throws Exception; | |
public void validate(UIValidationContext context); | |
public Result execute(UIContext context) throws Exception; | |
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
import java.util.jar.*; | |
import java.util.zip.*; | |
import java.io.*; | |
import java.util.*; | |
public class JarReader { | |
public static void main(String args[]) { | |
try { | |
String jarName = "specj.ear"; | |
FileInputStream fin = new FileInputStream(jarName); |
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
@InjectCommand | |
AeshCommand command | |
public interface Command { | |
void execute() throws IOException; | |
} | |
vs | |
public interface Command { |
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
#!/bin/bash | |
bla | |
bla | |
bla | |
./jboss-cli.sh -c <<EOF | |
bob | |
admin123$ | |
batch | |
/system-property=bar:add(value=foo) | |
run-batch |
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
# Set default values for all following accounts. | |
defaults | |
#tls on | |
#tls_trust_file /etc/ssl/certs/ca-certificates.crt | |
logfile ~/.msmtp.log | |
# redhat | |
account redhat | |
host smtp.corp.redhat.com | |
from spederse@redhat.com |
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
[general] | |
accounts = work | |
maxsyncaccounts = 1 | |
maxconnections = 1 | |
ui = Noninteractive.Basic | |
#ui = Noninteractive.quiet | |
# -------------------- Work details. -------------------- | |
[Account work] | |
localrepository = work-Local |
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
public interface HibernateValueMapper { | |
void $hibernate_setValue(Object value, String fieldName); | |
} | |
bytecode impl in entities: | |
... | |
public void $hibernate_setValue(Object value, String fieldName) { | |
if(fieldName == "name") | |
name = (String) value; | |
else if(fieldName == "address"; |
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
$ cat aeshtest.sh | |
#!/bin/bash | |
java -cp . AeshExample <<EOFDEL | |
login | |
admin | |
admin!234 | |
ls | |
exit |
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
import org.jboss.aesh.cl.Arguments; | |
import org.jboss.aesh.cl.CommandDefinition; | |
import org.jboss.aesh.console.AeshConsole; | |
import org.jboss.aesh.console.AeshConsoleBuilder; | |
import org.jboss.aesh.console.Prompt; | |
import org.jboss.aesh.console.command.Command; | |
import org.jboss.aesh.console.command.CommandResult; | |
import org.jboss.aesh.console.command.invocation.CommandInvocation; | |
import org.jboss.aesh.console.command.registry.AeshCommandRegistryBuilder; | |
import org.jboss.aesh.console.command.registry.CommandRegistry; |
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
import org.jboss.aesh.console.AeshConsoleCallback; | |
import org.jboss.aesh.console.Console; | |
import org.jboss.aesh.console.ConsoleCallback; | |
import org.jboss.aesh.console.ConsoleOperation; | |
import org.jboss.aesh.console.Prompt; | |
import org.jboss.aesh.console.settings.SettingsBuilder; | |
public class ConsoleExample { | |
public static void main(String... args) { |
OlderNewer