This file contains hidden or 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 org.skife.jdbi.v2.docs; | |
import org.skife.jdbi.v2.SQLStatement; | |
import org.skife.jdbi.v2.sqlobject.Binder; | |
import org.skife.jdbi.v2.sqlobject.BinderFactory; | |
import org.skife.jdbi.v2.sqlobject.BindingAnnotation; | |
import org.skife.jdbi.v2.sqlobject.SqlStatementCustomizer; | |
import org.skife.jdbi.v2.sqlobject.SqlStatementCustomizerFactory; | |
import org.skife.jdbi.v2.sqlobject.SqlStatementCustomizingAnnotation; |
This file contains hidden or 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
<?xml version="1.0" encoding="UTF-8"?> | |
<scheme name="T2" version="1" parent_scheme="Default"> | |
<option name="LINE_SPACING" value="1.2" /> | |
<option name="EDITOR_FONT_SIZE" value="14" /> | |
<option name="EDITOR_FONT_NAME" value="Menlo" /> | |
<colors> | |
<option name="ANNOTATIONS_COLOR" value="3e83e7" /> | |
<option name="CARET_COLOR" value="ffff99" /> | |
<option name="CARET_ROW_COLOR" value="" /> | |
<option name="CONSOLE_BACKGROUND_KEY" value="1a1a1a" /> |
This file contains hidden or 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 com.ning.atlas.aws; | |
import com.amazonaws.auth.BasicAWSCredentials; | |
import com.amazonaws.services.elasticloadbalancing.AmazonElasticLoadBalancingClient; | |
import com.amazonaws.services.elasticloadbalancing.model.Instance; | |
import com.amazonaws.services.elasticloadbalancing.model.RegisterInstancesWithLoadBalancerRequest; | |
import com.ning.atlas.Installer; | |
import com.ning.atlas.Server; | |
import org.slf4j.Logger; | |
import org.slf4j.LoggerFactory; |
This file contains hidden or 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
require 'prettyprint' # for the p function | |
module Enumerable | |
alias :fold :inject | |
end | |
root = [["root", [ | |
["child", [ | |
["grandkid", []], | |
["grandkid2", []]]], |
This file contains hidden or 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 TheBasics | |
{ | |
@SqlUpdate("insert into something (id, name) values (:id, :name)") | |
int insert(@BindBean Something something); | |
@SqlQuery("select id, name from something where id = :id") | |
Something findById(@Bind("id") long id); | |
} |
This file contains hidden or 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 ruby | |
t = <<-EOT | |
#!/usr/bin/env ruby | |
if 1+1 == 2 | |
puts "hello world" | |
end | |
EOT | |
# what one liner replaces '.gsub /^\s*/, "' to make this output "win" | |
s = <<-EOB.gsub /^\s*/, "" |
This file contains hidden or 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 org.skife.jdbi.v2.unstable.eod; | |
import junit.framework.TestCase; | |
import org.h2.jdbcx.JdbcDataSource; | |
import org.skife.jdbi.v2.DBI; | |
import org.skife.jdbi.v2.Handle; | |
import org.skife.jdbi.v2.Something; | |
import java.io.Closeable; | |
import java.util.List; |
This file contains hidden or 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
require 'org-ruby' | |
module Jekyll | |
class OrgModeConverter < Converter | |
safe true | |
priority :low | |
def matches(ext) | |
ext =~ /org/i |
This file contains hidden or 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 org.skife.sand; | |
import java.lang.reflect.InvocationTargetException; | |
import java.lang.reflect.Method; | |
import java.lang.reflect.Modifier; | |
import java.util.Comparator; | |
import java.util.Map; | |
import java.util.SortedMap; | |
import java.util.TreeMap; | |
import java.util.concurrent.Semaphore; |
This file contains hidden or 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 com.ning.http.client.fancy; | |
import com.ning.http.client.AsyncHandler; | |
import com.ning.http.client.AsyncHttpClient; | |
import com.ning.http.client.HttpResponseBodyPart; | |
import com.ning.http.client.HttpResponseHeaders; | |
import com.ning.http.client.HttpResponseStatus; | |
import com.ning.http.client.Response; | |
import org.apache.log4j.BasicConfigurator; | |
import org.mortbay.jetty.Connector; |