nus-yam/ex-repair huggingface dataset:
Buggy code:
@ Repository @ SuppressWarnings ( "unchecked" ) @ Transactional public class RemindDao extends BaseDao { @ Autowired APIController api ; @ Autowired private TicketDao ticketDao ; @ Autowired private SectionDao sectionDao ; @ Autowired protected SessionData data ; public Remind addRemind ( Section section ) { } public Remind addRemind ( Section section , int user ) { if ( ( section . getTicket ( ) ) != null ) { Ticket ticket = ticketDao . getTicket ( section . getTicket ( ) ) ; Remind remind = new Remind ( ) ; remind . setTicket ( section . getTicket ( ) ) ; remind . setUser ( user ) ; remind . setLabel ( section . getLabel ( ) ) ; <START_BUG> remind . setShortText ( HtmlUtils . getShortText ( ticket . getQuestions ( ) , 50 ) ) ; <END_BUG> List < String > pathList = new ArrayList < > ( ) ; api . getPath ( section . getId ( ) ) . forEach ( ( sec ) -> { pathList . add ( sec . getLabel ( ) ) ; } ) ; pathList . remove ( ( ( pathList . size ( ) ) - 1 ) ) ; String path = Joiner . on ( "<seq2seq4repair_space>→<seq2seq4repair_space>" ) . join ( pathList ) ; remind . setPath ( path ) ; int id = ( ( int ) ( getSess ( ) . save ( remind ) ) ) ; remind . setId ( id ) ; return remind ; } else { List < Section > children = api . getSections ( section . getId ( ) ) ; children . forEach ( ( child ) -> { addRemind ( child . getId ( ) , user ) ; } ) ; return null ; } } public Remind get ( int id ) { } public void addRemind ( int sectionId , int user ) { } public List < Remind > getReminds ( ) { } public List < Remind > getReminds ( User user ) { } public Result delete ( int id ) { } public void deleteWithTicketId ( Integer ticket ) { } public void addRemindTicket ( Integer ticketId ) { } }

Fix:
remind . setShortText ( HtmlUtils . getEscapedShortText ( ticket . getQuestions ( ) , 50 ) ) ;
Buggy code:
public class CommandSearchImpl extends Command { public static String [ ] COMMAND_ALIASES_SEARCH = new String [ ] { "search" , "find" } ; public CommandSearchImpl ( CommandInput commandInput ) { } @ Override public boolean processCommand ( Data data , UI ui ) { ArrayList < Task > searchTaskResult = new ArrayList < Task > ( ) ; ArrayList < Task > fullTaskList = new ArrayList < Task > ( ) ; fullTaskList = data . searchTask ( ) ; <START_BUG> String searchKey = commandInput . getName ( ) ; <END_BUG> if ( ( commandInput . getName ( ) ) != null ) { for ( int i = 0 ; i < ( fullTaskList . size ( ) ) ; i ++ ) { if ( fullTaskList . get ( i ) . getName ( ) . toLowerCase ( ) . contains ( searchKey ) ) { searchTaskResult . add ( fullTaskList . get ( i ) ) ; } } ui . showSearchResults ( searchKey , searchTaskResult ) ; ui . showMessage ( "Type<seq2seq4repair_space>\"show<seq2seq4repair_space>all\"<seq2seq4repair_space>to<seq2seq4repair_space>show<seq2seq4repair_space>all<seq2seq4repair_space>tasks." ) ; return true ; } else { ui . showError ( "Please<seq2seq4repair_space>fill<seq2seq4repair_space>in<seq2seq4repair_space>the<seq2seq4repair_space>search<seq2seq4repair_space>key!" ) ; } return false ; } }

Fix:
String searchKey = commandInput . getName ( ) . toLowerCase ( ) ;
Buggy code:
public class ExampleRunner { static final ModelNode SB_ADDR = new ModelNode ( ) ; static final ModelNode WC_ADDR = new ModelNode ( ) ; public static void main ( String [ ] args ) throws Exception { } protected void run ( ModelControllerClient client ) throws Exception { } ModelNode createSocketBinding ( final ModelControllerClient client ) throws Exception { } ModelNode createWebConnector ( final ModelControllerClient client ) throws Exception { final ModelNode operation = new ModelNode ( ) ; operation . get ( OP ) . set ( ADD ) ; operation . get ( OP_ADDR ) . set ( ExampleRunner . WC_ADDR ) ; <START_BUG> operation . get ( "protocol" ) . set ( "http" ) ; <END_BUG> operation . get ( "socket-binding" ) . set ( "new-http-binding" ) ; operation . get ( "scheme" ) . set ( "http" ) ; return client . execute ( operation ) ; } void checkSuccess ( final ModelNode result ) { } }

Fix:
operation . get ( "protocol" ) . set ( "HTTP//1.1" ) ;
Buggy code:
public class CopyCommand extends FigureTransferCommand { public CopyCommand ( String name , DrawingView view ) { } public void execute ( ) { } public boolean isExecutable ( ) { <START_BUG> return ( view ( ) . selectionCount ( ) ) > 0 ; <END_BUG> } }

Fix:
return ( fView . selectionCount ( ) ) > 0 ;
Buggy code:
public class SoftKeyboard extends CordovaPlugin { public SoftKeyboard ( ) { } public void showKeyBoard ( ) { cordova . getActivity ( ) . runOnUiThread ( new Runnable ( ) { public void run ( ) { <START_BUG> webView . requestFocus ( ) ; <END_BUG> InputMethodManager mgr = ( ( InputMethodManager ) ( cordova . getActivity ( ) . getSystemService ( INPUT_METHOD_SERVICE ) ) ) ; mgr . showSoftInput ( webView . getView ( ) , SHOW_IMPLICIT ) ; ( ( InputMethodManager ) ( cordova . getActivity ( ) . getSystemService ( INPUT_METHOD_SERVICE ) ) ) . showSoftInput ( webView . getView ( ) , 0 ) ; } } ) ; } public void hideKeyBoard ( ) { } public boolean isKeyBoardShowing ( ) { } public int getWebViewWidth ( ) { } public int getWebViewHeight ( ) { } public int getDisplayHeight ( ) { } public boolean sendTap ( final int posx , final int posy , final CallbackContext callbackContext ) { } @ Override public boolean execute ( String action , JSONArray args , CallbackContext callbackContext ) { } }

