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
# encoding: UTF-8 | |
require 'rubygems' | |
require 'date' | |
require 'optparse' | |
require 'ostruct' | |
require 'oauth' | |
require 'json' | |
class FitbitArchiver |
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
cd ~/the/old/repo | |
find -E . -regex ".*(File1|File2)\.java" | xargs git log --pretty=email --patch-with-stat --reverse | (cd ~/the/new/repo && git am) |
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 ac.simons.utils; | |
/** | |
* Use it like throw Unchecker.uncheck(checkedException); | |
* | |
* @author Michael J. Simons, 2012-02-03 | |
* http://www.gamlor.info/wordpress/2010/02/throwing-checked-excpetions-like-unchecked-exceptions-in-java/ | |
*/ | |
public final class Unchecker { | |
private Unchecker(){} |
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 tests; | |
import java.io.Serializable; | |
import java.util.Calendar; | |
import javax.persistence.Column; | |
import javax.persistence.Entity; | |
import javax.persistence.EntityManager; | |
import javax.persistence.EntityManagerFactory; | |
import javax.persistence.GeneratedValue; |
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 breaks several criteria queries, especially root.subquery() and a join on foobar in the subquery */ | |
@Id | |
@ManyToOne(fetch=FetchType.EAGER, optional=false) | |
@JoinColumn(name="foobar_id") | |
@Fetch(FetchMode.JOIN) | |
Foobar foobar; | |
@Id | |
@Column(name="id") |
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 org.hibernate.bugs; | |
import java.time.LocalDate; | |
import java.time.ZoneId; | |
import java.time.ZonedDateTime; | |
import java.util.List; | |
import javax.persistence.Entity; | |
import javax.persistence.EntityManager; | |
import javax.persistence.EntityManagerFactory; | |
import javax.persistence.GeneratedValue; |
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
NamedNativeQuery( | |
name="Foobar.findByBlahAndBlub" | |
query="Select * from foobar where blah_id = :blah and lower(blub) = :blub" | |
) | |
Optional<Foobar> findByBlahAndBlub(Blah blah, String blub); | |
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
Checking compile classpath | |
Checking runtime classpath | |
Checking test classpath | |
Found duplicate (but equal) classes in [net.minidev:accessors-smart:1.1, org.ow2.asm:asm:5.0.3]: | |
org.objectweb.asm.AnnotationVisitor | |
org.objectweb.asm.AnnotationWriter | |
org.objectweb.asm.Attribute | |
org.objectweb.asm.ByteVector | |
org.objectweb.asm.ClassReader | |
org.objectweb.asm.ClassVisitor |
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
CREATE OR REPLACE TYPE T_SBFA_ASPECT_INSTANCE_FACTORY AS OBJECT ( | |
CONSTRUCTOR FUNCTION T_SBFA_ASPECT_INSTANCE_FACTORY RETURN self AS result, | |
MEMBER PROCEDURE SET_ASPECT_BEAN_NAME(P_ASPECT_BEAN_NAME IN VARCHAR2), | |
MEMBER FUNCTION GETASPECTINSTANCE RETURN OBJECT | |
) | |
/ |
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 patternexamples; | |
import java.util.ArrayList; | |
import java.util.Collections; | |
import java.util.List; | |
import java.util.function.Function; | |
public class Sandwich { | |
private final String bread; |