Datasets:

diff
stringlengths
262
553k
is_single_chunk
bool
2 classes
is_single_function
bool
1 class
buggy_function
stringlengths
20
391k
fixed_function
stringlengths
0
392k
diff --git a/src/com/jjw/addressbook/pojo/Person.java b/src/com/jjw/addressbook/pojo/Person.java index 79813a8..3666a46 100644 --- a/src/com/jjw/addressbook/pojo/Person.java +++ b/src/com/jjw/addressbook/pojo/Person.java @@ -1,123 +1,122 @@ package com.jjw.addressbook.pojo; public class Person { private Strin...
true
true
public Person(String name, String address, String city, String state, String phoneNumber) { super(); myName = name; myAddress = address; myCity = city; myState = state; myPhoneNumber = phoneNumber; }
public Person(String name, String address, String city, String state, String phoneNumber) { myName = name; myAddress = address; myCity = city; myState = state; myPhoneNumber = phoneNumber; }
diff --git a/src/org/openstreetmap/josm/actions/SaveAction.java b/src/org/openstreetmap/josm/actions/SaveAction.java index 76668ec5..d0a4a0b9 100644 --- a/src/org/openstreetmap/josm/actions/SaveAction.java +++ b/src/org/openstreetmap/josm/actions/SaveAction.java @@ -1,41 +1,43 @@ // License: GPL. Copyright 2007 by Imm...
true
true
@Override public File getFile(Layer layer) { File f = layer.getAssociatedFile(); if(f != null && layer instanceof GpxLayer && f.exists() && 1 != new ExtendedDialog(Main.parent, tr("Overwrite"), tr("File {0} exists. Overwrite?", f.getName()), new String[] {tr("Overwrite"), tr(...
@Override public File getFile(Layer layer) { File f = layer.getAssociatedFile(); if(f != null && ! f.exists()) f=null; if(f != null && layer instanceof GpxLayer && 1 != new ExtendedDialog(Main.parent, tr("Overwrite"), tr("File {0} exists. Overwrite?", f.getName())...
diff --git a/ecologylab/net/ParsedURL.java b/ecologylab/net/ParsedURL.java index 0ec7cf1e..e7407b01 100644 --- a/ecologylab/net/ParsedURL.java +++ b/ecologylab/net/ParsedURL.java @@ -1,1427 +1,1428 @@ package ecologylab.net; import java.io.File; import java.io.FileInputStream; import java.io.FileNotFoundException...
true
true
public static ParsedURL createFromHTML(ParsedURL contextPURL, String addressString, boolean fromSearchPage) { if ((addressString == null) || (addressString.length() == 0)) return null; if( addressString.startsWith("#") ) { //return get(contextPURL.url(), addressStr...
public static ParsedURL createFromHTML(ParsedURL contextPURL, String addressString, boolean fromSearchPage) { if ((addressString == null) || (addressString.length() == 0)) return null; if( addressString.startsWith("#") ) { //return get(contextPURL.url(), addressStr...
diff --git a/src/com/stefankopieczek/audinance/conversion/multiplexers/SimpleMultiplexer.java b/src/com/stefankopieczek/audinance/conversion/multiplexers/SimpleMultiplexer.java index 5063825..637999e 100644 --- a/src/com/stefankopieczek/audinance/conversion/multiplexers/SimpleMultiplexer.java +++ b/src/com/stefankopiec...
true
true
public DecodedAudio toNChannels(DecodedAudio result, Integer targetNumChannels) { DecodedSource[] oldChannels = result.getChannels(); DecodedSource[] newChannels = new DecodedSource[targetNumChannels]; if (targetNumChannels > oldChannels.length) { // More channels have ...
public DecodedAudio toNChannels(DecodedAudio result, Integer targetNumChannels) { DecodedSource[] oldChannels = result.getChannels(); DecodedSource[] newChannels = new DecodedSource[targetNumChannels.intValue()]; if (targetNumChannels > oldChannels.length)...
diff --git a/DVST/src/com/dhbw/dvst/helper/SpielerListeArrayAdapter.java b/DVST/src/com/dhbw/dvst/helper/SpielerListeArrayAdapter.java index 1b67ad4..1dd6661 100644 --- a/DVST/src/com/dhbw/dvst/helper/SpielerListeArrayAdapter.java +++ b/DVST/src/com/dhbw/dvst/helper/SpielerListeArrayAdapter.java @@ -1,136 +1,136 @@ pa...
true
true
protected void setLoeschenListener(Button btn_loeschen) { btn_loeschen.setOnClickListener(new View.OnClickListener() { @Override public void onClick(final View v) { OnClickListener spielerLoeschen = new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int ...
protected void setLoeschenListener(Button btn_loeschen) { btn_loeschen.setOnClickListener(new View.OnClickListener() { @Override public void onClick(final View v) { OnClickListener spielerLoeschen = new DialogInterface.OnClickListener() { @Override public void onClick(DialogInterface dialog, int ...
diff --git a/sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/core/session/SipSessionImpl.java b/sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/core/session/SipSessionImpl.java index 3a747995a..83702f55b 100644 --- a/sip-servlets-impl/src/main/java/org/mobicents/servlet/sip/core/session/SipSessionIm...
false
true
public SipServletRequest createRequest(final String method) { if(method.equalsIgnoreCase(Request.ACK) || method.equalsIgnoreCase(Request.PRACK) || method.equalsIgnoreCase(Request.CANCEL)) { throw new IllegalArgumentException( "Can not create ACK, PRACK or CANCEL requests with this method"); } if(!isV...
public SipServletRequest createRequest(final String method) { if(method.equalsIgnoreCase(Request.ACK) || method.equalsIgnoreCase(Request.PRACK) || method.equalsIgnoreCase(Request.CANCEL)) { throw new IllegalArgumentException( "Can not create ACK, PRACK or CANCEL requests with this method"); } if(!isV...
diff --git a/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java b/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java index 625792607..06034a534 100644 --- a/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java +++ b/src/main/org/jboss/jms/server/remoting/JMSWireFormat.java @@ -1,358 +1,358 @@ /* ...
true
true
public void write(Object obj, OutputStream out) throws IOException { if (trace) { log.trace("Writing " + obj); } DataOutputStream dos; if (out instanceof DataOutputStream) { //For non HTTP transports - we should ALWAYS be passed a DataOutputStream ...
public void write(Object obj, OutputStream out) throws IOException { if (trace) { log.trace("Writing " + obj); } DataOutputStream dos; if (out instanceof DataOutputStream) { //For non HTTP transports - we should ALWAYS be passed a DataOutputStream ...
diff --git a/org.nelfin.othello/test/iago/SmartPlayerTestAbstract.java b/org.nelfin.othello/test/iago/SmartPlayerTestAbstract.java index ead7fe3..7e1690a 100644 --- a/org.nelfin.othello/test/iago/SmartPlayerTestAbstract.java +++ b/org.nelfin.othello/test/iago/SmartPlayerTestAbstract.java @@ -1,33 +1,39 @@ package iago...
false
true
public void testPerfectPlay() { Board small4x4Board = new Board(DebugFunctions.make4x4OthelloString()); Boolean blacksTurn = true; Move nextMove = new Move(0,0); while(!nextMove.equals(new Move(-1,-1))) { if(blacksTurn) { nextMove = smartBlackPlayer.chooseMove(small4x4Board); }else{ nextMo...
public void testPerfectPlay() { Board small4x4Board = new Board(DebugFunctions.make4x4OthelloString()); Boolean blacksTurn = true; Move nextMove = new Move(0,0); int consecutivePasses = 0; while(consecutivePasses < 2) { if(blacksTurn) { nextMove = smartBlackPlayer.chooseMove(small4x4Board); ...
diff --git a/trunk/src/om/stdcomponent/RadioBoxComponent.java b/trunk/src/om/stdcomponent/RadioBoxComponent.java index 149ce69..e3170b9 100644 --- a/trunk/src/om/stdcomponent/RadioBoxComponent.java +++ b/trunk/src/om/stdcomponent/RadioBoxComponent.java @@ -1,248 +1,248 @@ /* OpenMark online assessment system Copyr...
true
true
protected void produceVisibleOutput(QContent qc,boolean bInit,boolean bPlain) throws OmException { Element eOuterBox=qc.createElement("div"); qc.addInlineXHTML(eOuterBox); if(!bPlain) { eOuterBox.setAttribute("class","radiobox"); eOuterBox.setAttribute("id",QDocument.ID_PREFIX+getID()); eOuterBox.se...
protected void produceVisibleOutput(QContent qc,boolean bInit,boolean bPlain) throws OmException { Element eOuterBox=qc.createElement("div"); qc.addInlineXHTML(eOuterBox); if(!bPlain) { eOuterBox.setAttribute("class","radiobox"); eOuterBox.setAttribute("id",QDocument.ID_PREFIX+getID()); eOuterBox.se...
diff --git a/src/main/java/ru/mystamps/web/validation/jsr303/NotEmptyFileValidator.java b/src/main/java/ru/mystamps/web/validation/jsr303/NotEmptyFileValidator.java index 1bcc1856..66643189 100644 --- a/src/main/java/ru/mystamps/web/validation/jsr303/NotEmptyFileValidator.java +++ b/src/main/java/ru/mystamps/web/valida...
true
true
public boolean isValid(MultipartFile file, ConstraintValidatorContext ctx) { if (file == null) { return true; } if (file.getSize() == 0) { // NOPMD return false; } return true; }
public boolean isValid(MultipartFile file, ConstraintValidatorContext ctx) { if (file == null) { return true; } if (file.isEmpty()) { return false; } return true; }
diff --git a/libraries/javalib/java/io/RandomAccessFile.java b/libraries/javalib/java/io/RandomAccessFile.java index 135b82a95..a3dd096ea 100644 --- a/libraries/javalib/java/io/RandomAccessFile.java +++ b/libraries/javalib/java/io/RandomAccessFile.java @@ -1,265 +1,265 @@ /* * Java core library component. * * Co...
true
true
final public String readLine() throws IOException { final StringBuffer buffer = new StringBuffer(); int nread = 0; while (true) { final int data = read(); final char ch = (char) (data & 0xff); if (data == -1) break; nread++; if (ch == '\n') break; if (ch == '\r') { // Check for '\r\n' fi...
final public String readLine() throws IOException { final StringBuffer buffer = new StringBuffer(); int nread = 0; while (true) { final int data = read(); final char ch = (char) (data & 0xff); if (data == -1) break; nread++; if (ch == '\n') break; if (ch == '\r') { // Check for '\r\n' fi...
diff --git a/geogebra/geogebra/kernel/arithmetic/ExpressionNode.java b/geogebra/geogebra/kernel/arithmetic/ExpressionNode.java index c08b17793..36021f832 100644 --- a/geogebra/geogebra/kernel/arithmetic/ExpressionNode.java +++ b/geogebra/geogebra/kernel/arithmetic/ExpressionNode.java @@ -1,2465 +1,2465 @@ /* GeoGebr...
false
true
final private String operationToString(String leftStr, String rightStr, boolean valueForm) { ExpressionValue leftEval; StringBuilder sb = new StringBuilder(); int STRING_TYPE = kernel.getCASPrintForm(); switch (operation) { case NOT: switch (...
final private String operationToString(String leftStr, String rightStr, boolean valueForm) { ExpressionValue leftEval; StringBuilder sb = new StringBuilder(); int STRING_TYPE = kernel.getCASPrintForm(); switch (operation) { case NOT: switch (...
diff --git a/bundles/org.eclipse.wst.xml.xpath2.processor/src/org/eclipse/wst/xml/xpath2/processor/internal/types/ElementType.java b/bundles/org.eclipse.wst.xml.xpath2.processor/src/org/eclipse/wst/xml/xpath2/processor/internal/types/ElementType.java index f4aa1ed..9a48c6f 100644 --- a/bundles/org.eclipse.wst.xml.xpath...
true
true
public ResultSequence typed_value() { ResultSequence rs = ResultSequenceFactory.create_new(); PSVIElementNSImpl psviElem = (PSVIElementNSImpl)_value; XSTypeDefinition typeDef = psviElem.getTypeDefinition(); if (typeDef != null && typeDef.getNamespace().equals(XSCtrLibrary.XML_SCHEMA_NS)) { Object sc...
public ResultSequence typed_value() { ResultSequence rs = ResultSequenceFactory.create_new(); PSVIElementNSImpl psviElem = (PSVIElementNSImpl)_value; XSTypeDefinition typeDef = psviElem.getTypeDefinition(); if (XSCtrLibrary.XML_SCHEMA_NS.equals(typeDef.getNamespace())) { Object schemaTypeValue = get...
diff --git a/openejb/examples/webservice-attachments/src/test/java/org/superbiz/attachment/AttachmentTest.java b/openejb/examples/webservice-attachments/src/test/java/org/superbiz/attachment/AttachmentTest.java index 96c654637..b9cf8f13e 100644 --- a/openejb/examples/webservice-attachments/src/test/java/org/superbiz/at...
true
true
public void testAttachmentViaWsInterface() throws Exception { Service service = Service.create( new URL("http://127.0.0.1:4204/webservice-attachements/AttachmentImpl?wsdl"), new QName("http://superbiz.org/wsdl", "AttachmentWsService")); assertNotNull(service); ...
public void testAttachmentViaWsInterface() throws Exception { Service service = Service.create( new URL("http://127.0.0.1:4204/webservice-attachments/AttachmentImpl?wsdl"), new QName("http://superbiz.org/wsdl", "AttachmentWsService")); assertNotNull(service); ...
diff --git a/pmd/regress/test/net/sourceforge/pmd/rules/basic/BasicRulesTest.java b/pmd/regress/test/net/sourceforge/pmd/rules/basic/BasicRulesTest.java index bbf3d89b3..01e62f99a 100644 --- a/pmd/regress/test/net/sourceforge/pmd/rules/basic/BasicRulesTest.java +++ b/pmd/regress/test/net/sourceforge/pmd/rules/basic/Bas...
true
true
public void setUp() { addRule("basic", "AvoidDecimalLiteralsInBigDecimalConstructor"); addRule("basic", "AvoidMultipleUnaryOperators"); addRule("basic", "AvoidThreadGroup"); addRule("basic", "AvoidUsingHardCodedIP"); // addRule("basic", "AvoidUsingHardCodedURL"); addRule(...
public void setUp() { addRule("basic", "AvoidDecimalLiteralsInBigDecimalConstructor"); addRule("basic", "AvoidMultipleUnaryOperators"); addRule("basic", "AvoidThreadGroup"); addRule("basic", "AvoidUsingHardCodedIP"); // addRule("basic", "AvoidUsingHardCodedURL"); addRule(...
diff --git a/src/org/python/core/PyModule.java b/src/org/python/core/PyModule.java index 5ccef86c..643f3087 100644 --- a/src/org/python/core/PyModule.java +++ b/src/org/python/core/PyModule.java @@ -1,182 +1,185 @@ // Copyright (c) Corporation for National Research Initiatives package org.python.core; import org.p...
true
true
protected PyObject impAttr(String name) { PyObject path = __dict__.__finditem__("__path__"); PyObject pyName = __dict__.__finditem__("__name__"); if (path == null || pyName == null) { return null; } PyObject attr = null; String fullName = (pyName.__str__(...
protected PyObject impAttr(String name) { if (__dict__ == null) { return null; } PyObject path = __dict__.__finditem__("__path__"); PyObject pyName = __dict__.__finditem__("__name__"); if (path == null || pyName == null) { return null; } ...
diff --git a/src/examples/com/basho/riakcs/client/UserOperations.java b/src/examples/com/basho/riakcs/client/UserOperations.java index 357e549..8eb6371 100644 --- a/src/examples/com/basho/riakcs/client/UserOperations.java +++ b/src/examples/com/basho/riakcs/client/UserOperations.java @@ -1,46 +1,46 @@ /* * This file...
true
true
public static void runIt(boolean enableDebugOutput) throws Exception { CSCredentials csCredentials= new CSCredentials(CSCredentials.class.getResourceAsStream("CSCredentials.Riak.properties")); RiakCSClient csClient= new RiakCSClient(csCredentials.getCSAccessKey(), csCredentials.getsCSSecretKey(), csCredential...
public static void runIt(boolean enableDebugOutput) throws Exception { CSCredentials csCredentials= new CSCredentials(CSCredentials.class.getResourceAsStream("CSCredentials.Riak.properties")); RiakCSClient csClient= new RiakCSClient(csCredentials.getCSAccessKey(), csCredentials.getsCSSecretKey(), csCredential...
diff --git a/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java b/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyAction.java index 557a8a991..f8cd91fb0 100644 --- a/continuum-webapp/src/main/java/org/apache/maven/continuum/web/action/WorkingCopyA...
true
true
public String execute() throws ContinuumException { try { checkViewProjectGroupAuthorization( getProjectGroupName() ); } catch ( AuthorizationRequiredException e ) { return REQUIRES_AUTHORIZATION; } List<File> files = getCo...
public String execute() throws ContinuumException { try { checkViewProjectGroupAuthorization( getProjectGroupName() ); } catch ( AuthorizationRequiredException e ) { return REQUIRES_AUTHORIZATION; } List<File> files = getCo...
diff --git a/ide/eclipse/esb/org.wso2.developerstudio.eclipse.esb/src/org/wso2/developerstudio/eclipse/esb/mediators/impl/AggregateMediatorImpl.java b/ide/eclipse/esb/org.wso2.developerstudio.eclipse.esb/src/org/wso2/developerstudio/eclipse/esb/mediators/impl/AggregateMediatorImpl.java index 544de480f..e082fa7cf 100644...
true
true
public Element doSave(Element parent) throws Exception { Element self = createChildElement(parent, "aggregate"); String correlationValue; Element completionElem; switch (getCurrentEsbVersion()){ case ESB301: // Correlation expression. If the expression is empty, don't put the tag correlationValue = getC...
public Element doSave(Element parent) throws Exception { Element self = createChildElement(parent, "aggregate"); String correlationValue; Element completionElem; switch (getCurrentEsbVersion()){ case ESB301: // Correlation expression. If the expression is empty, don't put the tag correlationValue = getC...
diff --git a/src/main/java/de/prob/animator/CommandProcessor.java b/src/main/java/de/prob/animator/CommandProcessor.java index c487195..ce35355 100644 --- a/src/main/java/de/prob/animator/CommandProcessor.java +++ b/src/main/java/de/prob/animator/CommandProcessor.java @@ -1,57 +1,58 @@ package de.prob.animator; imp...
true
true
public ISimplifiedROMap<String, PrologTerm> sendCommand( final ICommand command) throws ProBException { PrologTermStringOutput pto = new PrologTermStringOutput(); command.writeCommand(pto); pto.printAtom("true"); final String query = pto.fullstop().toString(); String result = cli.send(query); Map<Str...
public ISimplifiedROMap<String, PrologTerm> sendCommand( final ICommand command) throws ProBException { PrologTermStringOutput pto = new PrologTermStringOutput(); command.writeCommand(pto); pto.printAtom("true"); final String query = pto.fullstop().toString(); String result = cli.send(query); Map<Str...
diff --git a/src/com/android/launcher3/LauncherModel.java b/src/com/android/launcher3/LauncherModel.java index 041882fd9..11aeb20b0 100644 --- a/src/com/android/launcher3/LauncherModel.java +++ b/src/com/android/launcher3/LauncherModel.java @@ -1,2861 +1,2861 @@ /* * Copyright (C) 2008 The Android Open Source Projec...
false
true
static boolean shortcutExists(Context context, String title, Intent intent) { final ContentResolver cr = context.getContentResolver(); Cursor c = cr.query(LauncherSettings.Favorites.CONTENT_URI, new String[] { "title", "intent" }, "title=? and intent=?", new String[] { title,...
static boolean shortcutExists(Context context, String title, Intent intent) { final ContentResolver cr = context.getContentResolver(); Cursor c = cr.query(LauncherSettings.Favorites.CONTENT_URI, new String[] { "title", "intent" }, "title=? and intent=?", new String[] { title,...
diff --git a/src/MainForm.java b/src/MainForm.java index e1fed0e..ab8b927 100644 --- a/src/MainForm.java +++ b/src/MainForm.java @@ -1,489 +1,490 @@ import javax.swing.*; import javax.swing.event.ChangeEvent; import javax.swing.event.ChangeListener; import javax.swing.event.ListSelectionEvent; import javax.swing.e...
true
true
public MainForm() { // Worker worker1 = new Worker("Рогов П.А.", 0.0); workers.add(worker1); Worker worker2 = new Worker("Золотов А.В.", 0.0); workers.add(worker2); workers.add(new Worker("Полулях А.В.", 0.0)); workers.add(new Worker("Горелов А.Г.", 0.0)); ...
public MainForm() { // Worker worker1 = new Worker("Рогов П.А.", 0.0); workers.add(worker1); Worker worker2 = new Worker("Золотов А.В.", 0.0); workers.add(worker2); workers.add(new Worker("Полулях А.В.", 0.0)); workers.add(new Worker("Горелов А.Г.", 0.0)); ...
diff --git a/src/nz/gen/wellington/guardian/android/activities/ui/ArticleImageDecorator.java b/src/nz/gen/wellington/guardian/android/activities/ui/ArticleImageDecorator.java index 3e7e2fe..744fb17 100644 --- a/src/nz/gen/wellington/guardian/android/activities/ui/ArticleImageDecorator.java +++ b/src/nz/gen/wellington/g...
true
true
private static ImageDecoratedArticle applyThumbnailIfAvailableLocally(ImageDAO imageDAO, Article article) { Bitmap image = null; if (article.getThumbnailUrl() != null && imageDAO.isAvailableLocally(article.getThumbnailUrl())) { image = imageDAO.getImage(article.getThumbnailUrl()); } else if (article.getMain...
private static ImageDecoratedArticle applyThumbnailIfAvailableLocally(ImageDAO imageDAO, Article article) { Bitmap image = null; if (article.getThumbnailUrl() != null && imageDAO.isAvailableLocally(article.getThumbnailUrl())) { image = imageDAO.getImage(article.getThumbnailUrl()); } else if (article.getMain...
diff --git a/src/ltguide/base/configuration/Configuration.java b/src/ltguide/base/configuration/Configuration.java index a14664b..45b3461 100644 --- a/src/ltguide/base/configuration/Configuration.java +++ b/src/ltguide/base/configuration/Configuration.java @@ -1,146 +1,149 @@ package ltguide.base.configuration; imp...
true
true
protected void load() { boolean loaded = false; try { load(file); loaded = true; } catch (final FileNotFoundException e) {} catch (final IOException e) { plugin.logException(e, "cannot load " + file); } catch (final InvalidConfigurationException e) { if (e.getCause() instanceof YAMLException)...
protected void load() { boolean loaded = false; try { load(file); loaded = true; } catch (final FileNotFoundException e) {} catch (final IOException e) { plugin.logException(e, "cannot load " + file); } catch (final InvalidConfigurationException e) { if (e.getCause() instanceof YAMLException)...
diff --git a/src/CollisionManager.java b/src/CollisionManager.java index b1fcd3f..e433111 100644 --- a/src/CollisionManager.java +++ b/src/CollisionManager.java @@ -1,37 +1,37 @@ import java.util.ArrayList; public class CollisionManager { public static boolean checkAndHandleCollisions(Bird bird, ArrayList<Ent...
true
true
public static boolean checkAndHandleCollisions(Bird bird, ArrayList<Entity> entities, Health birdHealth) { Boolean exit = false; for (Entity entity : entities) { if(entity.colidable) { //Bird poops on shit if(entity.boundingShape.intersects(bird.getCrap().getBoundingShape()) && bird.getCrap().isAc...
public static boolean checkAndHandleCollisions(Bird bird, ArrayList<Entity> entities, Health birdHealth) { Boolean exit = false; for (Entity entity : entities) { if(entity.colidable) { //Bird poops on shit if(entity.boundingShape.intersects(bird.getCrap().getBoundingShape()) && bird.getCrap().isAc...
diff --git a/event-bus-toposervice/src/main/java/pegasus/eventbus/topology/service/Activator.java b/event-bus-toposervice/src/main/java/pegasus/eventbus/topology/service/Activator.java index 6735a4e..ba16d11 100755 --- a/event-bus-toposervice/src/main/java/pegasus/eventbus/topology/service/Activator.java +++ b/event-bu...
true
true
public void start(BundleContext bundleContext) throws Exception { LOG.info("OSGi Starting: {}", TopologyService.class.getName()); ServiceReference eventManagerServiceReference = bundleContext.getServiceReference(EventManager.class.getName()); if (eventManagerServiceReference != null) { ...
public void start(BundleContext bundleContext) throws Exception { LOG.info("OSGi Starting: {}", TopologyService.class.getName()); ServiceReference eventManagerServiceReference = bundleContext.getServiceReference(EventManager.class.getName()); if (eventManagerServiceReference != null) { ...
diff --git a/src/org/openstreetmap/josm/gui/MainApplication.java b/src/org/openstreetmap/josm/gui/MainApplication.java index cd37b8ba..fdb79fac 100644 --- a/src/org/openstreetmap/josm/gui/MainApplication.java +++ b/src/org/openstreetmap/josm/gui/MainApplication.java @@ -1,226 +1,227 @@ // License: GPL. Copyright 2007 ...
true
true
public static void main(final String[] argArray) { ///////////////////////////////////////////////////////////////////////// // TO ALL TRANSLATORS ///////////////////////////////////////////////////////////////////////// // Do not translate the early strings be...
public static void main(final String[] argArray) { ///////////////////////////////////////////////////////////////////////// // TO ALL TRANSLATORS ///////////////////////////////////////////////////////////////////////// // Do not translate the early strings be...
diff --git a/libcore/tools/runner/java/dalvik/runner/Dx.java b/libcore/tools/runner/java/dalvik/runner/Dx.java index 83f126552..d36a99d28 100644 --- a/libcore/tools/runner/java/dalvik/runner/Dx.java +++ b/libcore/tools/runner/java/dalvik/runner/Dx.java @@ -1,32 +1,37 @@ /* * Copyright (C) 2009 The Android Open Sourc...
false
true
public void dex(String output, Classpath classpath) { new Command.Builder() .args("dx") .args("--dex") .args("--output=" + output) .args(Strings.objectsToStrings(classpath.getElements())) .execute(); }
public void dex(String output, Classpath classpath) { // We pass --core-library so that we can write tests in the same package they're testing, // even when that's a core library package. If you're actually just using this tool to // execute arbitrary code, this has the unfortunate side-effe...
diff --git a/src/main/groovy/ui/text/GroovyFilter.java b/src/main/groovy/ui/text/GroovyFilter.java index d7db17f6d..94b74cd0b 100644 --- a/src/main/groovy/ui/text/GroovyFilter.java +++ b/src/main/groovy/ui/text/GroovyFilter.java @@ -1,263 +1,259 @@ /* * GroovyFilter.java * * Copyright (c) 2004, 2007 Evan A Slati...
true
true
private void init() { StyleContext styleContext = StyleContext.getDefaultStyleContext(); Style defaultStyle = styleContext.getStyle(StyleContext.DEFAULT_STYLE); StyleConstants.setFontFamily(defaultStyle, StructuredSyntaxResources.EDITOR_FONT.getFamily()); ...
private void init() { StyleContext styleContext = StyleContext.getDefaultStyleContext(); Style defaultStyle = styleContext.getStyle(StyleContext.DEFAULT_STYLE); Style comment = styleContext.addStyle(COMMENT, defaultStyle); StyleConstants.setForeground(comment, COMMENT_COLOR)...
diff --git a/src/main/java/org/primefaces/mobile/renderkit/DataListRenderer.java b/src/main/java/org/primefaces/mobile/renderkit/DataListRenderer.java index a28ec6f..7b8e453 100644 --- a/src/main/java/org/primefaces/mobile/renderkit/DataListRenderer.java +++ b/src/main/java/org/primefaces/mobile/renderkit/DataListRende...
false
true
protected void encodeMarkup(FacesContext context, DataList dataList) throws IOException { if(dataList.isLazy()) { dataList.loadLazyData(); } ResponseWriter writer = context.getResponseWriter(); UIComponent header = dataList.getHeader(); UI...
protected void encodeMarkup(FacesContext context, DataList dataList) throws IOException { if(dataList.isLazy()) { dataList.loadLazyData(); } ResponseWriter writer = context.getResponseWriter(); UIComponent header = dataList.getHeader(); UI...
diff --git a/src/play/modules/jpagen/Generator.java b/src/play/modules/jpagen/Generator.java index da006e4..6b35d07 100644 --- a/src/play/modules/jpagen/Generator.java +++ b/src/play/modules/jpagen/Generator.java @@ -1,308 +1,308 @@ package play.modules.jpagen; import java.io.File; import java.sql.Connection; imp...
true
true
public static void main(String[] args) throws Exception { // Load all forbidden keywords init(); try { // init Play Framework File root = new File(System.getProperty("application.path")); Play.init(root, System.getProperty("play.id", "")); Thread.currentThread().setContextClassLoader(Play.classload...
public static void main(String[] args) throws Exception { // Load all forbidden keywords init(); try { // init Play Framework File root = new File(System.getProperty("application.path")); Play.init(root, System.getProperty("play.id", "")); Thread.currentThread().setContextClassLoader(Play.classload...
diff --git a/liquibase-core/src/main/java/liquibase/sqlgenerator/core/SetTableRemarksGenerator.java b/liquibase-core/src/main/java/liquibase/sqlgenerator/core/SetTableRemarksGenerator.java index 7f70fcce..53586795 100644 --- a/liquibase-core/src/main/java/liquibase/sqlgenerator/core/SetTableRemarksGenerator.java +++ b/...
false
true
public Sql[] generateSql(SetTableRemarksStatement statement, Database database, SqlGeneratorChain sqlGeneratorChain) { String sql; if (database instanceof OracleDatabase) { sql = "COMMENT ON TABLE "+database.escapeTableName(statement.getSchemaName(), statement.getTableName())+" IS '"+sta...
public Sql[] generateSql(SetTableRemarksStatement statement, Database database, SqlGeneratorChain sqlGeneratorChain) { String sql; String remarks = database.escapeStringForDatabase(statement.getRemarks()); if (database instanceof OracleDatabase) { sql = "COMMENT ON TABLE "+databa...
diff --git a/src/java/davmail/imap/ImapConnection.java b/src/java/davmail/imap/ImapConnection.java index 5c62a50..e677c31 100644 --- a/src/java/davmail/imap/ImapConnection.java +++ b/src/java/davmail/imap/ImapConnection.java @@ -1,1711 +1,1711 @@ /* * DavMail POP/IMAP/SMTP/CalDav/LDAP Exchange Gateway * Copyright ...
false
true
public void run() { final String capabilities; int imapIdleDelay = Settings.getIntProperty("davmail.imapIdleDelay") * 60; if (imapIdleDelay > 0) { capabilities = "CAPABILITY IMAP4REV1 AUTH=LOGIN IDLE"; } else { capabilities = "CAPABILITY IMAP4REV1 AUTH=LOGIN";...
public void run() { final String capabilities; int imapIdleDelay = Settings.getIntProperty("davmail.imapIdleDelay") * 60; if (imapIdleDelay > 0) { capabilities = "CAPABILITY IMAP4REV1 AUTH=LOGIN IDLE"; } else { capabilities = "CAPABILITY IMAP4REV1 AUTH=LOGIN";...
diff --git a/finance/swing/src/main/java/com/lavida/swing/service/ArticlesTableModel.java b/finance/swing/src/main/java/com/lavida/swing/service/ArticlesTableModel.java index 97b9c77..42c3ee4 100644 --- a/finance/swing/src/main/java/com/lavida/swing/service/ArticlesTableModel.java +++ b/finance/swing/src/main/java/com/...
true
true
public void setValueAt(Object aValue, int rowIndex, int columnIndex) { ArticleJdo articleJdo = getArticleJdoByRowIndex(rowIndex); String value = (String) aValue; SimpleDateFormat calendarFormatter = new SimpleDateFormat("dd.MM.yyyy"); calendarFormatter.setLenient(false); try ...
public void setValueAt(Object aValue, int rowIndex, int columnIndex) { ArticleJdo articleJdo = getArticleJdoByRowIndex(rowIndex); String value = (String) aValue; SimpleDateFormat calendarFormatter = new SimpleDateFormat("dd.MM.yyyy"); calendarFormatter.setLenient(false); try ...
diff --git a/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/descriptors/XPathQuery.java b/as/plugins/org.jboss.ide.eclipse.as.core/jbosscore/org/jboss/ide/eclipse/as/core/extensions/descriptors/XPathQuery.java index 748987799..dc58b21f0 100644 --- a/as/plugins/org.jboss.ide....
false
true
protected void loadResults() { String[] files = getFilter().getIncludedFiles(); String fileLoc; ArrayList<XPathFileResult> resultList = new ArrayList<XPathFileResult>(); List<Node> nodeList = null; for( int i = 0; i < files.length; i++ ) { fileLoc = new Path(baseDir).append(files[i]).toOSString(); Docu...
protected void loadResults() { try { String[] files = getFilter().getIncludedFiles(); String fileLoc; ArrayList<XPathFileResult> resultList = new ArrayList<XPathFileResult>(); List<Node> nodeList = null; for( int i = 0; i < files.length; i++ ) { fileLoc = new Path(baseDir).append(files[i]).toOSStr...
diff --git a/server/src/test/java/com/barchart/netty/server/http/TestHttpServer.java b/server/src/test/java/com/barchart/netty/server/http/TestHttpServer.java index decc226..75c3643 100644 --- a/server/src/test/java/com/barchart/netty/server/http/TestHttpServer.java +++ b/server/src/test/java/com/barchart/netty/server/...
true
true
public void setUp() throws Exception { basic = new TestRequestHandler("basic", false, 0, 0, false, false); async = new TestRequestHandler("async", true, 0, 0, false, false); asyncDelayed = new TestRequestHandler("async-delayed", true, 50, 0, false, false); clientDisconnect = new TestRequestHandl...
public void setUp() throws Exception { basic = new TestRequestHandler("basic", false, 0, 0, false, false); async = new TestRequestHandler("async", true, 0, 0, false, false); asyncDelayed = new TestRequestHandler("async-delayed", true, 50, 0, false, false); clientDisconnect = new TestRequestHandl...
diff --git a/src/main/java/hudson/plugins/jira/Updater.java b/src/main/java/hudson/plugins/jira/Updater.java index 079a5c0..406cef3 100644 --- a/src/main/java/hudson/plugins/jira/Updater.java +++ b/src/main/java/hudson/plugins/jira/Updater.java @@ -1,133 +1,134 @@ package hudson.plugins.jira; import hudson.Util; i...
true
true
static boolean perform(AbstractBuild build, BuildListener listener) throws InterruptedException, IOException { PrintStream logger = listener.getLogger(); JiraSite site = JiraSite.get(build.getProject()); if(site==null) { logger.println(Messages.Updater_NoJiraSite()); ...
static boolean perform(AbstractBuild build, BuildListener listener) throws InterruptedException, IOException { PrintStream logger = listener.getLogger(); JiraSite site = JiraSite.get(build.getProject()); if(site==null) { logger.println(Messages.Updater_NoJiraSite()); ...
diff --git a/src/org/muckebox/android/net/DownloadServer.java b/src/org/muckebox/android/net/DownloadServer.java index 3daf05a..8abc398 100644 --- a/src/org/muckebox/android/net/DownloadServer.java +++ b/src/org/muckebox/android/net/DownloadServer.java @@ -1,230 +1,230 @@ /* * Copyright 2013 Karsten Patzwaldt *...
true
true
public void run() { super.run(); try { d("Starting server on " + mPort); mServerSocket = new ServerSocket(mPort, 0, InetAddress.getByName("localhost")); mServerSocket.setReuseAddress(true); try { mReady = true...
public void run() { super.run(); try { d("Starting server on " + mPort); mServerSocket = new ServerSocket(mPort, 0, InetAddress.getByName("localhost")); mServerSocket.setReuseAddress(true); try { mReady = true...
diff --git a/src/org/apache/xerces/xinclude/XIncludeHandler.java b/src/org/apache/xerces/xinclude/XIncludeHandler.java index 7e33af55..6ac885dd 100644 --- a/src/org/apache/xerces/xinclude/XIncludeHandler.java +++ b/src/org/apache/xerces/xinclude/XIncludeHandler.java @@ -1,2585 +1,2587 @@ /* * Copyright 2001-2004 The...
false
true
protected boolean handleIncludeElement(XMLAttributes attributes) throws XNIException { setSawInclude(fDepth, true); fNamespaceContext.setContextInvalid(); if (getSawInclude(fDepth - 1)) { reportFatalError("IncludeChild", new Object[] { XINCLUDE_INCLUDE }); } ...
protected boolean handleIncludeElement(XMLAttributes attributes) throws XNIException { setSawInclude(fDepth, true); fNamespaceContext.setContextInvalid(); if (getSawInclude(fDepth - 1)) { reportFatalError("IncludeChild", new Object[] { XINCLUDE_INCLUDE }); } ...
diff --git a/src/main/java/org/pandora/PandoraWorldGenerator.java b/src/main/java/org/pandora/PandoraWorldGenerator.java index 24a342b..6680ab0 100644 --- a/src/main/java/org/pandora/PandoraWorldGenerator.java +++ b/src/main/java/org/pandora/PandoraWorldGenerator.java @@ -1,1280 +1,1280 @@ /* * Copyright (c) 2012-20...
true
true
public boolean placeBlocks(Location start, boolean fastFail) { if (plugin == null || start == null) return false; else if (!modifiedBlocks.containsKey(start)) return false; Map<Block, BlockValues> modified = modifiedBlocks.get(start); if(modified.isEmpty()) return true; List<BlockState> blocks = ...
public boolean placeBlocks(Location start, boolean fastFail) { if (plugin == null || start == null || modifiedBlocks == null) return false; else if (!modifiedBlocks.containsKey(start)) return false; Map<Block, BlockValues> modified = modifiedBlocks.get(start); if(modified.isEmpty()) return true; ...
diff --git a/src-support/org/seasr/meandre/support/io/JARInstaller.java b/src-support/org/seasr/meandre/support/io/JARInstaller.java index b861d00d..4552929f 100644 --- a/src-support/org/seasr/meandre/support/io/JARInstaller.java +++ b/src-support/org/seasr/meandre/support/io/JARInstaller.java @@ -1,143 +1,145 @@ /** ...
false
true
public static synchronized InstallStatus installFromStream(InputStream jarStream, String sDestDir, boolean bForce ) { File fRootDir = new File(sDestDir); // Basic checking if ( fRootDir.exists() ) { if ( bForce ) { boolean bOK = deleteDir(fRootDir); if ( !bOK ) return InstallStatus.FAILED; } els...
public static synchronized InstallStatus installFromStream(InputStream jarStream, String sDestDir, boolean bForce ) { File fRootDir = new File(sDestDir); // Basic checking if ( fRootDir.exists() ) { if ( bForce ) { boolean bOK = deleteDir(fRootDir); if ( !bOK ) return InstallStatus.FAILED; } els...
diff --git a/src/org/nutz/lang/util/MultiLineProperties.java b/src/org/nutz/lang/util/MultiLineProperties.java index 7002295c3..cd8160bd4 100644 --- a/src/org/nutz/lang/util/MultiLineProperties.java +++ b/src/org/nutz/lang/util/MultiLineProperties.java @@ -1,143 +1,143 @@ package org.nutz.lang.util; import java.io....
true
true
public synchronized void load(Reader reader) throws IOException { BufferedReader tr = null; if (reader instanceof BufferedReader) tr = (BufferedReader) reader; else tr = new BufferedReader(reader); this.clear(); String s; while (null != (s = tr.readLine())) { if (Strings.isBlank(s)) continue; ...
public synchronized void load(Reader reader) throws IOException { BufferedReader tr = null; if (reader instanceof BufferedReader) tr = (BufferedReader) reader; else tr = new BufferedReader(reader); this.clear(); String s; while (null != (s = tr.readLine())) { if (Strings.isBlank(s)) continue; ...
diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/RevWalkTextBuiltin.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/RevWalkTextBuiltin.java index 715cb71b..50fe31f8 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/RevWalkTextBuiltin.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/RevWa...
true
true
protected void run() throws Exception { walk = createWalk(); for (final RevSort s : sorting) walk.sort(s, true); if (pathFilter instanceof FollowFilter) walk.setTreeFilter(pathFilter); else if (pathFilter != TreeFilter.ALL) walk.setTreeFilter(AndTreeFilter.create(pathFilter, TreeFilter.ANY_DIFF)...
protected void run() throws Exception { walk = createWalk(); for (final RevSort s : sorting) walk.sort(s, true); if (pathFilter instanceof FollowFilter) walk.setTreeFilter(pathFilter); else if (pathFilter != TreeFilter.ALL) walk.setTreeFilter(AndTreeFilter.create(pathFilter, TreeFilter.ANY_DIFF)...
diff --git a/ui/plugins/eu.esdihumboldt.hale.ui.common/src/eu/esdihumboldt/hale/ui/common/definition/viewer/InheritedPropertiesFilter.java b/ui/plugins/eu.esdihumboldt.hale.ui.common/src/eu/esdihumboldt/hale/ui/common/definition/viewer/InheritedPropertiesFilter.java index a449336e8..9f398bb66 100644 --- a/ui/plugins/eu...
true
true
public boolean select(Viewer viewer, Object parentElement, Object element) { if (element instanceof TreePath) { element = ((TreePath) element).getLastSegment(); } if (element instanceof EntityDefinition) { EntityDefinition entityDef = (EntityDefinition) element; /* * Only filter properties directl...
public boolean select(Viewer viewer, Object parentElement, Object element) { if (element instanceof TreePath) { element = ((TreePath) element).getLastSegment(); } if (element instanceof EntityDefinition) { EntityDefinition entityDef = (EntityDefinition) element; /* * Only filter properties directl...
diff --git a/jcr/src/main/java/org/crsh/jcr/command/JCRCommand.java b/jcr/src/main/java/org/crsh/jcr/command/JCRCommand.java index b09d4ee1..b279b1e8 100644 --- a/jcr/src/main/java/org/crsh/jcr/command/JCRCommand.java +++ b/jcr/src/main/java/org/crsh/jcr/command/JCRCommand.java @@ -1,101 +1,101 @@ /* * Copyright (C)...
false
true
public Map<String, Boolean> complete(ParameterDescriptor<?> parameter, String prefix) throws Exception { if (parameter.getAnnotation() instanceof Path) { String path = (String)getProperty("currentPath"); Session session = (Session)getProperty("session"); // if (session != null) { ...
public Map<String, Boolean> complete(ParameterDescriptor<?> parameter, String prefix) throws Exception { if (parameter.getJavaValueType() == Path.class) { Path path = (Path)getProperty("currentPath"); Session session = (Session)getProperty("session"); // if (session != null) { N...
diff --git a/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/MicrojaxPostServlet.java b/microsling/microsling-core/src/main/java/org/apache/sling/microsling/slingservlets/MicrojaxPostServlet.java index b7a3e47280..13f2af11e1 100644 --- a/microsling/microsling-core/src/main/java/org/ap...
true
true
protected void createOrUpdateNodesFromRequest(SlingHttpServletRequest request, SlingHttpServletResponse response, Session s) throws RepositoryException, IOException { // Where to redirect to when done String redirectPath = request.getHeader("Referer"); // find out the actual "save pref...
protected void createOrUpdateNodesFromRequest(SlingHttpServletRequest request, SlingHttpServletResponse response, Session s) throws RepositoryException, IOException { // Where to redirect to when done String redirectPath = request.getHeader("Referer"); // find out the actual "save pref...
diff --git a/objectmodel/MasterPresenter.java b/objectmodel/MasterPresenter.java index df7fb3d..1022db1 100644 --- a/objectmodel/MasterPresenter.java +++ b/objectmodel/MasterPresenter.java @@ -1,1010 +1,1010 @@ /* * Copyright 2012 Anthony Cassidy * * Licensed under the Apache License, Version 2.0 (the "License")...
true
true
public void mergeWithScene(LoadedLoad s) { String name = s.getName(); logger.fine(name); System.out.println("dumping " + name); SceneObjectCollection theirs = s.getSceneObjectCollection(); SceneObjectCollection ours = this.scenePresenter.getModel().objectCollection(); for(int i=0;i<theirs.count();i++)...
public void mergeWithScene(LoadedLoad s) { String name = s.getName(); logger.fine(name); System.out.println("dumping " + name); SceneObjectCollection theirs = s.getSceneObjectCollection(); SceneObjectCollection ours = this.scenePresenter.getModel().objectCollection(); for(int i=0;i<theirs.count();i++)...
diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/provisional/p2/ui/dialogs/RepositoryManipulationPage.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/provisional/p2/ui/dialogs/RepositoryManipulationPage.java index 8fc6a67c8..28f3d879f 100644 --- a/bundles/org.ecl...
true
true
protected Control createContents(Composite parent) { display = parent.getDisplay(); // The help refers to the full-blown dialog. No help if it's read only. if (manipulator != null) PlatformUI.getWorkbench().getHelpSystem().setHelp(parent.getShell(), IProvHelpContextIds.REPOSITORY_MANIPULATION_DIALOG); Com...
protected Control createContents(Composite parent) { display = parent.getDisplay(); // The help refers to the full-blown dialog. No help if it's read only. if (manipulator != null) PlatformUI.getWorkbench().getHelpSystem().setHelp(parent.getShell(), IProvHelpContextIds.REPOSITORY_MANIPULATION_DIALOG); Com...
diff --git a/src/main/java/org/mapdb/StoreDirect.java b/src/main/java/org/mapdb/StoreDirect.java index 1c86d1a5..48ee605e 100644 --- a/src/main/java/org/mapdb/StoreDirect.java +++ b/src/main/java/org/mapdb/StoreDirect.java @@ -1,656 +1,656 @@ /* * Copyright (c) 2012 Jan Kotek * * Licensed under the Apache Lice...
false
true
public void compact() { if(readOnly) throw new IllegalAccessError(); index.putLong(IO_PHYS_SIZE,physSize); index.putLong(IO_INDEX_SIZE,indexSize); if(index.getFile()==null) throw new UnsupportedOperationException("compact not supported for memory storage yet"); structuralLo...
public void compact() { if(readOnly) throw new IllegalAccessError(); index.putLong(IO_PHYS_SIZE,physSize); index.putLong(IO_INDEX_SIZE,indexSize); if(index.getFile()==null) throw new UnsupportedOperationException("compact not supported for memory storage yet"); structuralLo...
diff --git a/kChat/src/me/KeybordPiano459/kChat/ChatColors.java b/kChat/src/me/KeybordPiano459/kChat/ChatColors.java index 3ff84f7..cd3c23f 100644 --- a/kChat/src/me/KeybordPiano459/kChat/ChatColors.java +++ b/kChat/src/me/KeybordPiano459/kChat/ChatColors.java @@ -1,26 +1,26 @@ package me.KeybordPiano459.kChat; imp...
false
true
public void onChat(AsyncPlayerChatEvent event) { Player player = event.getPlayer(); String msg = event.getMessage(); if (plugin.colorallowed) { event.setMessage(ChatColor.translateAlternateColorCodes('&', msg)); } // Add color symbols to chat messages if (player.i...
public void onChat(AsyncPlayerChatEvent event) { Player player = event.getPlayer(); String msg = event.getMessage(); if (plugin.colorallowed) { event.setMessage(ChatColor.translateAlternateColorCodes('&', msg)); } if (player.isOp() && !plugin.opcolor.equals("none"...
diff --git a/src/net/sf/hajdbc/sync/DifferentialSynchronizationStrategy.java b/src/net/sf/hajdbc/sync/DifferentialSynchronizationStrategy.java index 0e3b1f62..7a1dfab2 100644 --- a/src/net/sf/hajdbc/sync/DifferentialSynchronizationStrategy.java +++ b/src/net/sf/hajdbc/sync/DifferentialSynchronizationStrategy.java @@ -1...
false
true
public void synchronize(Connection inactiveConnection, Connection activeConnection, DatabaseMetaDataCache metaData, Dialect dialect) throws SQLException { inactiveConnection.setAutoCommit(true); Statement statement = inactiveConnection.createStatement(); Collection<TableProperties> tables = metaData.getData...
public void synchronize(Connection inactiveConnection, Connection activeConnection, DatabaseMetaDataCache metaData, Dialect dialect) throws SQLException { inactiveConnection.setAutoCommit(true); Statement statement = inactiveConnection.createStatement(); Collection<TableProperties> tables = metaData.getData...
diff --git a/src/java/org/jamwiki/servlets/MoveServlet.java b/src/java/org/jamwiki/servlets/MoveServlet.java index 385b8255..7f9616fc 100644 --- a/src/java/org/jamwiki/servlets/MoveServlet.java +++ b/src/java/org/jamwiki/servlets/MoveServlet.java @@ -1,117 +1,118 @@ /** * Licensed under the GNU LESSER GENERAL PUBLIC...
false
true
private void move(HttpServletRequest request, ModelAndView next, WikiPageInfo pageInfo) throws Exception { String virtualWiki = JAMWikiServlet.getVirtualWikiFromURI(request); String topicName = JAMWikiServlet.getTopicFromRequest(request); if (!StringUtils.hasText(topicName)) { throw new WikiException(new Wiki...
private void move(HttpServletRequest request, ModelAndView next, WikiPageInfo pageInfo) throws Exception { String virtualWiki = JAMWikiServlet.getVirtualWikiFromURI(request); String topicName = JAMWikiServlet.getTopicFromRequest(request); if (!StringUtils.hasText(topicName)) { throw new WikiException(new Wiki...
diff --git a/xbean-server/src/main/java/org/apache/xbean/server/spring/configuration/ClassLoaderXmlPreprocessor.java b/xbean-server/src/main/java/org/apache/xbean/server/spring/configuration/ClassLoaderXmlPreprocessor.java index 2481e833..dbc39df2 100644 --- a/xbean-server/src/main/java/org/apache/xbean/server/spring/c...
true
true
public void preprocess(SpringApplicationContext applicationContext, XmlBeanDefinitionReader reader, Document document) { // determine the classLoader ClassLoader classLoader; NodeList classpathElements = document.getDocumentElement().getElementsByTagName("classpath"); if (classpathEl...
public void preprocess(SpringApplicationContext applicationContext, XmlBeanDefinitionReader reader, Document document) { // determine the classLoader ClassLoader classLoader; NodeList classpathElements = document.getDocumentElement().getElementsByTagName("classpath"); if (classpathEl...
diff --git a/src/ece5984/phase2/truerandomstudy/Grapher.java b/src/ece5984/phase2/truerandomstudy/Grapher.java index 4ee9261..59dafa8 100644 --- a/src/ece5984/phase2/truerandomstudy/Grapher.java +++ b/src/ece5984/phase2/truerandomstudy/Grapher.java @@ -1,81 +1,81 @@ package ece5984.phase2.truerandomstudy; import ja...
true
true
public static Bitmap graph(Analysis analysis) { DecimalFormat df = new DecimalFormat("#.#"); Bitmap bmp = Bitmap.createBitmap(200, 200, Bitmap.Config.RGB_565); Canvas canvas = new Canvas(bmp); Paint paintBlack = new Paint(); paintBlack.setColor(Color.WHITE); paintBlack.setTextAlign(Align.LEFT); Paint pa...
public static Bitmap graph(Analysis analysis) { DecimalFormat df = new DecimalFormat("#.#"); Bitmap bmp = Bitmap.createBitmap(200, 200, Bitmap.Config.RGB_565); Canvas canvas = new Canvas(bmp); Paint paintBlack = new Paint(); paintBlack.setColor(Color.WHITE); paintBlack.setTextAlign(Align.LEFT); Paint pa...
diff --git a/modules/unsupported/jdbc-teradata/src/test/java/org/geotools/data/teradata/TeradataTestSetup.java b/modules/unsupported/jdbc-teradata/src/test/java/org/geotools/data/teradata/TeradataTestSetup.java index c13e7fde5..eeb8516b6 100644 --- a/modules/unsupported/jdbc-teradata/src/test/java/org/geotools/data/ter...
true
true
protected void setUpData() throws Exception { runSafe("DELETE FROM SYSSPATIAL.GEOMETRY_COLUMNS WHERE F_TABLE_NAME = 'ft1'"); runSafe("DELETE FROM SYSSPATIAL.GEOMETRY_COLUMNS WHERE F_TABLE_NAME = 'ft2'"); runSafe("DROP TRIGGER \"ft1_geometry_mi\""); runSafe("DROP TRIGGER \"ft1_geometry_mu\""); ...
protected void setUpData() throws Exception { runSafe("DELETE FROM SYSSPATIAL.GEOMETRY_COLUMNS WHERE F_TABLE_NAME = 'ft1'"); runSafe("DELETE FROM SYSSPATIAL.GEOMETRY_COLUMNS WHERE F_TABLE_NAME = 'ft2'"); runSafe("DROP TRIGGER \"ft1_geometry_mi\""); runSafe("DROP TRIGGER \"ft1_geometry_mu\""); ...
diff --git a/src/pg13/presentation/PuzzlePropertiesWidget.java b/src/pg13/presentation/PuzzlePropertiesWidget.java index 948aaeb..ba9e2d5 100644 --- a/src/pg13/presentation/PuzzlePropertiesWidget.java +++ b/src/pg13/presentation/PuzzlePropertiesWidget.java @@ -1,366 +1,366 @@ package pg13.presentation; import java....
true
true
public PuzzlePropertiesWidget(Composite parent, int style, Puzzle displayingPuzzle, boolean editMode) { super(parent, style); Register.newWindow(this); this.displayingPuzzle = displayingPuzzle; setLayout(new FormLayout()); // puzzle name txtPuzzleName = new Text(this, SWT.BORDER); txtPuzzleName.setF...
public PuzzlePropertiesWidget(Composite parent, int style, Puzzle displayingPuzzle, boolean editMode) { super(parent, style); Register.newWindow(this, "PuzzlePropertiesWidget" + (editMode == true? "Edit" : "View" )); this.displayingPuzzle = displayingPuzzle; setLayout(new FormLayout()); // puzzle name ...
diff --git a/plugins/org.eclipse.emf.compare.ui/src/org/eclipse/emf/compare/ui/viewer/content/part/ModelContentMergeViewerPart.java b/plugins/org.eclipse.emf.compare.ui/src/org/eclipse/emf/compare/ui/viewer/content/part/ModelContentMergeViewerPart.java index 9450037d4..5a1ad5373 100755 --- a/plugins/org.eclipse.emf.com...
false
true
private void drawRectangle(PaintEvent event, TreeItem treeItem, DiffElement diff) { final Rectangle treeBounds = tree.getTree().getClientArea(); final Rectangle treeItemBounds = treeItem.getBounds(); if (DiffAdapterFactory.shouldBeHidden(diff)) return; // Defines the circling Color RGB color = pa...
private void drawRectangle(PaintEvent event, TreeItem treeItem, DiffElement diff) { final Rectangle treeBounds = tree.getTree().getClientArea(); final Rectangle treeItemBounds = treeItem.getBounds(); if (DiffAdapterFactory.shouldBeHidden(diff)) return; // Defines the circling Color RGB color = pa...
diff --git a/deegree-core/deegree-core-base/src/main/java/org/deegree/feature/xpath/TypedObjectNodeXPathEvaluator.java b/deegree-core/deegree-core-base/src/main/java/org/deegree/feature/xpath/TypedObjectNodeXPathEvaluator.java index d16f5b01b9..4788ae04e4 100644 --- a/deegree-core/deegree-core-base/src/main/java/org/de...
true
true
public TypedObjectNode[] eval( GMLObject context, ValueReference propName ) throws FilterEvaluationException { // simple property with just a simple element step? QName simplePropName = propName.getAsQName(); if ( bindings != null && ( simplePropName...
public TypedObjectNode[] eval( GMLObject context, ValueReference propName ) throws FilterEvaluationException { // simple property with just a simple element step? QName simplePropName = propName.getAsQName(); if ( bindings != null && simplePropName != null ...
diff --git a/src/test/java/org/test/streaming/VideoRegistrationFullCycleTest.java b/src/test/java/org/test/streaming/VideoRegistrationFullCycleTest.java index adc2f57..dac269e 100644 --- a/src/test/java/org/test/streaming/VideoRegistrationFullCycleTest.java +++ b/src/test/java/org/test/streaming/VideoRegistrationFullCy...
false
true
public void testRestrievalPlan(){ Conf conf = new Conf("/alt-test-conf.properties"); String videoFileName = conf.get("test.video.file.name"); File video = new File(conf.getCachosDir(), videoFileName); Assert.assertTrue("file: "+video.getAbsolutePath()+" does not exist", video.exists()); Notifier notif...
public void testRestrievalPlan(){ Conf conf = new Conf("/alt-test-conf.properties"); String videoFileName = conf.get("test.video.file.name"); File video = new File(conf.getCachosDir(), videoFileName); Assert.assertTrue("file: "+video.getAbsolutePath()+" does not exist", video.exists()); Notifier notif...
diff --git a/feed/src/main/java/org/apache/falcon/workflow/OozieFeedWorkflowBuilder.java b/feed/src/main/java/org/apache/falcon/workflow/OozieFeedWorkflowBuilder.java index 0cbdf771..7b9095f8 100644 --- a/feed/src/main/java/org/apache/falcon/workflow/OozieFeedWorkflowBuilder.java +++ b/feed/src/main/java/org/apache/fal...
true
true
public Properties newWorkflowSchedule(Feed feed, Date startDate, String clusterName, String user) throws FalconException { org.apache.falcon.entity.v0.feed.Cluster feedCluster = FeedHelper.getCluster(feed, clusterName); if (!startDate.before(feedCluster.getValidity().getEnd())) { ...
public Properties newWorkflowSchedule(Feed feed, Date startDate, String clusterName, String user) throws FalconException { org.apache.falcon.entity.v0.feed.Cluster feedCluster = FeedHelper.getCluster(feed, clusterName); if (!startDate.before(feedCluster.getValidity().getEnd())) { ...
diff --git a/caGrid/projects/introduce-buildtools/src/gov/nih/nci/cagrid/introduce/servicetasks/deployment/validator/DeploymentValidatorTask.java b/caGrid/projects/introduce-buildtools/src/gov/nih/nci/cagrid/introduce/servicetasks/deployment/validator/DeploymentValidatorTask.java index 0337566f..7d00ae20 100644 --- a/c...
false
true
public void execute() throws BuildException { super.execute(); try { Properties properties = new Properties(); properties.putAll(this.getProject().getProperties()); String baseDir = this.getProject().getBaseDir().getAbsolutePath(); ...
public void execute() throws BuildException { super.execute(); try { Properties properties = new Properties(); properties.putAll(this.getProject().getProperties()); String baseDir = this.getProject().getBaseDir().getAbsolutePath(); ...
diff --git a/net.sourceforge.vrapper.core/src/net/sourceforge/vrapper/vim/modes/commandline/CommandLineParser.java b/net.sourceforge.vrapper.core/src/net/sourceforge/vrapper/vim/modes/commandline/CommandLineParser.java index 4d5d66ec..624747e4 100644 --- a/net.sourceforge.vrapper.core/src/net/sourceforge/vrapper/vim/mo...
true
true
public Command parseAndExecute(String first, String command) { try { // if the command is a number, jump to the given line int line = Integer.parseInt(command); return new MotionCommand(GoToLineMotion.FIRST_LINE.withCount(line)); } catch (NumberFormatException e) ...
public Command parseAndExecute(String first, String command) { try { // if the command is a number, jump to the given line int line = Integer.parseInt(command); return new MotionCommand(GoToLineMotion.FIRST_LINE.withCount(line)); } catch (NumberFormatException e) ...
diff --git a/main/src/main/java/com/bloatit/web/linkable/login/SignUpAction.java b/main/src/main/java/com/bloatit/web/linkable/login/SignUpAction.java index 793b19f13..2bd0ae96e 100644 --- a/main/src/main/java/com/bloatit/web/linkable/login/SignUpAction.java +++ b/main/src/main/java/com/bloatit/web/linkable/login/SignU...
true
true
protected final Url doProcess() { if (password != passwordCheck) { transmitParameters(); session.notifyError("Password doesn't match confirmation."); return new SignUpPageUrl(); } final Locale locale = new Locale(lang, country); final Member m = n...
protected final Url doProcess() { if (!password.equals(passwordCheck)) { transmitParameters(); session.notifyError("Password doesn't match confirmation."); return new SignUpPageUrl(); } final Locale locale = new Locale(lang, country); final Member...
diff --git a/src/com/herocraftonline/dev/heroes/spout/SpoutInventoryListener.java b/src/com/herocraftonline/dev/heroes/spout/SpoutInventoryListener.java index dc3e3c10..7bdcdd36 100644 --- a/src/com/herocraftonline/dev/heroes/spout/SpoutInventoryListener.java +++ b/src/com/herocraftonline/dev/heroes/spout/SpoutInventor...
true
true
public void onInventoryCraft(InventoryCraftEvent event) { if (event.getResult() == null || event.isCancelled()) { return; } if (event.isShiftClick() && event.getPlayer().getInventory().firstEmpty() == -1) { return; } ItemStack cursor = event.getCurso...
public void onInventoryCraft(InventoryCraftEvent event) { if (event.getResult() == null || event.isCancelled() || Heroes.properties.disabledWorlds.contains(event.getPlayer().getWorld().getName())) { return; } if (event.isShiftClick() && event.getPlayer().getInventory().firstEmpt...
diff --git a/src/org/mozilla/javascript/CompilerEnvirons.java b/src/org/mozilla/javascript/CompilerEnvirons.java index 14bf5af8..8ed1444a 100644 --- a/src/org/mozilla/javascript/CompilerEnvirons.java +++ b/src/org/mozilla/javascript/CompilerEnvirons.java @@ -1,187 +1,187 @@ /* -*- Mode: java; tab-width: 8; indent-tabs...
true
true
public void initFromContext(Context cx) { setErrorReporter(cx.getErrorReporter()); this.languageVersion = cx.getLanguageVersion(); useDynamicScope = cx.compileFunctionsWithDynamicScopeFlag; generateDebugInfo = (!cx.isGeneratingDebugChanged() || cx.isG...
public void initFromContext(Context cx) { setErrorReporter(cx.getErrorReporter()); this.languageVersion = cx.getLanguageVersion(); useDynamicScope = cx.hasFeature(Context.FEATURE_DYNAMIC_SCOPE); generateDebugInfo = (!cx.isGeneratingDebugChanged() || c...
diff --git a/tests/org.eclipse.dltk.ruby.core.tests/src/org/eclipse/dltk/ruby/tests/parser/jruby/ZippedParserSuite.java b/tests/org.eclipse.dltk.ruby.core.tests/src/org/eclipse/dltk/ruby/tests/parser/jruby/ZippedParserSuite.java index cbbd5822..99d4aba1 100644 --- a/tests/org.eclipse.dltk.ruby.core.tests/src/org/eclips...
true
true
public ZippedParserSuite(String testsZip) { super(testsZip); ZipFile zipFile; try { zipFile = new ZipFile(AbstractModelTests.storeToMetadata(Activator .getDefault().getBundle(), "parser.zip", testsZip)); Enumeration entries = zipFile.entries(); while (entries.hasMoreElements()) { ZipEntry entry...
public ZippedParserSuite(String testsZip) { super(testsZip); ZipFile zipFile; try { zipFile = new ZipFile(AbstractModelTests.storeToMetadata(Activator .getDefault().getBundle(), "parser.zip", testsZip)); Enumeration entries = zipFile.entries(); while (entries.hasMoreElements()) { ZipEntry entry...
diff --git a/src/edu/sc/seis/sod/editor/SimpleGUIEditor.java b/src/edu/sc/seis/sod/editor/SimpleGUIEditor.java index 9a17c595d..672f8b37c 100644 --- a/src/edu/sc/seis/sod/editor/SimpleGUIEditor.java +++ b/src/edu/sc/seis/sod/editor/SimpleGUIEditor.java @@ -1,362 +1,363 @@ /** * SimpleGUI.java * * @author Created...
false
true
public void start() { frame = new JFrame(frameName); JMenuBar menubar = new JMenuBar(); frame.setJMenuBar(menubar); JMenu fileMenu = new JMenu("File"); menubar.add(fileMenu); final JMenuItem saveAs = new JMenuItem("Save As..."); saveAs.addActionListener(new Ac...
public void start() { frame = new JFrame(frameName); JMenuBar menubar = new JMenuBar(); frame.setJMenuBar(menubar); JMenu fileMenu = new JMenu("File"); menubar.add(fileMenu); final JMenuItem saveAs = new JMenuItem("Save As..."); saveAs.addActionListener(new Ac...
diff --git a/src/main/java/org/dynmap/JsonFileClientUpdateComponent.java b/src/main/java/org/dynmap/JsonFileClientUpdateComponent.java index 748755b9..0515c662 100644 --- a/src/main/java/org/dynmap/JsonFileClientUpdateComponent.java +++ b/src/main/java/org/dynmap/JsonFileClientUpdateComponent.java @@ -1,151 +1,151 @@ ...
true
true
protected void writeUpdates() { long current = System.currentTimeMillis(); File outputFile; //Handles Updates for (DynmapWorld dynmapWorld : plugin.mapManager.worlds.values()) { World world = dynmapWorld.world; current = System.currentTimeMillis(); ...
protected void writeUpdates() { long current = System.currentTimeMillis(); File outputFile; //Handles Updates for (DynmapWorld dynmapWorld : plugin.mapManager.worlds.values()) { World world = dynmapWorld.world; current = System.currentTimeMillis(); ...
diff --git a/src/cli/src/main/java/org/geogit/cli/porcelain/Merge.java b/src/cli/src/main/java/org/geogit/cli/porcelain/Merge.java index fec44b91..d0a29fd4 100644 --- a/src/cli/src/main/java/org/geogit/cli/porcelain/Merge.java +++ b/src/cli/src/main/java/org/geogit/cli/porcelain/Merge.java @@ -1,150 +1,150 @@ /* Copyr...
true
true
public void runInternal(GeogitCLI cli) throws IOException { checkParameter(commits.size() > 0, "No commits provided to merge."); ConsoleReader console = cli.getConsole(); final GeoGIT geogit = cli.getGeogit(); Ansi ansi = newAnsi(console.getTerminal()); if (abort) { ...
public void runInternal(GeogitCLI cli) throws IOException { checkParameter(commits.size() > 0 || abort, "No commits provided to merge."); ConsoleReader console = cli.getConsole(); final GeoGIT geogit = cli.getGeogit(); Ansi ansi = newAnsi(console.getTerminal()); if (abort...
diff --git a/src/com/leafdigital/hawthorn/server/HttpServer.java b/src/com/leafdigital/hawthorn/server/HttpServer.java index a7a4c94..4093b04 100644 --- a/src/com/leafdigital/hawthorn/server/HttpServer.java +++ b/src/com/leafdigital/hawthorn/server/HttpServer.java @@ -1,896 +1,904 @@ /* Copyright 2009 Samuel Marshall...
true
true
public void send(int code, byte[] dataBytes, String contentType, String location, boolean cacheForAges) throws IllegalArgumentException { try { // Get header StringBuilder header = new StringBuilder(); String codeText; switch(code) { case 200: codeText = "OK"; break; ...
public void send(int code, byte[] dataBytes, String contentType, String location, boolean cacheForAges) throws IllegalArgumentException { try { // Get header StringBuilder header = new StringBuilder(); String codeText; switch(code) { case 200: codeText = "OK"; break; ...
diff --git a/src/impl/com/sun/ws/rest/impl/modelapi/validation/BasicValidator.java b/src/impl/com/sun/ws/rest/impl/modelapi/validation/BasicValidator.java index 96131b88..2b2d5968 100644 --- a/src/impl/com/sun/ws/rest/impl/modelapi/validation/BasicValidator.java +++ b/src/impl/com/sun/ws/rest/impl/modelapi/validation/B...
false
true
public void visitAbstractResource(AbstractResource resource) { // resource should have at least one resource method, subresource method or subresource locator if ((resource.getResourceMethods().size() + resource.getSubResourceMethods().size() + resource.getSubResourceLocators().size()) == 0) { ...
public void visitAbstractResource(AbstractResource resource) { // resource should have at least one resource method, subresource method or subresource locator if ((resource.getResourceMethods().size() + resource.getSubResourceMethods().size() + resource.getSubResourceLocators().size()) == 0) { ...
diff --git a/optaplanner-core/src/main/java/org/optaplanner/core/config/score/director/ScoreDirectorFactoryConfig.java b/optaplanner-core/src/main/java/org/optaplanner/core/config/score/director/ScoreDirectorFactoryConfig.java index e28ca7861..7a941dc1f 100644 --- a/optaplanner-core/src/main/java/org/optaplanner/core/c...
true
true
private KieBase buildKieBase() { if (kieBase != null) { if (!CollectionUtils.isEmpty(scoreDrlList)) { throw new IllegalArgumentException("If kieBase is not null, the scoreDrlList (" + scoreDrlList + ") must be empty."); } if (kieBas...
private KieBase buildKieBase() { if (kieBase != null) { if (!CollectionUtils.isEmpty(scoreDrlList)) { throw new IllegalArgumentException("If kieBase is not null, the scoreDrlList (" + scoreDrlList + ") must be empty."); } if (kieBas...
diff --git a/plugins/org.bigraph.model/src/org/bigraph/model/loaders/XMLLoader.java b/plugins/org.bigraph.model/src/org/bigraph/model/loaders/XMLLoader.java index 1260dc21..3bd0d42e 100644 --- a/plugins/org.bigraph.model/src/org/bigraph/model/loaders/XMLLoader.java +++ b/plugins/org.bigraph.model/src/org/bigraph/model/...
false
true
protected <T extends ModelObject> T loadRelative(String replacement, Class<? extends T> klass, XMLLoader loader) throws LoadFailedException { if (replacement != null) { if (getFile() == null) throw new Error("BUG: relative path to resolve, " + "but no IFileWrapper set on " + this); IResourc...
protected <T extends ModelObject> T loadRelative(String replacement, Class<? extends T> klass, XMLLoader loader) throws LoadFailedException { if (replacement != null) { if (getFile() == null) throw new Error("BUG: relative path to resolve, " + "but no IFileWrapper set on " + this); IResourc...
diff --git a/src/test/acceptanceTest/java/GreeterTest.java b/src/test/acceptanceTest/java/GreeterTest.java index 5b493cc..51e59c4 100644 --- a/src/test/acceptanceTest/java/GreeterTest.java +++ b/src/test/acceptanceTest/java/GreeterTest.java @@ -1,12 +1,12 @@ import org.junit.Test; import static org.hamcrest.core.Is...
true
true
public void says_hello_to_the_world() { Greeter greeter = new Greeter(); assertThat("", is("a")); }
public void says_hello_to_the_world() { Greeter greeter = new Greeter(); assertThat("", is("")); }
diff --git a/src/keepcalm/mods/bukkit/forgeHandler/BukkitCraftingHandler.java b/src/keepcalm/mods/bukkit/forgeHandler/BukkitCraftingHandler.java index b5574e4..4d1243f 100644 --- a/src/keepcalm/mods/bukkit/forgeHandler/BukkitCraftingHandler.java +++ b/src/keepcalm/mods/bukkit/forgeHandler/BukkitCraftingHandler.java @@ ...
true
true
public void onCrafting(EntityPlayer player, ItemStack item, IInventory craftMatrix) { if (craftMatrix instanceof InventoryCrafting) { EntityPlayerMP fp; if (player instanceof EntityPlayerMP) fp = (EntityPlayerMP) player; else fp = BukkitContainer.MOD_PLAYER; InventoryCrafting inv = (InventoryCr...
public void onCrafting(EntityPlayer player, ItemStack item, IInventory craftMatrix) { if (craftMatrix instanceof InventoryCrafting) { EntityPlayerMP fp; if (player instanceof EntityPlayerMP) fp = (EntityPlayerMP) player; else fp = BukkitContainer.MOD_PLAYER; InventoryCrafting inv = (InventoryCr...
diff --git a/jslint4java/src/test/java/com/googlecode/jslint4java/formatter/CheckstyleXmlFormatterTest.java b/jslint4java/src/test/java/com/googlecode/jslint4java/formatter/CheckstyleXmlFormatterTest.java index 0b15185..9f2400a 100644 --- a/jslint4java/src/test/java/com/googlecode/jslint4java/formatter/CheckstyleXmlFor...
true
true
public void shouldHaveOneProblem() throws Exception { String name = "bad.js"; Issue issue = new Issue.IssueBuilder(name, 1, 1, "this is not a daffodil").build(); JSLintResult result = new JSLintResult.ResultBuilder(name).addIssue(issue).build(); String expected = "<file name=\"bad.js...
public void shouldHaveOneProblem() throws Exception { String name = "bad.js"; Issue issue = new Issue.IssueBuilder(name, 1, 1, "this is not a daffodil").build(); JSLintResult result = new JSLintResult.ResultBuilder(name).addIssue(issue).build(); String expected = "<file name=\"bad.js...
diff --git a/temp2/CA/src/Datapath.java b/temp2/CA/src/Datapath.java index 391ac1a..0399153 100644 --- a/temp2/CA/src/Datapath.java +++ b/temp2/CA/src/Datapath.java @@ -1,307 +1,307 @@ public class Datapath { long pc = 0; Adder adder = new Adder(); Control control = new Control(); IM im = new IM(); Re...
true
true
public void performInstruction(String ins) { // String Instruction = im.getInstruction(pc); pc = adder.add(pc, 4); String[] z = ins.split(" "); String in = z[0]; if (z.length == 2) { control.set_controler("000010"); if (z[0].equals("000011")) { long y = pc + 4; String...
public void performInstruction(String ins) { // String Instruction = im.getInstruction(pc); pc = adder.add(pc, 4); String[] z = ins.split(" "); String in = z[0]; if (z.length == 2) { control.set_controler("000010"); if (z[0].equals("000011")) { long y = pc + 4; String...
diff --git a/tregmine/src/info/tregmine/Tregmine.java b/tregmine/src/info/tregmine/Tregmine.java index 80358fb..6818a6d 100644 --- a/tregmine/src/info/tregmine/Tregmine.java +++ b/tregmine/src/info/tregmine/Tregmine.java @@ -1,645 +1,645 @@ package info.tregmine; import info.tregmine.api.TregminePlayer; import i...
false
true
public boolean onCommand(CommandSender sender, Command command, String commandLabel, final String[] args) { String commandName = command.getName().toLowerCase(); Player from = null; TregminePlayer player = null; if(!(sender instanceof Player)) { if(commandName.equals("say")) { StringBuffer buf = new Str...
public boolean onCommand(CommandSender sender, Command command, String commandLabel, final String[] args) { String commandName = command.getName().toLowerCase(); Player from = null; TregminePlayer player = null; if(!(sender instanceof Player)) { if(commandName.equals("say")) { StringBuffer buf = new Str...
diff --git a/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/strings/TermsStringOrdinalsFacetCollector.java b/modules/elasticsearch/src/main/java/org/elasticsearch/search/facet/terms/strings/TermsStringOrdinalsFacetCollector.java index ba0a2ec90a0..66c23f9da28 100644 --- a/modules/elasticsearch...
false
true
@Override public Facet facet() { if (current != null) { missing += current.counts[0]; total += current.total - current.counts[0]; // if we have values for this one, add it if (current.values.length > 1) { aggregators.add(current); }...
@Override public Facet facet() { if (current != null) { missing += current.counts[0]; total += current.total - current.counts[0]; // if we have values for this one, add it if (current.values.length > 1) { aggregators.add(current); }...
diff --git a/src/main/java/org/sql2o/Query.java b/src/main/java/org/sql2o/Query.java index 207d520..833deb4 100644 --- a/src/main/java/org/sql2o/Query.java +++ b/src/main/java/org/sql2o/Query.java @@ -1,505 +1,505 @@ package org.sql2o; import org.joda.time.DateTime; import org.slf4j.Logger; import org.slf4j.Logge...
true
true
public <T> List<T> executeAndFetch(Class returnType){ List list = new ArrayList(); PojoMetadata metadata = new PojoMetadata(returnType, this.isCaseSensitive(), this.getColumnMappings()); try{ //java.util.Date st = new java.util.Date(); long start = System.currentTimeM...
public <T> List<T> executeAndFetch(Class returnType){ List list = new ArrayList(); PojoMetadata metadata = new PojoMetadata(returnType, this.isCaseSensitive(), this.getColumnMappings()); try{ //java.util.Date st = new java.util.Date(); long start = System.currentTimeM...
diff --git a/vaadin-framework/src/main/java/pt/ist/vaadinframework/EmbeddedWindow.java b/vaadin-framework/src/main/java/pt/ist/vaadinframework/EmbeddedWindow.java index 9af87ac..d6c1913 100644 --- a/vaadin-framework/src/main/java/pt/ist/vaadinframework/EmbeddedWindow.java +++ b/vaadin-framework/src/main/java/pt/ist/vaa...
true
true
public EmbeddedWindow(final Map<Pattern, Class<? extends EmbeddedComponentContainer>> resolver) { final VerticalLayout layout = new VerticalLayout(); layout.addComponent(fragmentUtility); fragmentUtility.addListener(new UriFragmentUtility.FragmentChangedListener() { @Override public void fragmentChange...
public EmbeddedWindow(final Map<Pattern, Class<? extends EmbeddedComponentContainer>> resolver) { final VerticalLayout layout = new VerticalLayout(); layout.addComponent(fragmentUtility); fragmentUtility.addListener(new UriFragmentUtility.FragmentChangedListener() { @Override public void fragmentChange...
diff --git a/PTFrontend/src/javaworld/InstTupleRew.java b/PTFrontend/src/javaworld/InstTupleRew.java index 214154a..0ccd435 100644 --- a/PTFrontend/src/javaworld/InstTupleRew.java +++ b/PTFrontend/src/javaworld/InstTupleRew.java @@ -1,248 +1,248 @@ package javaworld; import java.util.Map; import AST.TypeDecl; i...
true
true
protected HashMap<ASTNode,String> findInternalRenames(TypeDecl target) { // XXX what about types that can only be found in the parent, are these renamed correctly? // do any such exist? is the parent always ptdecl? HashMap< ASTNode, String > rv = new LinkedHashMap< ASTNode, String >(); ...
protected HashMap<ASTNode,String> findInternalRenames(TypeDecl target) { // XXX what about types that can only be found in the parent, are these renamed correctly? // do any such exist? is the parent always ptdecl? HashMap< ASTNode, String > rv = new LinkedHashMap< ASTNode, String >(); ...
diff --git a/Slick/src/org/newdawn/slick/opengl/PNGImageData.java b/Slick/src/org/newdawn/slick/opengl/PNGImageData.java index 983db02..1ec7e41 100644 --- a/Slick/src/org/newdawn/slick/opengl/PNGImageData.java +++ b/Slick/src/org/newdawn/slick/opengl/PNGImageData.java @@ -1,787 +1,787 @@ package org.newdawn.slick.open...
false
true
public ByteBuffer loadImage(InputStream fis, boolean flipped, boolean forceAlpha, int[] transparent) throws IOException { if (transparent != null) { forceAlpha = true; } init(fis); if (!isRGB()) { throw new IOException("Only RGB formatted images are supported by the PNGLoader"); } texWidth =...
public ByteBuffer loadImage(InputStream fis, boolean flipped, boolean forceAlpha, int[] transparent) throws IOException { if (transparent != null) { forceAlpha = true; } init(fis); if (!isRGB()) { throw new IOException("Only RGB formatted images are supported by the PNGLoader"); } texWidth =...
diff --git a/src/com/android/gallery3d/app/AlbumSetPage.java b/src/com/android/gallery3d/app/AlbumSetPage.java index 6941f291..dafe3792 100644 --- a/src/com/android/gallery3d/app/AlbumSetPage.java +++ b/src/com/android/gallery3d/app/AlbumSetPage.java @@ -1,707 +1,705 @@ /* * Copyright (C) 2010 The Android Open Sourc...
true
true
private void pickAlbum(int slotIndex) { if (!mIsActive) return; MediaSet targetSet = mAlbumSetDataAdapter.getMediaSet(slotIndex); if (targetSet == null) return; // Content is dirty, we shall reload soon if (targetSet.getTotalMediaItemCount() == 0) { showEmptyAlbumToast(T...
private void pickAlbum(int slotIndex) { if (!mIsActive) return; MediaSet targetSet = mAlbumSetDataAdapter.getMediaSet(slotIndex); if (targetSet == null) return; // Content is dirty, we shall reload soon if (targetSet.getTotalMediaItemCount() == 0) { showEmptyAlbumToast(T...
diff --git a/ij/plugin/MacroInstaller.java b/ij/plugin/MacroInstaller.java index 2ac21087..32c6b306 100644 --- a/ij/plugin/MacroInstaller.java +++ b/ij/plugin/MacroInstaller.java @@ -1,409 +1,410 @@ package ij.plugin; import java.awt.*; import java.io.*; import java.awt.event.*; import ij.*; import ij.gui.*; imp...
true
true
void install() { if (text!=null) { Tokenizer tok = new Tokenizer(); pgm = tok.tokenize(text); } IJ.showStatus(""); int[] code = pgm.getCode(); Symbol[] symbolTable = pgm.getSymbolTable(); int count=0, token, nextToken, address; String name; Symbol symbol; shortcutsInUse = null; inUseCount = 0...
void install() { if (text!=null) { Tokenizer tok = new Tokenizer(); pgm = tok.tokenize(text); } IJ.showStatus(""); int[] code = pgm.getCode(); Symbol[] symbolTable = pgm.getSymbolTable(); int count=0, token, nextToken, address; String name; Symbol symbol; shortcutsInUse = null; inUseCount = 0...
diff --git a/de.xwic.etlgine/src/de/xwic/etlgine/extractor/CSVExtractor.java b/de.xwic.etlgine/src/de/xwic/etlgine/extractor/CSVExtractor.java index 7a54bdc..2c79e40 100644 --- a/de.xwic.etlgine/src/de/xwic/etlgine/extractor/CSVExtractor.java +++ b/de.xwic.etlgine/src/de/xwic/etlgine/extractor/CSVExtractor.java @@ -1,1...
true
true
public void openSource(ISource source, IDataSet dataSet) throws ETLException { this.dataSet = dataSet; if (!(source instanceof FileSource)) { throw new ETLException("Can not handle a source of this type - FileSource type required."); } FileSource fsrc = (FileSource)source; try { recordNumber = 0;...
public void openSource(ISource source, IDataSet dataSet) throws ETLException { this.dataSet = dataSet; if (!(source instanceof FileSource)) { throw new ETLException("Can not handle a source of this type - FileSource type required."); } FileSource fsrc = (FileSource)source; try { recordNumber = 0;...
diff --git a/xengine_less/src/com/xengine/android/utils/XStringUtil.java b/xengine_less/src/com/xengine/android/utils/XStringUtil.java index 86b7285..cd34fd4 100644 --- a/xengine_less/src/com/xengine/android/utils/XStringUtil.java +++ b/xengine_less/src/com/xengine/android/utils/XStringUtil.java @@ -1,391 +1,393 @@ pa...
true
true
public static String filterHtmlTag(String inputString) { String htmlStr = inputString; // 含html标签的字符串 String textStr = ""; Pattern p_script; Matcher m_script; Pattern p_style; Matcher m_style; Pattern p_html; Matcher m_html; try { ...
public static String filterHtmlTag(String inputString) { String htmlStr = inputString; // 含html标签的字符串 String textStr = ""; Pattern p_script; Matcher m_script; Pattern p_style; Matcher m_style; Pattern p_html; Matcher m_html; try { ...
diff --git a/rsa/src/main/java/org/rackspace/capman/tools/util/PrivKeyReader.java b/rsa/src/main/java/org/rackspace/capman/tools/util/PrivKeyReader.java index 6eeeb5c..117a0a1 100644 --- a/rsa/src/main/java/org/rackspace/capman/tools/util/PrivKeyReader.java +++ b/rsa/src/main/java/org/rackspace/capman/tools/util/PrivKe...
true
true
public static PrivKeyReader newPrivKeyReader(String pemString) throws PrivKeyDecodeException { JCERSAPrivateCrtKey privKey; Object obj; String msg; try { obj = PemUtils.fromPemString(pemString); } catch (PemException ex) { throw new PrivKeyDecodeExcept...
public static PrivKeyReader newPrivKeyReader(String pemString) throws PrivKeyDecodeException { JCERSAPrivateCrtKey privKey; Object obj; String msg; try { obj = PemUtils.fromPemString(pemString); } catch (PemException ex) { throw new PrivKeyDecodeExcept...
diff --git a/src/main/java/org/apache/commons/digester3/annotations/handlers/ObjectCreateHandler.java b/src/main/java/org/apache/commons/digester3/annotations/handlers/ObjectCreateHandler.java index 6c4b24a0..b6649849 100644 --- a/src/main/java/org/apache/commons/digester3/annotations/handlers/ObjectCreateHandler.java ...
true
true
public void handle( ObjectCreate annotation, AnnotatedElement element, RulesBinder rulesBinder ) { Class<?> type = null; if ( element instanceof Class<?> ) { type = (Class<?>) element; } else if ( element instanceof Constructor<?> ) { type ...
public void handle( ObjectCreate annotation, AnnotatedElement element, RulesBinder rulesBinder ) { Class<?> type = null; if ( element instanceof Class<?> ) { type = (Class<?>) element; } else if ( element instanceof Constructor<?> ) { type ...
diff --git a/contrib/alpha/PipesTest.java b/contrib/alpha/PipesTest.java index d01d3af..2e46794 100644 --- a/contrib/alpha/PipesTest.java +++ b/contrib/alpha/PipesTest.java @@ -1,448 +1,451 @@ import static org.junit.Assert.assertEquals; import static org.junit.Assert.fail; import java.util.List; import java.util...
false
true
public String exec(String s, String stdin) throws Exception { final String[] qq = s.trim().split(" ", 2); String cmd = qq[0].trim(); String arg = qq.length > 1 ? qq[1] : ""; if ("sed".equals(cmd)) return (String)mods.plugin.callAPI("MiscUtils", "Sed", arg, stdin); if ("tr".equals(cmd)) retu...
public String exec(String s, String stdin) throws Exception { final String[] qq = s.trim().split(" ", 2); String cmd = qq[0].trim(); String arg = qq.length > 1 ? qq[1] : ""; if ("sed".equals(cmd)) return (String)mods.plugin.callAPI("MiscUtils", "Sed", arg, stdin); if ("tr".equals(cmd)) retu...
diff --git a/dspace/src/org/dspace/content/WorkspaceItem.java b/dspace/src/org/dspace/content/WorkspaceItem.java index ce353af26..3a005898d 100644 --- a/dspace/src/org/dspace/content/WorkspaceItem.java +++ b/dspace/src/org/dspace/content/WorkspaceItem.java @@ -1,600 +1,600 @@ /* * WorkspaceItem.java * * Version:...
false
true
public static WorkspaceItem create(Context c, Collection coll, boolean template) throws AuthorizeException, SQLException, IOException { // Check the user has permission to ADD to the collection AuthorizeManager.authorizeAction(c, coll, Constants.ADD); // Create a...
public static WorkspaceItem create(Context c, Collection coll, boolean template) throws AuthorizeException, SQLException, IOException { // Check the user has permission to ADD to the collection AuthorizeManager.authorizeAction(c, coll, Constants.ADD); // Create a...
diff --git a/src/org/apache/fop/fo/flow/TableCell.java b/src/org/apache/fop/fo/flow/TableCell.java index 23643552c..eeaa99cf6 100644 --- a/src/org/apache/fop/fo/flow/TableCell.java +++ b/src/org/apache/fop/fo/flow/TableCell.java @@ -1,426 +1,432 @@ /* * -- $Id$ -- * Copyright (C) 2001 The Apache Software Foundatio...
true
true
public Status layout(Area area) throws FOPException { int originalAbsoluteHeight = area.getAbsoluteHeight(); if (this.marker == BREAK_AFTER) { return new Status(Status.OK); } if (this.marker == START) { // if (!setup) { // doSetup(area); ...
public Status layout(Area area) throws FOPException { int originalAbsoluteHeight = area.getAbsoluteHeight(); if (this.marker == BREAK_AFTER) { return new Status(Status.OK); } if (this.marker == START) { // if (!setup) { // doSetup(area); ...
diff --git a/src/main/java/org/iplantc/workflow/service/dto/analysis/list/AnalysisRating.java b/src/main/java/org/iplantc/workflow/service/dto/analysis/list/AnalysisRating.java index e47edd9..8de369f 100644 --- a/src/main/java/org/iplantc/workflow/service/dto/analysis/list/AnalysisRating.java +++ b/src/main/java/org/ip...
true
true
public AnalysisRating(AnalysisListing analysis, Map<Long, UserRating> userRatings) { this.average = analysis.getAverageRating(); UserRating userRating = userRatings.get(analysis.getHid()); this.user = userRating.userRating; this.commentId = userRating.commentId; }
public AnalysisRating(AnalysisListing analysis, Map<Long, UserRating> userRatings) { this.average = analysis.getAverageRating(); UserRating userRating = userRatings.get(analysis.getHid()); if (userRating != null) { this.user = userRating.userRating; this.commentId = u...
diff --git a/src/mobi/cyann/deviltools/SettingsManager.java b/src/mobi/cyann/deviltools/SettingsManager.java index 0c63f9b..a24042c 100644 --- a/src/mobi/cyann/deviltools/SettingsManager.java +++ b/src/mobi/cyann/deviltools/SettingsManager.java @@ -1,1101 +1,1101 @@ /** * SettingsManager.java * Nov 27, 2011 11:19:...
true
true
private static String buildCommand(Context c, SharedPreferences preferences) { StringBuilder command = new StringBuilder(); String status = null; String filepath = null; int value = -1; if(!preferences.getBoolean(c.getString(R.string.key_default_voltage), true)) { // restore voltage setting if and only...
private static String buildCommand(Context c, SharedPreferences preferences) { StringBuilder command = new StringBuilder(); String status = null; String filepath = null; int value = -1; if(!preferences.getBoolean(c.getString(R.string.key_default_voltage), true)) { // restore voltage setting if and only...
diff --git a/main/src/cgeo/geocaching/cgeoimages.java b/main/src/cgeo/geocaching/cgeoimages.java index 40adc00d5..c177bf24a 100644 --- a/main/src/cgeo/geocaching/cgeoimages.java +++ b/main/src/cgeo/geocaching/cgeoimages.java @@ -1,212 +1,212 @@ package cgeo.geocaching; import cgeo.geocaching.activity.AbstractActivi...
true
true
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // get parameters Bundle extras = getIntent().getExtras(); // try to get data from extras int img_type = UNKNOWN_TYPE; if (extras != null) { geocode = extras.getString(...
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); // get parameters Bundle extras = getIntent().getExtras(); // try to get data from extras int img_type = UNKNOWN_TYPE; if (extras != null) { geocode = extras.getString(...
diff --git a/astrid/src/com/todoroo/astrid/adapter/FilterAdapter.java b/astrid/src/com/todoroo/astrid/adapter/FilterAdapter.java index 34ba0a27e..a63fad66f 100644 --- a/astrid/src/com/todoroo/astrid/adapter/FilterAdapter.java +++ b/astrid/src/com/todoroo/astrid/adapter/FilterAdapter.java @@ -1,505 +1,505 @@ /** * Se...
true
true
public void populateView(ViewHolder viewHolder) { FilterListItem filter = viewHolder.item; if(filter == null) return; viewHolder.view.setBackgroundResource(0); if(viewHolder.decoration != null) { ((ViewGroup)viewHolder.view).removeView(viewHolder.decoration)...
public void populateView(ViewHolder viewHolder) { FilterListItem filter = viewHolder.item; if(filter == null) return; viewHolder.view.setBackgroundResource(0); if(viewHolder.decoration != null) { ((ViewGroup)viewHolder.view).removeView(viewHolder.decoration)...
diff --git a/src/main/java/com/khs/sherpa/context/factory/ManagedBean.java b/src/main/java/com/khs/sherpa/context/factory/ManagedBean.java index 37dc3f7..7596f21 100644 --- a/src/main/java/com/khs/sherpa/context/factory/ManagedBean.java +++ b/src/main/java/com/khs/sherpa/context/factory/ManagedBean.java @@ -1,60 +1,60 ...
true
true
protected Object createInstance() { try { return type.getDeclaringClass().newInstance(); } catch (Exception e) { throw new SherpaRuntimeException("Unable to create Managed Bean [" + type + "]"); } }
protected Object createInstance() { try { return type.newInstance(); } catch (Exception e) { throw new SherpaRuntimeException("Unable to create Managed Bean [" + type + "]"); } }
diff --git a/server/src/main/java/com/metamx/druid/initialization/ServerInit.java b/server/src/main/java/com/metamx/druid/initialization/ServerInit.java index 8b38872608..bb1d0d631d 100644 --- a/server/src/main/java/com/metamx/druid/initialization/ServerInit.java +++ b/server/src/main/java/com/metamx/druid/initializati...
true
true
public static StupidPool<ByteBuffer> makeComputeScratchPool(DruidProcessingConfig config) { try { Class<?> vmClass = Class.forName("sun.misc.VM"); Object maxDirectMemoryObj = vmClass.getMethod("maxDirectMemory").invoke(null); if (maxDirectMemoryObj == null || !(maxDirectMemoryObj instanceof N...
public static StupidPool<ByteBuffer> makeComputeScratchPool(DruidProcessingConfig config) { try { Class<?> vmClass = Class.forName("sun.misc.VM"); Object maxDirectMemoryObj = vmClass.getMethod("maxDirectMemory").invoke(null); if (maxDirectMemoryObj == null || !(maxDirectMemoryObj instanceof N...
diff --git a/src/java/org/jivesoftware/sparkimpl/plugin/systray/SysTrayPlugin.java b/src/java/org/jivesoftware/sparkimpl/plugin/systray/SysTrayPlugin.java index b12a529b..6778a183 100644 --- a/src/java/org/jivesoftware/sparkimpl/plugin/systray/SysTrayPlugin.java +++ b/src/java/org/jivesoftware/sparkimpl/plugin/systray/...
true
true
public void initialize() { SystemTray tray = SystemTray.getSystemTray(); SparkManager.getNativeManager().addNativeHandler(this); SparkManager.getMessageEventManager().addMessageEventNotificationListener(this); newMessageIcon = SparkRes.getImageIcon(SparkRes.MESSAGE_NEW_TRAY); typingIcon = SparkRes.get...
public void initialize() { SystemTray tray = SystemTray.getSystemTray(); SparkManager.getNativeManager().addNativeHandler(this); SparkManager.getMessageEventManager().addMessageEventNotificationListener(this); newMessageIcon = SparkRes.getImageIcon(SparkRes.MESSAGE_NEW_TRAY); typingIcon = SparkRes.get...
diff --git a/src/main/gradeapp/HelperButton.java b/src/main/gradeapp/HelperButton.java index 3028938..910b8f1 100644 --- a/src/main/gradeapp/HelperButton.java +++ b/src/main/gradeapp/HelperButton.java @@ -1,233 +1,238 @@ package gradeapp; import javax.swing.JOptionPane; import javax.swing.JButton; import javax.sw...
false
true
private JPanel createSimpleDialogBox() { final ButtonGroup group = new ButtonGroup(); final String loadHelpCommand = "loadhelp"; final String graphHelpCommand = "graphhelp"; final String emailHelpCommand = "emailhelp"; final String saveHelpCommand = "savehelp"; final...
private JPanel createSimpleDialogBox() { final ButtonGroup group = new ButtonGroup(); final String loadHelpCommand = "loadhelp"; final String graphHelpCommand = "graphhelp"; final String emailHelpCommand = "emailhelp"; final String saveHelpCommand = "savehelp"; final...