Fix:
webView . getView ( ) . requestFocus ( ) ;
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class GlobalOpsTestCase extends AbstractCliTestBase { @ ArquillianResource URL url ; @ BeforeClass public static void before ( ) throws Exception { } @ AfterClass public static void after ( ) throws Exception { } @ Deployment public static Archive < ? > getDeployment ( ) { } @ Test public void testReadResource ( ) throws Exception { } @ Test public void testReadResourceRecursive ( ) throws Exception { } private void testReadResource ( boolean recursive ) throws Exception { } @ Test public void testReadAttribute ( ) throws Exception { } @ Test public void testWriteAttribute ( ) { } @ Test public void testReadResourceDescription ( ) throws Exception { } @ Test public void testReadOperationNames ( ) throws Exception { } @ Test public void testReadOperationDescription ( ) throws Exception { } @ Test public void testReadChildrenTypes ( ) throws Exception { } @ Test public void testReadChildrenNames ( ) throws Exception { } @ Test public void testReadChildrenResources ( ) throws Exception { } @ Test public void testAddRemoveOperation ( ) throws Exception { cli . sendLine ( "//socket-binding-group=standard-sockets//socket-binding=test:add(port=8181)" ) ; CLIOpResult result = cli . readAllAsOpResult ( ) ; assertTrue ( result . isIsOutcomeSuccess ( ) ) ; cli . sendLine ( "//subsystem=web//connector=test-connector:add(socket-binding=test,<seq2seq4repair_space>scheme=http,<seq2seq4repair_space>protocol=\"HTTP//1.1\",<seq2seq4repair_space>enabled=true)" ) ; result = cli . readAllAsOpResult ( ) ; assertTrue ( result . isIsOutcomeSuccess ( ) ) ; String cURL = ( "http:////" + ( url . getHost ( ) ) ) + ":8181" ; String response = HttpRequest . get ( cURL , 10 , TimeUnit . SECONDS ) ; assertTrue ( ( "Invalid<seq2seq4repair_space>response:<seq2seq4repair_space>" + response ) , ( ( response . indexOf ( "JBoss" ) ) >= 0 ) ) ; <START_BUG> cli . sendLine ( "//subsystem=web//connector=test-connector:remove" ) ; <END_BUG> result = cli . readAllAsOpResult ( ) ; assertTrue ( result . isIsOutcomeSuccess ( ) ) ; cli . sendLine ( "//socket-binding-group=standard-sockets//socket-binding=test:remove" ) ; result = cli . readAllAsOpResult ( ) ; assertTrue ( result . isIsOutcomeSuccess ( ) ) ; Thread . sleep ( 5000 ) ; boolean failed = false ; try { response = HttpRequest . get ( cURL , 10 , TimeUnit . SECONDS ) ; } catch ( Exception e ) { failed = true ; } assertTrue ( ( "Connector<seq2seq4repair_space>still<seq2seq4repair_space>live:<seq2seq4repair_space>" + response ) , failed ) ; } }

Fix:
cli . sendLine ( "//subsystem=web//connector=test-connector:remove{allow-resource-service-restart=true}" ) ;
Buggy code:
public class SourceMethod extends NamedMember implements IMethod { protected String [ ] parameterTypes ; protected SourceMethod ( JavaElement parent , String name , String [ ] parameterTypes ) { } protected void closing ( Object info ) throws JavaModelException { } public boolean equals ( Object o ) { } public IMemberValuePair getDefaultValue ( ) throws JavaModelException { <START_BUG> SourceMethodInfo sourceMethodInfo = ( ( SourceMethodInfo ) ( getElementInfo ( ) ) ) ; <END_BUG> if ( sourceMethodInfo . isAnnotationMethod ( ) ) { return ( ( SourceAnnotationMethodInfo ) ( sourceMethodInfo ) ) . defaultValue ; } return null ; } public int getElementType ( ) { } public String [ ] getExceptionTypes ( ) throws JavaModelException { } protected void getHandleMemento ( StringBuffer buff ) { } protected char getHandleMementoDelimiter ( ) { } public String getKey ( ) { } public int getNumberOfParameters ( ) { } public String [ ] getParameterNames ( ) throws JavaModelException { } public String [ ] getParameterTypes ( ) { } public ITypeParameter getTypeParameter ( String typeParameterName ) { } public ITypeParameter [ ] getTypeParameters ( ) throws JavaModelException { } public String [ ] getTypeParameterSignatures ( ) throws JavaModelException { } public IJavaElement getPrimaryElement ( boolean checkOwner ) { } public String [ ] getRawParameterNames ( ) throws JavaModelException { } public String getReturnType ( ) throws JavaModelException { } public String getSignature ( ) throws JavaModelException { } public int hashCode ( ) { } public boolean isConstructor ( ) throws JavaModelException { } public boolean isMainMethod ( ) throws JavaModelException { } public boolean isResolved ( ) { } public boolean isSimilar ( IMethod method ) { } public String readableName ( ) { } public JavaElement resolved ( Binding binding ) { } protected void toStringInfo ( int tab , StringBuffer buffer , Object info , boolean showResolvedInfo ) { } protected void toStringName ( StringBuffer buffer ) { } protected void toStringName ( StringBuffer buffer , int flags ) { } }

Fix:
SourceMethodElementInfo sourceMethodInfo = ( ( SourceMethodElementInfo ) ( getElementInfo ( ) ) ) ;
Buggy code:
public class MonthDV extends AbstractDateTimeDV { public Object getActualValue ( String content , ValidationContext context ) throws InvalidDatatypeValueException { } protected DateTimeData parse ( String str ) throws SchemaDateTimeException { } protected String dateToString ( DateTimeData date ) { } protected XMLGregorianCalendar getXMLGregorianCalendar ( DateTimeData date ) { <START_BUG> return factory . newXMLGregorianCalendar ( DatatypeConstants . FIELD_UNDEFINED , date . unNormMonth , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , ( date . hasTimeZone ( ) ? ( ( date . timezoneHr ) * 60 ) + ( date . timezoneMin ) : DatatypeConstants . FIELD_UNDEFINED ) ) ; <END_BUG> } }

Fix:
return datatypeFactory . newXMLGregorianCalendar ( DatatypeConstants . FIELD_UNDEFINED , date . unNormMonth , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , DatatypeConstants . FIELD_UNDEFINED , ( date . hasTimeZone ( ) ? ( ( date . timezoneHr ) * 60 ) + ( date . timezoneMin ) : DatatypeConstants . FIELD_UNDEFINED ) ) ;
Buggy code:
public class DeleteAction extends AbstractAction { public DeleteAction ( JFrame p , tree t , String text , String actionCmd , String toolTip , ImageIcon icon , KeyStroke accelerator ) { } public void actionPerformed ( ActionEvent e ) { } private void playSound ( String s ) { try { <START_BUG> URL soundFileUrl = getClass ( ) . getResource ( ( ( "//sounds//" + s ) + ".wav" ) ) ; <END_BUG> AudioInputStream sound = AudioSystem . getAudioInputStream ( soundFileUrl ) ; DataLine . Info info = new DataLine . Info ( Clip . class , sound . getFormat ( ) ) ; Clip clip = ( ( Clip ) ( AudioSystem . getLine ( info ) ) ) ; clip . open ( sound ) ; clip . start ( ) ; } catch ( Exception soundException ) { System . out . println ( "no<seq2seq4repair_space>sound,<seq2seq4repair_space>sorry" ) ; } } private int showDialog ( ) { } private JFrame parentWindow ; private tree myTreeClass ; No newline ; at end ; of file ; }

