Skip to content

Instantly share code, notes, and snippets.

@jcfandino
jcfandino / RxJavaTest.java
Last active August 29, 2015 14:05
RxJava batches, window vs. buffer
import static org.junit.Assert.assertTrue;
import java.util.List;
import java.util.concurrent.CountDownLatch;
import java.util.concurrent.TimeUnit;
import org.junit.Before;
import org.junit.Test;
import rx.Observable;
@jcfandino
jcfandino / markdown.xml
Created September 26, 2014 15:48
markdown.xml
<?xml version="1.0" encoding="UTF-8"?>
<Module>
<ModulePrefs title="markdown" />
<Content type="html"><![CDATA[
<script src="http://strapdownjs.com/v/0.2/strapdown.js"></script>
]]></Content>
</Module>
/*
* Copyright (c) 2009-2012 jMonkeyEngine
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions are
* met:
*
* * Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
#!/bin/bash
emojis=(:bowtie: :smile: :smile: :laughing: :laughing:
:blush: :blush: :smiley: :smiley: :relaxed: :relaxed:
:smirk: :smirk: :heart_eyes: :heart_eyes: :kissing_heart: :kissing_heart:
:kissing_closed_eyes: :kissing_closed_eyes: :flushed: :flushed: :relieved: :relieved:
:laughing: :satisfied: :grin: :grin: :wink: :wink:
:stuck_out_tongue_winking_eye: :stuck_out_tongue_winking_eye: :stuck_out_tongue_closed_eyes: :stuck_out_tongue_closed_eyes: :grinning: :grinning:
:kissing: :kissing: :kissing_smiling_eyes: :kissing_smiling_eyes: :stuck_out_tongue: :stuck_out_tongue:
:sleeping: :sleeping: :worried: :worried: :frowning: :frowning:
@jcfandino
jcfandino / EclipseNPE.log
Created April 11, 2018 14:17
Rename refactor throws this exception
!ENTRY org.eclipse.ltk.ui.refactoring 4 10000 2018-04-11 16:10:49.643
!MESSAGE Internal Error
!STACK 0
java.lang.reflect.InvocationTargetException
at org.eclipse.jface.operation.ModalContext.run(ModalContext.java:398)
at org.eclipse.ltk.internal.ui.refactoring.RefactoringWizardDialog2.run(RefactoringWizardDialog2.java:321)
at org.eclipse.ltk.ui.refactoring.RefactoringWizard.internalPerformFinish(RefactoringWizard.java:636)
at org.eclipse.ltk.ui.refactoring.UserInputWizardPage.performFinish(UserInputWizardPage.java:145)
at org.eclipse.jdt.internal.ui.refactoring.reorg.RenameTypeWizardInputPage.performFinish(RenameTypeWizardInputPage.java:150)
at org.eclipse.ltk.ui.refactoring.RefactoringWizard.performFinish(RefactoringWizard.java:710)
@jcfandino
jcfandino / TestH2GisApplication.java
Last active May 24, 2019 20:54
H2Gis in cluster mode
package com.github.jcfandino;
import org.h2.tools.CreateCluster;
import org.h2.tools.Server;
import org.h2gis.functions.factory.H2GISFunctions;
import java.nio.file.Files;
import java.nio.file.Path;
import java.sql.DriverManager;
@jcfandino
jcfandino / TestTexturePickApp.java
Created January 6, 2022 17:18
Picking texture pixel with a ray cast
package com.example;
import com.jme3.app.SimpleApplication;
import com.jme3.asset.plugins.ClasspathLocator;
import com.jme3.collision.CollisionResult;
import com.jme3.collision.CollisionResults;
import com.jme3.font.BitmapText;
import com.jme3.light.AmbientLight;
import com.jme3.material.Material;
import com.jme3.math.ColorRGBA;
import com.jme3.app.SimpleApplication;
import com.jme3.material.Material;
import com.jme3.math.Vector2f;
import com.jme3.math.Vector3f;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Geometry;
import com.jme3.scene.Mesh;
import com.jme3.scene.VertexBuffer.Type;
import com.jme3.scene.control.AbstractControl;