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/analyzer/src/java/ru/goodsReview/analyzer/util/dictionary/DictionaryGenerator.java b/analyzer/src/java/ru/goodsReview/analyzer/util/dictionary/DictionaryGenerator.java index 7f99357..517926d 100644 --- a/analyzer/src/java/ru/goodsReview/analyzer/util/dictionary/DictionaryGenerator.java +++ b/analyzer/src/j...
true
true
private static void extractWordsFromDataset() throws XPathExpressionException, FileNotFoundException { XPath xPath = XPathFactory.newInstance().newXPath(); File file = new File("cameras.xml"); // xPath expression for extract comment XPathExpression xPathExpression = xPath.compile(...
private static void extractWordsFromDataset() throws XPathExpressionException, FileNotFoundException { XPath xPath = XPathFactory.newInstance().newXPath(); File file = new File("cameras.xml"); // xPath expression for extract comment XPathExpression xPathExpression = xPath.compile(...
diff --git a/test/unit/org/apache/cassandra/db/marshal/RoundTripTest.java b/test/unit/org/apache/cassandra/db/marshal/RoundTripTest.java index 685b78f8..fae1067a 100644 --- a/test/unit/org/apache/cassandra/db/marshal/RoundTripTest.java +++ b/test/unit/org/apache/cassandra/db/marshal/RoundTripTest.java @@ -1,117 +1,118 ...
true
true
public void testTimeUUID() { UUID uuid = UUIDGen.makeType1UUIDFromHost(FBUtilities.getLocalAddress()); assert TimeUUIDType.instance.getString(TimeUUIDType.instance.fromString(uuid.toString())) .equals(uuid.toString()); assert TimeUUIDType.instance.fromString(TimeUUIDType....
public void testTimeUUID() { UUID uuid = UUIDGen.makeType1UUIDFromHost(FBUtilities.getLocalAddress()); assert TimeUUIDType.instance.getString(TimeUUIDType.instance.fromString(uuid.toString())) .equals(uuid.toString()); assert TimeUUIDType.instance.fromString(TimeUUIDType....
diff --git a/GUI.java b/GUI.java index 99fd439..155968f 100644 --- a/GUI.java +++ b/GUI.java @@ -1,147 +1,147 @@ import java.awt.*; import java.awt.event.*; import javax.swing.*; import javax.swing.UIManager.*; public class GUI extends JFrame implements ActionListener { private JButton waveButton; ...
false
true
GUI() { attemptNimbusStyle(); setTitle("Volume Integral Visualizer"); waveButton = new JButton("Wave" ); wavierButton = new JButton("Wavier"); //=========================================| defaultShaderButton = new JButton("Plain" ); phongShad...
GUI() { attemptNimbusStyle(); setTitle("Volume Integral Visualizer"); waveButton = new JButton("Wave" ); wavierButton = new JButton("Wavier"); //=========================================| defaultShaderButton = new JButton("Plain" ); phongShad...
diff --git a/bugrap-ui/src/main/java/com/vaadin/training/bugrap/view/reports/components/ManageButtonsLayout.java b/bugrap-ui/src/main/java/com/vaadin/training/bugrap/view/reports/components/ManageButtonsLayout.java index 3993162..c2f36a6 100644 --- a/bugrap-ui/src/main/java/com/vaadin/training/bugrap/view/reports/compo...
true
true
public ManageButtonsLayout() { setWidth("100%"); Button reportBugButton = new Button("Report a bug", new Button.ClickListener() { @Override public void buttonClick(Button.ClickEvent event) { presenter.reportBugButtonClicked(); } }); ...
public ManageButtonsLayout() { setWidth("100%"); Button reportBugButton = new Button("Report a bug", new Button.ClickListener() { @Override public void buttonClick(Button.ClickEvent event) { presenter.reportBugButtonClicked(); } }); ...
diff --git a/plugins/SPIMAcquisition/spim/progacq/OMETIFFHandler.java b/plugins/SPIMAcquisition/spim/progacq/OMETIFFHandler.java index a1d104726..cd421c38d 100644 --- a/plugins/SPIMAcquisition/spim/progacq/OMETIFFHandler.java +++ b/plugins/SPIMAcquisition/spim/progacq/OMETIFFHandler.java @@ -1,198 +1,198 @@ package sp...
true
true
public OMETIFFHandler(CMMCore iCore, File outDir, String xyDev, String cDev, String zDev, String tDev, AcqRow[] acqRows, int iTimeSteps, double iDeltaT) { if(outDir == null || !outDir.exists() || !outDir.isDirectory()) throw new IllegalArgumentException("Null path specified: " + outDir.toString()); imag...
public OMETIFFHandler(CMMCore iCore, File outDir, String xyDev, String cDev, String zDev, String tDev, AcqRow[] acqRows, int iTimeSteps, double iDeltaT) { if(outDir == null || !outDir.exists() || !outDir.isDirectory()) throw new IllegalArgumentException("Null path specified: " + outDir.toString()); imag...
diff --git a/src/main/java/see/functions/service/ExtensibleApply.java b/src/main/java/see/functions/service/ExtensibleApply.java index 02a2a8d..ca02617 100644 --- a/src/main/java/see/functions/service/ExtensibleApply.java +++ b/src/main/java/see/functions/service/ExtensibleApply.java @@ -1,68 +1,68 @@ /* * Copyright...
true
true
public VarArgFunction<Object, Object> apply(@Nonnull final Context context) { return new VarArgFunction<Object, Object>() { @Override public Object apply(@Nonnull List<Object> args) { Preconditions.checkArgument(args.size() >= 1, "Apply takes one or more arguments"); ...
public VarArgFunction<Object, Object> apply(@Nonnull final Context context) { return new VarArgFunction<Object, Object>() { @Override public Object apply(@Nonnull List<Object> args) { Preconditions.checkArgument(args.size() >= 1, "Apply takes one or more arguments"); ...
diff --git a/okapi/steps/diffleverage/src/main/java/net/sf/okapi/steps/diffleverage/DiffLeverageStep.java b/okapi/steps/diffleverage/src/main/java/net/sf/okapi/steps/diffleverage/DiffLeverageStep.java index a071c4e48..e7ea5c8a6 100644 --- a/okapi/steps/diffleverage/src/main/java/net/sf/okapi/steps/diffleverage/DiffLeve...
true
true
private void diffLeverage() { DiffLists<TextUnit> diffTextUnits; diffTextUnits = new DiffLists<TextUnit>(oldTextUnits, newTextUnits, sourceComparator); // diff the two TextUnit lists based on the provided Comparator diffTextUnits.diff(); // loop through the matches and copy over the old target to the new ...
private void diffLeverage() { DiffLists<TextUnit> diffTextUnits; diffTextUnits = new DiffLists<TextUnit>(oldTextUnits, newTextUnits, sourceComparator); // diff the two TextUnit lists based on the provided Comparator diffTextUnits.diff(); // loop through the matches and copy over the old target to the new ...
diff --git a/java/testing/org/apache/derbyTesting/functionTests/tests/store/RecoveryAfterBackup.java b/java/testing/org/apache/derbyTesting/functionTests/tests/store/RecoveryAfterBackup.java index f95eb948f..d825c14d5 100644 --- a/java/testing/org/apache/derbyTesting/functionTests/tests/store/RecoveryAfterBackup.java +...
true
true
public static void main(String[] argv) throws Throwable { try { ij.getPropertyArg(argv); Connection conn = ij.startJBMS(); conn.setAutoCommit(true); // After recovery table should contain two records with // values 0 and 1 ...
public static void main(String[] argv) throws Throwable { try { ij.getPropertyArg(argv); Connection conn = ij.startJBMS(); conn.setAutoCommit(true); // After recovery table should contain two records with // values 0 and 1 ...
diff --git a/src/main/java/at/yawk/snap/SnapTrayIcon.java b/src/main/java/at/yawk/snap/SnapTrayIcon.java index 6a9ea2b..8079609 100644 --- a/src/main/java/at/yawk/snap/SnapTrayIcon.java +++ b/src/main/java/at/yawk/snap/SnapTrayIcon.java @@ -1,132 +1,126 @@ package at.yawk.snap; import java.awt.AWTException; import...
true
true
public void run() { try { trayIcon = new TrayIcon(generateLogo()); trayIcon.setToolTip("YawkatSnap"); final PopupMenu popup = new PopupMenu(); final MenuItem exit = new MenuItem("Exit"); exit.addActionListener(new ActionListener() { ...
public void run() { try { trayIcon = new TrayIcon(generateLogo()); trayIcon.setToolTip("YawkatSnap"); final PopupMenu popup = new PopupMenu(); final MenuItem exit = new MenuItem("Exit"); exit.addActionListener(new ActionListener() { ...
diff --git a/src/main/java/reindent/Reindent.java b/src/main/java/reindent/Reindent.java index 795f1d0..ac9d9f4 100644 --- a/src/main/java/reindent/Reindent.java +++ b/src/main/java/reindent/Reindent.java @@ -1,69 +1,68 @@ /** * */ package reindent; import java.io.File; import java.io.FileNotFoundException; ...
true
true
public static void main(String[] args) { // Argument checking if(args.length != 2) { System.err.println("Usage: java reindent.Reindent INFILE OUTFILE"); System.exit(1); } // Input file checking File inFile = new File(args[0]); if(!inFile.isFile() || !inFile.canRead() || inFile.length() <= 0) { ...
public static void main(String[] args) { // Argument checking if(args.length != 2) { System.err.println("Usage: java reindent.Reindent INFILE OUTFILE"); System.exit(1); } // Input file checking File inFile = new File(args[0]); if(!inFile.isFile() || !inFile.canRead() || inFile.length() <= 0) { ...
diff --git a/src/com/pokebros/android/pokemononline/battle/Battle.java b/src/com/pokebros/android/pokemononline/battle/Battle.java index f75bad34..224c7f41 100644 --- a/src/com/pokebros/android/pokemononline/battle/Battle.java +++ b/src/com/pokebros/android/pokemononline/battle/Battle.java @@ -1,295 +1,295 @@ package ...
true
true
public void dealWithCommand(BattleCommand bc, byte player, Bais msg) { switch(bc) { case SendOut: { if (player != me) { super.dealWithCommand(bc, player, msg); return; } boolean silent = msg.readBool(); byte fromSpot = msg.readByte(); BattlePoke temp = myTeam.pokes[0]; myTeam.pok...
public void dealWithCommand(BattleCommand bc, byte player, Bais msg) { switch(bc) { case SendOut: { if (player != me) { super.dealWithCommand(bc, player, msg); return; } boolean silent = msg.readBool(); byte fromSpot = msg.readByte(); BattlePoke temp = myTeam.pokes[0]; myTeam.pok...
diff --git a/rhogen-wizard/src/rhogenwizard/builder/RhogenBuilder.java b/rhogen-wizard/src/rhogenwizard/builder/RhogenBuilder.java index ba3128b..c4e27da 100644 --- a/rhogen-wizard/src/rhogenwizard/builder/RhogenBuilder.java +++ b/rhogen-wizard/src/rhogenwizard/builder/RhogenBuilder.java @@ -1,70 +1,70 @@ package rhog...
true
true
protected IProject[] build(int kind, Map args, final IProgressMonitor monitor) throws CoreException { try { String platformName = (String) getProject().getSessionProperty(getPlatformQualifier()); if (kind != CLEAN_BUILD && platformName != null) { ConsoleHelper.consolePrint("Build project " ...
protected IProject[] build(int kind, Map args, final IProgressMonitor monitor) throws CoreException { try { String platformName = (String) getProject().getSessionProperty(getPlatformQualifier()); if (kind != CLEAN_BUILD && platformName != null) { ConsoleHelper.consolePrint("Build project " ...
diff --git a/loci/visbio/overlays/OverlayTransform.java b/loci/visbio/overlays/OverlayTransform.java index 64c9c423b..d9964bd6d 100644 --- a/loci/visbio/overlays/OverlayTransform.java +++ b/loci/visbio/overlays/OverlayTransform.java @@ -1,819 +1,819 @@ // // OverlayTransform.java // /* VisBio application for vis...
false
true
public String distributeObjects(int[] pos) { int ndx = MathUtil.positionToRaster(lengths, pos); if (ndx < 0 || ndx >= overlays.length) { return "Invalid dimensional position."; } // grab overlay from the clipboard int size = clipboard.size(); if (size == 0) { return "You must firs...
public String distributeObjects(int[] pos) { int ndx = MathUtil.positionToRaster(lengths, pos); if (ndx < 0 || ndx >= overlays.length) { return "Invalid dimensional position."; } // grab overlay from the clipboard int size = clipboard.size(); if (size == 0) { return "You must firs...
diff --git a/bConomy/src/uk/codingbadgers/bconomy/config/Config.java b/bConomy/src/uk/codingbadgers/bconomy/config/Config.java index 8c06b5d..6ea3e24 100644 --- a/bConomy/src/uk/codingbadgers/bconomy/config/Config.java +++ b/bConomy/src/uk/codingbadgers/bconomy/config/Config.java @@ -1,82 +1,82 @@ package uk.codingbad...
true
true
public static boolean setupConfig() { FileConfiguration config = Global.getPlugin().getConfig(); try { // database config config.addDefault("database.driver", "SQL"); config.addDefault("database.host", "localhost"); config.addDefault("database.dbname", "bConomy"); config.addDefault("database.t...
public static boolean setupConfig() { FileConfiguration config = Global.getModule().getConfig(); try { // database config config.addDefault("database.driver", "SQL"); config.addDefault("database.host", "localhost"); config.addDefault("database.dbname", "bConomy"); config.addDefault("database.t...
diff --git a/src/org/bukkit/plugin/java/JavaPluginLoader.java b/src/org/bukkit/plugin/java/JavaPluginLoader.java index 085e96f7..bd6d0f86 100644 --- a/src/org/bukkit/plugin/java/JavaPluginLoader.java +++ b/src/org/bukkit/plugin/java/JavaPluginLoader.java @@ -1,55 +1,55 @@ package org.bukkit.plugin.java; import ja...
true
true
public Plugin loadPlugin(File file) throws InvalidPluginException { JavaPlugin result = null; PluginDescriptionFile description = new PluginDescriptionFile("Sample Plugin", "org.bukkit.plugin.sample.main"); if (!file.exists()) { throw new InvalidPluginException(new FileNotFoundE...
public Plugin loadPlugin(File file) throws InvalidPluginException { JavaPlugin result = null; PluginDescriptionFile description = new PluginDescriptionFile("Sample Plugin", "org.bukkit.plugin.sample.main"); if (!file.exists()) { throw new InvalidPluginException(new FileNotFoundE...
diff --git a/working-capital/src/module/workingCapital/domain/util/WorkingCapitalInitializationBean.java b/working-capital/src/module/workingCapital/domain/util/WorkingCapitalInitializationBean.java index b7aa43dd..1a70d262 100644 --- a/working-capital/src/module/workingCapital/domain/util/WorkingCapitalInitializationB...
true
true
public WorkingCapitalInitialization create() { String iban = internationalBankAccountNumber == null || internationalBankAccountNumber.isEmpty() || !Character.isDigit(internationalBankAccountNumber.charAt(0)) ? internationalBankAccountNumber : "PT50" + internationalBankAccountNumber; return new WorkingCapitalI...
public WorkingCapitalInitialization create() { String iban = internationalBankAccountNumber == null || internationalBankAccountNumber.isEmpty() || !Character.isDigit(internationalBankAccountNumber.charAt(0)) ? internationalBankAccountNumber : "PT50" + internationalBankAccountNumber; return new WorkingCapitalI...
diff --git a/src/cubetech/client/MessageField.java b/src/cubetech/client/MessageField.java index 4e6b7f6..a30d875 100644 --- a/src/cubetech/client/MessageField.java +++ b/src/cubetech/client/MessageField.java @@ -1,76 +1,76 @@ package cubetech.client; import cubetech.gfx.Sprite; import cubetech.gfx.SpriteManager.T...
false
true
public void Render() { String extraHax = ""; if(this == Ref.client.message.chatField) extraHax = "say: "; // hot-wire chat capability boolean cardi = isActive() && (int)(Ref.client.realtime / 250f)%2 == 1; String str = extraHax + buffer.toString() + (cardi?"_":""); ...
public void Render() { String extraHax = ""; if(this == Ref.client.message.chatField) extraHax = "say: "; // hot-wire chat capability boolean cardi = isActive() && (int)(Ref.client.realtime / 250f)%2 == 1; String str = extraHax + buffer.toString() + (cardi?"_":" "); ...
diff --git a/src/com/herocraftonline/dev/heroes/skill/skills/SkillRoot.java b/src/com/herocraftonline/dev/heroes/skill/skills/SkillRoot.java index 39af3a49..efa7a898 100644 --- a/src/com/herocraftonline/dev/heroes/skill/skills/SkillRoot.java +++ b/src/com/herocraftonline/dev/heroes/skill/skills/SkillRoot.java @@ -1,149...
true
true
public boolean use(Hero hero, LivingEntity target, String[] args) { Player player = hero.getPlayer(); if (player.equals(target) || hero.getSummons().contains(target)) if (!(target instanceof Player)) { Messaging.send(player, "You need a target!"); return false; ...
public boolean use(Hero hero, LivingEntity target, String[] args) { Player player = hero.getPlayer(); if (player.equals(target) || hero.getSummons().contains(target)) { Messaging.send(player, "You need a target!"); return false; } //PvP Check if (targ...
diff --git a/MinFinal/src/org/min/packkmean/Main.java b/MinFinal/src/org/min/packkmean/Main.java index 148819f..9ed3a3e 100644 --- a/MinFinal/src/org/min/packkmean/Main.java +++ b/MinFinal/src/org/min/packkmean/Main.java @@ -1,17 +1,17 @@ package org.min.packkmean; public class Main { public static void main(S...
true
true
public static void main(String[] args) { //Cargamos el fichero Properties LoadProperties loadP = new LoadProperties(args[0]); loadP.load(); //Cargamos los datos del fichero .arff LoadData loadD = new LoadData(loadP.getData()); ListaEntidades lista = loadD.CargarDatos(); //Llamamos a k-means }
public static void main(String[] args) { //Cargamos el fichero Properties LoadProperties loadP = new LoadProperties(args[0]); loadP.load(); //Cargamos los datos del fichero .arff LoadData loadD = new LoadData(loadP.getData()); ListaEntidades lista = loadD.CargarDatos(loadP.getK()); //Llamamos a k-m...
diff --git a/atlas-web/src/test/java/uk/ac/ebi/gxa/web/AtlasPlotterAssayFactorValuesTest.java b/atlas-web/src/test/java/uk/ac/ebi/gxa/web/AtlasPlotterAssayFactorValuesTest.java index 328bbd34d..b45792465 100644 --- a/atlas-web/src/test/java/uk/ac/ebi/gxa/web/AtlasPlotterAssayFactorValuesTest.java +++ b/atlas-web/src/te...
true
true
public void testAssayFactorValues() { String[] factorValues = new String[]{"value1", "value2", "value1", "value2", "value3"}; List<Float> expressions = Arrays.asList(1.0f, 2.0f, 1.0f, 2.0f, 3.0f, 0.0f); assertEquals(factorValues.length, expressions.size()); AssayFactorValues afv = n...
public void testAssayFactorValues() { String[] factorValues = new String[]{"value1", "value2", "value1", "value2", "value3"}; List<Float> expressions = Arrays.asList(1.0f, 2.0f, 1.0f, 2.0f, 3.0f); assertEquals(factorValues.length, expressions.size()); AssayFactorValues afv = new Ass...
diff --git a/brunson/src/edu/ntnu/brunson/player/Phase2Player.java b/brunson/src/edu/ntnu/brunson/player/Phase2Player.java index 68eb900..fa25c8a 100644 --- a/brunson/src/edu/ntnu/brunson/player/Phase2Player.java +++ b/brunson/src/edu/ntnu/brunson/player/Phase2Player.java @@ -1,84 +1,84 @@ package edu.ntnu.brunson.pla...
false
true
public Action act(Round round, Pile community, int bet, int raises, int pot, int players) { if(round == Round.PREFLOP) { return getPreflopAction(bet,raises, players, pot); } double handStrength = HandRating.strength(this.getHand(), community, players); if(bet == 1) { if(Util.potOdds(pot, bet) > han...
public Action act(Round round, Pile community, int bet, int raises, int pot, int players) { if(round == Round.PREFLOP) { return getPreflopAction(bet,raises, players, pot); } double handStrength = HandRating.strength(this.getHand(), community, players); if(bet > 0) { if(Util.potOdds(pot, bet) < hand...
diff --git a/src/main/java/net/worldoftomorrow/noitem/util/Updater.java b/src/main/java/net/worldoftomorrow/noitem/util/Updater.java index 7a4b185..c405b73 100644 --- a/src/main/java/net/worldoftomorrow/noitem/util/Updater.java +++ b/src/main/java/net/worldoftomorrow/noitem/util/Updater.java @@ -1,564 +1,567 @@ packag...
false
true
private void unzip(String file) { try { File fSourceZip = new File(file); String zipPath = file.substring(0, file.length() - 4); ZipFile zipFile = new ZipFile(fSourceZip); Enumeration<? extends ZipEntry> e = zipFile.entries(); while (e.hasMoreElements()) { ZipEntry entry = (ZipEntry) e.nextElement...
private void unzip(String file) { try { File fSourceZip = new File(file); String zipPath = file.substring(0, file.length() - 4); ZipFile zipFile = new ZipFile(fSourceZip); Enumeration<? extends ZipEntry> e = zipFile.entries(); while (e.hasMoreElements()) { ZipEntry entry = (ZipEntry) e.nextElement...
diff --git a/src/main/battlecode/engine/instrumenter/IndividualClassLoader.java b/src/main/battlecode/engine/instrumenter/IndividualClassLoader.java index 64b3d7ca..85d12ed2 100644 --- a/src/main/battlecode/engine/instrumenter/IndividualClassLoader.java +++ b/src/main/battlecode/engine/instrumenter/IndividualClassLoade...
true
true
protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { synchronized(teamPackageName) { // check if the team we're loading already has errors if(teamsWithErrors.contains(teamPackageName)) throw new InstrumentationException(); name = name.replace('.','/'); // thi...
protected Class<?> loadClass(String name, boolean resolve) throws ClassNotFoundException { synchronized(teamPackageName) { // check if the team we're loading already has errors if(teamsWithErrors.contains(teamPackageName)) throw new InstrumentationException(); name = name.replace('.','/'); // thi...
diff --git a/TwistedMod_common/com/mrgreaper/twisted/items/recipies.java b/TwistedMod_common/com/mrgreaper/twisted/items/recipies.java index e2131ec..e6abf4e 100644 --- a/TwistedMod_common/com/mrgreaper/twisted/items/recipies.java +++ b/TwistedMod_common/com/mrgreaper/twisted/items/recipies.java @@ -1,83 +1,83 @@ pack...
true
true
public static void registerRecipes() { /* GameRegistry.addRecipe(new ItemStack(wand),//output item new Object[] { " X",//crafting grid " / ", "/ ", 'X', Item.goldenCarrot, //items used in the above list '/', Item.stick }); */ //my recipes GameRegistry.addRecipe(new ItemStack(Items....
public static void registerRecipes() { /* GameRegistry.addRecipe(new ItemStack(wand),//output item new Object[] { " X",//crafting grid " / ", "/ ", 'X', Item.goldenCarrot, //items used in the above list '/', Item.stick }); */ //my recipes GameRegistry.addRecipe(new ItemStack(Items....
diff --git a/src/uk/co/timwise/sqlhawk/html/HtmlDiagramFormatter.java b/src/uk/co/timwise/sqlhawk/html/HtmlDiagramFormatter.java index de43833..81698dd 100644 --- a/src/uk/co/timwise/sqlhawk/html/HtmlDiagramFormatter.java +++ b/src/uk/co/timwise/sqlhawk/html/HtmlDiagramFormatter.java @@ -1,56 +1,56 @@ /* This file is ...
true
true
protected Dot getDot() { Dot dot = Dot.getInstance(); if (!dot.exists()) { if (!printedNoDotWarning) { printedNoDotWarning = true; System.err.println(); System.err.println("Warning: Failed to run dot."); System.err.println(" Download " + dot.getSupportedVersions()); System.err.println(" ...
protected Dot getDot() { Dot dot = Dot.getInstance(); if (!dot.exists()) { if (!printedNoDotWarning) { printedNoDotWarning = true; System.err.println(); System.err.println("Warning: Failed to run dot."); System.err.println(" Download " + dot.getSupportedVersions()); System.err.println(" ...
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/repo/RepositoryRoot.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/repo/RepositoryRoot.java index e2fd68883..8e7c3ea2f 100644 --- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/repo/...
true
true
public void writeState(XMLWriter writer) throws IOException { HashMap attributes = new HashMap(); attributes.clear(); attributes.put(RepositoriesViewContentHandler.ID_ATTRIBUTE, root.getLocation()); String programName = ((CVSRepositoryLocation)root).getRemoteCVSProgramName(); if (!programName.equals(CVSRep...
public void writeState(XMLWriter writer) throws IOException { HashMap attributes = new HashMap(); attributes.clear(); attributes.put(RepositoriesViewContentHandler.ID_ATTRIBUTE, root.getLocation()); String programName = ((CVSRepositoryLocation)root).getRemoteCVSProgramName(); if (!programName.equals(CVSRep...
diff --git a/CamelRouteSecurity/src/main/java/com/trivadis/camel/security/rb/CategoryShiroRouteBuilder.java b/CamelRouteSecurity/src/main/java/com/trivadis/camel/security/rb/CategoryShiroRouteBuilder.java index 6e0eebd..c7de8af 100644 --- a/CamelRouteSecurity/src/main/java/com/trivadis/camel/security/rb/CategoryShiroRo...
true
true
public void configure() throws Exception { final byte[] passPhrase = "CamelSecureRoute".getBytes(); List<Permission> permissionsList = new ArrayList<Permission>(); Permission permission = new WildcardPermission( "trivadis:calculateCategory:*"); permissionsList.add(permission); ShiroSecurityPolicy shiro...
public void configure() throws Exception { final byte[] passPhrase = "CamelSecureRoute".getBytes(); List<Permission> permissionsList = new ArrayList<Permission>(); Permission permission = new WildcardPermission( "trivadis:calculateCategory:*"); permissionsList.add(permission); ShiroSecurityPolicy shiro...
diff --git a/WeCharades/src/com/example/wecharades/presenter/GameDashboardPresenter.java b/WeCharades/src/com/example/wecharades/presenter/GameDashboardPresenter.java index 97dbc48..4a3709d 100644 --- a/WeCharades/src/com/example/wecharades/presenter/GameDashboardPresenter.java +++ b/WeCharades/src/com/example/wecharad...
true
true
private void updateButtonInformation(Turn turn, Button button) { //TODO This method is a bit elaborate String buttonText = ""; if(game.isFinished() || (turn.getTurnNumber() < game.getTurn()) ) { buttonText = (turn.getAnsPlayer().equals(dc.getCurrentPlayer())) ? turn.getAnsPlayerScore() + " points" ...
private void updateButtonInformation(Turn turn, Button button) { //TODO This method is a bit elaborate String buttonText = ""; if(game.isFinished() || (turn.getTurnNumber() < game.getTurn()) ) { buttonText = (turn.getAnsPlayer().equals(dc.getCurrentPlayer())) ? turn.getAnsPlayerScore() + " points" ...
diff --git a/deegree-core/deegree-core-commons/src/main/java/org/deegree/commons/config/DeegreeWorkspace.java b/deegree-core/deegree-core-commons/src/main/java/org/deegree/commons/config/DeegreeWorkspace.java index ef3fea24df..4326c1605c 100644 --- a/deegree-core/deegree-core-commons/src/main/java/org/deegree/commons/c...
true
true
private void load() { // setup classloader File modules = new File( dir, "modules" ); moduleClassLoader = Thread.currentThread().getContextClassLoader(); if ( modules.exists() ) { File[] fs = modules.listFiles(); if ( fs != null ) { List<URL> u...
private void load() { // setup classloader File modules = new File( dir, "modules" ); moduleClassLoader = Thread.currentThread().getContextClassLoader(); if ( modules.exists() ) { File[] fs = modules.listFiles(); if ( fs != null ) { List<URL> u...
diff --git a/trunk/src/webcamstudio/sources/VideoSourceV4L.java b/trunk/src/webcamstudio/sources/VideoSourceV4L.java index 46da65e..a2766b4 100644 --- a/trunk/src/webcamstudio/sources/VideoSourceV4L.java +++ b/trunk/src/webcamstudio/sources/VideoSourceV4L.java @@ -1,319 +1,319 @@ /** * WebcamStudio for GNU/Linux ...
true
true
private void startSource2() { isPlaying = true; stopMe = false; location = getDeviceForName(name, new File(location)).getAbsolutePath(); try { sink = new RGBDataSink(name + uuId, this); sink.setPassDirectBuffer(true); String rescaling = ""; ...
private void startSource2() { isPlaying = true; stopMe = false; location = getDeviceForName(name, new File(location)).getAbsolutePath(); try { sink = new RGBDataSink(name + uuId, this); sink.setPassDirectBuffer(true); String rescaling = ""; ...
diff --git a/project/src/main/java/org/springframework/roo/project/MavenCommands.java b/project/src/main/java/org/springframework/roo/project/MavenCommands.java index b5d26afbc..3b5415840 100644 --- a/project/src/main/java/org/springframework/roo/project/MavenCommands.java +++ b/project/src/main/java/org/springframewor...
false
true
public void createProject( @CliOption(key = { "", "topLevelPackage" }, mandatory = true, optionContext = "update", help = "The uppermost package name (this becomes the <groupId> in Maven and also the '~' value when using Roo's shell)") final JavaPackage topLevelPackage, @CliOption(key = "projectName", mandatory = ...
public void createProject( @CliOption(key = { "", "topLevelPackage" }, mandatory = true, optionContext = "update", help = "The uppermost package name (this becomes the <groupId> in Maven and also the '~' value when using Roo's shell)") final JavaPackage topLevelPackage, @CliOption(key = "projectName", mandatory = ...
diff --git a/src/com/cpdev/RecorderService.java b/src/com/cpdev/RecorderService.java index b48285f..c34a643 100644 --- a/src/com/cpdev/RecorderService.java +++ b/src/com/cpdev/RecorderService.java @@ -1,64 +1,64 @@ package com.cpdev; import android.content.Intent; import android.os.Binder; import android.os.IBind...
true
true
public void stopRecording(RadioActivity view) { Log.d(TAG, "Stopping recording"); caller = view; RadioApplication radioApplication = (RadioApplication) this.getApplicationContext(); RecordingTask recordingTask = radioApplication.getRecordingTask(); recordingTask.cancel(true);...
public void stopRecording(RadioActivity view) { Log.d(TAG, "Stopping recording"); caller = view; RadioApplication radioApplication = (RadioApplication) this.getApplicationContext(); RecordingTask recordingTask = radioApplication.getRecordingTask(); recordingTask.cancel(true);...
diff --git a/src/sk/ksp/riso/svpismo/svpismo.java b/src/sk/ksp/riso/svpismo/svpismo.java index 6461d08..f64b746 100644 --- a/src/sk/ksp/riso/svpismo/svpismo.java +++ b/src/sk/ksp/riso/svpismo/svpismo.java @@ -1,262 +1,262 @@ package sk.ksp.riso.svpismo; import android.app.Activity; import android.os.Bundle; impor...
false
true
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); final svpismo myself = this; requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.svpismo); SharedPreferences settings = getSharedPreferences(prefname, 0); s...
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); final svpismo myself = this; requestWindowFeature(Window.FEATURE_NO_TITLE); setContentView(R.layout.svpismo); SharedPreferences settings = getSharedPreferences(prefname, 0); s...
diff --git a/nexus/nexus-test-harness/nexus-test-harness-its/src/test/java/org/sonatype/nexus/integrationtests/nexus977tasks/Nexus977GroupOfGroupsSnapshotRemoverTaskTaskIT.java b/nexus/nexus-test-harness/nexus-test-harness-its/src/test/java/org/sonatype/nexus/integrationtests/nexus977tasks/Nexus977GroupOfGroupsSnapshot...
false
true
public void snapshotRemoval() throws Exception { String path = "nexus977tasks/project/1.0-SNAPSHOT/project-1.0-20100520.154534-88.jar"; downloadFile( new URL( AbstractNexusIntegrationTest.nexusBaseUrl + REPOSITORY_RELATIVE_URL + "g4/" + path ), "target/downloads/nex...
public void snapshotRemoval() throws Exception { String path = "nexus977tasks/project/1.0-SNAPSHOT/project-1.0-20100520.154534-88.jar"; downloadFile( new URL( AbstractNexusIntegrationTest.nexusBaseUrl + REPOSITORY_RELATIVE_URL + "g4/" + path ), "target/downloads/nex...
diff --git a/src/de/bananaco/bpermissions/imp/Config.java b/src/de/bananaco/bpermissions/imp/Config.java index 985d7e7..c6bc091 100644 --- a/src/de/bananaco/bpermissions/imp/Config.java +++ b/src/de/bananaco/bpermissions/imp/Config.java @@ -1,65 +1,65 @@ package de.bananaco.bpermissions.imp; import java.io.File; ...
true
true
private void loadUnsafe() throws Exception { // Your standard create if not exist shizzledizzle if(!file.exists()) { if(file.getParentFile() != null) file.getParentFile().mkdirs(); file.createNewFile(); } config.load(file); // set the value to default config.set("auto-save", config.get("auto-save...
private void loadUnsafe() throws Exception { // Your standard create if not exist shizzledizzle if(!file.exists()) { if(file.getParentFile() != null) file.getParentFile().mkdirs(); file.createNewFile(); } config.load(file); // set the value to default config.set("auto-save", config.get("auto-save...
diff --git a/src/main/java/ru/tehkode/modifyworld/handlers/EntityListener.java b/src/main/java/ru/tehkode/modifyworld/handlers/EntityListener.java index 0f667ca..1440113 100644 --- a/src/main/java/ru/tehkode/modifyworld/handlers/EntityListener.java +++ b/src/main/java/ru/tehkode/modifyworld/handlers/EntityListener.java...
true
true
public void onEntityDamage(EntityDamageEvent event) { if (event instanceof EntityDamageByEntityEvent) { EntityDamageByEntityEvent edbe = (EntityDamageByEntityEvent) event; Player player; if (edbe.getDamager() instanceof Player) { // Prevent from damaging by player player = (Player) edbe.getDamager(); ...
public void onEntityDamage(EntityDamageEvent event) { if (event instanceof EntityDamageByEntityEvent) { EntityDamageByEntityEvent edbe = (EntityDamageByEntityEvent) event; Player player; if (edbe.getDamager() instanceof Player) { // Prevent from damaging by player player = (Player) edbe.getDamager(); ...
diff --git a/src/net/java/games/jogl/impl/windows/WindowsGLContext.java b/src/net/java/games/jogl/impl/windows/WindowsGLContext.java index d58a781a8..0dd05f7ba 100644 --- a/src/net/java/games/jogl/impl/windows/WindowsGLContext.java +++ b/src/net/java/games/jogl/impl/windows/WindowsGLContext.java @@ -1,631 +1,633 @@ /*...
false
true
protected void choosePixelFormatAndCreateContext(boolean onscreen) { PIXELFORMATDESCRIPTOR pfd = null; int pixelFormat = 0; if (onscreen) { GLCapabilities[] availableCaps = null; int numFormats = 0; pfd = newPixelFormatDescriptor(); GraphicsDevice device = component.getGraphicsConf...
protected void choosePixelFormatAndCreateContext(boolean onscreen) { PIXELFORMATDESCRIPTOR pfd = null; int pixelFormat = 0; if (onscreen) { GLCapabilities[] availableCaps = null; int numFormats = 0; pfd = newPixelFormatDescriptor(); GraphicsDevice device = component.getGraphicsConf...
diff --git a/apache/src/main/java/org/rhq/plugins/apache/util/RuntimeApacheConfiguration.java b/apache/src/main/java/org/rhq/plugins/apache/util/RuntimeApacheConfiguration.java index 3e11ff3353..1f00aec427 100644 --- a/apache/src/main/java/org/rhq/plugins/apache/util/RuntimeApacheConfiguration.java +++ b/apache/src/mai...
false
true
private static <T> void transform(TreeWalker<T> walker, T parentNode, TransformState state) { if (walker.getChildren(parentNode).isEmpty()) { return; } walker.onBeforeChildrenScan(parentNode); for (T node : walker.getChildren(parentNode)) { boolean recurseFu...
private static <T> void transform(TreeWalker<T> walker, T parentNode, TransformState state) { if (walker.getChildren(parentNode).isEmpty()) { return; } walker.onBeforeChildrenScan(parentNode); for (T node : walker.getChildren(parentNode)) { boolean recurseFu...
diff --git a/src/com/android/bluetooth/opp/BluetoothOppReceiver.java b/src/com/android/bluetooth/opp/BluetoothOppReceiver.java index 8a2c46f..6364e1c 100644 --- a/src/com/android/bluetooth/opp/BluetoothOppReceiver.java +++ b/src/com/android/bluetooth/opp/BluetoothOppReceiver.java @@ -1,288 +1,288 @@ /* * Copyright (...
true
true
public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if (action.equals(BluetoothAdapter.ACTION_STATE_CHANGED)) { if (BluetoothAdapter.STATE_ON == intent.getIntExtra( BluetoothAdapter.EXTRA_STATE, BluetoothAdapter.ERROR)) { ...
public void onReceive(Context context, Intent intent) { String action = intent.getAction(); if (action.equals(BluetoothAdapter.ACTION_STATE_CHANGED)) { if (BluetoothAdapter.STATE_ON == intent.getIntExtra( BluetoothAdapter.EXTRA_STATE, BluetoothAdapter.ERROR)) { ...
diff --git a/main/src/jp/ac/osaka_u/ist/sel/metricstool/main/data/target/ArrayConstructorCallInfo.java b/main/src/jp/ac/osaka_u/ist/sel/metricstool/main/data/target/ArrayConstructorCallInfo.java index 95ce8e5a..e7b3d032 100644 --- a/main/src/jp/ac/osaka_u/ist/sel/metricstool/main/data/target/ArrayConstructorCallInfo.ja...
true
true
public String getText() { final StringBuilder text = new StringBuilder(); text.append("new "); final ArrayTypeInfo arrayType = this.getType(); final TypeInfo elementType = arrayType.getElementType(); text.append(elementType.getTypeName()); final int dimension = arr...
public String getText() { final StringBuilder text = new StringBuilder(); text.append("new "); final ArrayTypeInfo arrayType = this.getType(); final TypeInfo elementType = arrayType.getElementType(); text.append(elementType.getTypeName()); final int dimension = arr...
diff --git a/addon-displaystring/src/main/java/org/springframework/roo/addon/displaystring/DisplayStringMetadata.java b/addon-displaystring/src/main/java/org/springframework/roo/addon/displaystring/DisplayStringMetadata.java index d01c13e85..18ebfcdab 100644 --- a/addon-displaystring/src/main/java/org/springframework/r...
true
true
private MethodMetadata getDisplayStringMethod() { JavaSymbolName methodName = new JavaSymbolName("getDisplayString"); if (getGovernorMethod(methodName) != null) { return null; } final ImportRegistrationResolver imports = builder.getImportRegistrationResolver(); final List<?> fieldsList = CollectionUtils...
private MethodMetadata getDisplayStringMethod() { JavaSymbolName methodName = new JavaSymbolName("getDisplayString"); if (getGovernorMethod(methodName) != null) { return null; } final ImportRegistrationResolver imports = builder.getImportRegistrationResolver(); final List<?> fieldsList = CollectionUtils...
diff --git a/play-platformservices-core/src/main/java/eu/play_project/play_platformservices/PlayPlatformservices.java b/play-platformservices-core/src/main/java/eu/play_project/play_platformservices/PlayPlatformservices.java index 056dc145..19c750a3 100644 --- a/play-platformservices-core/src/main/java/eu/play_project/...
true
true
public synchronized void initComponentActivity(Body body) { if (!init) { this.logger = LoggerFactory.getLogger(this.getClass()); logger.info("Initialising {} component.", this.getClass().getSimpleName()); eleGenerator = new EleGeneratorForConstructQuery(); /* * Provide QueryDispatchApi as ...
public synchronized void initComponentActivity(Body body) { if (!init) { this.logger = LoggerFactory.getLogger(this.getClass()); logger.info("Initialising {} component.", this.getClass().getSimpleName()); eleGenerator = new EleGeneratorForConstructQuery(); /* * Provide QueryDispatchApi as ...
diff --git a/java/RsvpScore.java b/java/RsvpScore.java index c23dec5..e1291df 100644 --- a/java/RsvpScore.java +++ b/java/RsvpScore.java @@ -1,73 +1,76 @@ import java.io.BufferedWriter; import java.io.IOException; import java.io.FileWriter; import java.io.PrintWriter; import java.sql.Connection; import java.sql.D...
true
true
public static void main(final String[] args) { final String conStr = "jdbc:oracle:thin:@SMARTR510-SERV1:1521:orcl"; final String filename = "out/%s_%d_%d.csv"; final int MIN_GROUP = Integer.parseInt(args[2]); final int MAX_GROUP = Integer.parseInt(args[3]); final int MIN_WEEK = 1, MAX_WEEK = 6; ...
public static void main(final String[] args) { final String conStr = "jdbc:oracle:thin:@SMARTR510-SERV1:1521:orcl"; final String filename = "out/%s_%d_%d.csv"; final int MIN_GROUP = Integer.parseInt(args[2]); final int MAX_GROUP = Integer.parseInt(args[3]); final int MIN_WEEK = 1, MAX_WEEK = 6; ...
diff --git a/support/org/intellij/grammar/generator/ParserGenerator.java b/support/org/intellij/grammar/generator/ParserGenerator.java index c55ac0a..060d2f2 100755 --- a/support/org/intellij/grammar/generator/ParserGenerator.java +++ b/support/org/intellij/grammar/generator/ParserGenerator.java @@ -1,1172 +1,1172 @@ ...
true
true
private void generateNode(final BnfRule rule, BnfExpression node, String funcName, Set<BnfExpression> visited) { IElementType type = getEffectiveType(node); for (String s : StringUtil.split(node.getText(), "\n")) { out("// " + s); } boolean isRule = node.getParent() == rule; boolean firstNo...
private void generateNode(final BnfRule rule, BnfExpression node, String funcName, Set<BnfExpression> visited) { IElementType type = getEffectiveType(node); for (String s : StringUtil.split(node.getText(), "\n")) { out("// " + s); } boolean isRule = node.getParent() == rule; boolean firstNo...
diff --git a/src/com/google/refine/crowdsourcing/crowdflower/GetJobInfoCommand.java b/src/com/google/refine/crowdsourcing/crowdflower/GetJobInfoCommand.java index a58599a..f24d770 100644 --- a/src/com/google/refine/crowdsourcing/crowdflower/GetJobInfoCommand.java +++ b/src/com/google/refine/crowdsourcing/crowdflower/Ge...
false
true
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { String jsonString = request.getParameter("extension"); JSONObject extension = ParsingUtilities.eval...
public void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { try { String jsonString = request.getParameter("extension"); JSONObject extension = ParsingUtilities.eval...
diff --git a/org.dawnsci.conversion/src/org/dawnsci/conversion/converters/CustomNCDConverter.java b/org.dawnsci.conversion/src/org/dawnsci/conversion/converters/CustomNCDConverter.java index 05602857..4d416fa7 100644 --- a/org.dawnsci.conversion/src/org/dawnsci/conversion/converters/CustomNCDConverter.java +++ b/org.da...
false
true
protected void iterate(final ILazyDataset lz, final String nameFrag, final IConversionContext context) throws Exception { //get the x axis if required IDataset axis = null; if (context.getAxisDatasetName() != null) { axis = getAxis(context.getAxisDatasetName...
protected void iterate(final ILazyDataset lz, final String nameFrag, final IConversionContext context) throws Exception { //get the x axis if required IDataset axis = null; if (context.getAxisDatasetName() != null) { axis = getAxis(context.getAxisDatasetName...
diff --git a/src/org/redbus/ui/RedbusTabView.java b/src/org/redbus/ui/RedbusTabView.java index 46c2e0c..d370837 100644 --- a/src/org/redbus/ui/RedbusTabView.java +++ b/src/org/redbus/ui/RedbusTabView.java @@ -1,62 +1,62 @@ /* * Copyright 2011 Colin Paton - cozzarp@googlemail.com * This file is part of rEdBus. * ...
true
true
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.redbustablayout); TabHost tabHost = getTabHost(); tabHost.addTab(tabHost.newTabSpec("bookmarks").setIndicator("Bookmarks") .setContent(new Intent().setClass(this, Bookmar...
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.redbustablayout); TabHost tabHost = getTabHost(); tabHost.addTab(tabHost.newTabSpec("bookmarks").setIndicator("Bookmarks") .setContent(new Intent().setClass(this, Bookmar...
diff --git a/source/silvertrout/Network.java b/source/silvertrout/Network.java index d46d1e8..637ee39 100644 --- a/source/silvertrout/Network.java +++ b/source/silvertrout/Network.java @@ -1,930 +1,930 @@ /* _______ __ __ _______ __ * | __|__| |.--.--.-----.----.|_ ...
true
true
void onJoin(String nickname, String channelName) { User user = getUser(nickname); Channel channel = getChannel(channelName); // Its'a me mario! (It's me joining) if (user == getMyUser()) { System.out.println("Half-joining channel " + channelName); // Add cha...
void onJoin(String nickname, String channelName) { User user = getUser(nickname); Channel channel = getChannel(channelName); // Its'a me mario! (It's me joining) if (user.equals(getMyUser())) { System.out.println("Half-joining channel " + channelName); // Ad...
diff --git a/Peer/src/edu/ncsu/ip/gogo/peer/server/RFCServer.java b/Peer/src/edu/ncsu/ip/gogo/peer/server/RFCServer.java index 08a4d59..5458303 100644 --- a/Peer/src/edu/ncsu/ip/gogo/peer/server/RFCServer.java +++ b/Peer/src/edu/ncsu/ip/gogo/peer/server/RFCServer.java @@ -1,63 +1,63 @@ package edu.ncsu.ip.gogo.peer.se...
false
true
public void run() { ServerSocket serverSocket = null; try { serverSocket = new ServerSocket(rfcServerPort); } catch (IOException e) { System.out.println("RFCServer.run() - Could not start RFC server on : "+ rfcServerPort + ". Exiting!"); System.ex...
public void run() { ServerSocket serverSocket = null; try { serverSocket = new ServerSocket(rfcServerPort); } catch (IOException e) { System.out.println("RFCServer.run() - Could not start RFC server on : "+ rfcServerPort + ". Exiting!"); System.ex...
diff --git a/src/com/dmdirc/addons/ui_swing/textpane/TextPaneCanvas.java b/src/com/dmdirc/addons/ui_swing/textpane/TextPaneCanvas.java index f67ba79c..c57da84e 100644 --- a/src/com/dmdirc/addons/ui_swing/textpane/TextPaneCanvas.java +++ b/src/com/dmdirc/addons/ui_swing/textpane/TextPaneCanvas.java @@ -1,944 +1,944 @@ ...
true
true
private void paintOntoGraphics(final Graphics2D g) { final float formatWidth = getWidth() - DOUBLE_SIDE_PADDING; final float formatHeight = getHeight(); float drawPosY = formatHeight; int paragraphStart; int paragraphEnd; LineBreakMeasurer lineMeasurer; text...
private void paintOntoGraphics(final Graphics2D g) { final float formatWidth = getWidth() - DOUBLE_SIDE_PADDING; final float formatHeight = getHeight(); float drawPosY = formatHeight; int paragraphStart; int paragraphEnd; LineBreakMeasurer lineMeasurer; text...
diff --git a/src/com/RoboMobo/ActivityConnectMenu.java b/src/com/RoboMobo/ActivityConnectMenu.java index 7547df8..28aa46c 100644 --- a/src/com/RoboMobo/ActivityConnectMenu.java +++ b/src/com/RoboMobo/ActivityConnectMenu.java @@ -1,191 +1,194 @@ package com.RoboMobo; import android.app.Activity; import android.blue...
false
true
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.connect); lvDevices = (ListView) findViewById(R.id.lv_devices); btArrAdapter = new ArrayAdapter<String>(getApplicationContext(), android.R.layout.simple_expandable_list_...
public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.connect); lvDevices = (ListView) findViewById(R.id.lv_devices); btArrAdapter = new ArrayAdapter<String>(getApplicationContext(), android.R.layout.simple_expandable_list_...
diff --git a/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/model/handlers/bean/JSFRenameFieldParticipant.java b/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools/jsf/model/handlers/bean/JSFRenameFieldParticipant.java index 8551f9540..868900339 100644 --- a/jsf/plugins/org.jboss.tools.jsf/src/org/jboss/tools...
false
true
public Change createChange(IProgressMonitor pm) throws CoreException, OperationCanceledException { if (!pm.isCanceled()) { if(!updateReferences() && object == null) return null; String newName = getArguments().getNewName(); if (field != null) { JSFRenameFieldChange c2 = new JSFRenameFieldChange(field...
public Change createChange(IProgressMonitor pm) throws CoreException, OperationCanceledException { if (!pm.isCanceled()) { if(!updateReferences() && object == null) return null; String newName = getArguments().getNewName(); if (field != null) { JSFRenameFieldChange c2 = new JSFRenameFieldChange(field...
diff --git a/src/main/java/com/springrts/springls/commands/impl/ForceJoinBattleCommandProcessor.java b/src/main/java/com/springrts/springls/commands/impl/ForceJoinBattleCommandProcessor.java index d36f02d..3e94bbd 100644 --- a/src/main/java/com/springrts/springls/commands/impl/ForceJoinBattleCommandProcessor.java +++ b...
true
true
public boolean process(Client client, List<String> args) throws CommandProcessingException { boolean checksOk = super.process(client, args); if (!checksOk) { return false; } String userName = args.get(0); Client affectedClient = getContext().getClients().getClient(userName); if (affectedClient == n...
public boolean process(Client client, List<String> args) throws CommandProcessingException { boolean checksOk = super.process(client, args); if (!checksOk) { return false; } String userName = args.get(0); Client affectedClient = getContext().getClients().getClient(userName); if (affectedClient == n...
diff --git a/QuizWebsite/src/servlets/NewAccountServlet.java b/QuizWebsite/src/servlets/NewAccountServlet.java index a1e6808..0d0ae8f 100644 --- a/QuizWebsite/src/servlets/NewAccountServlet.java +++ b/QuizWebsite/src/servlets/NewAccountServlet.java @@ -1,87 +1,87 @@ package servlets; import java.io.IOException; im...
true
true
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { Connection conn = (Connection) getServletContext().getAttribute("database"); String usr = request.getParameter("username"); String pass = request.getParameter("password"); String hash = Pas...
protected void doPost(HttpServletRequest request, HttpServletResponse response) throws ServletException, IOException { Connection conn = (Connection) getServletContext().getAttribute("database"); String usr = request.getParameter("username"); String pass = request.getParameter("password"); String hash = Pas...
diff --git a/src/android/Settings.java b/src/android/Settings.java index 3378ba9..aa74caf 100644 --- a/src/android/Settings.java +++ b/src/android/Settings.java @@ -1,46 +1,43 @@ package com.codeb.cordova.plugins.settings; import org.apache.cordova.CordovaPlugin; import org.apache.cordova.CallbackContext; impo...
false
true
public boolean execute(String action, JSONArray args, CallbackContext callbackContext) throws JSONException { System.err.println("SETTINGS PLUGIN Execution"); try { if (action.equals("getBluetooth")) { String message = args.getString(0); System.err.println("SETTINGS PLUGIN Execution getBluetoot...
public boolean execute(String action, JSONArray args, CallbackContext callbackContext) throws JSONException { try { if (action.equals("getBluetooth")) { String message = args.getString(0); this.getBluetooth(message, callbackContext); return true; } return false; } catch(Exception e) { ...
diff --git a/libraries/javalib/kaffe/net/www/protocol/http/HttpURLConnection.java b/libraries/javalib/kaffe/net/www/protocol/http/HttpURLConnection.java index e7c1a049c..35777b3d3 100644 --- a/libraries/javalib/kaffe/net/www/protocol/http/HttpURLConnection.java +++ b/libraries/javalib/kaffe/net/www/protocol/http/HttpUR...
true
true
public void connect() throws IOException { for (;;) { // reset response data responseCode = -1; responseMessage = null; headerFields = new Vector(); int port; String host; if (useProxy) { port = proxyPort; host = proxyHost; } else { port = url.getPort(); host = url.getHost(); } ...
public void connect() throws IOException { for (;;) { // reset response data responseCode = -1; responseMessage = null; headerFields = new Vector(); int port; String host; if (useProxy) { port = proxyPort; host = proxyHost; } else { port = url.getPort(); host = url.getHost(); } ...
diff --git a/org.eclipse.jdt.debug.ui/ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/ClasspathContainerSourceContainerBrowser.java b/org.eclipse.jdt.debug.ui/ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/ClasspathContainerSourceContainerBrowser.java index 03a34ca0c..44de798bf 100644 --- a/org.eclipse.jdt.debug.u...
true
true
public ISourceContainer[] createSourceContainers(Shell shell, ISourceLookupDirector director) { IJavaProject project = null; ILaunchConfiguration configuration = director.getLaunchConfiguration(); if (configuration != null) { try { project = JavaRuntime.getJavaProject(configuration); } catch (CoreExcep...
public ISourceContainer[] createSourceContainers(Shell shell, ISourceLookupDirector director) { IJavaProject project = null; ILaunchConfiguration configuration = director.getLaunchConfiguration(); if (configuration != null) { try { project = JavaRuntime.getJavaProject(configuration); } catch (CoreExcep...
diff --git a/src/main/java/org/spoutcraft/client/inventory/SimpleMaterialManager.java b/src/main/java/org/spoutcraft/client/inventory/SimpleMaterialManager.java index d45f3987..19869813 100644 --- a/src/main/java/org/spoutcraft/client/inventory/SimpleMaterialManager.java +++ b/src/main/java/org/spoutcraft/client/invent...
true
true
public String getToolTip(ItemStack is) { net.minecraft.src.ItemStack itemstack = new net.minecraft.src.ItemStack(is.getTypeId(), is.getAmount(), is.getDurability()); Item rawItem = Item.itemsList[itemstack.itemID]; List<String> list; if (rawItem != null) { list = itemstack.getTooltip(Minecraft.theMinecraft....
public String getToolTip(ItemStack is) { net.minecraft.src.ItemStack itemstack = new net.minecraft.src.ItemStack(is.getTypeId(), is.getAmount(), is.getDurability()); Item rawItem = Item.itemsList[itemstack.itemID]; List<String> list; if (rawItem != null) { list = itemstack.getTooltip(Minecraft.theMinecraft....
diff --git a/app/Global.java b/app/Global.java index e6ae4c16..1a0eeb39 100644 --- a/app/Global.java +++ b/app/Global.java @@ -1,221 +1,221 @@ /* * Copyright 2013 TORCH UG * * This file is part of Graylog2. * * Graylog2 is free software: you can redistribute it and/or modify * it under the terms of the GNU...
true
true
public void onStart(Application app) { final String appSecret = app.configuration().getString("application.secret"); if (appSecret == null || appSecret.isEmpty()) { log.error("Please configure application.secret in your conf/graylog2-web-interface.conf"); throw new IllegalStateE...
public void onStart(Application app) { final String appSecret = app.configuration().getString("application.secret"); if (appSecret == null || appSecret.isEmpty()) { log.error("Please configure application.secret in your conf/graylog2-web-interface.conf"); throw new IllegalStateE...
diff --git a/Payhum/src/com/openhr/user/action/ValidateUser.java b/Payhum/src/com/openhr/user/action/ValidateUser.java index dc071d2..a962305 100644 --- a/Payhum/src/com/openhr/user/action/ValidateUser.java +++ b/Payhum/src/com/openhr/user/action/ValidateUser.java @@ -1,96 +1,97 @@ /* * To change this template, choo...
true
true
public ActionForward execute(ActionMapping map, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception { JSONArray result = null; BufferedReader bf = request.getReader(); StringBuffer sb = new StringBuffer(); String line = null; while ((line...
public ActionForward execute(ActionMapping map, ActionForm form, HttpServletRequest request, HttpServletResponse response) throws Exception { JSONArray result = null; BufferedReader bf = request.getReader(); StringBuffer sb = new StringBuffer(); String line = null; while ((line...
diff --git a/src/beads_main/net/beadsproject/beads/ugens/IIRFilter.java b/src/beads_main/net/beadsproject/beads/ugens/IIRFilter.java index a996d7b..f49d6f9 100644 --- a/src/beads_main/net/beadsproject/beads/ugens/IIRFilter.java +++ b/src/beads_main/net/beadsproject/beads/ugens/IIRFilter.java @@ -1,152 +1,152 @@ packag...
false
true
protected static IIRFilterAnalysis analyzeFilter(float[] as, float[] bs, float freq, float samplingFreq) { double w = -2 * freq * Math.PI / samplingFreq; double nr = 0, ni = 0, dr = 1, di = 0; if (bs.length > 0) { nr = bs[0]; for (int i = 1; i < bs.length; i++) { nr += bs[i] * Math.cos(w * i); ...
protected static IIRFilterAnalysis analyzeFilter(float[] bs, float[] as, float freq, float samplingFreq) { double w = -2 * freq * Math.PI / samplingFreq; double nr = 0, ni = 0, dr = 1, di = 0; if (bs.length > 0) { nr = bs[0]; for (int i = 1; i < bs.length; i++) { nr += bs[i] * Math.cos(w * i); ...
diff --git a/src/main/java/com/imaginarycode/minecraft/redisbungee/RedisBungee.java b/src/main/java/com/imaginarycode/minecraft/redisbungee/RedisBungee.java index 2663756..1519dbf 100644 --- a/src/main/java/com/imaginarycode/minecraft/redisbungee/RedisBungee.java +++ b/src/main/java/com/imaginarycode/minecraft/redisbun...
false
true
private void loadConfig() throws IOException { if (!getDataFolder().exists()) { getDataFolder().mkdir(); } File file = new File(getDataFolder(), "config.yml"); if (!file.exists()) { file.createNewFile(); try (InputStream in = getResourceAsStream(...
private void loadConfig() throws IOException { if (!getDataFolder().exists()) { getDataFolder().mkdir(); } File file = new File(getDataFolder(), "config.yml"); if (!file.exists()) { file.createNewFile(); try (InputStream in = getResourceAsStream(...
diff --git a/src/main/java/edu/rit/asksg/web/TwilioController.java b/src/main/java/edu/rit/asksg/web/TwilioController.java index 124aa65..77c4983 100644 --- a/src/main/java/edu/rit/asksg/web/TwilioController.java +++ b/src/main/java/edu/rit/asksg/web/TwilioController.java @@ -1,49 +1,51 @@ package edu.rit.asksg.web; ...
true
true
public ResponseEntity<String> receiveSMS(@RequestParam(value = "SmsSid") String smsSid, @RequestParam(value = "AccountSid") String accountSid, @RequestParam(value = "From") String from, @Reques...
public ResponseEntity<String> receiveSMS(@RequestParam(value = "SmsSid") String smsSid, @RequestParam(value = "AccountSid") String accountSid, @RequestParam(value = "From") String from, @Reques...
diff --git a/gcs/src/pt/com/gcs/messaging/QueueProcessorList.java b/gcs/src/pt/com/gcs/messaging/QueueProcessorList.java index e02b3cbf..6d0e00a0 100755 --- a/gcs/src/pt/com/gcs/messaging/QueueProcessorList.java +++ b/gcs/src/pt/com/gcs/messaging/QueueProcessorList.java @@ -1,192 +1,192 @@ package pt.com.gcs.messaging...
true
true
private synchronized void i_remove(String queueName) { try { if (!qpCache.containsKey(queueName)) { throw new IllegalArgumentException(String.format("Queue named '%s' doesn't exist", queueName)); } QueueProcessor qp; try { qp = get(queueName); } catch (MaximumQueuesAllowedReach...
private synchronized void i_remove(String queueName) { try { if (!qpCache.containsKey(queueName)) { throw new IllegalArgumentException(String.format("Queue named '%s' doesn't exist.", queueName)); } QueueProcessor qp; try { qp = get(queueName); } catch (MaximumQueuesAllowedReac...
diff --git a/kendzi3d-josm-core/src/main/java/kendzi/josm/kendzi3d/util/NamedColorsEnum.java b/kendzi3d-josm-core/src/main/java/kendzi/josm/kendzi3d/util/NamedColorsEnum.java index f3c7ce5..c9e51cf 100644 --- a/kendzi3d-josm-core/src/main/java/kendzi/josm/kendzi3d/util/NamedColorsEnum.java +++ b/kendzi3d-josm-core/src/...
true
true
public static Color getColorByName(String name) { if (name == null) { return null; } name = name.toLowerCase(); return NamedColorsEnum.valueOf(name).getColor(); }
public static Color getColorByName(String name) { if (name == null) { return null; } name = name.toLowerCase(); try { return NamedColorsEnum.valueOf(name).getColor(); } catch (IllegalArgumentException e) { // } return null...
diff --git a/org.iucn.sis.server.extensions.recentasms/src/org/iucn/sis/server/extensions/recentasms/RecentActivityRestlet.java b/org.iucn.sis.server.extensions.recentasms/src/org/iucn/sis/server/extensions/recentasms/RecentActivityRestlet.java index 6ea8c03d..05dddc29 100644 --- a/org.iucn.sis.server.extensions.recent...
false
true
public Representation handleGet(Request request, Response response, Session session) throws ResourceException { Calendar cal = Calendar.getInstance(); cal.add(Calendar.DATE, -1); String date = new SimpleDateFormat("yyyy-MM-dd").format(cal.getTime()); String query = null; /* * Queries require * 1...
public Representation handleGet(Request request, Response response, Session session) throws ResourceException { Calendar cal = Calendar.getInstance(); cal.add(Calendar.DATE, -1); String date = new SimpleDateFormat("yyyy-MM-dd").format(cal.getTime()); String query = null; /* * Queries require * 1...
diff --git a/runtime/src/com/sun/xml/bind/api/JAXBRIContext.java b/runtime/src/com/sun/xml/bind/api/JAXBRIContext.java index 2e716613..63db1d68 100644 --- a/runtime/src/com/sun/xml/bind/api/JAXBRIContext.java +++ b/runtime/src/com/sun/xml/bind/api/JAXBRIContext.java @@ -1,485 +1,485 @@ /* * DO NOT ALTER OR REMOVE CO...
true
true
public static JAXBRIContext newInstance(@NotNull Class[] classes, @Nullable Collection<TypeReference> typeRefs, @Nullable Map<Class,Class> subclassReplacements, @Nullable String defaultNamespaceRemap, boolean c14nSupport, @Nullable RuntimeAnnotationReader ar) throws JAXBException { ...
public static JAXBRIContext newInstance(@NotNull Class[] classes, @Nullable Collection<TypeReference> typeRefs, @Nullable Map<Class,Class> subclassReplacements, @Nullable String defaultNamespaceRemap, boolean c14nSupport, @Nullable RuntimeAnnotationReader ar) throws JAXBException { ...
diff --git a/src/main/java/org/encog/neural/neat/PersistNEATNetwork.java b/src/main/java/org/encog/neural/neat/PersistNEATNetwork.java index 6ad7a71ba..8b73c611a 100644 --- a/src/main/java/org/encog/neural/neat/PersistNEATNetwork.java +++ b/src/main/java/org/encog/neural/neat/PersistNEATNetwork.java @@ -1,148 +1,148 @@...
true
true
public Object read(InputStream is) { NEATNetwork result = new NEATNetwork(); EncogReadHelper in = new EncogReadHelper(is); EncogFileSection section; Map<Integer,NEATNeuron> neuronMap = new HashMap<Integer,NEATNeuron>(); while( (section = in.readNextSection()) != null ) { if( section.getSectionName().e...
public Object read(InputStream is) { NEATNetwork result = new NEATNetwork(); EncogReadHelper in = new EncogReadHelper(is); EncogFileSection section; Map<Integer,NEATNeuron> neuronMap = new HashMap<Integer,NEATNeuron>(); while( (section = in.readNextSection()) != null ) { if( section.getSectionName().e...
diff --git a/src/com/github/notizklotz/derbunddownloader/download/IssueDownloadService.java b/src/com/github/notizklotz/derbunddownloader/download/IssueDownloadService.java index 380a94d..a681246 100644 --- a/src/com/github/notizklotz/derbunddownloader/download/IssueDownloadService.java +++ b/src/com/github/notizklotz/...
true
true
protected void onHandleIntent(Intent intent) { if (!(intent.hasExtra(EXTRA_DAY) && intent.hasExtra(EXTRA_MONTH) && intent.hasExtra(EXTRA_YEAR))) { throw new IllegalArgumentException("Intent is missing extras"); } Log.d(LOG_TAG, "Handling download intent"); WifiManager.W...
protected void onHandleIntent(Intent intent) { if (!(intent.hasExtra(EXTRA_DAY) && intent.hasExtra(EXTRA_MONTH) && intent.hasExtra(EXTRA_YEAR))) { throw new IllegalArgumentException("Intent is missing extras"); } Log.d(LOG_TAG, "Handling download intent"); WifiManager.W...
diff --git a/pageHit/src/main/java/org/jahia/modules/pagehit/PageHitService.java b/pageHit/src/main/java/org/jahia/modules/pagehit/PageHitService.java index 5e75f703..103859a9 100644 --- a/pageHit/src/main/java/org/jahia/modules/pagehit/PageHitService.java +++ b/pageHit/src/main/java/org/jahia/modules/pagehit/PageHitSe...
false
true
public void process(Exchange exchange) throws Exception { final String message = (String) exchange.getIn().getBody(); final Matcher matcher = pattern.matcher(message); if (matcher.matches()) { final String path = matcher.group(5); final JCRTemplate tpl = JCRTemplate.g...
public void process(Exchange exchange) throws Exception { final String message = (String) exchange.getIn().getBody(); final Matcher matcher = pattern.matcher(message); if (matcher.matches()) { final String path = matcher.group(5); final JCRTemplate tpl = JCRTemplate.g...
diff --git a/src/com/hashcode/safestrap/ics/UninstallDialogThread.java b/src/com/hashcode/safestrap/ics/UninstallDialogThread.java index cc04a50..b709d43 100644 --- a/src/com/hashcode/safestrap/ics/UninstallDialogThread.java +++ b/src/com/hashcode/safestrap/ics/UninstallDialogThread.java @@ -1,55 +1,55 @@ package com....
true
true
public void run() { try { reply(1,0,"Preparing Uninstall..."); pause(2000); AssetControl unzip = new AssetControl(); unzip.apkPath= packageCodePath; unzip.mAppRoot = mAppRoot.toString(); unzip.LOGTAG = LOGTAG; reply(1,0,"Unpacking Files..."); unzip.unzipAssets();...
public void run() { try { reply(1,0,"Preparing Uninstall..."); pause(2000); AssetControl unzip = new AssetControl(); unzip.apkPath= packageCodePath; unzip.mAppRoot = mAppRoot.toString(); unzip.LOGTAG = LOGTAG; reply(1,0,"Unpacking Files..."); unzip.unzipAssets();...
diff --git a/src/test/java/name/pehl/taoki/rest/paging/NumbersQueryResourceIntegrationTest.java b/src/test/java/name/pehl/taoki/rest/paging/NumbersQueryResourceIntegrationTest.java index f507768..79b90b2 100644 --- a/src/test/java/name/pehl/taoki/rest/paging/NumbersQueryResourceIntegrationTest.java +++ b/src/test/java/...
true
true
public void testPaging() throws IOException, ResourceException, JSONException { ClientResource resource = new ClientResource(BASE_URL + "/numbers?offset=5&pageSsize=19"); assertJson(resource); }
public void testPaging() throws IOException, ResourceException, JSONException { ClientResource resource = new ClientResource(BASE_URL + "/numbers?offset=5&pageSize=19"); assertJson(resource); }
diff --git a/nmer/NMer.java b/nmer/NMer.java index 9e64cac..8d050aa 100644 --- a/nmer/NMer.java +++ b/nmer/NMer.java @@ -1,126 +1,123 @@ import java.io.*; import java.util.Collections; import java.util.List; import java.util.Map; import java.util.Set; public class NMer { private static class IntHolder { ...
false
true
private void processBR (BufferedReader br) throws IOException { String line; int lineNo = 0; while ((line = br.readLine()) != null) { lineNo++; if (line.trim().equals ("")) continue; String subjectID = "none"; if (line.indexOf (":") >= 0) { String[] lparts = line.split (":", 2); subjectID...
private void processBR (BufferedReader br) throws IOException { String line; int lineNo = 0; while ((line = br.readLine()) != null) { lineNo++; if (line.trim().equals ("")) continue; String subjectID = "none"; if (line.indexOf (":") >= 0) { String[] lparts = line.split (":", 2); subjectID...
diff --git a/src/parser/EventParser.java b/src/parser/EventParser.java index d13fd78..95d2ed2 100644 --- a/src/parser/EventParser.java +++ b/src/parser/EventParser.java @@ -1,129 +1,131 @@ package parser; import java.io.BufferedReader; import java.io.IOException; import java.io.InputStream; import java.io.InputS...
true
true
private static Entity createEntity(String eventURL, Event tempEvent, EventSummary tempSummary, String[] tags) { Entity event = new Entity("event", tempEvent.getID()); // store URL and timestamp of datastore transaction event.setProperty("url", eventURL); event.setProperty("date...
private static Entity createEntity(String eventURL, Event tempEvent, EventSummary tempSummary, String[] tags) { Entity event = new Entity("event", tempEvent.getID()); // store URL and timestamp of datastore transaction event.setProperty("url", eventURL); event.setProperty("date...
diff --git a/src/test/java/edu/uaskl/cpp/exporter/ExportTest.java b/src/test/java/edu/uaskl/cpp/exporter/ExportTest.java index f0a8057..01e1e78 100644 --- a/src/test/java/edu/uaskl/cpp/exporter/ExportTest.java +++ b/src/test/java/edu/uaskl/cpp/exporter/ExportTest.java @@ -1,37 +1,38 @@ package edu.uaskl.cpp.exporter; ...
true
true
public void test() { final GraphUndirected<NodeCppOSM, EdgeCppOSM> graph = importOsmUndirected(getClass().getResource("../fh_way_no_meta.osm").toString()); final List<NodeCppOSM> nodes = new LinkedList<>(); nodes.add(graph.getNode(279266215l)); nodes.add(graph.getNode(279266248l)); ...
public void test() { final GraphUndirected<NodeCppOSM, EdgeCppOSM> graph = importOsmUndirected(getClass().getResource("../fh_way_no_meta.osm").toString()); final List<NodeCppOSM> nodes = new LinkedList<>(); nodes.add(graph.getNode(280959081l)); nodes.add(graph.getNode(267970528l)); ...
diff --git a/plugins/net.lucky-dip.hamleditor/src/net/lucky_dip/hamleditor/editor/contentassist/HamlContentAssistantProcessor.java b/plugins/net.lucky-dip.hamleditor/src/net/lucky_dip/hamleditor/editor/contentassist/HamlContentAssistantProcessor.java index 467e23c..f6bd3af 100644 --- a/plugins/net.lucky-dip.hamleditor/...
true
true
public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) { IDocument doc = viewer.getDocument(); IDocumentExtension3 doc3 = (IDocumentExtension3) viewer.getDocument(); ArrayList res = new ArrayList(); try { ITypedRegion region = doc3.getPartition(HamlEditor.HAML_PARTITIONING,...
public ICompletionProposal[] computeCompletionProposals(ITextViewer viewer, int offset) { IDocument doc = viewer.getDocument(); IDocumentExtension3 doc3 = (IDocumentExtension3) viewer.getDocument(); ArrayList res = new ArrayList(); try { ITypedRegion region = doc3.getPartition(HamlEditor.HAML_PARTITIONING,...
diff --git a/TheRoom/src/com/room/Options.java b/TheRoom/src/com/room/Options.java index 1bb45a3..6b4d6d6 100644 --- a/TheRoom/src/com/room/Options.java +++ b/TheRoom/src/com/room/Options.java @@ -1,201 +1,199 @@ package com.room; import java.util.StringTokenizer; import android.graphics.Bitmap; import android....
true
true
public void onBoxDown(SLayout.Box box, MotionEvent event) { StringTokenizer st = new StringTokenizer(box.name, "_"); String clicked = st.nextToken(); if (clicked.equals("checkbox")) { MSoundManager.getInstance().playSoundEffect(R.raw.tick); int check = Integer.parseInt(st.nextToken()); boolean curState;...
public void onBoxDown(SLayout.Box box, MotionEvent event) { StringTokenizer st = new StringTokenizer(box.name, "_"); String clicked = st.nextToken(); if (clicked.equals("checkbox")) { MSoundManager.getInstance().playSoundEffect(R.raw.tick); int check = Integer.parseInt(st.nextToken()); boolean curState;...
diff --git a/calendar3/webcommon/src/org/bedework/webcommon/pref/UpdatePrefsAction.java b/calendar3/webcommon/src/org/bedework/webcommon/pref/UpdatePrefsAction.java index 038e59b7..09c37a53 100644 --- a/calendar3/webcommon/src/org/bedework/webcommon/pref/UpdatePrefsAction.java +++ b/calendar3/webcommon/src/org/bedework...
true
true
public String doAction(HttpServletRequest request, HttpServletResponse response, BwSession sess, BwActionFormBase form) throws Throwable { CalSvcI svc = form.fetchSvci(); BwPreferences prefs; /* Refetch the prefs */ if (getReq...
public String doAction(HttpServletRequest request, HttpServletResponse response, BwSession sess, BwActionFormBase form) throws Throwable { CalSvcI svc = form.fetchSvci(); BwPreferences prefs; /* Refetch the prefs */ if (getPub...
diff --git a/src/de/ueller/midlet/gps/GuiSatellites.java b/src/de/ueller/midlet/gps/GuiSatellites.java index 4ceb274e..7e28c62b 100644 --- a/src/de/ueller/midlet/gps/GuiSatellites.java +++ b/src/de/ueller/midlet/gps/GuiSatellites.java @@ -1,158 +1,160 @@ package de.ueller.midlet.gps; /* * GpsMid - Copyright (c) 2...
false
true
protected void paint(Graphics g) { //#debug debug mLogger.debug("Drawing Satellites screen"); int h = getHeight(); int w = getWidth(); // Clear the screen to the map background colour. g.setColor(C.BACKGROUND_COLOR); g.fillRect(0, 0, w, h); int centerX = getWidth() / 2; int centerY = getHeight...
protected void paint(Graphics g) { //#debug debug mLogger.debug("Drawing Satellites screen"); int h = getHeight(); int w = getWidth(); // Clear the screen to the map background colour. g.setColor(C.BACKGROUND_COLOR); g.fillRect(0, 0, w, h); int centerX = getWidth() / 2; int centerY = getHeight...
diff --git a/src/net/czlee/debatekeeper/AlertManager.java b/src/net/czlee/debatekeeper/AlertManager.java index 4612485..f407cbb 100644 --- a/src/net/czlee/debatekeeper/AlertManager.java +++ b/src/net/czlee/debatekeeper/AlertManager.java @@ -1,370 +1,370 @@ /* * Copyright (C) 2012 Phillip Cao, Chuan-Zheng Lee * *...
true
true
private void flashScreen(BellSoundInfo bsi) { Timer repeatTimer = new Timer(); final long repeatPeriod = bsi.getRepeatPeriod(); final int timesToPlay = bsi.getTimesToPlay(); if (timesToPlay == 0) return; // Do nothing if the number of bells is zero wakeUpScreenFor...
private void flashScreen(BellSoundInfo bsi) { Timer repeatTimer = new Timer(); final long repeatPeriod = bsi.getRepeatPeriod(); final int timesToPlay = bsi.getTimesToPlay(); if (timesToPlay == 0) return; // Do nothing if the number of bells is zero wakeUpScreenFor...
diff --git a/src/com/android/deskclock/HandleSetAlarm.java b/src/com/android/deskclock/HandleSetAlarm.java index ee7f257..4510985 100644 --- a/src/com/android/deskclock/HandleSetAlarm.java +++ b/src/com/android/deskclock/HandleSetAlarm.java @@ -1,125 +1,125 @@ /* * Copyright (C) 2010 The Android Open Source Project ...
true
true
protected void onCreate(Bundle icicle) { super.onCreate(icicle); Intent intent = getIntent(); if (intent == null || !ACTION_SET_ALARM.equals(intent.getAction())) { finish(); return; } else if (!intent.hasExtra(EXTRA_HOUR)) { startActivity(new Inten...
protected void onCreate(Bundle icicle) { super.onCreate(icicle); Intent intent = getIntent(); if (intent == null || !ACTION_SET_ALARM.equals(intent.getAction())) { finish(); return; } else if (!intent.hasExtra(EXTRA_HOUR)) { startActivity(new Inten...
diff --git a/src/main/java/login/LoginController.java b/src/main/java/login/LoginController.java index 4aec16f..2b18ab6 100644 --- a/src/main/java/login/LoginController.java +++ b/src/main/java/login/LoginController.java @@ -1,87 +1,86 @@ package login; import java.util.logging.Logger; import javax.enterprise.inje...
true
true
public String authenticate() { // Example using most common scenario of username/password pair: UsernamePasswordToken token = new UsernamePasswordToken(username, password); // "Remember Me" built-in: token.setRememberMe(rememberMe); Subject currentUser =...
public String authenticate() { // Example using most common scenario of username/password pair: UsernamePasswordToken token = new UsernamePasswordToken(username, password); // "Remember Me" built-in: token.setRememberMe(rememberMe); Subject currentUser =...
diff --git a/src/test/java/de/taimos/gpsd4java/test/Tester.java b/src/test/java/de/taimos/gpsd4java/test/Tester.java index 761153e..57b3099 100644 --- a/src/test/java/de/taimos/gpsd4java/test/Tester.java +++ b/src/test/java/de/taimos/gpsd4java/test/Tester.java @@ -1,98 +1,98 @@ /** * Copyright 2011 Thorsten Höger, T...
true
true
public static void main(final String[] args) { try { String host = "192.168.4.29"; int port = 2947; switch (args.length) { case 0: // Nothing to do, use default break; case 1: // only server specified host = args[0]; break; case 2: // Server and port specified host = ar...
public static void main(final String[] args) { try { String host = "localhost"; int port = 2947; switch (args.length) { case 0: // Nothing to do, use default break; case 1: // only server specified host = args[0]; break; case 2: // Server and port specified host = args[...
diff --git a/jupload2/src/wjhk/jupload2/policies/CoppermineUploadPolicy.java b/jupload2/src/wjhk/jupload2/policies/CoppermineUploadPolicy.java index 3a7add3..1605b3a 100644 --- a/jupload2/src/wjhk/jupload2/policies/CoppermineUploadPolicy.java +++ b/jupload2/src/wjhk/jupload2/policies/CoppermineUploadPolicy.java @@ -1,3...
true
true
public boolean checkUploadSuccess(String serverOutput, String serverOutputBody) throws JUploadException { final Pattern patternSuccess = Pattern .compile(getStringUploadSuccess()); final Pattern patternTransferEncodingChunked = Pattern.compile( "^Transfer-...
public boolean checkUploadSuccess(String serverOutput, String serverOutputBody) throws JUploadException { final Pattern patternSuccess = Pattern .compile(getStringUploadSuccess()); final Pattern patternTransferEncodingChunked = Pattern.compile( "^Transfer-...
diff --git a/src/fr/eurecom/cardify/Lobby.java b/src/fr/eurecom/cardify/Lobby.java index 6daea6e..2948580 100644 --- a/src/fr/eurecom/cardify/Lobby.java +++ b/src/fr/eurecom/cardify/Lobby.java @@ -1,394 +1,394 @@ package fr.eurecom.cardify; import java.net.InetAddress; import java.util.Set; import android.app.A...
false
true
private void showCardHandSizeSelector() { int maxHandSize = (int) Math.floor(52/(client.getReceivers().size()+1)) + 1; AlertDialog.Builder alert = new AlertDialog.Builder(this); alert.setTitle("Select initial card hand: "); final NumberPicker np = new NumberPicker(this); String[] numbers = new String...
private void showCardHandSizeSelector() { int maxHandSize = (int) Math.floor(52/(client.getReceivers().size()+1)); AlertDialog.Builder alert = new AlertDialog.Builder(this); alert.setTitle("Select initial card hand: "); final NumberPicker np = new NumberPicker(this); String[] numbers = new String[max...
diff --git a/src/com/digitallizard/bbcnewsreader/widget/ReaderWidget.java b/src/com/digitallizard/bbcnewsreader/widget/ReaderWidget.java index 6eed92f..e48cfb6 100644 --- a/src/com/digitallizard/bbcnewsreader/widget/ReaderWidget.java +++ b/src/com/digitallizard/bbcnewsreader/widget/ReaderWidget.java @@ -1,45 +1,45 @@ ...
true
true
public void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] appWidgetIds){ // retrieve the news from the database DatabaseHandler database = new DatabaseHandler(context); NewsItem[] items = database.getItems("Headlines", NUM_ITEMS); // create references to the required view RemoteViews ...
public void onUpdate(Context context, AppWidgetManager appWidgetManager, int[] appWidgetIds){ // retrieve the news from the database DatabaseHandler database = new DatabaseHandler(context); NewsItem[] items = database.getItems("Headlines", NUM_ITEMS); // create references to the required view RemoteViews ...
diff --git a/src/com/mel/wallpaper/starWars/StarWarsGame.java b/src/com/mel/wallpaper/starWars/StarWarsGame.java index ef6d540..0965c02 100644 --- a/src/com/mel/wallpaper/starWars/StarWarsGame.java +++ b/src/com/mel/wallpaper/starWars/StarWarsGame.java @@ -1,267 +1,267 @@ package com.mel.wallpaper.starWars; import ...
true
true
public void initialize(){ //initialize model float sf = this.backgroundScaleFactor; InvisibleWalls walls = new InvisibleWalls(sf*52f, sf*52f, sf*550f, sf*52f, this.background); //TODO: cambiar esto por un campo horizontal mas largo //TESTING DIMENSIONES CAMPO //this.background.attachChild(new Rectangle...
public void initialize(){ //initialize model float sf = this.backgroundScaleFactor; InvisibleWalls walls = new InvisibleWalls(sf*52f, sf*52f, sf*600f, sf*52f, this.background); //TODO: cambiar esto por un campo horizontal mas largo //TESTING DIMENSIONES CAMPO //this.background.attachChild(new Rectangle...
diff --git a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/SynchronizeQueryJob.java b/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/SynchronizeQueryJob.java index 697caf42e..1a9a90065 100644 --- a/org.eclipse.mylyn.tasks.ui/src/org/eclipse/mylyn/tasks/ui/SynchronizeQueryJob.java +++ b/org.eclips...
true
true
protected IStatus run(IProgressMonitor monitor) { try { monitor.beginTask("Synchronizing " + queries.size() + " queries", 20 + queries.size() * 10 + 40); Set<AbstractTask> allTasks = Collections.unmodifiableSet(taskList.getRepositoryTasks(repository.getUrl())); for (AbstractTask task : allTasks) { tas...
protected IStatus run(IProgressMonitor monitor) { try { monitor.beginTask("Synchronizing " + queries.size() + " queries", 20 + queries.size() * 10 + 40); Set<AbstractTask> allTasks = Collections.unmodifiableSet(taskList.getRepositoryTasks(repository.getUrl())); for (AbstractTask task : allTasks) { tas...
diff --git a/MipsCompiler/src/mainCompiler.java b/MipsCompiler/src/mainCompiler.java index fa8904c..aeeef4b 100644 --- a/MipsCompiler/src/mainCompiler.java +++ b/MipsCompiler/src/mainCompiler.java @@ -1,676 +1,676 @@ import java.io.File; import java.io.FileWriter; import java.io.IOException; import java.io.PrintWri...
true
true
public static void main(String[] args) { // TODO code application logic here String labelRegex = "^[a-zA-Z_]+:"; Pattern label = Pattern.compile(labelRegex); Pattern register = Pattern.compile("^\\$[0-9]?[0-9]"); HashMap labelLoc = new HashMap(); int instCount = 0; int byteLine = 0; int lastByte = 0; ...
public static void main(String[] args) { // TODO code application logic here String labelRegex = "^[a-zA-Z_]+:"; Pattern label = Pattern.compile(labelRegex); Pattern register = Pattern.compile("^\\$[0-9]?[0-9]"); HashMap labelLoc = new HashMap(); int instCount = 0; int byteLine = 0; int lastByte = 0; ...
diff --git a/src/biz/bokhorst/xprivacy/XActivityManager.java b/src/biz/bokhorst/xprivacy/XActivityManager.java index 9dd222c8..1739f1a4 100644 --- a/src/biz/bokhorst/xprivacy/XActivityManager.java +++ b/src/biz/bokhorst/xprivacy/XActivityManager.java @@ -1,61 +1,60 @@ package biz.bokhorst.xprivacy; import static de...
true
true
protected void before(MethodHookParam param) throws Throwable { if (param.getResult() != null) if (isRestricted(param)) { String methodName = param.method.getName(); if (methodName.equals("getRecentTasks")) param.setResult(new ArrayList<ActivityManager.RecentTaskInfo>()); else if (methodName.equa...
protected void before(MethodHookParam param) throws Throwable { if (isRestricted(param)) { String methodName = param.method.getName(); if (methodName.equals("getRecentTasks")) param.setResult(new ArrayList<ActivityManager.RecentTaskInfo>()); else if (methodName.equals("getRunningAppProcesses")) para...
diff --git a/chorus/src/main/java/org/chorusbdd/chorus/core/interpreter/FeatureFileParser.java b/chorus/src/main/java/org/chorusbdd/chorus/core/interpreter/FeatureFileParser.java index a6bf8949..1d0e68b0 100644 --- a/chorus/src/main/java/org/chorusbdd/chorus/core/interpreter/FeatureFileParser.java +++ b/chorus/src/main...
false
true
public List<FeatureToken> parse(Reader r) throws IOException, ParseException { BufferedReader reader = new BufferedReader(r, 32768); //first pre-parse the step macros List<StepMacro> featureLocalStepMacro = stepMacroParser.parse(reader); //we need to run the feature using combined...
public List<FeatureToken> parse(Reader r) throws IOException, ParseException { BufferedReader reader = new BufferedReader(r, 32768); //first pre-parse the step macros List<StepMacro> featureLocalStepMacro = stepMacroParser.parse(reader); //we need to run the feature using combined...
diff --git a/Client.java b/Client.java index ae39b2a..9699a5a 100644 --- a/Client.java +++ b/Client.java @@ -1,123 +1,123 @@ // Attribution-Noncommercial-Share Alike 3.0 Unported // (see more at http://creativecommons.org/licenses/by-nc-sa/3.0/) // (c) 2009 Maxim Kirillov <max630@gmail.com> import java.io.IOExcep...
true
true
Client(String hostname, int port) { try { this.client_socket = new Socket(InetAddress.getLocalHost(), 20015); } catch (Exception e) { throw new RuntimeException(e); } this.listeners = new ConcurrentHashMap<Integer, WeakReference<EventsQueue>>(); this.counter = new AtomicInteger(0); final Client rea...
Client(String hostname, int port) { try { this.client_socket = new Socket(InetAddress.getByName(hostname), port); } catch (Exception e) { throw new RuntimeException(e); } this.listeners = new ConcurrentHashMap<Integer, WeakReference<EventsQueue>>(); this.counter = new AtomicInteger(0); final Client...
diff --git a/Slick/src/org/newdawn/slick/Animation.java b/Slick/src/org/newdawn/slick/Animation.java index ed1d391..cdd64af 100644 --- a/Slick/src/org/newdawn/slick/Animation.java +++ b/Slick/src/org/newdawn/slick/Animation.java @@ -1,724 +1,728 @@ package org.newdawn.slick; import java.util.ArrayList; import or...
false
true
private void nextFrame(long delta) { if (stopped) { return; } if (frames.size() == 0) { return; } nextChange -= delta; while (nextChange < 0 && (!stopped)) { if (currentFrame == stopAt) { stopped = true; break; } if ((currentFrame == frames.size() - 1) && (!loop)) { ...
private void nextFrame(long delta) { if (stopped) { return; } if (frames.size() == 0) { return; } nextChange -= delta; while (nextChange < 0 && (!stopped)) { if (currentFrame == stopAt) { stopped = true; break; } if ((currentFrame == frames.size() - 1) && (!loop) && (!pingPong)...
diff --git a/srcj/com/sun/electric/tool/user/ui/SizeListener.java b/srcj/com/sun/electric/tool/user/ui/SizeListener.java index fc7b5872f..8c462ecf9 100644 --- a/srcj/com/sun/electric/tool/user/ui/SizeListener.java +++ b/srcj/com/sun/electric/tool/user/ui/SizeListener.java @@ -1,851 +1,863 @@ /* -*- tab-width: 4 -*- ...
true
true
private Point2D getNewNodeSize(MouseEvent evt, Point2D newCenter, NodeInst desiredNI) { NodeInst selNode = selectedNode; if (selNode == null) selNode = desiredNI; // get the coordinates of the cursor in database coordinates EditWindow wnd = (EditWindow)evt.getSource(); int oldx = evt.getX(); int oldy = e...
private Point2D getNewNodeSize(MouseEvent evt, Point2D newCenter, NodeInst desiredNI) { NodeInst selNode = selectedNode; if (selNode == null) selNode = desiredNI; // get the coordinates of the cursor in database coordinates EditWindow wnd = (EditWindow)evt.getSource(); int oldx = evt.getX(); int oldy = e...
diff --git a/src/View.java b/src/View.java index 57564f5..bae2af1 100644 --- a/src/View.java +++ b/src/View.java @@ -1,72 +1,73 @@ import org.newdawn.slick.*; import org.newdawn.slick.geom.ShapeRenderer; import org.newdawn.slick.gui.TextField; import java.awt.Font; public class View { Model model; F...
false
true
public void render(GameContainer gc, Graphics g) { g.setFont( times2); //start screen if (model.cur_screen == Model.Screen.START){ model.start_screen.render(g); } //draw command boxes else if (model.cur_screen == Model.Screen.LEVEL1) { g.setBackground(Color.black); for (int x = 0; x < model.box...
public void render(GameContainer gc, Graphics g) { g.setFont( times2); //start screen if (model.cur_screen == Model.Screen.START){ model.start_screen.render(g); } //draw command boxes else if (model.cur_screen == Model.Screen.LEVEL1) { g.setBackground(Color.black); for (int x = 0; x < model.box...
diff --git a/Lib/test/javatests/AnonInner.java b/Lib/test/javatests/AnonInner.java index beeaab14..f2d702c8 100644 --- a/Lib/test/javatests/AnonInner.java +++ b/Lib/test/javatests/AnonInner.java @@ -1,20 +1,15 @@ package javatests; import java.util.Date; public class AnonInner { public int doit() { ...
true
true
public int doit() { Date d = new Date() { public int hashCode() { return 2000; } //XXX: stuck compareTo to make the compiler happier. // hopefully this doesn't mess up the test. public int compareTo(Object x) { return 0; } }; ...
public int doit() { Date d = new Date() { public int hashCode() { return 2000; } }; return d.hashCode(); }
diff --git a/uk.ac.bolton.archimate.editor/src/uk/ac/bolton/archimate/editor/diagram/editparts/OrthogonalAnchor.java b/uk.ac.bolton.archimate.editor/src/uk/ac/bolton/archimate/editor/diagram/editparts/OrthogonalAnchor.java index ae2755f4..6fa1a0e4 100644 --- a/uk.ac.bolton.archimate.editor/src/uk/ac/bolton/archimate/ed...
true
true
public Point getLocation(Point reference) { @SuppressWarnings("rawtypes") Iterator connectionIt; IFigure remoteFig = null; Rectangle remoteFigBBox = new Rectangle(); Rectangle figureBBox = new Rectangle(); boolean inFigure = false; double anchorX; double anchorY; double cosPi4 = Math.cos(Math.P...
public Point getLocation(Point reference) { @SuppressWarnings("rawtypes") Iterator connectionIt; IFigure remoteFig = null; Rectangle remoteFigBBox = new Rectangle(); Rectangle figureBBox = new Rectangle(); boolean inFigure = false; double anchorX; double anchorY; double cosPi4 = Math.cos(Math.P...
diff --git a/vraptor-core/src/test/java/br/com/caelum/vraptor/vraptor2/VRaptor2RequestExecutionTest.java b/vraptor-core/src/test/java/br/com/caelum/vraptor/vraptor2/VRaptor2RequestExecutionTest.java index 2aa9ff057..5866e0c87 100644 --- a/vraptor-core/src/test/java/br/com/caelum/vraptor/vraptor2/VRaptor2RequestExecutio...
false
true
public void shouldAddInterceptorsInOrder() throws InterceptionException, IOException { final Sequence sequence = mockery.sequence("executionSequence"); mockery.checking(new Expectations() { { one(stack).add(ResourceLookupInterceptor.class); inSequence(sequ...
public void shouldAddInterceptorsInOrder() throws InterceptionException, IOException { final Sequence sequence = mockery.sequence("executionSequence"); mockery.checking(new Expectations() { { one(stack).add(ResourceLookupInterceptor.class); inSequence(sequ...
diff --git a/indexSearch.java b/indexSearch.java index cdf89df..090b29f 100644 --- a/indexSearch.java +++ b/indexSearch.java @@ -1,45 +1,59 @@ import java.util.*; import java.io.*; public class indexSearch { //private static ArrayList<Integer> IDs = new ArrayList<Integer>(); //private static ArrayList<Double...
false
true
public static void indSearch() { try { FileWriter fwrite = new FileWriter("indexedanswers.txt"); BufferedWriter writer = new BufferedWriter(fwrite); for (int i=0; i<Record.numQuery(); i++) { timer.startIndTimer(); int id = Integer.parseInt(Record.getQuery(i)); A...
public static void indSearch() { try { FileWriter fwrite = new FileWriter("indexedanswers.txt"); BufferedWriter writer = new BufferedWriter(fwrite); for (int i=0; i<Record.numQuery(); i++) { timer.startIndTimer(); int id = Integer.parseInt(Record.getQuery(i)); A...
diff --git a/src/edu/upenn/cis350/ShowEvent.java b/src/edu/upenn/cis350/ShowEvent.java index 88fb393..f8dd320 100644 --- a/src/edu/upenn/cis350/ShowEvent.java +++ b/src/edu/upenn/cis350/ShowEvent.java @@ -1,398 +1,401 @@ package edu.upenn.cis350; import java.text.SimpleDateFormat; import java.util.ArrayList; impo...
true
true
public View getView(int position, View convertView, ViewGroup parent) { View v = convertView; LayoutInflater vi = (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE); final ListItem item = events.get(position); if (item != null) { // Not used right now if (item.isSection()) { ...
public View getView(int position, View convertView, ViewGroup parent) { View v = convertView; // if not null, it has already been populated - helps it from being slow if(convertView != null) return convertView; LayoutInflater vi = (LayoutInflater)getSystemService(Context.LAYOUT_INFLATER_SERVICE); ...