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
apply plugin: 'checkstyle' | |
checkstyleMain { | |
ignoreFailures = false | |
reports { | |
include ( '**/*.java') | |
xml { | |
destination "${rootProject.buildDir}/reports/checkstyle/main.xml" | |
} | |
} |
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 com.app.web; | |
import org.springframework.beans.factory.annotation.Autowired; | |
import org.springframework.context.ApplicationContext; | |
import org.springframework.stereotype.Service; | |
import com.google.web.bindery.requestfactory.server.ServiceLayerDecorator; | |
import com.google.web.bindery.requestfactory.shared.Locator; | |
import com.google.web.bindery.requestfactory.shared.RequestContext; | |
import com.google.web.bindery.requestfactory.shared.ServiceLocator; |
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
Amadahl's Law => Nc * Uc * (1 + W/C) | |
Speed => 1 / (F + (1-F)/N) |
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
file("${theDir}").listFiles().each { | |
println """<suppress checks=".*" files="${it.getName()}"/>""" | |
} |
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
import org.junit.Test | |
public class NamespaceTest { | |
@Test | |
public void testMarkupBuilderUsingNamespace() throws Exception { | |
final investmentNS = 'urn:investment:facility' | |
def path = new XmlSlurper() | |
.parseText(""" |
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
/**Step 2**/ | |
public class DevModeLauncher { | |
public static void main(String[] args) throws Exception { | |
String[] devArg = new String[]{ | |
"-war", | |
"src/main/webapp", | |
"-startupUrl", | |
"ApplicationScaffold.html", | |
"com.mycompany.ApplicationScaffold" |
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
cglib:cglib-nodep:2.1_3 | |
net.sourceforge.cssparser:cssparser:0.9.5 | |
org.freemarker:freemarker:2.3.16 | |
com.google.guava:guava:10.0.1 | |
org.hamcrest:hamcrest-core:1.1 |
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
f=file('ivy-install.xml') | |
[ | |
'compile', | |
'spring' | |
].each {name -> | |
file("gradle/${name}.properties").eachLine {line-> | |
library=line.split(':') | |
def depStr = """ |
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
static { | |
System.setProperty("browser", "chrome"); | |
System.setProperty("webdriver.chrome.driver", "/Google/Chrome/Application/chrome.exe"); | |
} |
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
/** | |
1. extract using | |
mysqldump -udev -p -d --xml movies > movies.xml | |
2. run this | |
*/ | |
class DBRev { | |
private String res = 'movies.xml' | |
private String dir = 'grails-app/domain' |