Fix:
URL soundFileUrl = getClass ( ) . getResource ( ( ( "//resources//sounds//" + s ) + ".wav" ) ) ;
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class AddMySqlDataSourceOperationsUnitTestCase extends DsMgmtTestBase { @ Deployment ( testable = false ) public static Archive < ? > getDeployment ( ) { } @ Test public void testAddDsAndTestConnection ( ) throws Exception { final ModelNode address = new ModelNode ( ) ; address . add ( "subsystem" , "datasources" ) ; address . add ( "data-source" , "MySqlDs_Pool" ) ; address . protect ( ) ; final ModelNode operation = new ModelNode ( ) ; operation . get ( OP ) . set ( "add" ) ; operation . get ( OP_ADDR ) . set ( address ) ; operation . get ( "jndi-name" ) . set ( "java:jboss//datasources//MySqlDs" ) ; <START_BUG> operation . get ( "driver-name" ) . set ( "mysql-connector-java-5.1.15.jar_com.mysql.jdbc.Driver_5_1" ) ; <END_BUG> operation . get ( "connection-url" ) . set ( "dont_care" ) ; operation . get ( "user-name" ) . set ( "sa" ) ; operation . get ( "password" ) . set ( "sa" ) ; executeOperation ( operation ) ; final ModelNode operation0 = new ModelNode ( ) ; operation0 . get ( OP ) . set ( "take-snapshot" ) ; executeOperation ( operation0 ) ; List < ModelNode > newList = marshalAndReparseDsResources ( "data-source" ) ; remove ( address ) ; Assert . assertNotNull ( "Reparsing<seq2seq4repair_space>failed:" , newList ) ; Assert . assertNotNull ( findNodeWithProperty ( newList , "jndi-name" , "java:jboss//datasources//MySqlDs" ) ) ; } }

Fix:
operation . get ( "driver-name" ) . set ( "mysql-connector-java-5.1.15.jar" ) ;
Buggy code:
public class TableController implements ListSelectionListener , ITableController , TableModelChangedListener { private static final Logger LOG = Logger . getLogger ( "org.columba.mail.gui.table" ) ; private HeaderTableModel headerTableModel ; protected TableView view ; protected IFrameMediator frameController ; protected ExtendablePopupMenu menu ; protected TableModelSorter tableModelSorter ; protected TableModelThreadedView tableModelThreadedView ; protected int [ ] previouslySelectedRows ; private MessageNode [ ] previouslySelectedNodes ; private IMailbox previouslySelectedFolder ; private ColumnHeaderTooltips tips ; public TableController ( IFrameMediator frameController ) { } public void initTooltips ( ) { } public TableView getView ( ) { } public IHeaderTableModel getHeaderTableModel ( ) { } public void setSelected ( Object [ ] uids ) { } public void createPopupMenu ( ) { } public JPopupMenu getPopupMenu ( ) { } public void tableChanged ( TableModelChangedEvent event ) { } public IFrameMediator getFrameController ( ) { } public void showHeaderList ( IMailbox folder , IHeaderList headerList ) throws Exception { } public void clear ( ) { } public TableModelSorter getTableModelSorter ( ) { } public TableModelThreadedView getTableModelThreadedView ( ) { } public void valueChanged ( ListSelectionEvent arg0 ) { } public boolean isInterestedIn ( IMailFolder folder ) { } public IMessageNode [ ] getSelectedNodes ( ) { } public Object selectFirstRow ( ) { } public Object selectLastRow ( ) { } public void selectRow ( int row ) { } public IMessageNode getMessageNode ( Object uid ) { } public void enableThreadedView ( boolean enableThreadedMode , boolean updateModel ) { getTableModelThreadedView ( ) . setEnabled ( enableThreadedMode ) ; getHeaderTableModel ( ) . enableThreadedView ( enableThreadedMode ) ; getView ( ) . enableThreadedView ( enableThreadedMode ) ; if ( updateModel ) getHeaderTableModel ( ) . update ( ) ; if ( enableThreadedMode ) { for ( int i = 0 ; i < ( getView ( ) . getRowCount ( ) ) ; i ++ ) { <START_BUG> System . out . println ( ( ( ( "i=" + i ) + "<seq2seq4repair_space>count=" ) + ( getView ( ) . getRowCount ( ) ) ) ) ; <END_BUG> TreePath path = getView ( ) . getTree ( ) . getPathForRow ( i ) ; MessageNode node = ( ( MessageNode ) ( path . getLastPathComponent ( ) ) ) ; IColumbaHeader h = node . getHeader ( ) ; boolean unseen = ! ( h . getFlags ( ) . getSeen ( ) ) ; if ( unseen ) { getView ( ) . getTree ( ) . expandPath ( path ) ; } } } } public void clearSelection ( ) { } public void makeSelectedRowVisible ( ) { } public Observable getSortingStateObservable ( ) { } public void setSortingOrder ( boolean order ) { } public void setSortingColumn ( String column ) { } public String getSortingColumn ( ) { } public boolean getSortingOrder ( ) { } }

