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
package tld.examples; | |
public class Example { | |
protected String mandatory; | |
protected String optional; | |
protected String mandatoryIfOptionalExists; | |
private Example() { | |
} |
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
$ find . | |
. | |
./classes | |
./source | |
./source/local | |
./source/local/User1.java | |
./source/foreign | |
./source/foreign/User2.java | |
$ | |
$ javac -d ./classes source/local/*.java source/foreign/*.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
package tld.examples.builders; | |
public abstract class AbstractEntity { | |
protected String varAbstractEntity; | |
public AbstractEntity() { | |
} | |
public AbstractEntity(final AbstractEntityBuilder abstractEntityBuilder) { |
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
TASK [mysql-ansible-apt-module : Install mysql server - ansible module] ******** | |
fatal: [ansible-apt-module]: FAILED! => {"cache_update_time": 1515198522, "cache_updated": false, "changed": false, "msg": "'/usr/bin/apt-get -y -o \"Dpkg::Options::=--force-confdef\" -o \"Dpkg::Options::=--force-confold\" install 'mysql-server'' failed: No apport report written because the error message indicates its a followup error from a previous failure.\nE: Sub-process /usr/bin/dpkg returned an error code (1)\n", | |
"rc": 100, "stderr": "No apport report written because the error message indicates its a followup error from a previous failure.\nE: Sub-process /usr/bin/dpkg returned an error code (1)\n", | |
"stderr_lines": ["No apport report written because the error message indicates its a followup error from a previous failure.", | |
"E: Sub-process /usr/bin/dpkg returned an error code (1)"], "stdout": "Reading package lists...\nBuilding dependency tree...\nReading state information...\nThe following additional packages will be i |
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
#!/usr/bin/env bash | |
set -e | |
set -o pipefail | |
plugin_repo_url="http://updates.jenkins-ci.org/download/plugins" | |
plugin_dir="/var/lib/jenkins/plugins" | |
include_optionals=false | |
showUsage() { |
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
0x34fc06f5c73f1bad89193796e283ac796ad2928c |
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 class JitExample { | |
public static void main(final String[] args) { | |
new JitExample(); | |
} | |
public JitExample() { | |
final long oneStart = System.nanoTime(); |
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 class Pattern { | |
public static void main(final String[] args) { | |
final StringBuilder sb = new StringBuilder(); | |
for (int i = 1; i <= 7; i++) { | |
System.out.println(String.format("%s %s %s", sb.toString(), i, sb.reverse())); | |
sb.reverse().append(" " + i); | |
} | |
} | |
} |
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 class Student { | |
... | |
} | |
public class FrontEndCode { | |
... | |
public void updateStudentWithNewName(final Id id, final String firstName, final String lastName) { | |
final Student student = bec.getStudent(id); | |
student.setFirstName(firstName); | |
student.setLastName(lastName); |
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
HttpServer server = new GrizzlyHttpServerFactory.createHttpServer(uri, resourceConfig); | |
server.getServerConfiguration() | |
.addHttpHandler(new CLStaticHttpHandler(Application.class.getClassLoader()), "/"); | |
WebappContext webappContext = new WebappContext("grizzly web context", "/"); | |
FilterRegistration filterRegistration = webappContext.addFilter("MyFilter", MyFilter.class); | |
filterRegistration.addMappingForUrlPatterns(EnumSet.of(DispatcherType.REQUEST), "/*"); |