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
uses gw.api.util.Math | |
var resultTimesVariable = new long[100] | |
var resultTimesConcat = new long[100] | |
for (var count in 0..99) { | |
var startDate = (new Date()).Time | |
for (var i in 0..1000000) { | |
var elem1 = Math.random(10000) | |
var result = "bla ${elem1}" |
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
git log --pretty=fuller |
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
uses gw.lang.reflect.IPropertyInfo | |
var propertyList = entity.Entity.TypeInfo.Properties.toArray() | |
propertyList = propertyList.sort( \ elt1, elt2 -> elt1.toString() < elt2.toString()) | |
propertyList = propertyList.where( \ elt -> elt.toString().matches(".*[a-z]+.*")) | |
propertyList = propertyList.where( \ elt -> not ((elt as IPropertyInfo).Hidden or (elt as IPropertyInfo).Internal)) | |
print("Found entity properties ("+propertyList.Count+"):") | |
for(myProperty in propertyList) { |
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
set ANT_OPTS=-agentlib:jdwp=transport=dt_socket,address=5005,server=y,suspend=y |
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
// ==UserScript== | |
// @name Automatic Login | |
// @namespace browser | |
// @include http://localhost:8080/url* | |
// @version 2 | |
// ==/UserScript== | |
document.getElementById('username').value="login"; | |
document.getElementById('password').value="password"; | |
document.getElementById('loginButton').click(); |
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
uses java.lang.Character | |
uses java.lang.Integer | |
uses java.util.ArrayList | |
class ModuloTenRecursiveProcessor { | |
/** | |
* Validate a number string using Modulo10 rekursiv | |
*/ | |
public static function checkSum(numberString:String):int { |
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
uses java.lang.Integer | |
uses java.util.Arrays | |
uses java.lang.Character | |
uses java.util.ArrayList | |
class ModuloTenProcessor { | |
/** | |
* Validate a number string using Luhn algorithm | |
*/ |
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 de.lray.intercom.pattern; | |
public interface Strategy { | |
void execute(Integer number); | |
Integer[] getResult(); | |
} |
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 de.lray.intercom.highscore; | |
import de.lray.intercom.pattern.Strategy; | |
import org.junit.Before; | |
import org.junit.Test; | |
import java.util.*; | |
import static org.junit.Assert.assertArrayEquals; |
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 de.lray.intercom.highscore; | |
import java.io.FileNotFoundException; | |
import java.io.IOException; | |
/** | |
* Runner class for command line calls. | |
* | |
* Extracts the given parameter, transforms them to the sub components and shows the result. | |
*/ |
NewerOlder