Fix:
TableController . LOG . info ( ( ( ( "i=" + i ) + "<seq2seq4repair_space>count=" ) + ( getView ( ) . getRowCount ( ) ) ) ) ;
Buggy code:
public class WordCountTopology { public static class SplitSentence extends ShellBolt implements IRichBolt { public SplitSentence ( ) { } @ Override public void declareOutputFields ( OutputFieldsDeclarer declarer ) { } @ Override public Map < String , Object > getComponentConfiguration ( ) { } } public static class WordCount extends BaseBasicBolt { Map < String , Integer > counts = new HashMap < String , Integer > ( ) ; @ Override public void execute ( Tuple tuple , BasicOutputCollector collector ) { } @ Override public void declareOutputFields ( OutputFieldsDeclarer declarer ) { } } public static void main ( String [ ] args ) throws Exception { TopologyBuilder builder = new TopologyBuilder ( ) ; builder . setSpout ( "spout" , new RandomSentenceSpout ( ) , 5 ) ; builder . setBolt ( "split" , new WordCountTopology . SplitSentence ( ) , 8 ) . shuffleGrouping ( "spout" ) ; builder . setBolt ( "count" , new WordCountTopology . WordCount ( ) , 12 ) . fieldsGrouping ( "split" , new Fields ( "word" ) ) ; Config conf = new Config ( ) ; conf . setDebug ( true ) ; if ( ( args != null ) && ( ( args . length ) > 0 ) ) { conf . setNumWorkers ( 3 ) ; <START_BUG> StormSubmitter . submitTopology ( args [ 0 ] , conf , builder . createTopology ( ) ) ; <END_BUG> } else { conf . setMaxTaskParallelism ( 3 ) ; LocalCluster cluster = new LocalCluster ( ) ; cluster . submitTopology ( "word-count" , conf , builder . createTopology ( ) ) ; Thread . sleep ( 10000 ) ; cluster . shutdown ( ) ; } } }

Fix:
StormSubmitter . submitTopologyWithProgressBar ( args [ 0 ] , conf , builder . createTopology ( ) ) ;
Buggy code:
public class WorkbenchPreview implements IThemePreview { private IPreferenceStore store ; private boolean disposed = false ; private CTabFolder folder ; private ITheme theme ; private ToolBar toolBar ; private CLabel viewMessage ; private ViewForm viewForm ; private IPropertyChangeListener fontAndColorListener = new IPropertyChangeListener ( ) { public void propertyChange ( PropertyChangeEvent event ) { } } ; private IPropertyChangeListener preferenceListener = new IPropertyChangeListener ( ) { public void propertyChange ( PropertyChangeEvent event ) { } } ; public void createControl ( Composite parent , ITheme currentTheme ) { } protected void setTabStyle ( ) { } protected void setTabPosition ( ) { } private void setColorsAndFonts ( ) { folder . setSelectionForeground ( theme . getColorRegistry ( ) . get ( ACTIVE_TAB_TEXT_COLOR ) ) ; folder . setForeground ( theme . getColorRegistry ( ) . get ( INACTIVE_TAB_TEXT_COLOR ) ) ; Color [ ] colors = new Color [ 2 ] ; colors [ 0 ] = theme . getColorRegistry ( ) . get ( INACTIVE_TAB_BG_START ) ; colors [ 1 ] = theme . getColorRegistry ( ) . get ( INACTIVE_TAB_BG_END ) ; <START_BUG> folder . setBackground ( colors , new int [ ] { 100 } , false ) ; <END_BUG> toolBar . setBackground ( colors [ 1 ] ) ; viewMessage . setBackground ( colors [ 1 ] ) ; viewForm . setBackground ( colors [ 1 ] ) ; colors [ 0 ] = theme . getColorRegistry ( ) . get ( ACTIVE_TAB_BG_START ) ; colors [ 1 ] = theme . getColorRegistry ( ) . get ( ACTIVE_TAB_BG_END ) ; folder . setSelectionBackground ( colors , new int [ ] { theme . getInt ( ACTIVE_TAB_PERCENT ) } , theme . getBoolean ( ACTIVE_TAB_VERTICAL ) ) ; folder . setFont ( theme . getFontRegistry ( ) . get ( TAB_TEXT_FONT ) ) ; viewMessage . setFont ( theme . getFontRegistry ( ) . get ( VIEW_MESSAGE_TEXT_FONT ) ) ; } public void dispose ( ) { } }

Fix:
folder . setBackground ( colors [ 1 ] ) ;
Buggy code:
public class InfinispanSubsystemDescribe implements OperationStepHandler { public static final InfinispanSubsystemDescribe INSTANCE = new InfinispanSubsystemDescribe ( ) ; @ Override public void execute ( OperationContext context , ModelNode operation ) throws OperationFailedException { ModelNode result = context . getResult ( ) ; PathAddress rootAddress = PathAddress . pathAddress ( PathAddress . pathAddress ( operation . require ( OP_ADDR ) ) . getLastElement ( ) ) ; ModelNode subsystemModel = Tools . readModel ( context . readResource ( EMPTY_ADDRESS ) ) ; result . add ( InfinispanSubsystemAdd . createOperation ( rootAddress . toModelNode ( ) , subsystemModel ) ) ; InfinispanSubsystemDescribe . addCacheContainerCommands ( subsystemModel , rootAddress . toModelNode ( ) , result ) ; <START_BUG> context . completeStep ( ) ; <END_BUG> } public static void addCacheContainerCommands ( ModelNode subsystem , ModelNode subsystemAddress , ModelNode result ) throws OperationFailedException { } public static void addCacheCommands ( Property container , ModelNode containerAddress , ModelNode result ) throws OperationFailedException { } private static void addCacheContainerConfigCommands ( Property container , ModelNode address , ModelNode result ) throws OperationFailedException { } private static void addCacheConfigCommands ( Property cache , ModelNode address , ModelNode result ) throws OperationFailedException { } private static void addSharedStateCacheConfigCommands ( Property cache , ModelNode address , ModelNode result ) throws OperationFailedException { } private static void addStoreWriteBehindConfigCommands ( ModelNode store , ModelNode address , ModelNode result ) throws OperationFailedException { } private static void addCacheStorePropertyCommands ( ModelNode store , ModelNode address , ModelNode result ) throws OperationFailedException { } }

Fix:
context . stepCompleted ( ) ;
Buggy code:
public class SystemMapper extends CompoundRequestMapper { private final Application application ; public SystemMapper ( final Application application ) { } private IProvider < IResourceCachingStrategy > getResourceCachingStrategy ( ) { return new IProvider < IResourceCachingStrategy > ( ) { public IResourceCachingStrategy get ( ) { <START_BUG> return application . getResourceSettings ( ) . getResourceCachingStrategy ( ) ; <END_BUG> } } ; } private static class ParentFolderPlaceholderProvider implements IProvider < String > { private final Application application ; public ParentFolderPlaceholderProvider ( Application application ) { } public String get ( ) { } } private static class HomePageProvider < C extends IRequestablePage > extends ClassProvider < C > { private final Application application ; private HomePageProvider ( final Application application ) { } @ Override public Class < C > get ( ) { } } }

