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/noshufou/android/su/UninstallReceiver.java b/src/com/noshufou/android/su/UninstallReceiver.java index 6a5659a..cbbd2d0 100644 --- a/src/com/noshufou/android/su/UninstallReceiver.java +++ b/src/com/noshufou/android/su/UninstallReceiver.java @@ -1,16 +1,17 @@ package com.noshufou.android.su; impo...
true
true
public void onReceive(Context context, Intent intent) { DBHelper db = new DBHelper(context); int uid = intent.getIntExtra(Intent.EXTRA_UID, 0); if (uid != 1 && !(intent.getBooleanExtra(Intent.EXTRA_REPLACING, false))) { db.deleteByUid(uid); } }
public void onReceive(Context context, Intent intent) { DBHelper db = new DBHelper(context); int uid = intent.getIntExtra(Intent.EXTRA_UID, 0); if (uid != 1 && !(intent.getBooleanExtra(Intent.EXTRA_REPLACING, false))) { db.deleteByUid(uid); } db.close(); }
diff --git a/src/main/java/hudson/plugins/promoted_builds/conditions/DownstreamPassCondition.java b/src/main/java/hudson/plugins/promoted_builds/conditions/DownstreamPassCondition.java index 7f28572..1c4d289 100644 --- a/src/main/java/hudson/plugins/promoted_builds/conditions/DownstreamPassCondition.java +++ b/src/main...
true
true
public void onCompleted(AbstractBuild<?,?> build, TaskListener listener) { // this is not terribly efficient, for(AbstractProject<?,?> j : Hudson.getInstance().getAllItems(AbstractProject.class)) { JobPropertyImpl p = j.getProperty(JobPropertyImpl.class); ...
public void onCompleted(AbstractBuild<?,?> build, TaskListener listener) { // this is not terribly efficient, for(AbstractProject<?,?> j : Hudson.getInstance().getAllItems(AbstractProject.class)) { JobPropertyImpl p = j.getProperty(JobPropertyImpl.class); ...
diff --git a/org/mailster/smtp/SmtpMessage.java b/org/mailster/smtp/SmtpMessage.java index 602d72e..aefe7b9 100644 --- a/org/mailster/smtp/SmtpMessage.java +++ b/org/mailster/smtp/SmtpMessage.java @@ -1,378 +1,378 @@ /* * Dumbster - a dummy SMTP server Copyright 2004 Jason Paul Kitchen Licensed * under the Apache ...
true
true
public void store(SmtpResponse response, String params) { boolean log = response.getNextState() == SmtpState.DATA_HDR || response.getNextState() == SmtpState.DATA_BODY; if (params != null) { if (SmtpState.DATA_HDR == response.getNextState()) he...
public void store(SmtpResponse response, String params) { boolean log = response.getNextState() == SmtpState.DATA_HDR || response.getNextState() == SmtpState.DATA_BODY; if (params != null) { if (SmtpState.DATA_HDR == response.getNextState()) he...
diff --git a/src/com/android/nfc/NfcService.java b/src/com/android/nfc/NfcService.java index b551829..9f6cd7f 100755 --- a/src/com/android/nfc/NfcService.java +++ b/src/com/android/nfc/NfcService.java @@ -1,2159 +1,2169 @@ /* * Copyright (C) 2010 The Android Open Source Project * * Licensed under the Apache Lice...
true
true
public void handleMessage(Message msg) { switch (msg.what) { case MSG_MOCK_NDEF: { NdefMessage ndefMsg = (NdefMessage) msg.obj; Bundle extras = new Bundle(); extras.putParcelable(Ndef.EXTRA_NDEF_MSG, ndefMsg); ...
public void handleMessage(Message msg) { switch (msg.what) { case MSG_MOCK_NDEF: { NdefMessage ndefMsg = (NdefMessage) msg.obj; Bundle extras = new Bundle(); extras.putParcelable(Ndef.EXTRA_NDEF_MSG, ndefMsg); ...
diff --git a/contentconnector/contentconnector-lucene/src/main/java/com/gentics/cr/lucene/indexer/index/LuceneDirectoryFactory.java b/contentconnector/contentconnector-lucene/src/main/java/com/gentics/cr/lucene/indexer/index/LuceneDirectoryFactory.java index d15fbe1c..78e59e95 100644 --- a/contentconnector/contentconne...
true
true
private static Directory createDirectory(final String directoryLocation, final CRConfig config) { Directory dir; if (RAM_IDENTIFICATION_KEY.equalsIgnoreCase(directoryLocation) || directoryLocation == null || directoryLocation.startsWith(RAM_IDENTIFICATION_KEY)) { dir = createRAMDirectory(directoryLocat...
private static Directory createDirectory(final String directoryLocation, final CRConfig config) { Directory dir; if (RAM_IDENTIFICATION_KEY.equalsIgnoreCase(directoryLocation) || directoryLocation == null || directoryLocation.startsWith(RAM_IDENTIFICATION_KEY)) { dir = createRAMDirectory(directoryLocat...
diff --git a/plugins/sonar-squid-java-plugin/src/test/java/org/sonar/java/bytecode/loader/JarLoaderTest.java b/plugins/sonar-squid-java-plugin/src/test/java/org/sonar/java/bytecode/loader/JarLoaderTest.java index 4fd70f11f9..efde0f4d36 100644 --- a/plugins/sonar-squid-java-plugin/src/test/java/org/sonar/java/bytecode/l...
true
true
public void testFindResource() throws Exception { File jar = SquidTestUtils.getFile("/bytecode/lib/hello.jar"); JarLoader jarLoader = new JarLoader(jar); URL url = jarLoader.findResource("META-INF/MANIFEST.MF"); assertThat(url.toString(), allOf(startsWith("jar:"), endsWith("/bytecode/lib/hello.jar!/M...
public void testFindResource() throws Exception { File jar = SquidTestUtils.getFile("/bytecode/lib/hello.jar"); JarLoader jarLoader = new JarLoader(jar); URL url = jarLoader.findResource("META-INF/MANIFEST.MF"); assertThat(url.toString(), allOf(startsWith("jar:"), endsWith("hello.jar!/META-INF/MANIFE...
diff --git a/backends/gdx-backend-android/src/com/badlogic/gdx/backends/android/AndroidGraphics.java b/backends/gdx-backend-android/src/com/badlogic/gdx/backends/android/AndroidGraphics.java index 463d161f0..0d9a8cb8a 100644 --- a/backends/gdx-backend-android/src/com/badlogic/gdx/backends/android/AndroidGraphics.java +...
true
true
public void onDrawFrame(javax.microedition.khronos.opengles.GL10 gl) { long time = System.nanoTime(); deltaTime = (time - lastFrameTime) / 1000000000.0f; lastFrameTime = time; mean.addValue(deltaTime); boolean lrunning = false; boolean lpause = false; boolean...
public void onDrawFrame(javax.microedition.khronos.opengles.GL10 gl) { long time = System.nanoTime(); deltaTime = (time - lastFrameTime) / 1000000000.0f; lastFrameTime = time; mean.addValue(deltaTime); boolean lrunning = false; boolean lpause = false; boolean...
diff --git a/src/org/apache/xerces/jaxp/validation/ValidatorHandlerImpl.java b/src/org/apache/xerces/jaxp/validation/ValidatorHandlerImpl.java index ee4f3ff5e..a9ed4f515 100644 --- a/src/org/apache/xerces/jaxp/validation/ValidatorHandlerImpl.java +++ b/src/org/apache/xerces/jaxp/validation/ValidatorHandlerImpl.java @@ ...
true
true
public void validate(Source source, Result result) throws SAXException, IOException { if (result instanceof SAXResult || result == null) { final SAXSource saxSource = (SAXSource) source; final SAXResult saxResult = (SAXResult) result; LexicalHandler ...
public void validate(Source source, Result result) throws SAXException, IOException { if (result instanceof SAXResult || result == null) { final SAXSource saxSource = (SAXSource) source; final SAXResult saxResult = (SAXResult) result; LexicalHandler ...
diff --git a/src/java/org/infoglue/deliver/taglib/common/XSLTransformTag.java b/src/java/org/infoglue/deliver/taglib/common/XSLTransformTag.java index aa23e6870..1f65f6db6 100755 --- a/src/java/org/infoglue/deliver/taglib/common/XSLTransformTag.java +++ b/src/java/org/infoglue/deliver/taglib/common/XSLTransformTag.java...
true
true
public int doEndTag() throws JspException { Timer timer = new Timer(); java.lang.System.setProperty("javax.xml.transform.TransformerFactory", "net.sf.saxon.TransformerFactoryImpl"); Source xmlSource = null; if(xml != null) { if(xml instanceof String) xmlSource = new StreamSource(new Strin...
public int doEndTag() throws JspException { Timer timer = new Timer(); java.lang.System.setProperty("javax.xml.transform.TransformerFactory", "net.sf.saxon.TransformerFactoryImpl"); Source xmlSource = null; if(xml != null) { if(xml instanceof String) xmlSource = new StreamSource(new Strin...
diff --git a/cost-server/src/main/java/com/unisys/ch/jax/costserver/controller/CostController.java b/cost-server/src/main/java/com/unisys/ch/jax/costserver/controller/CostController.java index 66c6b32..58cffed 100644 --- a/cost-server/src/main/java/com/unisys/ch/jax/costserver/controller/CostController.java +++ b/cost-...
true
true
public Collection<Cost> list(@RequestParam(value = "page", required = false) Integer page, @RequestParam(value = "pageSize", required = false) Integer pageSize) { if (page == null) { page = 1; } if (pageSize == null){ pageSize = Intege...
public Collection<Cost> list(@RequestParam(value = "page", required = false) Integer page, @RequestParam(value = "pageSize", required = false) Integer pageSize) { if (page == null) { page = 1; } if (pageSize == null){ pageSize = 100000...
diff --git a/src/main/java/org/londonsburning/proxy/ProxyPrinterRunner.java b/src/main/java/org/londonsburning/proxy/ProxyPrinterRunner.java index 544bef8..9aa833e 100644 --- a/src/main/java/org/londonsburning/proxy/ProxyPrinterRunner.java +++ b/src/main/java/org/londonsburning/proxy/ProxyPrinterRunner.java @@ -1,45 +1...
true
true
public static void main(final String[] args) { String applicationContext = "applicationContext.xml"; ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext(applicationContext); FlagParser flagParser = (FlagParser) context.getBean("flagParser"); fl...
public static void main(final String[] args) { String applicationContext = "applicationContext.xml"; ClassPathXmlApplicationContext context = new ClassPathXmlApplicationContext(applicationContext); FlagParser flagParser = (FlagParser) context.getBean("flagParser"); fl...
diff --git a/graylog2-server/src/test/java/org/graylog2/plugin/MessageTest.java b/graylog2-server/src/test/java/org/graylog2/plugin/MessageTest.java index d7701ab28..e14eecd83 100644 --- a/graylog2-server/src/test/java/org/graylog2/plugin/MessageTest.java +++ b/graylog2-server/src/test/java/org/graylog2/plugin/MessageT...
true
true
public void testAddFieldDoesOnlyAcceptAlphanumericKeys() throws Exception { Message m = new Message("foo", "bar", new DateTime()); m.addField("some_thing", "bar"); assertEquals("bar", m.getField("some_thing")); m = new Message("foo", "bar", new DateTime()); m.addField("some-...
public void testAddFieldDoesOnlyAcceptAlphanumericKeys() throws Exception { Message m = new Message("foo", "bar", new DateTime()); m.addField("some_thing", "bar"); assertEquals("bar", m.getField("some_thing")); m = new Message("foo", "bar", new DateTime()); m.addField("some-...
diff --git a/src/com/android/camera/Util.java b/src/com/android/camera/Util.java index d6ebb0a5..c7d85830 100644 --- a/src/com/android/camera/Util.java +++ b/src/com/android/camera/Util.java @@ -1,718 +1,718 @@ /* * Copyright (C) 2009 The Android Open Source Project * * Licensed under the Apache License, Version...
true
true
public static Size getOptimalPreviewSize(Activity currentActivity, List<Size> sizes, double targetRatio) { // Use a very small tolerance because we want an exact match. final double ASPECT_TOLERANCE = 0.001; if (sizes == null) return null; Size optimalSize = null; ...
public static Size getOptimalPreviewSize(Activity currentActivity, List<Size> sizes, double targetRatio) { // Not too small tolerance, some camera use 848, 854 or 864 for 480p final double ASPECT_TOLERANCE = 0.05; if (sizes == null) return null; Size optimalSize = null; ...
diff --git a/src/main/java/org/otherobjects/cms/validation/TypeDefConfiguredValidator.java b/src/main/java/org/otherobjects/cms/validation/TypeDefConfiguredValidator.java index d4f4fcf7..63f096f3 100644 --- a/src/main/java/org/otherobjects/cms/validation/TypeDefConfiguredValidator.java +++ b/src/main/java/org/otherobje...
true
true
public void validate(Object target, Errors errors) { TypeDef typeDef; if (target instanceof BaseNode) typeDef = ((BaseNode)target).getTypeDef(); else typeDef = typeService.getType(target.getClass()); StringBuffer valangRules = new StringBuffer(); ...
public void validate(Object target, Errors errors) { TypeDef typeDef; if (target instanceof BaseNode) typeDef = ((BaseNode)target).getTypeDef(); else typeDef = typeService.getType(target.getClass()); StringBuffer valangRules = new StringBuffer(); ...
diff --git a/FileList.java b/FileList.java index 3372251..c180343 100644 --- a/FileList.java +++ b/FileList.java @@ -1,76 +1,88 @@ import java.io.*; import java.nio.MappedByteBuffer; import java.nio.channels.FileChannel; import java.text.*; import java.util.Date; import SevenZip.Compression.LZMA.Decoder; pub...
false
true
private FileList() { try { ByteArrayOutputStream out = new ByteArrayOutputStream(); RandomAccessFile in = new RandomAccessFile("files.lzma", "r"); MappedByteBuffer buf = in.getChannel().map(FileChannel.MapMode.READ_ONLY, 0, in.length()); in.close(); Decoder decoder = new Decoder(); decoder.SetDeco...
private FileList() { try { ByteArrayOutputStream out = new ByteArrayOutputStream(); //TODO: less ugliness here File tmp = File.createTempFile("files", ".lzma"); { InputStream tmpin = this.getClass().getClassLoader().getResourceAsStream("files.lzma"); FileOutputStream tmpout = new FileOutputStream...
diff --git a/src/state/Octodude.java b/src/state/Octodude.java index 2e3d7cc..76bdd8f 100644 --- a/src/state/Octodude.java +++ b/src/state/Octodude.java @@ -1,80 +1,87 @@ /** * */ package state; import java.awt.Color; import java.awt.Graphics; import java.awt.Image; import java.awt.Point; import java.io.Se...
true
true
public void draw(Graphics g, Display d, int bottomPixelX, int bottomPixelY, boolean drawHealth){ double percentMoved = count * 0.25; // Tile coordinates of The Dude (x,y) double x = this.oldX + (this.x - this.oldX) * percentMoved; double y = this.oldY + (this.y - this.oldY) * percentMoved; // Pixel coo...
public void draw(Graphics g, Display d, int bottomPixelX, int bottomPixelY, boolean drawHealth){ double percentMoved = count * 0.25; // Tile coordinates of The Dude (x,y) double x, y; if(attacking == null) { x = this.oldX + (this.x - this.oldX) * percentMoved; y = this.oldY + (this.y - this.oldY) * ...
diff --git a/src/ibis/satin/impl/Statistics.java b/src/ibis/satin/impl/Statistics.java index 9d633a06..3772d3ba 100644 --- a/src/ibis/satin/impl/Statistics.java +++ b/src/ibis/satin/impl/Statistics.java @@ -1,766 +1,766 @@ /* $Id: StatsMessage.java 3698 2006-04-28 11:27:17Z rob $ */ package ibis.satin.impl; impo...
true
true
protected void printStats(int size, double totalTime) { java.io.PrintStream out = System.out; java.text.NumberFormat nf = java.text.NumberFormat.getInstance(); // for percentages java.text.NumberFormat pf = java.text.NumberFormat.getInstance(); pf.setMaximumFractionDigits(3)...
protected void printStats(int size, double totalTime) { java.io.PrintStream out = System.out; java.text.NumberFormat nf = java.text.NumberFormat.getInstance(); // for percentages java.text.NumberFormat pf = java.text.NumberFormat.getInstance(); pf.setMaximumFractionDigits(3)...
diff --git a/src/com/android/email/MessagingController.java b/src/com/android/email/MessagingController.java index 02996f98..a706ab92 100644 --- a/src/com/android/email/MessagingController.java +++ b/src/com/android/email/MessagingController.java @@ -1,2107 +1,2112 @@ /* * Copyright (C) 2008 The Android Open Source ...
true
true
private StoreSynchronizer.SyncResults synchronizeMailboxGeneric( final EmailContent.Account account, final EmailContent.Mailbox folder) throws MessagingException { Log.d(Email.LOG_TAG, "*** synchronizeMailboxGeneric ***"); ContentResolver resolver = mContext.getContentResolv...
private StoreSynchronizer.SyncResults synchronizeMailboxGeneric( final EmailContent.Account account, final EmailContent.Mailbox folder) throws MessagingException { Log.d(Email.LOG_TAG, "*** synchronizeMailboxGeneric ***"); ContentResolver resolver = mContext.getContentResolv...
diff --git a/n3phele/src/n3phele/service/lifecycle/ProcessLifecycle.java b/n3phele/src/n3phele/service/lifecycle/ProcessLifecycle.java index 629e128..6aa0ba1 100644 --- a/n3phele/src/n3phele/service/lifecycle/ProcessLifecycle.java +++ b/n3phele/src/n3phele/service/lifecycle/ProcessLifecycle.java @@ -1,1112 +1,1113 @@ ...
true
true
private boolean dispatch(final URI processId, final Date stamp) { NextStep dispatchCode = CloudProcessResource.dao.transact(new Work<NextStep>() { public NextStep run() { log.info(">>>>>>>>>Dispatch "+processId); CloudProcess process = CloudProcessResource.dao.load(processId); if(proces...
private boolean dispatch(final URI processId, final Date stamp) { NextStep dispatchCode = CloudProcessResource.dao.transact(new Work<NextStep>() { public NextStep run() { log.info(">>>>>>>>>Dispatch "+processId); CloudProcess process = CloudProcessResource.dao.load(processId); if(proces...
diff --git a/ui/plugins/eu.esdihumboldt.hale.ui/src/eu/esdihumboldt/hale/ui/io/source/FileSourceFileFieldEditor.java b/ui/plugins/eu.esdihumboldt.hale.ui/src/eu/esdihumboldt/hale/ui/io/source/FileSourceFileFieldEditor.java index 93c730a03..6485765fc 100644 --- a/ui/plugins/eu.esdihumboldt.hale.ui/src/eu/esdihumboldt/ha...
true
true
protected boolean checkState() { String msg = null; String path = getTextControl().getText(); if (path != null) { path = path.trim(); } else { path = "";//$NON-NLS-1$ } if (path.length() == 0) { if (!isEmptyStringAllowed()) { msg = getErrorMessage(); } } else { File file = resolve...
protected boolean checkState() { String msg = null; String path = getTextControl().getText(); if (path != null) { path = path.trim(); } else { path = "";//$NON-NLS-1$ } if (path.length() == 0) { if (!isEmptyStringAllowed()) { msg = getErrorMessage(); } } else { File file = resolve...
diff --git a/modules/world/avatarbase/src/classes/org/jdesktop/wonderland/modules/avatarbase/client/jme/cellrenderer/GestureHUD.java b/modules/world/avatarbase/src/classes/org/jdesktop/wonderland/modules/avatarbase/client/jme/cellrenderer/GestureHUD.java index 6bf99afdf..898b297a8 100644 --- a/modules/world/avatarbase/...
true
true
public void setAvatarCharacter(final WlAvatarCharacter avatar) { SwingUtilities.invokeLater(new Runnable() { public void run() { if (mainHUD == null) { mainHUD = HUDManagerFactory.getHUDManager().getHUD("main"); } // remove e...
public void setAvatarCharacter(final WlAvatarCharacter avatar) { SwingUtilities.invokeLater(new Runnable() { public void run() { if (mainHUD == null) { mainHUD = HUDManagerFactory.getHUDManager().getHUD("main"); } // remove e...
diff --git a/SlidingLayerSample/src/com/slidinglayer/SlidingLayer.java b/SlidingLayerSample/src/com/slidinglayer/SlidingLayer.java index 70b60d6..6cfe5c6 100644 --- a/SlidingLayerSample/src/com/slidinglayer/SlidingLayer.java +++ b/SlidingLayerSample/src/com/slidinglayer/SlidingLayer.java @@ -1,877 +1,877 @@ /* * Sli...
true
true
public boolean onTouchEvent(MotionEvent ev) { if (!mEnabled || !mIsDragging && !mLastTouchAllowed && !allowSlidingFromHere(ev)) { return false; } final int action = ev.getAction(); if (action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_CANCEL ...
public boolean onTouchEvent(MotionEvent ev) { if (!mEnabled || !mIsDragging && !mLastTouchAllowed && !allowSlidingFromHere(ev)) { return false; } final int action = ev.getAction(); if (action == MotionEvent.ACTION_UP || action == MotionEvent.ACTION_CANCEL ...
diff --git a/src/main/java/at/molindo/esi4j/rebuild/BulkIndexHelper.java b/src/main/java/at/molindo/esi4j/rebuild/BulkIndexHelper.java index 5187743..9e2e6cf 100644 --- a/src/main/java/at/molindo/esi4j/rebuild/BulkIndexHelper.java +++ b/src/main/java/at/molindo/esi4j/rebuild/BulkIndexHelper.java @@ -1,175 +1,176 @@ /*...
true
true
public void bulkIndex(List<?> list) { final int listSize = list.size(); ListenableActionFuture<BulkResponseWrapper> future = _index.bulkIndex(list); _lock.lock(); try { while (_running >= _maxRunning) { try { _nextCompleted.await(); } catch (InterruptedException e) { throw new RuntimeEx...
public void bulkIndex(List<?> list) { final int listSize = list.size(); ListenableActionFuture<BulkResponseWrapper> future = _index.bulkIndex(list); _lock.lock(); try { while (_running >= _maxRunning) { try { _nextCompleted.await(); } catch (InterruptedException e) { throw new RuntimeEx...
diff --git a/src/main/java/org/mgenterprises/java/bukkit/gmcfps/Core/BasicCommands/GameManagementCommands.java b/src/main/java/org/mgenterprises/java/bukkit/gmcfps/Core/BasicCommands/GameManagementCommands.java index f8a682e..1702374 100644 --- a/src/main/java/org/mgenterprises/java/bukkit/gmcfps/Core/BasicCommands/Gam...
true
true
private boolean processWizard(CommandSender cs, String[] args) { Player p = (Player) cs; if (!p.hasPermission("gfps.create") && !p.isOp()) { return true; } if (args.length > 2 && args[0].equals("create")) { Game newGame = new Game(gameManager.getPluginReferenc...
private boolean processWizard(CommandSender cs, String[] args) { Player p = (Player) cs; if (!p.hasPermission("gfps.create") && !p.isOp()) { p.sendRawMessage(ChatColor.RED+"You do not have permission"); return true; } if (args.length > 2 && args[0].equals("cre...
diff --git a/rwiki-tool/tool/src/java/uk/ac/cam/caret/sakai/rwiki/tool/service/impl/CommandServiceImpl.java b/rwiki-tool/tool/src/java/uk/ac/cam/caret/sakai/rwiki/tool/service/impl/CommandServiceImpl.java index 4177627e..5534acb0 100644 --- a/rwiki-tool/tool/src/java/uk/ac/cam/caret/sakai/rwiki/tool/service/impl/Comman...
true
true
public void execute(Dispatcher dispatcher,HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { String actionPath = MessageFormat.format(template, new Object[] { action }); try { dispatcher.dispatch(actionPath, request, response); if ( trackRe...
public void execute(Dispatcher dispatcher,HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { String actionPath = MessageFormat.format(template, new Object[] { action }); try { dispatcher.dispatch(actionPath, request, response); if ( trackRe...
diff --git a/src/autosaveworld/commands/CommandsHandler.java b/src/autosaveworld/commands/CommandsHandler.java index 3c4577e..e9e1d97 100644 --- a/src/autosaveworld/commands/CommandsHandler.java +++ b/src/autosaveworld/commands/CommandsHandler.java @@ -1,233 +1,233 @@ /** * This program is free software; you can red...
true
true
public boolean onCommand(CommandSender sender, Command command, String commandLabel, String[] args) { String commandName = command.getName().toLowerCase(); //check permissions if (!permCheck.isAllowed(sender, commandName, args, config.commandonlyfromconsole)) { plugin.sendMessage(sender, configmsg.message...
public boolean onCommand(CommandSender sender, Command command, String commandLabel, String[] args) { String commandName = command.getName().toLowerCase(); //check permissions if (!permCheck.isAllowed(sender, commandName, args, config.commandonlyfromconsole)) { plugin.sendMessage(sender, configmsg.message...
diff --git a/src/gb-actions-unredd/script/src/main/java/it/geosolutions/geobatch/unredd/script/util/rasterize/GDALRasterize.java b/src/gb-actions-unredd/script/src/main/java/it/geosolutions/geobatch/unredd/script/util/rasterize/GDALRasterize.java index a78f300..0f321d5 100644 --- a/src/gb-actions-unredd/script/src/main...
true
true
private File taskExecutor(File inputFile, File errorFile) throws IOException, ActionException { if (LOGGER.isDebugEnabled()) { LOGGER.debug("--------------------- TaskExecutor - rasterization ----------------"); } final TaskExecutorConfiguration teConfig = new TaskExecutorConfig...
private File taskExecutor(File inputFile, File errorFile) throws IOException, ActionException { if (LOGGER.isDebugEnabled()) { LOGGER.debug("--------------------- TaskExecutor - rasterization ----------------"); } final TaskExecutorConfiguration teConfig = new TaskExecutorConfig...
diff --git a/anglewyrm/src/ColoniesMain.java b/anglewyrm/src/ColoniesMain.java index 6c7422c..2415604 100644 --- a/anglewyrm/src/ColoniesMain.java +++ b/anglewyrm/src/ColoniesMain.java @@ -1,124 +1,125 @@ package colonies.anglewyrm.src; import java.util.ArrayList; import java.util.List; import colonies.vector67...
true
true
private void registerColoniesStuff() { // List of towns // TODO: find a way to save/load this data structure townsList = new ArrayList<TownHall>(); // Chest block chestBlock = new BlockColoniesChest(ConfigFile.parseInt("DefaultChestID")); LanguageRegistry.addName(chestBlock, "Colonies Chest"); GameRe...
private void registerColoniesStuff() { // List of towns // TODO: find a way to save/load this data structure townsList = new ArrayList<TownHall>(); // Chest block chestBlock = new BlockColoniesChest(ConfigFile.parseInt("DefaultChestID")); LanguageRegistry.addName(chestBlock, "Colonies Chest"); GameRe...
diff --git a/src/com/diycomputerscience/minesweepercore/RandomBoardInitializer.java b/src/com/diycomputerscience/minesweepercore/RandomBoardInitializer.java index c0935d1..ad4cf36 100644 --- a/src/com/diycomputerscience/minesweepercore/RandomBoardInitializer.java +++ b/src/com/diycomputerscience/minesweepercore/RandomB...
false
true
private List<Point> getRandonMinesForRow(int row, int mines) { List<Point> points = new ArrayList<Point>(); for(int j=0; j<mines; j++) { int col = getMineCountForThisRow(); boolean addedMine = false; while(!addedMine) { Point mine = new Point(row, col); if(!points.contains(mine)) { poin...
private List<Point> getRandonMinesForRow(int row, int mines) { List<Point> points = new ArrayList<Point>(); for(int j=0; j<mines; j++) { boolean addedMine = false; while(!addedMine) { int col = getMineCountForThisRow(); Point mine = new Point(row, col); if(!points.contains(mine)) { p...
diff --git a/Portal_DB-portlet/docroot/WEB-INF/src/org/goodreturn/story/portlet/StoryValidator.java b/Portal_DB-portlet/docroot/WEB-INF/src/org/goodreturn/story/portlet/StoryValidator.java index aa9fe13..15916ec 100644 --- a/Portal_DB-portlet/docroot/WEB-INF/src/org/goodreturn/story/portlet/StoryValidator.java +++ b/Po...
true
true
public static boolean validateStory(Story finalStory, List errors) { return false; }
public static boolean validateStory(Story story, List errors) { return false; }
diff --git a/HW3/SetupUI.java b/HW3/SetupUI.java index 2e24d34..8770fca 100644 --- a/HW3/SetupUI.java +++ b/HW3/SetupUI.java @@ -1,156 +1,155 @@ import java.util.List; import java.util.LinkedList; import java.util.Scanner; /** * Provides the saffolding to get the game up and running. Prompts * the user for ...
true
true
public void inputSetupGame() { Scanner userInput= new Scanner(System.in); // Get their name int tries= 0; String name= null; while( name == null && tries++ < 3 ) name= inputPlayerName( userInput ); // The player doesn't want to play? if( name == nu...
public void inputSetupGame() { Scanner userInput= new Scanner(System.in); // Get their name int tries= 0; String name= null; while( name == null && tries++ < 3 ) name= inputPlayerName( userInput ); // The player doesn't want to play? if( name == nu...
diff --git a/Tetris/src/net/foxycorndog/tetris/board/Board.java b/Tetris/src/net/foxycorndog/tetris/board/Board.java index 875e839..44a6b52 100644 --- a/Tetris/src/net/foxycorndog/tetris/board/Board.java +++ b/Tetris/src/net/foxycorndog/tetris/board/Board.java @@ -1,655 +1,658 @@ package net.foxycorndog.tetris.board; ...
true
true
public Board(int width, int height, int gridSpaceSize, final Tetris tetris) { super(width, height, gridSpaceSize); this.tetris = tetris; events = new ArrayList<BoardListener>(); pressStartTime = Long.MAX_VALUE; keyListener = new KeyListener() { public void keyPressed(KeyEvent event) { if (...
public Board(int width, int height, int gridSpaceSize, final Tetris tetris) { super(width, height, gridSpaceSize); this.tetris = tetris; events = new ArrayList<BoardListener>(); pressStartTime = Long.MAX_VALUE; keyListener = new KeyListener() { public void keyPressed(KeyEvent event) { if (...
diff --git a/src/game/ChoiceStorage.java b/src/game/ChoiceStorage.java index 8d43b7d..6b17f39 100644 --- a/src/game/ChoiceStorage.java +++ b/src/game/ChoiceStorage.java @@ -1,620 +1,620 @@ package game; import java.util.ArrayList; public class ChoiceStorage { private int currentChoice = -1; private ArrayList...
true
true
public ChoiceStorage(Person p) { // Choice1 final Requirements hr1[] = { new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0) }; ...
public ChoiceStorage(Person p) { // Choice1 final Requirements hr1[] = { new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0), new Requirements(0, 0, 0, 0, 0) }; ...
diff --git a/strategoxt-java-backend/java/runtime/org/strategoxt/lang/compat/report_failure_compat_1_0.java b/strategoxt-java-backend/java/runtime/org/strategoxt/lang/compat/report_failure_compat_1_0.java index ba863fcaa..8ba14d14a 100644 --- a/strategoxt-java-backend/java/runtime/org/strategoxt/lang/compat/report_fail...
true
true
public IStrategoTerm invoke(Context context, IStrategoTerm current, Strategy s) { synchronized (this) { String[] trace = context.getTrace(); try { logIntercept.proceed = log_0_2.instance; logIntercept.enabled = true; log_0_2.instance = logIntercept; return proceed.invoke(context, current, ...
public IStrategoTerm invoke(Context context, IStrategoTerm current, Strategy s) { synchronized (this) { String[] trace = context.getTrace(); try { logIntercept.proceed = log_0_2.instance; logIntercept.enabled = true; log_0_2.instance = logIntercept; return proceed.invoke(context, current, ...
diff --git a/javafxdoc/src/com/sun/tools/javafxdoc/Start.java b/javafxdoc/src/com/sun/tools/javafxdoc/Start.java index d2119faf8..07158bccc 100644 --- a/javafxdoc/src/com/sun/tools/javafxdoc/Start.java +++ b/javafxdoc/src/com/sun/tools/javafxdoc/Start.java @@ -1,485 +1,490 @@ /* * Copyright 2008-2009 Sun Microsystem...
false
true
private boolean parseAndExecute(String argv[]) throws IOException { long tm = System.currentTimeMillis(); ListBuffer<String> javaNames = new ListBuffer<String>(); // Preprocess @file arguments try { argv = CommandLine.parse(argv); } catch (FileNotFoundException ...
private boolean parseAndExecute(String argv[]) throws IOException { long tm = System.currentTimeMillis(); ListBuffer<String> javaNames = new ListBuffer<String>(); // Preprocess @file arguments try { argv = CommandLine.parse(argv); } catch (FileNotFoundException ...
diff --git a/src/com/episode6/android/common/ui/widget/HandyListView.java b/src/com/episode6/android/common/ui/widget/HandyListView.java index 0c16995..3bdb5fc 100644 --- a/src/com/episode6/android/common/ui/widget/HandyListView.java +++ b/src/com/episode6/android/common/ui/widget/HandyListView.java @@ -1,83 +1,83 @@ ...
false
true
public void setAdapter(ListAdapter adapter) { super.setAdapter(adapter); if (mLoadingListView != null) mLoadingListView.setVisibility(View.GONE); setVisibility(View.VISIBLE); setEmptyView(mEmptyListView); mEmptyListView = null; }
public void setAdapter(ListAdapter adapter) { if (mLoadingListView != null) mLoadingListView.setVisibility(View.GONE); setVisibility(View.VISIBLE); super.setEmptyView(mEmptyListView); mEmptyListView = null; super.setAdapter(adapter); }
diff --git a/src/main/java/com/orbekk/protobuf/RequestDispatcher.java b/src/main/java/com/orbekk/protobuf/RequestDispatcher.java index b0a4600..6af6e5e 100644 --- a/src/main/java/com/orbekk/protobuf/RequestDispatcher.java +++ b/src/main/java/com/orbekk/protobuf/RequestDispatcher.java @@ -1,119 +1,119 @@ package com.or...
false
true
public void internalRun() throws InterruptedException { Service service = services.get(request.getFullServiceName()); if (service == null) { response.setError(Data.Response.RpcError.UNKNOWN_SERVICE); output.put(response.build()); return; ...
public void internalRun() throws InterruptedException { response.setRequestId(request.getRequestId()); Service service = services.get(request.getFullServiceName()); if (service == null) { response.setError(Data.Response.RpcError.UNKNOWN_SERVICE); ...
diff --git a/htmlunit/src/java/com/gargoylesoftware/htmlunit/Version.java b/htmlunit/src/java/com/gargoylesoftware/htmlunit/Version.java index 4e622b628..3db5ff304 100644 --- a/htmlunit/src/java/com/gargoylesoftware/htmlunit/Version.java +++ b/htmlunit/src/java/com/gargoylesoftware/htmlunit/Version.java @@ -1,81 +1,81 ...
true
true
public static void main( final String args[] ) throws Exception { if( args.length == 1 && args[0].equals("-SanityCheck") ) { new Version().runSanityCheck(); return; } final Package aPackage = Package.getPackage("com.gargoylesoftware.htmlunit"); System.out.pr...
public static void main( final String args[] ) throws Exception { if( args.length == 1 && args[0].equals("-SanityCheck") ) { new Version().runSanityCheck(); return; } final Package aPackage = Package.getPackage("com.gargoylesoftware.htmlunit"); System.out.pr...
diff --git a/GuitarScoreVisualizer/src/main/java/com/livejournal/karino2/guitarscorevisualizer/EditActivity.java b/GuitarScoreVisualizer/src/main/java/com/livejournal/karino2/guitarscorevisualizer/EditActivity.java index 245e974..9f75840 100644 --- a/GuitarScoreVisualizer/src/main/java/com/livejournal/karino2/guitarsco...
true
true
public boolean onOptionsItemSelected(MenuItem item) { switch(item.getItemId()) { case R.id.action_edit: saveScoreIfNecessary(); setResult(Activity.RESULT_OK); finish(); return true; case android.R.id.home: ...
public boolean onOptionsItemSelected(MenuItem item) { switch(item.getItemId()) { case R.id.action_save: saveScoreIfNecessary(); setResult(Activity.RESULT_OK); finish(); return true; case android.R.id.home: ...
diff --git a/src/HashTable.java b/src/HashTable.java index fcb26ed..e88bd92 100644 --- a/src/HashTable.java +++ b/src/HashTable.java @@ -1,120 +1,118 @@ import java.math.BigInteger; /** * Provides the basic functionality for generating hash tables efficiently * using double hashing */ public abstract class H...
false
true
public static int getCoPrime(int bucketSize) { int a = CONSTANT_INTERVAL; int b = bucketSize; int c = 0; int newBucketSize = 0; // Quickly apply Euclid's Greatest Common Divisor algorithm, if while (b != 0) { c = b; b = a % b; a = c; } // If a is 1 then the bucketSize is co-prime with...
public static int getCoPrime(int bucketSize) { int a = CONSTANT_INTERVAL; int b = bucketSize; int c = 0; int newBucketSize = 0; // Quickly apply Euclid's Greatest Common Divisor algorithm, if while (b != 0) { c = b; b = a % b; a = c; } // If a is 1 then the bucketSize is co-prime with...
diff --git a/hudson-jetty-war-executable/src/main/java/org/eclipse/hudson/jetty/JettyLauncher.java b/hudson-jetty-war-executable/src/main/java/org/eclipse/hudson/jetty/JettyLauncher.java index 1b132816..cadd59ad 100644 --- a/hudson-jetty-war-executable/src/main/java/org/eclipse/hudson/jetty/JettyLauncher.java +++ b/hud...
true
true
public static void start(String[] args, URL warUrl) throws Exception { int httpPort = 8080; int httpsPort = -1; String keyStorePath = null; String keyStorePassword = null; for (int i = 0; i < args.length; i++) { if (args[i].startsWith("--httpPort=")) { ...
public static void start(String[] args, URL warUrl) throws Exception { int httpPort = 8080; int httpsPort = -1; String keyStorePath = null; String keyStorePassword = null; for (int i = 0; i < args.length; i++) { if (args[i].startsWith("--httpPort=")) { ...
diff --git a/resthub-core/src/main/java/org/resthub/core/util/PostInitializerRunner.java b/resthub-core/src/main/java/org/resthub/core/util/PostInitializerRunner.java index 2dff5fcf..d87f0a70 100644 --- a/resthub-core/src/main/java/org/resthub/core/util/PostInitializerRunner.java +++ b/resthub-core/src/main/java/org/re...
true
true
public void onApplicationEvent(ApplicationEvent event) { if (event instanceof ContextRefreshedEvent) { LOG.info("Scanning for Post Initializers..."); long startTime = System.currentTimeMillis(); ContextRefreshedEvent contextRefreshedEvent = (ContextRefreshedEvent) event; ...
public void onApplicationEvent(ApplicationEvent event) { if (event instanceof ContextRefreshedEvent) { LOG.info("Scanning for Post Initializers..."); long startTime = System.currentTimeMillis(); ContextRefreshedEvent contextRefreshedEvent = (ContextRefreshedEvent) event; ...
diff --git a/src/org/nutz/dao/impl/entity/field/OneLinkField.java b/src/org/nutz/dao/impl/entity/field/OneLinkField.java index 66af7b5af..dd82f44c8 100644 --- a/src/org/nutz/dao/impl/entity/field/OneLinkField.java +++ b/src/org/nutz/dao/impl/entity/field/OneLinkField.java @@ -1,53 +1,53 @@ package org.nutz.dao.impl.en...
true
true
public OneLinkField(Entity<?> entity, EntityHolder holder, LinkInfo info) { super(entity, holder, info); this.targetType = info.one.target(); // 宿主实体的字段 hostField = entity.getField(info.one.field()); if (null == hostField) throw Lang.makeThrow( "Invalid @One(field=%s) '%s' : %s<=>%s", info.one.fi...
public OneLinkField(Entity<?> entity, EntityHolder holder, LinkInfo info) { super(entity, holder, info); this.targetType = info.one.target(); // 宿主实体的字段 hostField = entity.getField(info.one.field()); if (null == hostField) throw Lang.makeThrow( "Invalid @One(field=%s) '%s' : %s<=>%s", info.one.fi...
diff --git a/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java b/plugins/org.jboss.tools.ws.jaxrs.core/src/org/jboss/tools/ws/jaxrs/core/internal/metamodel/validation/JaxrsJavaApplicationValidatorDelegate.java index b61901a1....
true
true
public void validate() throws CoreException { final JaxrsJavaApplication application = getElement(); deleteJaxrsMarkers(application.getResource()); final Annotation applicationPathAnnotation = application .getAnnotation(EnumJaxrsClassname.APPLICATION_PATH.qualifiedName); final IType appJavaElement = app...
public void validate() throws CoreException { final JaxrsJavaApplication application = getElement(); deleteJaxrsMarkers(application.getResource()); final Annotation applicationPathAnnotation = application .getAnnotation(EnumJaxrsClassname.APPLICATION_PATH.qualifiedName); final IType appJavaElement = app...
diff --git a/framework/freedomotic/src/it/freedomotic/util/PropertiesPanel_1.java b/framework/freedomotic/src/it/freedomotic/util/PropertiesPanel_1.java index 1f77bb1b..66d05cd0 100644 --- a/framework/freedomotic/src/it/freedomotic/util/PropertiesPanel_1.java +++ b/framework/freedomotic/src/it/freedomotic/util/Properti...
false
true
public synchronized void addElement(Component component, final int row, final int col) { if (component == null) { throw new IllegalArgumentException(); } try { table[row][col] = component; } catch (ArrayIndexOutOfBoundsException e) { Freedomotic.lo...
public synchronized void addElement(Component component, final int row, final int col) { if (component == null) { throw new IllegalArgumentException(); } try { table[row][col] = component; } catch (ArrayIndexOutOfBoundsException e) { Freedomotic.lo...
diff --git a/component/src/main/java/com/celements/photo/unpack/UnpackComponent.java b/component/src/main/java/com/celements/photo/unpack/UnpackComponent.java index 7c81527..a480149 100644 --- a/component/src/main/java/com/celements/photo/unpack/UnpackComponent.java +++ b/component/src/main/java/com/celements/photo/unp...
true
true
public String unzipFileToAttachment(XWikiAttachment zipSrcFile, String attName, DocumentReference destDocRef) { String cleanName = attName; if(zipSrcFile != null) { LOGGER.info("START unzip: zip='" + zipSrcFile.getFilename() + "' file='" + attName + "'"); if(isZipFile(zipSrcFile))...
public String unzipFileToAttachment(XWikiAttachment zipSrcFile, String attName, DocumentReference destDocRef) { String cleanName = attName; if(zipSrcFile != null) { LOGGER.info("START unzip: zip='" + zipSrcFile.getFilename() + "' file='" + attName + "'"); if(isZipFile(zipSrcFile))...
diff --git a/src/com/bigpupdev/synodroid/ui/SynodroidFragment.java b/src/com/bigpupdev/synodroid/ui/SynodroidFragment.java index ef03bdc..61d9ef8 100644 --- a/src/com/bigpupdev/synodroid/ui/SynodroidFragment.java +++ b/src/com/bigpupdev/synodroid/ui/SynodroidFragment.java @@ -1,247 +1,247 @@ /** * Copyright 2010 Eri...
false
true
public void handleMessage(Message msgP) { final Activity a = SynodroidFragment.this.getActivity(); final SynoServer server = ((Synodroid) a.getApplication()).getServer(); if (a != null){ Synodroid app = (Synodroid) a.getApplication(); Style msg_style = null; // According to the message switch...
public void handleMessage(Message msgP) { final Activity a = SynodroidFragment.this.getActivity(); if (a != null){ final SynoServer server = ((Synodroid) a.getApplication()).getServer(); Synodroid app = (Synodroid) a.getApplication(); Style msg_style = null; // According to the message switc...
diff --git a/src/no/runsafe/creativetoolbox/command/OldPlotsCommand.java b/src/no/runsafe/creativetoolbox/command/OldPlotsCommand.java index e8e0be9..4f01686 100644 --- a/src/no/runsafe/creativetoolbox/command/OldPlotsCommand.java +++ b/src/no/runsafe/creativetoolbox/command/OldPlotsCommand.java @@ -1,150 +1,150 @@ pa...
false
true
public String OnExecute(RunsafePlayer executor, String[] args) { if (!worldGuard.serverHasWorldGuard()) return "Unable to find WorldGuard!"; StringBuilder result = new StringBuilder(); Date now = new Date(); int count = 0; ArrayList<String> banned = new ArrayList<String>(); List<String> approved; ap...
public String OnExecute(RunsafePlayer executor, String[] args) { if (!worldGuard.serverHasWorldGuard()) return "Unable to find WorldGuard!"; StringBuilder result = new StringBuilder(); Date now = new Date(); int count = 0; ArrayList<String> banned = new ArrayList<String>(); List<String> approved; ap...
diff --git a/src/com/vhly/epubmaker/TxtSplit.java b/src/com/vhly/epubmaker/TxtSplit.java index 8f81702..3376fc3 100644 --- a/src/com/vhly/epubmaker/TxtSplit.java +++ b/src/com/vhly/epubmaker/TxtSplit.java @@ -1,192 +1,195 @@ package com.vhly.epubmaker; import java.io.*; import java.util.regex.Matcher; import java...
true
true
public static void main(String[] args) { int argc = args.length; if (argc != 2) { System.out.println("Usage: TxtSplit <txt> <target folder>"); } else { File file = new File(args[0]); if (file.exists() && file.canRead()) { File targetDir = n...
public static void main(String[] args) { int argc = args.length; if (argc != 2) { System.out.println("Usage: TxtSplit <txt> <target folder>"); } else { File file = new File(args[0]); if (file.exists() && file.canRead()) { File targetDir = n...
diff --git a/src/main/java/knowledgeTest/controller/test/TestRunController.java b/src/main/java/knowledgeTest/controller/test/TestRunController.java index 8e75e08..c05db2d 100644 --- a/src/main/java/knowledgeTest/controller/test/TestRunController.java +++ b/src/main/java/knowledgeTest/controller/test/TestRunController....
false
true
public @ResponseBody TaskModel getNextQuestion(@RequestBody RequestTask requestTask, HttpServletRequest request, HttpServletResponse response) { logger.info("runTest.jsp "); if (requestTask.getUserId() != 0) { User user = userService.findUserById(requestTa...
public @ResponseBody TaskModel getNextQuestion(@RequestBody RequestTask requestTask, HttpServletRequest request, HttpServletResponse response) { logger.info("runTest.jsp "); if (requestTask.getUserId() != 0) { User user = userService.findUserById(requestTa...
diff --git a/src/main/java/gov/usgs/gdp/analysis/grid/FeatureCoverageWeightedGridStatistics.java b/src/main/java/gov/usgs/gdp/analysis/grid/FeatureCoverageWeightedGridStatistics.java index f1269d26..774d126f 100644 --- a/src/main/java/gov/usgs/gdp/analysis/grid/FeatureCoverageWeightedGridStatistics.java +++ b/src/main/...
false
true
private static Range[] getRangesFromLatLonRect(LatLonRect llr, GridCoordSystem gcs) throws InvalidRangeException { int[] lowerCornerIndices = new int[2]; int[] upperCornerIndices = new int[2]; gcs.findXYindexFromLatLon(llr.getLatMin(), llr.getLonMin(), lowerCornerIndices); ...
public static Range[] getRangesFromLatLonRect(LatLonRect llr, GridCoordSystem gcs) throws InvalidRangeException { int[] lowerCornerIndices = new int[2]; int[] upperCornerIndices = new int[2]; gcs.findXYindexFromLatLon(llr.getLatMin(), llr.getLonMin(), lowerCornerIndices); ...
diff --git a/src/com/android/calendar/EmailAddressAdapter.java b/src/com/android/calendar/EmailAddressAdapter.java index 46799609..bfcb986f 100644 --- a/src/com/android/calendar/EmailAddressAdapter.java +++ b/src/com/android/calendar/EmailAddressAdapter.java @@ -1,76 +1,76 @@ /* * Copyright (C) 2007 The Android Open...
true
true
private final String makeDisplayString(Cursor cursor) { String name = cursor.getString(NAME_INDEX); String address = cursor.getString(DATA_INDEX); return new Rfc822Token(address, name, null).toString(); }
private final String makeDisplayString(Cursor cursor) { String name = cursor.getString(NAME_INDEX); String address = cursor.getString(DATA_INDEX); return new Rfc822Token(name, address, null).toString(); }
diff --git a/src/main/java/org/agmip/translators/dssat/DssatXFileInput.java b/src/main/java/org/agmip/translators/dssat/DssatXFileInput.java index a5442ad..b5f773a 100644 --- a/src/main/java/org/agmip/translators/dssat/DssatXFileInput.java +++ b/src/main/java/org/agmip/translators/dssat/DssatXFileInput.java @@ -1,994 +...
false
true
protected AdvancedHashMap readFile(HashMap brMap) throws IOException { AdvancedHashMap ret = new AdvancedHashMap(); String line; BufferedReader br; char[] buf; BufferedReader brw = null; char[] bufW = null; HashMap mapW; String wid; String fil...
protected AdvancedHashMap readFile(HashMap brMap) throws IOException { AdvancedHashMap ret = new AdvancedHashMap(); String line; BufferedReader br; char[] buf; BufferedReader brw = null; char[] bufW = null; HashMap mapW; String wid; String fil...
diff --git a/tools/rimd/src/org/rikulo/rimd/RikuloLinkRenderer.java b/tools/rimd/src/org/rikulo/rimd/RikuloLinkRenderer.java index 1e532d9..5628568 100755 --- a/tools/rimd/src/org/rikulo/rimd/RikuloLinkRenderer.java +++ b/tools/rimd/src/org/rikulo/rimd/RikuloLinkRenderer.java @@ -1,86 +1,87 @@ //Copyright (C) 2012 Pot...
false
true
public Rendering render(ExpLinkNode node, String text) { String url = node.url; boolean bApi = false; if ((bApi = url.equals("api:")) || url.equals("dart:")) { //package: [view](api:) or [html](dart:) final String urlPrefix = bApi ? _api: _dart; return new Rendering(urlPrefix + text.replace('/', '_') + "...
public Rendering render(ExpLinkNode node, String text) { String url = node.url; boolean bApi = false; if ((bApi = url.equals("api:")) || url.equals("dart:")) { //package: [view](api:) or [html](dart:) final String urlPrefix = bApi ? _api: _dart; return new Rendering(urlPrefix + text.replace('/', '_') + "...
diff --git a/src/main/java/netty/rpc/client/ClientHandler.java b/src/main/java/netty/rpc/client/ClientHandler.java index a80f7e9..f9973a0 100644 --- a/src/main/java/netty/rpc/client/ClientHandler.java +++ b/src/main/java/netty/rpc/client/ClientHandler.java @@ -1,50 +1,50 @@ package netty.rpc.client; import java.uti...
true
true
public void messageReceived(ChannelHandlerContext ctx, MessageEvent e){ Transport transport = (Transport)e.getMessage(); String keyString = new String(transport.getKey()); ResultHandler handler = callbackHandlerMap.remove(keyString); if(handler!=null){ handler.processor(transport.getValue()); }else{ lo...
public void messageReceived(ChannelHandlerContext ctx, MessageEvent e){ Transport transport = (Transport)e.getMessage(); String keyString = new String(transport.getKey()); ResultHandler handler = callbackHandlerMap.remove(keyString); if(handler!=null){ handler.processor(transport.getValue()); }else{ lo...
diff --git a/SoarSuite/Applications/TestJavaSML/Application.java b/SoarSuite/Applications/TestJavaSML/Application.java index 9564bdab3..6bb02f080 100644 --- a/SoarSuite/Applications/TestJavaSML/Application.java +++ b/SoarSuite/Applications/TestJavaSML/Application.java @@ -1,425 +1,425 @@ import sml.Agent; import sml....
false
true
private void Test() { // Make sure the kernel was ok if (m_Kernel.HadError()) throw new IllegalStateException("Error initializing kernel: " + m_Kernel.GetLastErrorDescription()) ; String version = m_Kernel.GetSoarKernelVersion() ; System.out.println("Soar version " + version) ; // Create an agent ...
private void Test() { // Make sure the kernel was ok if (m_Kernel.HadError()) throw new IllegalStateException("Error initializing kernel: " + m_Kernel.GetLastErrorDescription()) ; String version = m_Kernel.GetSoarKernelVersion() ; System.out.println("Soar version " + version) ; // Create an agent ...
diff --git a/components/dotnet-executable/src/main/java/npanday/executable/impl/CompilerContextImpl.java b/components/dotnet-executable/src/main/java/npanday/executable/impl/CompilerContextImpl.java index 76d892fe..9e94845c 100644 --- a/components/dotnet-executable/src/main/java/npanday/executable/impl/CompilerContextI...
true
true
public void init( CompilerRequirement compilerRequirement, CompilerConfig config, MavenProject project, CapabilityMatcher capabilityMatcher ) throws PlatformUnsupportedException { this.project = project; this.config = config; this.compilerRequirement = comp...
public void init( CompilerRequirement compilerRequirement, CompilerConfig config, MavenProject project, CapabilityMatcher capabilityMatcher ) throws PlatformUnsupportedException { this.project = project; this.config = config; this.compilerRequirement = comp...
diff --git a/src/MultiPlayer.java b/src/MultiPlayer.java index 2dba522..910969f 100644 --- a/src/MultiPlayer.java +++ b/src/MultiPlayer.java @@ -1,291 +1,295 @@ import org.newdawn.slick.GameContainer; import org.newdawn.slick.Graphics; import org.newdawn.slick.Image; import org.newdawn.slick.Input; import org.newd...
false
true
public void update(GameContainer gc, StateBasedGame sg, int delta) throws SlickException { System.out.println(-viewTopLeftX+viewBottomRightX); Input input = gc.getInput(); double r = 0; mouseX = input.getMouseX(); mouseY = input.getMouseY(); r = Math.atan2(mouseY-pla...
public void update(GameContainer gc, StateBasedGame sg, int delta) throws SlickException { System.out.println(-viewTopLeftX+viewBottomRightX); Input input = gc.getInput(); double r = 0; mouseX = input.getMouseX(); mouseY = input.getMouseY(); r = Math.atan2(mouseY-pla...
diff --git a/tool/src/java/org/sakaiproject/evaluation/tool/producers/TakeEvalProducer.java b/tool/src/java/org/sakaiproject/evaluation/tool/producers/TakeEvalProducer.java index eee661e4..9a81adad 100644 --- a/tool/src/java/org/sakaiproject/evaluation/tool/producers/TakeEvalProducer.java +++ b/tool/src/java/org/sakaip...
true
true
public void fillComponents(UIContainer tofill, ViewParameters viewparams, ComponentChecker checker) { // force the headers to expire this - http://jira.sakaiproject.org/jira/browse/EVALSYS-621 RenderingUtils.setNoCacheHeaders(httpServletResponse); boolean canAccess = false; // can ...
public void fillComponents(UIContainer tofill, ViewParameters viewparams, ComponentChecker checker) { // force the headers to expire this - http://jira.sakaiproject.org/jira/browse/EVALSYS-621 RenderingUtils.setNoCacheHeaders(httpServletResponse); boolean canAccess = false; // can ...
diff --git a/src/net/sourceforge/peers/sip/core/useragent/UserAgent.java b/src/net/sourceforge/peers/sip/core/useragent/UserAgent.java index 405880d..23ae51f 100644 --- a/src/net/sourceforge/peers/sip/core/useragent/UserAgent.java +++ b/src/net/sourceforge/peers/sip/core/useragent/UserAgent.java @@ -1,340 +1,340 @@ /*...
true
true
public UserAgent(SipListener sipListener) { this.sipListener = sipListener; config = new Config(Utils.getPeersHome() + CONFIG_FILE); cseqCounter = 0; StringBuffer buf = new StringBuffer(); buf.append("starting user agent ["); buf.append("myAddress: "...
public UserAgent(SipListener sipListener) { this.sipListener = sipListener; config = new Config(Utils.getPeersHome() + CONFIG_FILE); cseqCounter = 1; StringBuffer buf = new StringBuffer(); buf.append("starting user agent ["); buf.append("myAddress: "...
diff --git a/src/main/java/org/sonar/dev/TrimMojo.java b/src/main/java/org/sonar/dev/TrimMojo.java index 9c55cf1..d5edffe 100644 --- a/src/main/java/org/sonar/dev/TrimMojo.java +++ b/src/main/java/org/sonar/dev/TrimMojo.java @@ -1,142 +1,143 @@ /* * Sonar Development Maven Plugin * Copyright (C) 2010 SonarSource ...
true
true
private File[] scanFiles() { String[] defaultIncludes = {"**\\*"}; DirectoryScanner ds = new DirectoryScanner(); if (includes == null) { ds.setIncludes(defaultIncludes); } else { ds.setIncludes(includes); } ds.addDefaultExcludes(); // .svn, ... if (excludes != null) { ds....
private File[] scanFiles() { String[] defaultIncludes = {"**\\*"}; DirectoryScanner ds = new DirectoryScanner(); if (includes == null) { ds.setIncludes(defaultIncludes); } else { ds.setIncludes(includes); } // .svn, ... ds.addDefaultExcludes(); if (excludes != null) { ...
diff --git a/src/rs/pedjaapps/KernelTuner/ChangeVoltage.java b/src/rs/pedjaapps/KernelTuner/ChangeVoltage.java index 2dcfecf..7f88ba3 100644 --- a/src/rs/pedjaapps/KernelTuner/ChangeVoltage.java +++ b/src/rs/pedjaapps/KernelTuner/ChangeVoltage.java @@ -1,417 +1,417 @@ package rs.pedjaapps.KernelTuner; import java.i...
false
true
protected String doInBackground(String... args) { List<String> voltageFreqs = CPUInfo.voltageFreqs(); List<Integer> voltages = CPUInfo.voltages(); Process localProcess; if(new File(CPUInfo.VOLTAGE_PATH).exists()){ if(args[0].equals("minus")){ try { localProcess = Runtime.getRuntime().exec("su")...
protected String doInBackground(String... args) { List<String> voltageFreqs = CPUInfo.voltageFreqs(); List<Integer> voltages = CPUInfo.voltages(); Process localProcess; if(new File(CPUInfo.VOLTAGE_PATH).exists()){ if(args[0].equals("minus")){ try { localProcess = Runtime.getRuntime().exec("su")...
diff --git a/src/main/java/com/englishtown/vertx/jersey/impl/DefaultJerseyHandlerConfigurator.java b/src/main/java/com/englishtown/vertx/jersey/impl/DefaultJerseyHandlerConfigurator.java index c751b84..087661f 100644 --- a/src/main/java/com/englishtown/vertx/jersey/impl/DefaultJerseyHandlerConfigurator.java +++ b/src/m...
true
true
protected ResourceConfig getResourceConfig() { checkState(); JsonArray resources = config.getArray(CONFIG_RESOURCES, null); if (resources == null || resources.size() == 0) { throw new RuntimeException("At lease one resource package name must be specified in the config " + ...
protected ResourceConfig getResourceConfig() { checkState(); JsonArray resources = config.getArray(CONFIG_RESOURCES, null); if (resources == null || resources.size() == 0) { throw new RuntimeException("At least one resource package name must be specified in the config " + ...
diff --git a/src/main/java/water/DTask.java b/src/main/java/water/DTask.java index b97f82d06..d9855cd28 100644 --- a/src/main/java/water/DTask.java +++ b/src/main/java/water/DTask.java @@ -1,53 +1,53 @@ package water; import water.H2O.H2OCountedCompleter; /** Objects which are passed & remotely executed.<p> * ...
true
true
private Error barf() { return new RuntimeException(getClass().toString()+" should be automatically overridden in the subclass by the auto-serialization code"); }
private RuntimeException barf() { return new RuntimeException(getClass().toString()+" should be automatically overridden in the subclass by the auto-serialization code"); }
diff --git a/src/fr/frozentux/craftguard2/listener/PlayerListener.java b/src/fr/frozentux/craftguard2/listener/PlayerListener.java index 9af6035..79d7969 100644 --- a/src/fr/frozentux/craftguard2/listener/PlayerListener.java +++ b/src/fr/frozentux/craftguard2/listener/PlayerListener.java @@ -1,62 +1,62 @@ package fr.f...
true
true
public void onInventoryClick(InventoryClickEvent e){ SlotType slotType = e.getSlotType(); InventoryType invType = e.getInventory().getType(); int slot = e.getSlot(); Player player = (Player)e.getWhoClicked(); if(slotType == SlotType.RESULT && (invType.equals(InventoryType.CRAFTING) || invType.equals(Inven...
public void onInventoryClick(InventoryClickEvent e){ SlotType slotType = e.getSlotType(); InventoryType invType = e.getInventory().getType(); int slot = e.getSlot(); Player player = (Player)e.getWhoClicked(); if(slotType == SlotType.RESULT && (invType.equals(InventoryType.CRAFTING) || invType.equals(Inven...
diff --git a/src/com/fsck/k9/helper/ContactsSdk3_4.java b/src/com/fsck/k9/helper/ContactsSdk3_4.java index d01f8e8b..773ead78 100644 --- a/src/com/fsck/k9/helper/ContactsSdk3_4.java +++ b/src/com/fsck/k9/helper/ContactsSdk3_4.java @@ -1,257 +1,260 @@ package com.fsck.k9.helper; import android.app.Activity; import ...
false
true
public Cursor searchContacts(final CharSequence constraint) { final String where; final String[] args; if (constraint == null) { where = null; args = null; } else { where = Contacts.ContactMethods.KIND + " = " + Contacts...
public Cursor searchContacts(final CharSequence constraint) { final String where; final String[] args; if (constraint == null) { where = null; args = null; } else { where = Contacts.ContactMethods.KIND + " = " + Contacts...
diff --git a/src/com/android/contacts/editor/PhotoActionPopup.java b/src/com/android/contacts/editor/PhotoActionPopup.java index ac2d64fd3..cca6f9d08 100644 --- a/src/com/android/contacts/editor/PhotoActionPopup.java +++ b/src/com/android/contacts/editor/PhotoActionPopup.java @@ -1,138 +1,138 @@ /* * Copyright (C) 2...
true
true
public static ListPopupWindow createPopupMenu(Context context, View anchorView, final Listener listener, int mode) { // Build choices, depending on the current mode. We assume this Dialog is never called // if there are NO choices (e.g. a read-only picture is already super-primary) ...
public static ListPopupWindow createPopupMenu(Context context, View anchorView, final Listener listener, int mode) { // Build choices, depending on the current mode. We assume this Dialog is never called // if there are NO choices (e.g. a read-only picture is already super-primary) ...
diff --git a/src/edu/cudenver/bios/powersvc/resource/ParameterResourceHelper.java b/src/edu/cudenver/bios/powersvc/resource/ParameterResourceHelper.java index 73607f0..5bdd05e 100644 --- a/src/edu/cudenver/bios/powersvc/resource/ParameterResourceHelper.java +++ b/src/edu/cudenver/bios/powersvc/resource/ParameterResourc...
true
true
public static LinearModelPowerSampleSizeParameters linearModelParamsFromDomNode(Node node) throws ResourceException { LinearModelPowerSampleSizeParameters params = new LinearModelPowerSampleSizeParameters(); // make sure the root node is a power parameters if (!node.getNodeName().equals...
public static LinearModelPowerSampleSizeParameters linearModelParamsFromDomNode(Node node) throws ResourceException { LinearModelPowerSampleSizeParameters params = new LinearModelPowerSampleSizeParameters(); // make sure the root node is a power parameters if (!node.getNodeName().equals...
diff --git a/biz/src/main/java/org/huamuzhen/oa/biz/FeedbackManager.java b/biz/src/main/java/org/huamuzhen/oa/biz/FeedbackManager.java index 50e82fe..e31a0b3 100644 --- a/biz/src/main/java/org/huamuzhen/oa/biz/FeedbackManager.java +++ b/biz/src/main/java/org/huamuzhen/oa/biz/FeedbackManager.java @@ -1,132 +1,129 @@ pa...
true
true
public Feedback add(String reportFormId, String content, String signature, String orgUnitId, String owner, User currentUser, boolean agree, String currentReceiverId, String leader2Id) { Feedback feedback = new Feedback(); feedback.setContent(content); feedback.setSignature(signature); feedback.setFeedBackTi...
public Feedback add(String reportFormId, String content, String signature, String orgUnitId, String owner, User currentUser, boolean agree, String currentReceiverId, String leader2Id) { Feedback feedback = new Feedback(); feedback.setContent(content); feedback.setSignature(signature); feedback.setFeedBackTi...
diff --git a/modules/extension/xsd/xsd-gml3/src/main/java/org/geotools/gml3/bindings/ComplexSupportXSAnyTypeBinding.java b/modules/extension/xsd/xsd-gml3/src/main/java/org/geotools/gml3/bindings/ComplexSupportXSAnyTypeBinding.java index 29c2577f6..dc3bffceb 100644 --- a/modules/extension/xsd/xsd-gml3/src/main/java/org/...
false
true
public List getProperties(Object object, XSDElementDeclaration element) throws Exception { List<Object[/* 2 */]> properties = new ArrayList<Object[/* 2 */]>(); XSDTypeDefinition typeDef = element.getTypeDefinition(); boolean isAnyType = typeDef.getName() != null && typeDef.getTargetNamespace...
public List getProperties(Object object, XSDElementDeclaration element) throws Exception { List<Object[/* 2 */]> properties = new ArrayList<Object[/* 2 */]>(); XSDTypeDefinition typeDef = element.getTypeDefinition(); boolean isAnyType = typeDef.getName() != null && typeDef.getTargetNamespace...
diff --git a/src/testharness/TestCase.java b/src/testharness/TestCase.java index ef2183a..017b7f4 100644 --- a/src/testharness/TestCase.java +++ b/src/testharness/TestCase.java @@ -1,18 +1,18 @@ /** * Created: Mar 28, 2011 10:56:01 PM * */ public class TestCase { private org.apache.hadoop.util.Tool tool...
true
true
TestCase(org.apache.hadoop.util.Tool tool, String args) { this.tool = tool; this.args = args; }
TestCase(org.apache.hadoop.util.Tool tool, String[] args) { this.tool = tool; this.args = args; }
diff --git a/servlet/src/test/java/io/undertow/servlet/test/multipart/MultiPartTestCase.java b/servlet/src/test/java/io/undertow/servlet/test/multipart/MultiPartTestCase.java index ceabbfd27..0f901f48e 100644 --- a/servlet/src/test/java/io/undertow/servlet/test/multipart/MultiPartTestCase.java +++ b/servlet/src/test/ja...
true
true
public void testMultiPartRequest() throws IOException { TestHttpClient client = new TestHttpClient(); try { String uri = DefaultServer.getDefaultServerURL() + "/servletContext/1"; HttpPost post = new HttpPost(uri); MultipartEntity entity = new MultipartEntity(Http...
public void testMultiPartRequest() throws IOException { TestHttpClient client = new TestHttpClient(); try { String uri = DefaultServer.getDefaultServerURL() + "/servletContext/1"; HttpPost post = new HttpPost(uri); MultipartEntity entity = new MultipartEntity(Http...
diff --git a/main/src/main/java/com/bloatit/web/html/pages/IdeasList.java b/main/src/main/java/com/bloatit/web/html/pages/IdeasList.java index 0a39827d6..08711bfe6 100644 --- a/main/src/main/java/com/bloatit/web/html/pages/IdeasList.java +++ b/main/src/main/java/com/bloatit/web/html/pages/IdeasList.java @@ -1,229 +1,22...
true
true
private HtmlNode generateContent() { final HtmlDiv ideaBlock = new HtmlDiv("idea_summary"); { final HtmlDiv leftBlock = new HtmlDiv("idea_summary_left"); { final HtmlDiv karmaBlock = new HtmlDiv("idea_karma"); karmaBlock.add(new HtmlParagraph("" + idea.getPopularity())); leftBlock.add...
private HtmlNode generateContent() { final HtmlDiv ideaBlock = new HtmlDiv("idea_summary"); { final HtmlDiv leftBlock = new HtmlDiv("idea_summary_left"); { final HtmlDiv karmaBlock = new HtmlDiv("idea_karma"); karmaBlock.add(new HtmlParagraph("" + idea.getPopularity())); leftBlock.add...
diff --git a/src/main/java/com/theoryinpractise/clojure/ClojureSwankMojo.java b/src/main/java/com/theoryinpractise/clojure/ClojureSwankMojo.java index bad65bd..fa1a911 100644 --- a/src/main/java/com/theoryinpractise/clojure/ClojureSwankMojo.java +++ b/src/main/java/com/theoryinpractise/clojure/ClojureSwankMojo.java @@ ...
true
true
public void execute() throws MojoExecutionException { File swankTempFile; try { swankTempFile = File.createTempFile("swank", ".port"); } catch (java.io.IOException e) { throw new MojoExecutionException("could not create SWANK port file", e); } StringB...
public void execute() throws MojoExecutionException { File swankTempFile; try { swankTempFile = File.createTempFile("swank", ".port"); } catch (java.io.IOException e) { throw new MojoExecutionException("could not create SWANK port file", e); } StringB...
diff --git a/src/java/com/android/internal/telephony/gsm/GsmConnection.java b/src/java/com/android/internal/telephony/gsm/GsmConnection.java index ddfe082..21e52d8 100644 --- a/src/java/com/android/internal/telephony/gsm/GsmConnection.java +++ b/src/java/com/android/internal/telephony/gsm/GsmConnection.java @@ -1,768 +...
false
true
DisconnectCause disconnectCauseFromCode(int causeCode) { /** * See 22.001 Annex F.4 for mapping of cause codes * to local tones */ switch (causeCode) { case CallFailCause.USER_BUSY: return DisconnectCause.BUSY; case CallFailCau...
DisconnectCause disconnectCauseFromCode(int causeCode) { /** * See 22.001 Annex F.4 for mapping of cause codes * to local tones */ switch (causeCode) { case CallFailCause.USER_BUSY: return DisconnectCause.BUSY; case CallFailCau...
diff --git a/src/eval/e9/E9v3.java b/src/eval/e9/E9v3.java index 826b553..e8679c6 100644 --- a/src/eval/e9/E9v3.java +++ b/src/eval/e9/E9v3.java @@ -1,511 +1,511 @@ package eval.e9; import state4.BitUtil; import state4.Masks; import state4.MoveEncoder; import state4.State4; import eval.Evaluator3; import eval....
true
true
public int refine(final int player, final State4 s, final int lowerBound, final int upperBound, final int scoreEncoding) { int score = ScoreEncoder.getScore(scoreEncoding); int margin = ScoreEncoder.getMargin(scoreEncoding); int flags = ScoreEncoder.getFlags(scoreEncoding); boolean isLowerBound = ScoreEn...
public int refine(final int player, final State4 s, final int lowerBound, final int upperBound, final int scoreEncoding) { int score = ScoreEncoder.getScore(scoreEncoding); int margin = ScoreEncoder.getMargin(scoreEncoding); int flags = ScoreEncoder.getFlags(scoreEncoding); boolean isLowerBound = ScoreEn...
diff --git a/WWIDesigner/src/main/com/wwidesigner/gui/WhistleStudyModel.java b/WWIDesigner/src/main/com/wwidesigner/gui/WhistleStudyModel.java index 823e978..c0073d5 100644 --- a/WWIDesigner/src/main/com/wwidesigner/gui/WhistleStudyModel.java +++ b/WWIDesigner/src/main/com/wwidesigner/gui/WhistleStudyModel.java @@ -1,1...
true
true
protected BaseObjectiveFunction getObjectiveFunction() throws Exception { Category optimizerCategory = getCategory(OPTIMIZER_CATEGORY_ID); String optimizer = optimizerCategory.getSelectedSub(); Instrument instrument = getInstrument(); Tuning tuning = getTuning(); WhistleCalculator calculator = new WhistleCa...
protected BaseObjectiveFunction getObjectiveFunction() throws Exception { Category optimizerCategory = getCategory(OPTIMIZER_CATEGORY_ID); String optimizer = optimizerCategory.getSelectedSub(); Instrument instrument = getInstrument(); Tuning tuning = getTuning(); WhistleCalculator calculator = new WhistleCa...
diff --git a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/launching/StandardSourcePathProvider.java b/org.eclipse.jdt.launching/launching/org/eclipse/jdt/launching/StandardSourcePathProvider.java index 4742ee4e3..373591409 100644 --- a/org.eclipse.jdt.launching/launching/org/eclipse/jdt/launching/StandardSourceP...
true
true
public IRuntimeClasspathEntry[] resolveClasspath(IRuntimeClasspathEntry[] entries, ILaunchConfiguration configuration) throws CoreException { boolean includeJRE = false; IJavaProject pro = JavaRuntime.getJavaProject(configuration); includeJRE = pro == null; // omit JRE from source lookup path if the runtime JR...
public IRuntimeClasspathEntry[] resolveClasspath(IRuntimeClasspathEntry[] entries, ILaunchConfiguration configuration) throws CoreException { boolean includeJRE = false; IJavaProject pro = JavaRuntime.getJavaProject(configuration); includeJRE = pro == null; // omit JRE from source lookup path if the runtime JR...
diff --git a/src/main/java/at/yawk/fimficiton/operation/GetStoryMetaOperation.java b/src/main/java/at/yawk/fimficiton/operation/GetStoryMetaOperation.java index 6e9da02..36a5174 100644 --- a/src/main/java/at/yawk/fimficiton/operation/GetStoryMetaOperation.java +++ b/src/main/java/at/yawk/fimficiton/operation/GetStoryMe...
true
true
private Story requestJson() throws IOException { // prepare URL final URL targeting = new URL("http://fimfiction.net/api/story.php?story=" + this.storyFor.getId()); // download and convert to JsonObject using Gson final JsonObject returned; final InputStream request ...
private Story requestJson() throws IOException { // prepare URL final URL targeting = new URL("http://fimfiction.net/api/story.php?story=" + this.storyFor.getId()); // download and convert to JsonObject using Gson final JsonObject returned; final InputStream request ...
diff --git a/codecs/src/test/java/com/github/t1/webresource/log/LoggingInterceptorTest.java b/codecs/src/test/java/com/github/t1/webresource/log/LoggingInterceptorTest.java index 228fa18..0f2c73f 100644 --- a/codecs/src/test/java/com/github/t1/webresource/log/LoggingInterceptorTest.java +++ b/codecs/src/test/java/com/g...
false
true
public void shouldLogLogContextParameter() throws Exception { final String KEY = "user-id"; class Container { @Logged public void methodWithLogContextParameter(@LogContext(KEY) String one, String two) {} } whenDebugEnabled(); Method method = Container....
public void shouldLogLogContextParameter() throws Exception { final String KEY = "user-id"; class Container { @Logged public void methodWithLogContextParameter(@LogContext(KEY) String one, String two) {} } whenDebugEnabled(); Method method = Container....
diff --git a/src/com/nennig/life/wheel/MainActivity.java b/src/com/nennig/life/wheel/MainActivity.java index 6de4fb0..c0ffd72 100644 --- a/src/com/nennig/life/wheel/MainActivity.java +++ b/src/com/nennig/life/wheel/MainActivity.java @@ -1,186 +1,189 @@ /* Copyright (C) 2012 The Android Open Source Project Licen...
true
true
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); itemList.add(new Slice(lifeType, 3f)); // itemList.add(new Slice("Work", 4f/pieScale, res.getColor(R.color.yellow), res.getColor(R.color.yellow_light))); // itemList.add(new Slice("Social", 5f/pieSca...
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); itemList.add(new Slice(lifeType, 3f)); // itemList.add(new Slice("Work", 4f/pieScale, res.getColor(R.color.yellow), res.getColor(R.color.yellow_light))); // itemList.add(new Slice("Social", 5f/pieSca...
diff --git a/src/info/micdm/munin_client/NodeActivity.java b/src/info/micdm/munin_client/NodeActivity.java index 2f7824b..76f5cda 100644 --- a/src/info/micdm/munin_client/NodeActivity.java +++ b/src/info/micdm/munin_client/NodeActivity.java @@ -1,192 +1,191 @@ package info.micdm.munin_client; import info.micdm.muni...
false
true
protected boolean _onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) { if (Math.abs(e1.getY() - e2.getY()) < 200) { if (velocityX < 0) { _loadNextByType(); return true; } if (velocityX > 0) { _loadPre...
protected boolean _onFling(MotionEvent e1, MotionEvent e2, float velocityX, float velocityY) { if (Math.abs(velocityX) > Math.abs(velocityY)) { if (velocityX < 0) { _loadNextByType(); return true; } if (velocityX > 0) { _loa...
diff --git a/src/main/java/org/werti/uima/ae/relevance/GenericRelevanceAnnotator.java b/src/main/java/org/werti/uima/ae/relevance/GenericRelevanceAnnotator.java index 6721f91..dc54248 100644 --- a/src/main/java/org/werti/uima/ae/relevance/GenericRelevanceAnnotator.java +++ b/src/main/java/org/werti/uima/ae/relevance/Ge...
false
true
public void process(JCas cas) throws AnalysisEngineProcessException { log.info("Starting relevance annotation"); final Stack<String> tags = new Stack<String>(); final FSIndex tagIndex = cas.getAnnotationIndex(HTML.type); final Iterator<HTML> tit = tagIndex.iterator(); HTML tag = tit.next(); if (tag == null...
public void process(JCas cas) throws AnalysisEngineProcessException { log.info("Starting relevance annotation"); final Stack<String> tags = new Stack<String>(); final FSIndex tagIndex = cas.getAnnotationIndex(HTML.type); final Iterator<HTML> tit = tagIndex.iterator(); HTML tag = tit.next(); if (tag == null...
diff --git a/src/java/axiom/scripting/rhino/RhinoCore.java b/src/java/axiom/scripting/rhino/RhinoCore.java index ac63d6c..cfeeea9 100755 --- a/src/java/axiom/scripting/rhino/RhinoCore.java +++ b/src/java/axiom/scripting/rhino/RhinoCore.java @@ -1,1284 +1,1284 @@ /* * Helma License Notice * * The contents of this...
true
true
public RhinoCore(Application app) { this.app = app; wrappercache = new WeakCacheMap(500); prototypes = new Hashtable(); Context context = Context.enter(); context.setLanguageVersion(170); context.setCompileFunctionsWithDynamicScope(true); context.setApplicat...
public RhinoCore(Application app) { this.app = app; wrappercache = new WeakCacheMap(500); prototypes = new Hashtable(); Context context = Context.enter(); context.setLanguageVersion(170); context.setCompileFunctionsWithDynamicScope(true); context.setApplicat...
diff --git a/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateImpl.java b/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateImpl.java index 6841f4d9..7c6c6cc4 100644 --- a/bundles/org.eclipse.osgi/resolver/src/org/eclipse/osgi/internal/resolver/StateImpl.java +++...
true
true
private synchronized StateDelta resolve(boolean incremental, BundleDescription[] reResolve) { try { resolving = true; if (resolver == null) throw new IllegalStateException("no resolver set"); //$NON-NLS-1$ fullyLoad(); long start = 0; if (StateManager.DEBUG_PLATFORM_ADMIN_RESOLVER) start = Sys...
private synchronized StateDelta resolve(boolean incremental, BundleDescription[] reResolve) { try { resolving = true; if (resolver == null) throw new IllegalStateException("no resolver set"); //$NON-NLS-1$ fullyLoad(); long start = 0; if (StateManager.DEBUG_PLATFORM_ADMIN_RESOLVER) start = Sys...
diff --git a/src/whitehole/StrictThreadGroup.java b/src/whitehole/StrictThreadGroup.java index 19f1fac..f551d1e 100644 --- a/src/whitehole/StrictThreadGroup.java +++ b/src/whitehole/StrictThreadGroup.java @@ -1,65 +1,65 @@ /* Copyright 2012 The Whitehole team This file is part of Whitehole. Whitehol...
true
true
public void uncaughtException(Thread t, Throwable e) { if (e.getMessage().contains("Method 'gl") && e.getMessage().contains("' not available")) { JOptionPane.showMessageDialog(null, e.getMessage() + "\n\n" + "This error is likely caused by an ...
public void uncaughtException(Thread t, Throwable e) { if (e.getMessage().contains("Method 'gl") && e.getMessage().contains("' not available")) { JOptionPane.showMessageDialog(null, e.getMessage() + "\n\n" + "This error is likely caused by an ...
diff --git a/src/main/java/com/bergerkiller/bukkit/mw/Portal.java b/src/main/java/com/bergerkiller/bukkit/mw/Portal.java index f442bf6..b6616b5 100644 --- a/src/main/java/com/bergerkiller/bukkit/mw/Portal.java +++ b/src/main/java/com/bergerkiller/bukkit/mw/Portal.java @@ -1,322 +1,321 @@ package com.bergerkiller.bukki...
true
true
public static boolean handlePortalEnter(Entity e, Material portalMaterial) { Portal portal = getNear(e.getLocation()); if (portal == null) { // Default portals String def = null; if (portalMaterial == Material.PORTAL) { def = WorldConfig.get(e).getNetherPortal(); } else if (portalMaterial == Materi...
public static boolean handlePortalEnter(Entity e, Material portalMaterial) { Portal portal = getNear(e.getLocation()); if (portal == null) { // Default portals String def = null; if (portalMaterial == Material.PORTAL) { def = WorldConfig.get(e).getNetherPortal(); } else if (portalMaterial == Materi...
diff --git a/motech-omod/src/main/java/org/motech/openmrs/module/web/controller/MotherController.java b/motech-omod/src/main/java/org/motech/openmrs/module/web/controller/MotherController.java index 98afb1ca..9e5f7452 100755 --- a/motech-omod/src/main/java/org/motech/openmrs/module/web/controller/MotherController.java ...
true
true
public String submitForm(@ModelAttribute("mother") WebPatient mother, Errors errors, ModelMap model, SessionStatus status) { log.debug("Register Pregnant Mother"); ValidationUtils.rejectIfEmptyOrWhitespace(errors, "firstName", "motechmodule.firstName.required"); ValidationUtils.rejectIfEmptyOrWhitespace...
public String submitForm(@ModelAttribute("mother") WebPatient mother, Errors errors, ModelMap model, SessionStatus status) { log.debug("Register Pregnant Mother"); ValidationUtils.rejectIfEmptyOrWhitespace(errors, "firstName", "motechmodule.firstName.required"); ValidationUtils.rejectIfEmptyOrWhitespace...
diff --git a/src/com/djdch/bukkit/onehundredgenerator/mc100/GenLayer.java b/src/com/djdch/bukkit/onehundredgenerator/mc100/GenLayer.java index 37ed5ab..8399220 100644 --- a/src/com/djdch/bukkit/onehundredgenerator/mc100/GenLayer.java +++ b/src/com/djdch/bukkit/onehundredgenerator/mc100/GenLayer.java @@ -1,117 +1,117 @@...
true
true
public static GenLayer[] a(long paramLong) { Object localObject1 = new LayerIsland(1L); localObject1 = new GenLayerZoomFuzzy(2000L, (GenLayer) localObject1); localObject1 = new GenLayerIsland(1L, (GenLayer) localObject1); localObject1 = new GenLayerZoom(2001L, (GenLayer) localObject1...
public static GenLayer[] a(long paramLong) { Object localObject1 = new LayerIsland(1L); localObject1 = new GenLayerZoomFuzzy(2000L, (GenLayer) localObject1); localObject1 = new GenLayerIsland(1L, (GenLayer) localObject1); localObject1 = new GenLayerZoom(2001L, (GenLayer) localObject1...
diff --git a/app/extensions/ObjectExtensions.java b/app/extensions/ObjectExtensions.java index a89f174..0fe86b6 100644 --- a/app/extensions/ObjectExtensions.java +++ b/app/extensions/ObjectExtensions.java @@ -1,21 +1,21 @@ package extensions; import org.apache.commons.lang.StringUtils; import play.templates.JavaEx...
true
true
public static String toWords(Object object) { final String s = object.toString(); return StringUtils.capitalize(s.toLowerCase()); }
public static String toWords(Object object) { final String s = object.toString().replaceAll("_", " "); return StringUtils.capitalize(s.toLowerCase()); }
diff --git a/mmstudio/src/org/micromanager/conf/PeripheralDevicesPreInitializationPropertiesPage.java b/mmstudio/src/org/micromanager/conf/PeripheralDevicesPreInitializationPropertiesPage.java index 97285b5e5..3a9fa31c6 100644 --- a/mmstudio/src/org/micromanager/conf/PeripheralDevicesPreInitializationPropertiesPage.jav...
false
true
public boolean exitPage(boolean toNextPage) { try { if (toNextPage) { // set the properties of only the 'peripheral' devices!! Device devices[] = model_.getPeripheralDevices(); PropertyTableModel ptm = (PropertyTableModel) propTable_.getModel(); for (i...
public boolean exitPage(boolean toNextPage) { try { if (toNextPage) { // set all pre-initialization properties PropertyTableModel ptm = (PropertyTableModel) propTable_.getModel(); for (int i = 0; i < ptm.getRowCount(); i++) { Setting s = ptm.getSett...
diff --git a/src/main/org/deidentifier/arx/algorithm/FLASHAlgorithm.java b/src/main/org/deidentifier/arx/algorithm/FLASHAlgorithm.java index 043a7b729..d9dbec9fa 100644 --- a/src/main/org/deidentifier/arx/algorithm/FLASHAlgorithm.java +++ b/src/main/org/deidentifier/arx/algorithm/FLASHAlgorithm.java @@ -1,402 +1,403 @@...
true
true
public void traverse() { pqueue.clear(); stack.clear(); // check first node for (final Node[] level : lattice.getLevels()) { if (level.length != 0) { if (level.length == 1) { checker.check(level[0]); break; ...
public void traverse() { pqueue.clear(); stack.clear(); // check first node for (final Node[] level : lattice.getLevels()) { if (level.length != 0) { if (level.length == 1) { checker.check(level[0]); break; ...
diff --git a/logging/src/com/dmdirc/addons/logging/LoggingPlugin.java b/logging/src/com/dmdirc/addons/logging/LoggingPlugin.java index f201f3b8..bc2849ac 100644 --- a/logging/src/com/dmdirc/addons/logging/LoggingPlugin.java +++ b/logging/src/com/dmdirc/addons/logging/LoggingPlugin.java @@ -1,60 +1,60 @@ /* * Copyrig...
true
true
public void load(final PluginInfo pluginInfo, final ObjectGraph graph) { super.load(pluginInfo, graph); setObjectGraph(graph.plus(new LoggingModule(pluginInfo.getDomain()))); manager = getObjectGraph().get(LoggingManager.class); registerCommand(LoggingCommand.class, LoggingCommand....
public void load(final PluginInfo pluginInfo, final ObjectGraph graph) { super.load(pluginInfo, graph); setObjectGraph(graph.plus(new LoggingModule(pluginInfo))); manager = getObjectGraph().get(LoggingManager.class); registerCommand(LoggingCommand.class, LoggingCommand.INFO); }...
diff --git a/logwatcher-logback-appender/src/main/java/com/farpost/logwatcher/logback/LogWatcherAppender.java b/logwatcher-logback-appender/src/main/java/com/farpost/logwatcher/logback/LogWatcherAppender.java index d9bc74e..d055e84 100644 --- a/logwatcher-logback-appender/src/main/java/com/farpost/logwatcher/logback/Lo...
true
true
protected void append(ILoggingEvent event) { try { DateTime time = new DateTime(event.getTimeStamp()); Severity severity = severity(event.getLevel()); ThrowableProxy throwableProxy = (ThrowableProxy) event.getThrowableProxy(); Cause cause = throwableProxy != null ? constructCause(throwableProxy.getTh...
protected void append(ILoggingEvent event) { try { DateTime time = new DateTime(event.getTimeStamp()); Severity severity = severity(event.getLevel()); ThrowableProxy throwableProxy = (ThrowableProxy) event.getThrowableProxy(); Cause cause = throwableProxy != null ? constructCause(throwableProxy.getTh...
diff --git a/org.eclipse.riena.ui.ridgets.swt/src/org/eclipse/riena/ui/ridgets/swt/FocusManager.java b/org.eclipse.riena.ui.ridgets.swt/src/org/eclipse/riena/ui/ridgets/swt/FocusManager.java index 109f23c2f..a8ef9117e 100644 --- a/org.eclipse.riena.ui.ridgets.swt/src/org/eclipse/riena/ui/ridgets/swt/FocusManager.java +...
true
true
private boolean canGetFocus(final Control control) { // skip disabled or hidden if (!control.isEnabled() || !control.isVisible()) { return false; } // skip read-only if (SwtUtilities.hasStyle(control, SWT.READ_ONLY)) { return false; } if (control instanceof Text && !((Text) control).getEditable()) ...
private boolean canGetFocus(final Control control) { // skip disabled or hidden if (!control.isEnabled() || !control.isVisible()) { return false; } // skip read-only if (SwtUtilities.hasStyle(control, SWT.READ_ONLY)) { return false; } if (control instanceof Text && !((Text) control).getEditable()) ...
diff --git a/CubicTestPlugin/src/main/java/org/cubictest/model/PageElement.java b/CubicTestPlugin/src/main/java/org/cubictest/model/PageElement.java index 8fd8314f..dae8a69d 100644 --- a/CubicTestPlugin/src/main/java/org/cubictest/model/PageElement.java +++ b/CubicTestPlugin/src/main/java/org/cubictest/model/PageElemen...
true
true
public Identifier getMostSignificantIdentifier() { int highestProbability = 0; Identifier result = null; for (Identifier identifier : getIdentifiers()) { if (identifier.getProbability() > highestProbability) { result = identifier; highestProbability = identifier.getProbability(); } else if (...
public Identifier getMostSignificantIdentifier() { int highestProbability = 0; Identifier result = null; for (Identifier identifier : getIdentifiers()) { if (identifier.getProbability() > highestProbability) { result = identifier; highestProbability = identifier.getProbability(); } else if (...
diff --git a/core/src/main/java/cucumber/runtime/arquillian/DefaultObjectFactoryExtension.java b/core/src/main/java/cucumber/runtime/arquillian/DefaultObjectFactoryExtension.java index 74e1f81..b5b4853 100644 --- a/core/src/main/java/cucumber/runtime/arquillian/DefaultObjectFactoryExtension.java +++ b/core/src/main/jav...
true
true
public <T> T getInstance(Class<T> type) { if (!instances.containsKey(type)) { try { T instance = type.getConstructor().newInstance(); for (TestEnricher testEnricher : getTestEnrichers()) { testEnricher.enrich(instance); } ...
public <T> T getInstance(Class<T> type) { if (!instances.containsKey(type)) { try { T instance = type.getConstructor().newInstance(); for (TestEnricher testEnricher : getTestEnrichers()) { testEnricher.enrich(instance); } ...
diff --git a/ini/trakem2/display/DisplayCanvas.java b/ini/trakem2/display/DisplayCanvas.java index 06f830d2..994989e6 100644 --- a/ini/trakem2/display/DisplayCanvas.java +++ b/ini/trakem2/display/DisplayCanvas.java @@ -1,3151 +1,3151 @@ /** TrakEM2 plugin for ImageJ(C). Copyright (C) 2005-2009 Albert Cardona and...
false
true
public BufferedImage paintOffscreen(final Layer layer, final ArrayList<Displayable> al_paint, final Displayable active, final int g_width, final int g_height, final int c_alphas, final Loader loader, final HashMap<Color,Layer> hm, final ArrayList<LayerPanel> blending_list, final int mode, final GraphicsSource graphics...
public BufferedImage paintOffscreen(final Layer layer, final ArrayList<Displayable> al_paint, final Displayable active, final int g_width, final int g_height, final int c_alphas, final Loader loader, final HashMap<Color,Layer> hm, final ArrayList<LayerPanel> blending_list, final int mode, final GraphicsSource graphics...
diff --git a/src/org/letstalktech/aahw/POSTRequest.java b/src/org/letstalktech/aahw/POSTRequest.java index 276ae59..723bfa8 100644 --- a/src/org/letstalktech/aahw/POSTRequest.java +++ b/src/org/letstalktech/aahw/POSTRequest.java @@ -1,137 +1,137 @@ package org.letstalktech.aahw; import java.io.File; import java....
true
true
protected Result doInBackground(Parameters... parameters) { Result result = new Result(); android.util.Log.v("POSTRequest","Entered the POSTRequest"); try { String postURL = serverAddress+parameters[0].getPath(); post = new HttpPost(postURL); android.util.Log.e("POSTRequest",postURL); if(paramet...
protected Result doInBackground(Parameters... parameters) { Result result = new Result(); android.util.Log.v("POSTRequest","Entered the POSTRequest"); try { String postURL = serverAddress+parameters[0].getPath(); post = new HttpPost(postURL); android.util.Log.e("POSTRequest",postURL); if(paramet...
diff --git a/org.eclipse.virgo.kernel.osgi/src/test/java/org/eclipse/virgo/kernel/osgi/region/RegionManagerTests.java b/org.eclipse.virgo.kernel.osgi/src/test/java/org/eclipse/virgo/kernel/osgi/region/RegionManagerTests.java index 7da5074e..d515db84 100644 --- a/org.eclipse.virgo.kernel.osgi/src/test/java/org/eclipse/v...
false
true
public void testStartAndStop() throws Exception { StubBundleContext bundleContext = new StubBundleContext(); StubBundleContext surrogateBundleContext = new StubBundleContext(); Framework user = createMock(Framework.class); SurrogateBundle surrogate = createMock(SurrogateBund...
public void testStartAndStop() throws Exception { StubBundleContext bundleContext = new StubBundleContext(); StubBundleContext surrogateBundleContext = new StubBundleContext(); Framework user = createMock(Framework.class); SurrogateBundle surrogate = createMock(SurrogateBund...