Fix:
return application . getResourceSettings ( ) . getCachingStrategy ( ) ;
Buggy code:
public class CoolBar extends Composite { CoolItem [ ] items ; CoolItem [ ] originalItems ; boolean locked ; boolean ignoreResize ; static final int ReBarProc ; static final TCHAR ReBarClass = new TCHAR ( 0 , OS . REBARCLASSNAME , true ) ; static final int SEPARATOR_WIDTH = 2 ; static final int MAX_WIDTH = 32767 ; public CoolBar ( Composite parent , int style ) { } int callWindowProc ( int hwnd , int msg , int wParam , int lParam ) { } static int checkStyle ( int style ) { } protected void checkSubclass ( ) { } public Point computeSize ( int wHint , int hHint , boolean changed ) { } void createHandle ( ) { } void createItem ( CoolItem item , int index ) { } void createWidget ( ) { } void destroyItem ( CoolItem item ) { } void drawThemeBackground ( int hDC , int hwnd , RECT rect ) { } int getMargin ( int index ) { } Control findThemeControl ( ) { if ( ( ( style ) & ( SWT . FLAT ) ) != 0 ) <START_BUG> return super . findThemeControl ( ) ; <END_BUG> return ( background ) == ( - 1 ) ? this : super . findThemeControl ( ) ; } public CoolItem getItem ( int index ) { } public int getItemCount ( ) { } public int [ ] getItemOrder ( ) { } public CoolItem [ ] getItems ( ) { } public Point [ ] getItemSizes ( ) { } int getLastIndexOfRow ( int index ) { } boolean isLastItemOfRow ( int index ) { } public boolean getLocked ( ) { } public int [ ] getWrapIndices ( ) { } public int indexOf ( CoolItem item ) { } void resizeToPreferredWidth ( int index ) { } void resizeToMaximumWidth ( int index ) { } void releaseChildren ( boolean destroy ) { } void removeControl ( Control control ) { } void setBackgroundPixel ( int pixel ) { } void setForegroundPixel ( int pixel ) { } void setItemColors ( int foreColor , int backColor ) { } public void setItemLayout ( int [ ] itemOrder , int [ ] wrapIndices , Point [ ] sizes ) { } void setItemOrder ( int [ ] itemOrder ) { } void setItemSizes ( Point [ ] sizes ) { } public void setLocked ( boolean locked ) { } public void setWrapIndices ( int [ ] indices ) { } int widgetStyle ( ) { } TCHAR windowClass ( ) { } int windowProc ( ) { } LRESULT WM_COMMAND ( int wParam , int lParam ) { } LRESULT WM_ERASEBKGND ( int wParam , int lParam ) { } LRESULT WM_NOTIFY ( int wParam , int lParam ) { } LRESULT WM_SETREDRAW ( int wParam , int lParam ) { } LRESULT WM_SIZE ( int wParam , int lParam ) { } LRESULT wmNotifyChild ( int wParam , int lParam ) { } }

Fix:
return this ;
Buggy code:
public class VanillaEMC { private final FastList < VanillaEMC . RegEntry > regEntries ; private final FastMap < String , Float > oreEntries ; public VanillaEMC ( ) { } public void clear ( ) { } public void fromBytes ( byte [ ] b ) throws Exception { clear ( ) ; DataInputStream dis = new DataInputStream ( new ByteArrayInputStream ( b ) ) ; int s = dis . readShort ( ) ; for ( int i = 0 ; i < s ; i ++ ) { int j = dis . readShort ( ) ; int m = dis . readShort ( ) ; float v = dis . readFloat ( ) ; regEntries . add ( new VanillaEMC . RegEntry ( j , m , v ) ) ; } s = dis . readShort ( ) ; for ( int i = 0 ; i < s ; i ++ ) { String o = dis . readUTF ( ) ; float v = dis . readFloat ( ) ; oreEntries . put ( o , v ) ; } dis . close ( ) ; <START_BUG> logger . info ( ( ( ( "Loaded<seq2seq4repair_space>VanillaEMC<seq2seq4repair_space>from<seq2seq4repair_space>" + ( b . length ) ) + "<seq2seq4repair_space>bytes:<seq2seq4repair_space>" ) + ( LMStringUtils . stripI ( Converter . toInts ( b ) ) ) ) ) ; <END_BUG> } public byte [ ] toBytes ( ) throws Exception { } public void loadDefaults ( ) { } private void addOre ( String s , float v ) { } private void addReg ( ItemStack is , float v ) { } private void addReg ( Block b , int dmg , float v ) { } private void addReg ( Item b , int dmg , float v ) { } private void addReg ( String s , float v ) { } public float getEMC ( ItemStack is ) { } private static class RegEntry { public final Item item ; public final int damage ; public final float value ; public RegEntry ( ItemStack is , float v ) { } public RegEntry ( int i , int d , float v ) { } public boolean equalsItem ( ItemStack is ) { } public String toString ( ) { } } public static class EMCFile { @ Expose public Map < String , Float > regNames ; @ Expose public Map < String , Float > oreNames ; public void loadFrom ( VanillaEMC e ) { } public void saveTo ( VanillaEMC e ) { } } No newline ; at end ; of file ; }

Fix:
logger . info ( ( ( "Loaded<seq2seq4repair_space>VanillaEMC<seq2seq4repair_space>from<seq2seq4repair_space>" + ( b . length ) ) + "<seq2seq4repair_space>bytes" ) ) ;
Buggy code:
public class StreamInitiateVerbHandler implements IVerbHandler { private static Logger logger = LoggerFactory . getLogger ( StreamInitiateVerbHandler . class ) ; public void doVerb ( Message message ) { byte [ ] body = message . getMessageBody ( ) ; ByteArrayInputStream bufIn = new ByteArrayInputStream ( body ) ; if ( StreamInitiateVerbHandler . logger . isDebugEnabled ( ) ) StreamInitiateVerbHandler . logger . debug ( String . format ( "StreamInitiateVerbeHandler.doVerb<seq2seq4repair_space>%s<seq2seq4repair_space>%s<seq2seq4repair_space>%s" , message . getVerb ( ) , message . getMessageId ( ) , message . getMessageType ( ) ) ) ; try { StreamInitiateMessage biMsg = StreamInitiateMessage . serializer ( ) . deserialize ( new DataInputStream ( bufIn ) ) ; PendingFile [ ] pendingFiles = biMsg . getStreamContext ( ) ; if ( ( pendingFiles . length ) == 0 ) { if ( StreamInitiateVerbHandler . logger . isDebugEnabled ( ) ) StreamInitiateVerbHandler . logger . debug ( ( "no<seq2seq4repair_space>data<seq2seq4repair_space>needed<seq2seq4repair_space>from<seq2seq4repair_space>" + ( message . getFrom ( ) ) ) ) ; if ( instance . isBootstrapMode ( ) ) instance . removeBootstrapSource ( message . getFrom ( ) , new String ( message . getHeader ( TABLE_NAME ) ) ) ; return ; } for ( Map . Entry < PendingFile , PendingFile > pendingFile : getContextMapping ( pendingFiles ) . entrySet ( ) ) { PendingFile remoteFile = pendingFile . getKey ( ) ; PendingFile localFile = pendingFile . getValue ( ) ; FileStatus streamStatus = new FileStatus ( remoteFile . getFilename ( ) , remoteFile . getExpectedBytes ( ) ) ; if ( StreamInitiateVerbHandler . logger . isDebugEnabled ( ) ) StreamInitiateVerbHandler . logger . debug ( ( ( ( ( ( "Preparing<seq2seq4repair_space>to<seq2seq4repair_space>receive<seq2seq4repair_space>stream<seq2seq4repair_space>from<seq2seq4repair_space>" + ( message . getFrom ( ) ) ) + ":<seq2seq4repair_space>" ) + remoteFile ) + "<seq2seq4repair_space>-><seq2seq4repair_space>" ) + localFile ) ) ; addStreamContext ( message . getFrom ( ) , localFile , streamStatus ) ; } <START_BUG> StreamInManager . registerStreamCompletionHandler ( message . getFrom ( ) , new StreamCompletionHandler ( ) ) ; <END_BUG> if ( StreamInitiateVerbHandler . logger . isDebugEnabled ( ) ) StreamInitiateVerbHandler . logger . debug ( "Sending<seq2seq4repair_space>a<seq2seq4repair_space>stream<seq2seq4repair_space>initiate<seq2seq4repair_space>done<seq2seq4repair_space>message<seq2seq4repair_space>..." ) ; Message doneMessage = new Message ( FBUtilities . getLocalAddress ( ) , "" , Verb . STREAM_INITIATE_DONE , new byte [ 0 ] ) ; MessagingService . instance . sendOneWay ( doneMessage , message . getFrom ( ) ) ; } catch ( IOException ex ) { throw new IOError ( ex ) ; } } public LinkedHashMap < PendingFile , PendingFile > getContextMapping ( PendingFile [ ] remoteFiles ) throws IOException { } private void addStreamContext ( InetAddress host , PendingFile pendingFile , FileStatus streamStatus ) { } }

Fix:
StreamInManager . registerFileStatusHandler ( message . getFrom ( ) , new FileStatusHandler ( ) ) ;
Buggy code:
public class InitializeDatabaseIntegrationTests { private String enabled ; private ClassPathXmlApplicationContext context ; @ Before public void init ( ) { } @ After public void after ( ) { } @ Test public void testCreateEmbeddedDatabase ( ) throws Exception { } @ Test ( expected = BadSqlGrammarException . class ) public void testDisableCreateEmbeddedDatabase ( ) throws Exception { } @ Test public void testIgnoreFailedDrops ( ) throws Exception { } @ Test public void testScriptNameWithPattern ( ) throws Exception { } @ Test public void testScriptNameWithPlaceholder ( ) throws Exception { } @ Test public void testScriptNameWithExpressions ( ) throws Exception { } @ Test public void testCacheInitialization ( ) throws Exception { } private void assertCorrectSetup ( DataSource dataSource ) { JdbcTemplate t = new JdbcTemplate ( dataSource ) ; <START_BUG> assertEquals ( 1 , t . queryForObject ( "select<seq2seq4repair_space>count(*)<seq2seq4repair_space>from<seq2seq4repair_space>T_TEST" , Integer . class ) . intValue ( ) ) ; <END_BUG> } public static class CacheData implements InitializingBean { private JdbcTemplate jdbcTemplate ; private List < Map < String , Object > > cache ; public void setDataSource ( DataSource dataSource ) { } public List < Map < String , Object > > getCachedData ( ) { } @ Override public void afterPropertiesSet ( ) throws Exception { } } }

Fix:
assertEquals ( 1 , t . queryForInt ( "select<seq2seq4repair_space>count(*)<seq2seq4repair_space>from<seq2seq4repair_space>T_TEST" ) ) ;
Buggy code:
@ RunWith ( Arquillian . class ) @ RunAsClient public class ExtensionRemoveTestCase { private static final String MODULE_NAME = "extensionremovemodule" ; private static final String JAR_NAME = "extension-remove-module.jar" ; @ ContainerResource private ManagementClient managementClient ; private Archive < ? > createArchive ( ) { } @ Test public void testAddAndRemoveExtension ( ) throws Exception { } private ModelNode executeOperation ( ModelControllerClient client , String name , PathAddress address , boolean fail ) throws IOException { } private ModelNode readResourceDescription ( ModelControllerClient client ) throws IOException { } private ModelNode readResource ( ModelControllerClient client ) throws IOException { } private void deleteRecursively ( File file ) { } private void createTestModule ( File testModuleRoot ) throws IOException { } private void copyFile ( File target , InputStream src ) throws IOException { } private File getModulePath ( ) { String modulePath = System . getProperty ( "module.path" , null ) ; if ( modulePath == null ) { String jbossHome = System . getProperty ( "jboss.home" , null ) ; if ( jbossHome == null ) { throw new IllegalStateException ( "Neither<seq2seq4repair_space>-Dmodule.path<seq2seq4repair_space>nor<seq2seq4repair_space>-Djboss.home<seq2seq4repair_space>were<seq2seq4repair_space>set" ) ; } modulePath = ( jbossHome + ( File . separatorChar ) ) + "modules" ; } else { <START_BUG> modulePath = modulePath . split ( File . pathSeparator ) [ 1 ] ; <END_BUG> } File moduleDir = new File ( modulePath ) ; if ( ! ( moduleDir . exists ( ) ) ) { throw new IllegalStateException ( "Determined<seq2seq4repair_space>module<seq2seq4repair_space>path<seq2seq4repair_space>does<seq2seq4repair_space>not<seq2seq4repair_space>exist" ) ; } if ( ! ( moduleDir . isDirectory ( ) ) ) { throw new IllegalStateException ( "Determined<seq2seq4repair_space>module<seq2seq4repair_space>path<seq2seq4repair_space>is<seq2seq4repair_space>not<seq2seq4repair_space>a<seq2seq4repair_space>dir" ) ; } return moduleDir ; } }

Fix:
modulePath = modulePath . split ( File . pathSeparator ) [ 0 ] ;
Buggy code:
public class ClassfileSet extends FileSet { private List rootClasses = new ArrayList ( ) ; protected ClassfileSet ( ClassfileSet s ) { } public void setRootClass ( String rootClass ) throws TaskException { } public DirectoryScanner getDirectoryScanner ( Project p ) { DependScanner scanner = new DependScanner ( ) ; <START_BUG> scanner . setBasedir ( getDir ( p ) ) ; <END_BUG> scanner . setRootClasses ( rootClasses ) ; scanner . scan ( ) ; return scanner ; } public void addConfiguredRoot ( ClassfileSet . ClassRoot root ) { } public Object clone ( ) { } public static class ClassRoot { private String rootClass ; public void setClassname ( String name ) { } public String getClassname ( ) { } } }

Fix:
scanner . setBasedir ( getDir ( ) ) ;
Buggy code:
@ RunWith ( Arquillian . class ) public class EnvEntryInjectionTestCase { @ ArquillianResource private ManagementClient managementClient ; @ Deployment public static WebArchive deployment ( ) { } private String performCall ( String urlPattern ) throws Exception { <START_BUG> return HttpRequest . get ( ( ( ( "http:////" + ( managementClient . getMgmtAddress ( ) ) ) + ":8080//war-example//" ) + urlPattern ) , 5 , TimeUnit . SECONDS ) ; <END_BUG> } @ Test public void testEnvEntryInjectionIntoServlet ( ) throws Exception { } @ Test public void testEnvEntryInjectionIntoManagedBean ( ) throws NamingException { } @ Test public void testEnvEntryNonExistantManagedBean ( ) throws NamingException { } @ Test ( expected = NamingException . class ) public void testNonExistantResourceCannotBeLookedUp ( ) throws NamingException { } @ Test public void testBoxedUnboxedMismatch ( ) throws NamingException { } private static StringAsset getWebXml ( ) { } }

Fix:
return HttpRequest . get ( ( ( ( managementClient . getWebUri ( ) ) + "//war-example//" ) + urlPattern ) , 5 , TimeUnit . SECONDS ) ;
Buggy code:
public class TestDanishAnalyzer extends BaseTokenStreamTestCase { public void testResourcesAvailable ( ) { } public void testBasics ( ) throws IOException { } public void testExclude ( ) throws IOException { } public void testRandomStrings ( ) throws Exception { <START_BUG> checkRandomData ( random ( ) , new DanishAnalyzer ( TEST_VERSION_CURRENT ) , ( 10000 * ( RANDOM_MULTIPLIER ) ) ) ; <END_BUG> } }

Fix:
checkRandomData ( random ( ) , new DanishAnalyzer ( TEST_VERSION_CURRENT ) , ( 1000 * ( RANDOM_MULTIPLIER ) ) ) ;
Buggy code:
public class SimplePanel extends Panel { private static final long serialVersionUID = 1L ; public SimplePanel ( String id ) { } @ Override public IMarkupFragment getMarkup ( ) { <START_BUG> return Markup . get ( "<wicket:panel><span<seq2seq4repair_space>wicket:id='label'><//span><//wicket:panel>" ) ; <END_BUG> } }

Fix:
return Markup . of ( "<wicket:panel><span<seq2seq4repair_space>wicket:id='label'><//span><//wicket:panel>" ) ;
Buggy code:
public class StopWatch { private static final long NANO_2_MILLIS = 1000000L ; private static final int STATE_UNSTARTED = 0 ; private static final int STATE_RUNNING = 1 ; private static final int STATE_STOPPED = 2 ; private static final int STATE_SUSPENDED = 3 ; private static final int STATE_UNSPLIT = 10 ; private static final int STATE_SPLIT = 11 ; private int runningState = StopWatch . STATE_UNSTARTED ; private int splitState = StopWatch . STATE_UNSPLIT ; private long startTime ; private long startTimeMillis ; private long stopTime ; public StopWatch ( ) { } public void start ( ) { } public void stop ( ) { } public void reset ( ) { } public void split ( ) { } public void unsplit ( ) { } public void suspend ( ) { } public void resume ( ) { } public long getTime ( ) { } public long getNanoTime ( ) { if ( ( ( this . runningState ) == ( StopWatch . STATE_STOPPED ) ) || ( ( this . runningState ) == ( StopWatch . STATE_SUSPENDED ) ) ) { return ( this . stopTime ) - ( this . startTime ) ; } else if ( ( this . runningState ) == ( StopWatch . STATE_UNSTARTED ) ) { return 0 ; } else if ( ( this . runningState ) == ( StopWatch . STATE_RUNNING ) ) { return ( System . nanoTime ( ) ) - ( this . startTime ) ; } <START_BUG> throw new RuntimeException ( "Illegal<seq2seq4repair_space>running<seq2seq4repair_space>state<seq2seq4repair_space>has<seq2seq4repair_space>occured.<seq2seq4repair_space>" ) ; <END_BUG> } public long getSplitTime ( ) { } public long getSplitNanoTime ( ) { } public long getStartTime ( ) { } @ Override public String toString ( ) { } public String toSplitString ( ) { } }

Fix:
throw new RuntimeException ( "Illegal<seq2seq4repair_space>running<seq2seq4repair_space>state<seq2seq4repair_space>has<seq2seq4repair_space>occurred." ) ;
Buggy code:
public class Button implements TalesZToolItem { @ Override public void handleEvent ( BlockBreakEvent event ) { } @ Override public String getName ( ) { } @ Override public Material getType ( ) { } @ Override public int getAmount ( ) { } @ Override public short getDurability ( ) { } @ Override public ItemMeta configItemMeta ( ItemMeta itemMeta ) { } @ Override public MaterialData configMaterialData ( MaterialData materialData ) { } @ Override public void handleEvent ( InventoryClickEvent event ) { } @ Override public void handleEvent ( PlayerInteractEntityEvent event ) { } @ Override public void handleEvent ( PlayerInteractEvent event ) { if ( event . getAction ( ) . equals ( RIGHT_CLICK_BLOCK ) ) { <START_BUG> if ( event . getClickedBlock ( ) . getType ( ) . equals ( IRON_DOOR ) ) { <END_BUG> IronDoorUtil . open ( event . getClickedBlock ( ) ) ; TalesZItemUtil . removeOneItemFromPlayer ( event . getPlayer ( ) , event . getItem ( ) ) ; event . setUseItemInHand ( DENY ) ; } } } @ Override public void handleEvent ( PlayerItemConsumeEvent event ) { } @ Override public void handleEvent ( PlayerDropItemEvent event ) { } @ Override public void handleEvent ( EntityDamageByEntityEvent event ) { } @ Override public boolean compare ( ItemStack itemStack ) { } }

Fix:
if ( event . getClickedBlock ( ) . getType ( ) . equals ( IRON_DOOR_BLOCK ) ) {
Buggy code:
public class CacheContainerRemove extends AbstractRemoveStepHandler implements DescriptionProvider { @ Override public ModelNode getModelDescription ( Locale locale ) { <START_BUG> return LocalDescriptions . getCacheContainerRemoveDescription ( locale ) ; <END_BUG> } protected void performRuntime ( OperationContext context , ModelNode operation , ModelNode model ) { } protected void recoverServices ( OperationContext context , ModelNode operation , ModelNode model ) { } }

Fix:
return InfinispanDescriptions . getCacheContainerRemoveDescription ( locale ) ;
Buggy code:
public class TestPortugueseLightStemFilter extends BaseTokenStreamTestCase { private Analyzer analyzer = new Analyzer ( ) { @ Override protected TokenStreamComponents createComponents ( String fieldName , Reader reader ) { } } ; public void testExamples ( ) throws IOException { } public void testMoreExamples ( ) throws IOException { } public void testVocabulary ( ) throws IOException { } public void testRandomStrings ( ) throws Exception { <START_BUG> checkRandomData ( random ( ) , analyzer , ( 10000 * ( RANDOM_MULTIPLIER ) ) ) ; <END_BUG> } public void testEmptyTerm ( ) throws IOException { } }

Fix:
checkRandomData ( random ( ) , analyzer , ( 1000 * ( RANDOM_MULTIPLIER ) ) ) ;
Buggy code:
public class Perspective extends DockLayoutPanel { private DataManager data ; private Integer browserWindowWidth ; private Perspective . ViewNorth viewNorth ; private Perspective . ViewWest viewWest ; private Perspective . ViewEast viewEast ; private ScrollPanel scrollModel ; private ScrollPanel scrollParameters ; private ModelActionPanel modelActionPanel ; private ModelTree modelTree ; private ParameterTable parameterTable ; private UserPanel userPanel ; private ComponentInfoDialogBox componentInfoBox ; private LabelsMenu labelsMenu ; private OpenDialogBox openDialogBox ; private HandlerRegistration windowCloseHandler ; public Perspective ( DataManager data ) { } private class ViewNorth extends HorizontalPanel { public ViewNorth ( ) { } } private class ViewWest extends TabLayoutPanel { public ViewWest ( ) { } } private class ViewEast extends TabLayoutPanel { public ViewEast ( ) { } } public ScrollPanel getModelPanel ( ) { } public void setModelPanel ( ScrollPanel scrollModel ) { } public void setModelPanelTitle ( ) { String tabTitle = Constants . TITLE_MODEL_PANEL ; String modelName = data . getModel ( ) . getName ( ) ; <START_BUG> if ( modelName != ( Constants . DEFAULT_MODEL_NAME ) ) { <END_BUG> String marker = ( data . modelIsSaved ( ) ) ? "" : "*" ; tabTitle += ( ( "<seq2seq4repair_space>(" + marker ) + modelName ) + ")" ; String modelOwner = data . findModel ( modelName ) . getOwner ( ) ; if ( ( modelOwner != null ) && ( modelOwner != ( data . security . getWmtUsername ( ) ) ) ) { tabTitle += "<span<seq2seq4repair_space>style=\"margin-left:5px;<seq2seq4repair_space>color:rgb(203,73,54);<seq2seq4repair_space>" + "font-size:13px;\">read-only<//span>" ; } } viewWest . setTabHTML ( 0 , tabTitle ) ; } public ComponentInfoDialogBox getComponentInfoBox ( ) { } public void setComponentInfoBox ( ComponentInfoDialogBox componentInfoBox ) { } public ModelTree getModelTree ( ) { } public void setModelTree ( ModelTree modelTree ) { } public ScrollPanel getParametersPanel ( ) { } public void setParametersPanel ( ScrollPanel scrollParameters ) { } public void setParameterPanelTitle ( String componentId ) { } public ParameterTable getParameterTable ( ) { } public void setParameterTable ( ParameterTable parameterTable ) { } public TabLayoutPanel getViewEast ( ) { } public TabLayoutPanel getViewWest ( ) { } public ModelActionPanel getActionButtonPanel ( ) { } public void setActionButtonPanel ( ModelActionPanel modelActionPanel ) { } public LabelsMenu getLabelsMenu ( ) { } public void setLabelsMenu ( LabelsMenu labelsMenu ) { } public OpenDialogBox getOpenDialogBox ( ) { } public void setOpenDialogBox ( OpenDialogBox openDialogBox ) { } public UserPanel getUserPanel ( ) { } public void setUserPanel ( UserPanel userPanel ) { } public void initializeModel ( ) { } public void initializeParameterTable ( ) { } public HandlerRegistration getWindowCloseHandler ( ) { } public void setWindowCloseHandler ( HandlerRegistration windowCloseHandler ) { } public void reset ( ) { } }

Fix:
if ( ! ( modelName . equals ( DEFAULT_MODEL_NAME ) ) ) {
Buggy code:
public class Main { static HgmdMap hgmdMap ; static HgmdMap hgmdMapIndel ; static OmimMap omimMap ; static HgmdDiseaseMap hgmdDiseaseMap ; static InhouseMap inhouseMap ; public static void main ( String [ ] args ) throws Exception { } private static void printDisease ( String genesStr ) { String [ ] gs = genesStr . split ( ";" , ( - 1 ) ) ; HashSet < String > genes = new HashSet < String > ( ) ; for ( String gene_txt : gs ) { <START_BUG> String [ ] gene = gene_txt . split ( "[,()]" , ( - 1 ) ) ; <END_BUG> if ( ! ( gene [ 1 ] . equals ( "" ) ) ) { genes . add ( gene [ 1 ] ) ; } } boolean isFirst = true ; final String DIS_SEP = ";" ; StringBuilder diseaseHgmd = new StringBuilder ( ) ; StringBuilder diseaseOmim = new StringBuilder ( ) ; for ( String g : genes ) { if ( ! isFirst ) { diseaseHgmd . append ( DIS_SEP ) ; diseaseOmim . append ( DIS_SEP ) ; } diseaseHgmd . append ( ( ( ( "GENE:" + g ) + ":" ) + ( Main . hgmdDiseaseMap . get ( g ) ) ) ) ; diseaseOmim . append ( ( ( ( "GENE:" + g ) + ":" ) + ( Main . omimMap . get ( g ) ) ) ) ; isFirst = false ; } System . out . print ( diseaseHgmd . toString ( ) ) ; System . out . print ( "\t" ) ; System . out . print ( diseaseOmim . toString ( ) ) ; } }

Fix:
String [ ] gene = gene_txt . split ( "[,\\(\\)]" , ( - 1 ) ) ;