auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public com.google.gerrit.server.change.Description getDescription ( com.google.gerrit.server.change.ChangeResource rsrc ) { return new com.google.gerrit.extensions.webui.UiAction.Description ( ) . setLabel ( "Unignore" ) . setTitle ( "Unignore the change" ) . setVisible ( canUnignore ( rsrc ) ) ; }

Target:
public com.google.gerrit.server.change.Description getDescription ( com.google.gerrit.server.change.ChangeResource rsrc ) { return new com.google.gerrit.extensions.webui.UiAction.Description ( ) . setLabel ( "Unignore" ) . setTitle ( "Unignore the change" ) . setVisible ( isIgnored ( rsrc ) ) ; }
Source:
public void starChange ( java.lang.String id ) throws com.google.gerrit.extensions.restapi.RestApiException { throw new com.google.gerrit.extensions.restapi.NotImplementedException ( ) ; }

Target:
public void deleteWatchedProjects ( java.util.List < com.google.gerrit.extensions.client.ProjectWatchInfo > in ) throws com.google.gerrit.extensions.restapi.RestApiException { throw new com.google.gerrit.extensions.restapi.NotImplementedException ( ) ; }
Source:
public void run ( ) { switch ( getIntraLineStatus ( ) ) { case OFF : case OK : toggleShowIntraline ( ) ; break ; default : break ; } }

Target:
public void run ( ) { switch ( getIntraLineStatus ( ) ) { case OFF : case OK : toggleShowIntraline ( ) ; break ; case FAILURE : case TIMEOUT : default : break ; } }
Source:
public void currentAndInvalid ( ) { assertIllegalArgument ( ( ( com.google.gerrit.testutil.IndexVersions.CURRENT ) + ",foo" ) , "Invalid value for test: foo" ) ; }

Target:
public void currentAndInvalid ( ) { assertIllegalArgument ( ( ( com.google.gerrit.testing.IndexVersions.CURRENT ) + ",foo" ) , "Invalid value for test: foo" ) ; }
Source:
public java.util.List < com.google.gerrit.reviewdb.StarredChange > byAccount ( com.google.gerrit.reviewdb.Account.Id id ) { return byAccountId.get ( id ) . list ; }

Target:
public com.google.common.util.concurrent.ListenableFuture < java.util.List < com.google.gerrit.reviewdb.StarredChange > > byAccount ( com.google.gerrit.reviewdb.Account.Id id ) { return com.google.common.util.concurrent.Futures.compose ( byAccountId.get ( id ) , com.google.gerrit.server.StarredChangesCacheImpl.unpack ) ; }
Source:
private com.google.gerrit.server.project.ProjectControl user ( com.google.gerrit.server.git.ProjectConfig local , com.google.gerrit.reviewdb.client.AccountGroup ... memberOf ) { return user ( local , null , memberOf ) ; }

Target:
private com.google.gerrit.server.permissions.ProjectControl user ( com.google.gerrit.server.git.ProjectConfig local , com.google.gerrit.reviewdb.client.AccountGroup ... memberOf ) { return user ( local , null , memberOf ) ; }
Source:
public abstract < T extends java.lang.Enum < ? > > T readEnum ( T def , java.lang.String fmt , java.lang.Object ... args ) ;

Target:
public abstract < T extends java.lang.Enum < ? > , A extends java.util.EnumSet < ? extends T > > T readEnum ( T def , A options , java.lang.String fmt , java.lang.Object ... args ) ;
Source:
public void doChangeRestoreHook ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.reviewdb.client.Account account , java.lang.String reason , com.google.gerrit.reviewdb.server.ReviewDb db ) { }

Target:
public void doChangeRestoredHook ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.reviewdb.client.Account account , java.lang.String reason , com.google.gerrit.reviewdb.server.ReviewDb db ) { }
Source:
com.google.gerrit.server.notedb.ChangeUpdate create ( com.google.gerrit.server.project.ChangeControl ctl ) ;

Target:
com.google.gerrit.server.notedb.ChangeUpdate create ( com.google.gerrit.server.notedb.ChangeNotes notes , com.google.gerrit.server.CurrentUser user ) ;
Source:
public void getTask_NotFound ( ) throws java.lang.Exception { userSession.get ( ( "/config/server/tasks/" + ( getLogFileCompressorTaskId ( ) ) ) ) . assertNotFound ( ) ; }

Target:
public void getTask_NotFound ( ) throws java.lang.Exception { userRestSession.get ( ( "/config/server/tasks/" + ( getLogFileCompressorTaskId ( ) ) ) ) . assertNotFound ( ) ; }
Source:
public void commentOnReviewableChangeByOtherCcingSelf ( ) throws java.lang.Exception { com.google.gerrit.acceptance.TestAccount other = accounts.create ( "other" , "other@example.com" , "other" ) ; com.google.gerrit.acceptance.server.mail.StagedChange sc = stageReviewableChange ( com.google.gerrit.server.account.WatchConfig.NotifyType.ALL_COMMENTS ) ; review ( other , sc.changeId , com.google.gerrit.extensions.client.GeneralPreferencesInfo.EmailStrategy.CC_ON_OWN_COMMENTS ) ; assertThat ( sender ) . sent ( "comment" , sc ) . to ( sc.owner ) . to ( sc.reviewerByEmail ) . cc ( sc.reviewer , sc.ccer , other ) . cc ( sc.ccerByEmail ) . bcc ( sc.starrer ) . bcc ( com.google.gerrit.server.account.WatchConfig.NotifyType.ALL_COMMENTS ) ; }

Target:
public void commentOnReviewableChangeByOtherCcingSelf ( ) throws java.lang.Exception { com.google.gerrit.acceptance.TestAccount other = accountCreator.create ( "other" , "other@example.com" , "other" ) ; com.google.gerrit.acceptance.server.mail.StagedChange sc = stageReviewableChange ( com.google.gerrit.server.account.WatchConfig.NotifyType.ALL_COMMENTS ) ; review ( other , sc.changeId , com.google.gerrit.extensions.client.GeneralPreferencesInfo.EmailStrategy.CC_ON_OWN_COMMENTS ) ; assertThat ( sender ) . sent ( "comment" , sc ) . to ( sc.owner ) . cc ( sc.reviewer , sc.ccer , other ) . cc ( sc.reviewerByEmail , sc.ccerByEmail ) . bcc ( sc.starrer ) . bcc ( com.google.gerrit.server.account.WatchConfig.NotifyType.ALL_COMMENTS ) ; }
Source:
public void resetToDefaults ( ) { maximumPageSize = com.google.gerrit.reviewdb.AccountGeneralPreferences.DEFAULT_PAGESIZE ; showSiteHeader = true ; useFlashClipboard = true ; copySelfOnEmail = false ; downloadUrl = null ; downloadCommand = null ; dateFormat = null ; timeFormat = null ; }

Target:
public void resetToDefaults ( ) { maximumPageSize = com.google.gerrit.reviewdb.AccountGeneralPreferences.DEFAULT_PAGESIZE ; showSiteHeader = true ; useFlashClipboard = true ; copySelfOnEmail = false ; displayPatchSetsInReverseOrder = false ; downloadUrl = null ; downloadCommand = null ; dateFormat = null ; timeFormat = null ; }
Source:
private void cherryPickRootOntoBranch ( com.google.gerrit.server.git.CodeReviewCommit n ) { n.setStatusCode ( CommitMergeStatus.CANNOT_CHERRY_PICK_ROOT ) ; }

Target:
public void updateRepo ( com.google.gerrit.server.git.BatchUpdate.RepoContext ctx ) { toMerge.setStatusCode ( CommitMergeStatus.CANNOT_CHERRY_PICK_ROOT ) ; }
Source:
protected com.google.gerrit.server.account.AccountState fromDocument ( org.apache.lucene.document.Document doc ) { com.google.gerrit.reviewdb.client.Account.Id id = new com.google.gerrit.reviewdb.client.Account.Id ( doc.getField ( com.google.gerrit.server.index.account.AccountField.ID.getName ( ) ) . numericValue ( ) . intValue ( ) ) ; return accountCache.get ( ) . get ( id ) ; }

Target:
protected com.google.gerrit.server.account.AccountState fromDocument ( org.apache.lucene.document.Document doc ) { com.google.gerrit.reviewdb.client.Account.Id id = new com.google.gerrit.reviewdb.client.Account.Id ( doc.getField ( com.google.gerrit.server.index.account.AccountField.ID.getName ( ) ) . numericValue ( ) . intValue ( ) ) ; return accountCache.get ( ) . getEvenIfMissing ( id ) ; }
Source:
public void testToHeaderString_Email2 ( ) { org.junit.Assert.assertEquals ( "<a,b@a>" , com.google.gerrit.server.mail.AddressTest.format ( null , "a,b@a" ) ) ; }

Target:
public void testToHeaderString_Email2 ( ) { com.google.common.truth.Truth.assertThat ( com.google.gerrit.server.mail.AddressTest.format ( null , "a,b@a" ) ) . isEqualTo ( "<a,b@a>" ) ; }
Source:
public void visit ( org.pegdown.ast.ReferenceNode node ) { }

Target:
public void visit ( org.commonmark.node.HtmlBlock node ) { }
Source:
void start ( ) { oracle.requestSuggestions ( request , this ) ; }

Target:
void start ( ) { if ( ( request.getQuery ( ) ) == null ) { request.setQuery ( "" ) ; } oracle.requestSuggestions ( request , this ) ; }
Source:
public static java.lang.String toPatch ( com.google.gerrit.reviewdb.client.PatchSet.Id diffBase , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName , com.google.gerrit.client.diff.DisplaySide side , int line ) { return com.google.gerrit.client.Dispatcher.toPatch ( "" , diffBase , revision , fileName , side , line ) ; }

Target:
public static java.lang.String toPatch ( com.google.gerrit.client.DiffObject diffBase , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName , com.google.gerrit.client.diff.DisplaySide side , int line ) { return com.google.gerrit.client.Dispatcher.toPatch ( "" , diffBase , revision , fileName , side , line ) ; }
Source:
private java.lang.String encoding ( javax.servlet.http.HttpServletRequest req ) { return com.google.common.base.Objects.firstNonNull ( req.getCharacterEncoding ( ) , "UTF-8" ) ; }

Target:
private java.lang.String encoding ( javax.servlet.http.HttpServletRequest req ) { return com.google.common.base.MoreObjects.firstNonNull ( req.getCharacterEncoding ( ) , "UTF-8" ) ; }
Source:
public com.google.gerrit.reviewdb.client.Change abandon ( com.google.gerrit.server.update.BatchUpdate.Factory updateFactory , com.google.gerrit.server.project.ChangeControl control , java.lang.String msgTxt ) throws com.google.gerrit.extensions.restapi.RestApiException , com.google.gerrit.server.update.UpdateException { return abandon ( updateFactory , control , msgTxt , NotifyHandling.ALL , com.google.common.collect.ImmutableListMultimap.of ( ) ) ; }

Target:
public com.google.gerrit.reviewdb.client.Change abandon ( com.google.gerrit.server.update.BatchUpdate.Factory updateFactory , com.google.gerrit.server.project.ChangeControl control ) throws com.google.gerrit.extensions.restapi.RestApiException , com.google.gerrit.server.update.UpdateException { return abandon ( updateFactory , control , "" , defaultNotify ( control ) , com.google.common.collect.ImmutableListMultimap.of ( ) ) ; }
Source:
public java.lang.String toString ( ) { return atts.get ( "dn" ) ; }

Target:
java.lang.String get ( final java.lang.String attName ) throws javax.naming.NamingException { return java.lang.String.valueOf ( atts.get ( attName ) . get ( 0 ) ) ; }
Source:
private java.io.Writer getWriter ( javax.servlet.http.HttpServletResponse res ) throws java.io.IOException { return new java.io.OutputStreamWriter ( res.getOutputStream ( ) , res.getCharacterEncoding ( ) ) ; }

Target:
protected java.io.Writer newWriter ( javax.servlet.http.HttpServletResponse res ) throws java.io.IOException { return com.google.gitiles.BaseServlet.newWriter ( res.getOutputStream ( ) , res ) ; }
Source:
private static java.io.FileNotFoundException badSourceRoot ( java.net.URI u ) { return new java.io.FileNotFoundException ( ( "Cannot find source root from " + u ) ) ; }

Target:
private static java.nio.file.NoSuchFileException badSourceRoot ( java.net.URI u ) { return new java.nio.file.NoSuchFileException ( ( "Cannot find source root from " + u ) ) ; }
Source:
public void onClick ( com.google.gwt.user.client.ui.Widget sender ) { if ( ! ( discovering ) ) { providerId.setText ( identUrl ) ; form.submit ( ) ; } }

Target:
public void onClick ( final com.google.gwt.event.dom.client.ClickEvent event ) { if ( ! ( discovering ) ) { providerId.setText ( identUrl ) ; form.submit ( ) ; } }
Source:
public void onLostFocus ( com.google.gwt.user.client.ui.Widget sender ) { if ( "" . equals ( irevTxtBox.getText ( ) ) ) { irevTxtBox.setText ( Util.C.defaultRevisionSpec ( ) ) ; irevTxtBox.addStyleName ( "gerrit-InputFieldTypeHint" ) ; } }

Target:
public void onBlur ( com.google.gwt.event.dom.client.BlurEvent event ) { if ( "" . equals ( irevTxtBox.getText ( ) ) ) { irevTxtBox.setText ( Util.C.defaultRevisionSpec ( ) ) ; irevTxtBox.addStyleName ( "gerrit-InputFieldTypeHint" ) ; } }
Source:
public void includeNonExistingGroup ( ) throws java.lang.Exception { java.lang.String gx = createGroup ( "gx" ) ; try { gApi.groups ( ) . id ( gx ) . addGroups ( "non-existing" ) ; } catch ( com.google.gerrit.extensions.restapi.UnprocessableEntityException expecetd ) { } }

Target:
public void includeNonExistingGroup ( ) throws java.lang.Exception { java.lang.String gx = createGroup ( "gx" ) ; exception.expect ( com.google.gerrit.extensions.restapi.UnprocessableEntityException.class ) ; gApi.groups ( ) . id ( gx ) . addGroups ( "non-existing" ) ; }
Source:
com.ericsson.gerrit.plugins.multimaster.IndexResponseHandler.IndexResult post ( java.lang.String endpoint ) throws java.io.IOException { return httpClient.execute ( new org.apache.http.client.methods.HttpPost ( ( ( url ) + endpoint ) ) , new com.ericsson.gerrit.plugins.multimaster.IndexResponseHandler ( ) ) ; }

Target:
com.ericsson.gerrit.plugins.multimaster.HttpResponseHandler.HttpResult post ( java.lang.String endpoint ) throws java.io.IOException { return httpClient.execute ( new org.apache.http.client.methods.HttpPost ( ( ( url ) + endpoint ) ) , new com.ericsson.gerrit.plugins.multimaster.HttpResponseHandler ( ) ) ; }
Source:
public boolean updateUserModels ( java.util.List < com.gitblit.models.UserModel > models ) { return false ; }

Target:
public boolean updateTeamModels ( java.util.Collection < com.gitblit.models.TeamModel > arg0 ) { return false ; }
Source:
public void index ( com.google.gerrit.reviewdb.client.Change change ) throws java.io.IOException { index ( new com.google.gerrit.server.query.change.ChangeData ( change ) ) ; }

Target:
public void index ( com.google.gerrit.reviewdb.server.ReviewDb db , com.google.gerrit.reviewdb.client.Change change ) throws java.io.IOException { index ( changeDataFactory.create ( db , change ) ) ; }
Source:
public com.googlesource.gerrit.plugins.its.phabricator.conduit.results.ManiphestUpdate maniphestUpdate ( int taskId , java.lang.String comment ) throws com.googlesource.gerrit.plugins.its.phabricator.conduit.ConduitException { return maniphestUpdate ( taskId , comment , null ) ; }

Target:
public com.googlesource.gerrit.plugins.its.phabricator.conduit.results.ManiphestEdit maniphestEdit ( int taskId , java.lang.String comment ) throws com.googlesource.gerrit.plugins.its.phabricator.conduit.ConduitException { return maniphestEdit ( taskId , comment , null ) ; }
Source:
public static void putMessage ( com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String m , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.VoidResult > r ) { com.google.gerrit.client.changes.ChangeApi.change ( id.getParentKey ( ) . get ( ) ) . view ( "edit_message" ) . put ( m , r ) ; }

Target:
public static void putMessage ( com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String m , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.VoidResult > r ) { com.google.gerrit.client.changes.ChangeFileApi.putMessage ( id.getParentKey ( ) , m , r ) ; }
Source:
void applyDraft ( com.google.gerrit.server.notedb.ChangeDraftUpdate draftUpdate ) throws com.google.gwtorm.server.OrmException { if ( ( c.getRevId ( ) ) == null ) { com.google.gerrit.server.PatchLineCommentsUtil.setCommentRevId ( c , cache , change , ps ) ; } draftUpdate.putComment ( c ) ; }

Target:
void applyDraft ( com.google.gerrit.server.notedb.ChangeDraftUpdate draftUpdate ) throws com.google.gwtorm.server.OrmException { if ( ( c.revId ) == null ) { com.google.gerrit.server.CommentsUtil.setCommentRevId ( c , cache , change , ps ) ; } draftUpdate.putComment ( c ) ; }
Source:
void onCancel ( com.google.gwt.event.dom.client.ClickEvent e ) { hide ( ) ; }

Target:
void onCancel ( com.google.gwt.event.dom.client.ClickEvent e ) { message.setText ( "" ) ; hide ( ) ; }
Source:
public void parseReviewer ( ) throws java.lang.Exception { assertParseSucceeds ( ( "Update change\n" + ( ( ( ( ( "\n" + "Branch: refs/heads/master\n" ) + "Patch-Set: 1\n" ) + "Reviewer: Change Owner <1@gerrit>\n" ) + "CC: Other Account <2@gerrit>\n" ) + "Subject: This is a test change\n" ) ) ) ; assertParseFails ( ( "Update change\n" + ( ( "\n" + "Patch-Set: 1\n" ) + "Reviewer: 1@gerrit\n" ) ) ) ; }

Target:
public void parseReviewer ( ) throws java.lang.Exception { assertParseSucceeds ( ( "Update change\n" + ( ( ( ( ( ( "\n" + "Branch: refs/heads/master\n" ) + "Change-id: I577fb248e474018276351785930358ec0450e9f7\n" ) + "Patch-Set: 1\n" ) + "Reviewer: Change Owner <1@gerrit>\n" ) + "CC: Other Account <2@gerrit>\n" ) + "Subject: This is a test change\n" ) ) ) ; assertParseFails ( ( "Update change\n" + ( ( "\n" + "Patch-Set: 1\n" ) + "Reviewer: 1@gerrit\n" ) ) ) ; }
Source:
public static org.eclipse.jgit.lib.Config newDefaultConfig ( ) { org.eclipse.jgit.lib.Config cfg = new org.eclipse.jgit.lib.Config ( ) ; com.google.gerrit.testutil.InMemoryModule.setDefaults ( cfg ) ; return cfg ; }

Target:
public static org.eclipse.jgit.lib.Config newDefaultConfig ( ) { org.eclipse.jgit.lib.Config cfg = new org.eclipse.jgit.lib.Config ( ) ; com.google.gerrit.testing.InMemoryModule.setDefaults ( cfg ) ; return cfg ; }
Source:
public void add ( com.google.gerrit.lifecycle.LifecycleListener listener ) { manager.add ( listener ) ; }

Target:
public com.google.gerrit.server.plugins.Plugin.ApiType getApiType ( ) { return apiType ; }
Source:
public void onKeyPress ( final com.google.gwt.event.dom.client.KeyPressEvent event ) { if ( ( ( activePatchSetId ) > 0 ) && ( ( activePatchSetId ) < ( body.getWidgetCount ( ) ) ) ) { activate ( ( ( activePatchSetId ) + 1 ) ) ; } }

Target:
public void onKeyPress ( final com.google.gwt.event.dom.client.KeyPressEvent event ) { int index = ( indexOf ( activePatchSetId ) ) - 1 ; if ( 0 <= index ) { activate ( patchSets.get ( index ) . getId ( ) ) ; } }
Source:
public void revisionTest ( ) throws java.lang.Exception { createChange ( ) ; com.google.gerrit.acceptance.RestResponse response = adminSession.post ( "/changes/1/revisions/1/cookbook~hello-revision" ) ; com.google.common.truth.Truth.assertThat ( response.getEntityContent ( ) ) . contains ( "Hello admin from change 1, patch set 1!" ) ; }

Target:
public void revisionTest ( ) throws java.lang.Exception { createChange ( ) ; com.google.gerrit.acceptance.RestResponse response = adminRestSession.post ( "/changes/1/revisions/1/cookbook~hello-revision" ) ; com.google.common.truth.Truth.assertThat ( response.getEntityContent ( ) ) . contains ( "Hello admin from change 1, patch set 1!" ) ; }
Source:
com.google.gerrit.httpd.rpc.patch.PatchScriptFactory create ( com.google.gerrit.reviewdb.Patch.Key patchKey , @ com.google.inject.assistedinject.Assisted ( value = "patchSetA" ) com.google.gerrit.reviewdb.PatchSet.Id patchSetA , @ com.google.inject.assistedinject.Assisted ( value = "patchSetB" ) com.google.gerrit.reviewdb.PatchSet.Id patchSetB , com.google.gerrit.common.data.PatchScriptSettings settings ) ;

Target:
com.google.gerrit.httpd.rpc.patch.PatchScriptFactory create ( com.google.gerrit.reviewdb.Patch.Key patchKey , @ com.google.inject.assistedinject.Assisted ( value = "patchSetA" ) com.google.gerrit.reviewdb.PatchSet.Id patchSetA , @ com.google.inject.assistedinject.Assisted ( value = "patchSetB" ) com.google.gerrit.reviewdb.PatchSet.Id patchSetB , com.google.gerrit.reviewdb.AccountDiffPreference diffPrefs ) ;
Source:
public void publish ( ) throws com.google.gerrit.extensions.restapi.RestApiException { try { publish.apply ( revision , new com.google.gerrit.server.change.PublishDraftPatchSet.Input ( ) ) ; } catch ( com.google.gerrit.server.update.UpdateException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot publish draft patch set" , e ) ; } }

Target:
public void publish ( ) throws com.google.gerrit.extensions.restapi.RestApiException { try { publish.apply ( revision , new com.google.gerrit.server.change.PublishDraftPatchSet.Input ( ) ) ; } catch ( java.lang.Exception e ) { throw com.google.gerrit.server.api.ApiUtil.asRestApiException ( "Cannot publish draft patch set" , e ) ; } }
Source:
public void onSuccess ( java.lang.Boolean result ) { if ( result ) { link ( Util.C.groupTabAuditLog ( ) , auditLogTabToken , com.google.gerrit.reviewdb.client.AccountGroup.isInternalGroup ( group.getGroupUUID ( ) ) ) ; setToken ( token ) ; } display ( group , result ) ; }

Target:
public void onSuccess ( java.lang.Boolean result ) { if ( result ) { link ( AdminConstants.I.groupTabAuditLog ( ) , auditLogTabToken , com.google.gerrit.reviewdb.client.AccountGroup.isInternalGroup ( group.getGroupUUID ( ) ) ) ; setToken ( token ) ; } display ( group , result ) ; }
Source:
public void apply ( org.eclipse.jgit.dircache.DirCacheEntry ent ) { ent.setFileMode ( FileMode.REGULAR_FILE ) ; ent.setObjectId ( oid ) ; }

Target:
public void apply ( org.eclipse.jgit.dircache.DirCacheEntry ent ) { if ( ( ent.getRawMode ( ) ) == 0 ) { ent.setFileMode ( FileMode.REGULAR_FILE ) ; } ent.setObjectId ( content ) ; }
Source:
public static void detail ( int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.info.ChangeInfo > cb ) { com.google.gerrit.client.changes.ChangeApi.detail ( id ) . get ( cb ) ; }

Target:
private static com.google.gerrit.client.rpc.RestApi call ( @ com.google.gerrit.common.Nullable java.lang.String project , int id , java.lang.String action ) { return com.google.gerrit.client.changes.ChangeApi.change ( project , id ) . view ( action ) ; }
Source:
public void projectDetail ( final com.google.gerrit.reviewdb.client.Project.NameKey projectName , final com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.common.data.ProjectDetail > callback ) { projectDetailFactory.create ( projectName ) . to ( callback ) ; }

Target:
public void projectDetail ( final com.google.gerrit.reviewdb.client.Project.NameKey projectName , final com.google.gwtjsonrpc.common.AsyncCallback < com.google.gerrit.common.data.ProjectDetail > callback ) { projectDetailFactory.create ( projectName ) . to ( callback ) ; }
Source:
public boolean apply ( java.lang.String refPart ) { return refPart.endsWith ( ( "/" + ( changeId.get ( ) ) ) ) ; }

Target:
public Account.Id apply ( java.lang.String refPart ) { return Account.Id.parse ( refPart ) ; }
Source:
public java.util.List < com.google.gerrit.extensions.common.ProjectInfo > get ( ) throws com.google.gerrit.extensions.restapi.RestApiException { return list ( this ) ; }

Target:
public java.util.SortedMap < java.lang.String , com.google.gerrit.extensions.common.ProjectInfo > getAsMap ( ) throws com.google.gerrit.extensions.restapi.RestApiException { return list ( this ) ; }
Source:
private short getDefaultContext ( ) { final int idx = defaultContext.getSelectedIndex ( ) ; if ( 0 <= idx ) { return java.lang.Short.parseShort ( defaultContext.getValue ( idx ) ) ; } return com.google.gerrit.client.reviewdb.AccountGeneralPreferences.DEFAULT_CONTEXT ; }

Target:
private short getListBox ( final com.google.gwt.user.client.ui.ListBox f , final short defaultValue ) { final int idx = f.getSelectedIndex ( ) ; if ( 0 <= idx ) { return java.lang.Short.parseShort ( f.getValue ( idx ) ) ; } return defaultValue ; }
Source:
public void flushCache_NotFound ( ) throws java.lang.Exception { adminSession.post ( "/config/server/caches/nonExisting/flush" ) . assertNotFound ( ) ; }

Target:
public void flushCache_NotFound ( ) throws java.lang.Exception { adminRestSession.post ( "/config/server/caches/nonExisting/flush" ) . assertNotFound ( ) ; }
Source:
public void deleteBranchByAdmin ( ) throws java.lang.Exception { assertDeleteSucceeds ( ) ; }

Target:
public void deleteBranchByAdmin ( ) throws java.lang.Exception { assertDeleteSucceeds ( testBranch ) ; }
Source:
private native void init ( java.lang.String hashtags ) ;

Target:
private native void init ( com.google.gwt.core.client.JsArrayString add , com.google.gwt.core.client.JsArrayString remove ) ;
Source:
private static java.lang.String skip ( final java.lang.String prefix , final java.lang.String in ) { return in.substring ( prefix.length ( ) ) ; }

Target:
private static boolean matchExact ( java.lang.String want , java.lang.String token ) { return token.equals ( want ) ; }
Source:
public java.lang.String apply ( com.google.gerrit.extensions.common.ProblemInfo in ) { return in.message ; }

Target:
public java.lang.String apply ( com.google.gerrit.extensions.common.ProblemInfo in ) { com.google.common.base.Preconditions.checkArgument ( ( ( in.status ) == null ) , ( "Status is not null: " + ( in.message ) ) ) ; return in.message ; }
Source:
public com.google.gerrit.server.IdentifiedUser getUser ( ) { return getControl ( ) . getUser ( ) . asIdentifiedUser ( ) ; }

Target:
public com.google.gerrit.server.CurrentUser getUser ( ) { return getControl ( ) . getUser ( ) ; }
Source:
public final java.util.Set < java.lang.String > commandNames ( ) { return com.google.gerrit.client.rpc.Natives.keys ( _commands ( ) ) ; }

Target:
public final java.util.List < java.lang.String > commandNames ( ) { return _commands ( ) . sortedKeys ( ) ; }
Source:
public void testCreateLinkForWebUiDifferentUrlAndText ( ) { mockUnconnectableStoryboard ( ) ; replayMocks ( ) ; com.googlesource.gerrit.plugins.its.storyboard.StoryboardItsFacade itsFacade = createStoryboardItsFacade ( ) ; java.lang.String actual = itsFacade.createLinkForWebui ( "Test-Url" , "Test-Text" ) ; assertEquals ( "[Test-Url|Test-Text]" , actual ) ; }

Target:
public void testCreateLinkForWebUiDifferentUrlAndText ( ) { mockUnconnectableStoryboard ( ) ; replayMocks ( ) ; com.googlesource.gerrit.plugins.its.storyboard.StoryboardItsFacade itsFacade = createStoryboardItsFacade ( ) ; java.lang.String actual = itsFacade.createLinkForWebui ( "Test-Url" , "Test-Text" ) ; assertEquals ( "[Test-Text](Test-Url)" , actual ) ; }
Source:
public static com.google.gerrit.server.index.IndexConfig createDefault ( ) { return com.google.gerrit.server.index.IndexConfig.create ( java.lang.Integer.MAX_VALUE ) ; }

Target:
public static com.google.gerrit.server.index.IndexConfig create ( int maxLimit ) { if ( maxLimit == 0 ) { maxLimit = java.lang.Integer.MAX_VALUE ; } else { com.google.common.base.Preconditions.checkArgument ( ( maxLimit > 0 ) , "maxLimit must be positive: %s" , maxLimit ) ; } return new com.google.gerrit.server.index.AutoValue_IndexConfig ( maxLimit ) ; }
Source:
public boolean isVisible ( ) { return ( ( user.isInternalUser ( ) ) || ( canPerformOnAnyRef ( Permission.READ ) ) ) && ( ! ( isHidden ( ) ) ) ; }

Target:
public boolean isReadable ( ) { return ( user.isInternalUser ( ) ) || ( canPerformOnAnyRef ( Permission.READ ) ) ; }
Source:
public void readCommentLinks ( ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit rev = tr.commit ( ) . add ( "project.config" , ( "[commentlink \"bugzilla\"]\n" + ( "\tmatch = \"(bug\\\\s+#?)(\\\\d+)\"\n" + "\tlink = http://bugs.example.com/show_bug.cgi?id=$2" ) ) ) . create ( ) ; com.google.gerrit.server.git.ProjectConfig cfg = read ( rev ) ; java.util.Collection < com.google.gerrit.server.project.CommentLinkInfoImpl > commentLinks = cfg.getCommentLinkSections ( ) ; com.google.common.truth.Truth.assertThat ( commentLinks ) . hasSize ( 1 ) ; com.google.gerrit.server.project.CommentLinkInfoImpl commentLink = commentLinks.iterator ( ) . next ( ) ; com.google.common.truth.Truth.assertThat ( commentLink.name ) . isEqualTo ( "bugzilla" ) ; com.google.common.truth.Truth.assertThat ( commentLink.match ) . isEqualTo ( "(bug\\s+#?)(\\d+)" ) ; com.google.common.truth.Truth.assertThat ( commentLink.link ) . isEqualTo ( "http://bugs.example.com/show_bug.cgi?id=$2" ) ; }

Target:
public void readCommentLinks ( ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit rev = tr.commit ( ) . add ( "project.config" , ( "[commentlink \"bugzilla\"]\n" + ( "\tmatch = \"(bug\\\\s+#?)(\\\\d+)\"\n" + "\tlink = http://bugs.example.com/show_bug.cgi?id=$2" ) ) ) . create ( ) ; com.google.gerrit.server.git.ProjectConfig cfg = read ( rev ) ; com.google.common.truth.Truth.assertThat ( cfg.getCommentLinkSections ( ) ) . containsExactly ( new com.google.gerrit.server.project.CommentLinkInfoImpl ( "bugzilla" , "(bug\\s+#?)(\\d+)" , "http://bugs.example.com/show_bug.cgi?id=$2" , null , null ) ) ; }
Source:
private com.google.gerrit.server.git.GroupList readGroupList ( ) throws java.io.IOException { return com.google.gerrit.server.git.GroupList.parse ( new com.google.gerrit.reviewdb.client.Project.NameKey ( project ) , readUTF8 ( GroupList.FILE_NAME ) , com.google.gerrit.server.git.GroupList.createLoggerSink ( GroupList.FILE_NAME , com.google.gerrit.pgm.init.api.AllProjectsConfig.log ) ) ; }

Target:
private com.google.gerrit.server.project.GroupList readGroupList ( ) throws java.io.IOException { return com.google.gerrit.server.project.GroupList.parse ( new com.google.gerrit.reviewdb.client.Project.NameKey ( project ) , readUTF8 ( GroupList.FILE_NAME ) , com.google.gerrit.server.project.GroupList.createLoggerSink ( GroupList.FILE_NAME , com.google.gerrit.pgm.init.api.AllProjectsConfig.log ) ) ; }
Source:
public java.util.List < com.google.gerrit.server.account.GetSshKeys.SshKeyInfo > apply ( com.googlesource.gerrit.plugins.serviceuser.ServiceUserResource rsrc ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gwtorm.server.OrmException { return getSshKeys.get ( ) . apply ( rsrc ) ; }

Target:
public java.util.List < com.google.gerrit.server.account.GetSshKeys.SshKeyInfo > apply ( com.googlesource.gerrit.plugins.serviceuser.ServiceUserResource rsrc ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gwtorm.server.OrmException { return getSshKeys.get ( ) . apply ( rsrc.getUser ( ) ) ; }
Source:
public static void fetch ( org.eclipse.jgit.api.Git git , java.lang.String spec ) throws org.eclipse.jgit.api.errors.GitAPIException { org.eclipse.jgit.api.FetchCommand fetch = git.fetch ( ) ; fetch.setRefSpecs ( new org.eclipse.jgit.transport.RefSpec ( spec ) ) ; fetch.call ( ) ; }

Target:
public static void fetch ( org.eclipse.jgit.junit.TestRepository < ? > testRepo , java.lang.String spec ) throws org.eclipse.jgit.api.errors.GitAPIException { org.eclipse.jgit.api.FetchCommand fetch = testRepo.git ( ) . fetch ( ) ; fetch.setRefSpecs ( new org.eclipse.jgit.transport.RefSpec ( spec ) ) ; fetch.call ( ) ; }
Source:
private PushOneCommit.Result createDraft ( ) throws java.io.IOException , org.eclipse.jgit.api.errors.GitAPIException { com.google.gerrit.acceptance.PushOneCommit push = pushFactory.create ( db , admin.getIdent ( ) , git ) ; return push.to ( "refs/drafts/master" ) ; }

Target:
private PushOneCommit.Result createDraft ( ) throws java.lang.Exception { com.google.gerrit.acceptance.PushOneCommit push = pushFactory.create ( db , admin.getIdent ( ) , testRepo ) ; return push.to ( "refs/drafts/master" ) ; }
Source:
com.google.gerrit.extensions.restapi.Response < com.google.gerrit.server.change.ChangeJson.ChangeInfo > apply ( com.google.gerrit.server.change.RevisionResource rsrc ) throws com.google.gwtorm.server.OrmException { return cache ( json.format ( rsrc ) ) ; }

Target:
com.google.gerrit.extensions.restapi.Response < com.google.gerrit.extensions.common.ChangeInfo > apply ( com.google.gerrit.server.change.RevisionResource rsrc ) throws com.google.gwtorm.server.OrmException { return cache ( json.format ( rsrc ) ) ; }
Source:
public void onSuccess ( final com.google.gerrit.client.reviewdb.Account result ) { if ( result != null ) { com.google.gerrit.client.Gerrit.postSignIn ( result ) ; } else { com.google.gwt.user.client.Cookies.removeCookie ( com.google.gerrit.client.Gerrit.ACCOUNT_COOKIE ) ; com.google.gerrit.client.Gerrit.refreshMenuBar ( ) ; } finishModuleLoad ( ) ; }

Target:
public void onSuccess ( final com.google.gerrit.client.data.GerritConfig result ) { com.google.gerrit.client.Gerrit.config = result ; onModuleLoad2 ( ) ; }
Source:
public com.google.template.soy.data.SanitizedContent toSoy ( ) { finishActiveTag ( ) ; return com.google.template.soy.data.UnsafeSanitizedContentOrdainer.ordainAsSafe ( htmlBuf.toString ( ) , ContentKind.HTML ) ; }

Target:
public void finish ( ) { finishActiveTag ( ) ; }
Source:
public void postEvent ( com.google.gerrit.reviewdb.client.Project.NameKey projectName , com.google.gerrit.server.events.ProjectEvent event ) { fireEvent ( projectName , event ) ; }

Target:
public void postEvent ( com.google.gerrit.reviewdb.client.Branch.NameKey branchName , com.google.gerrit.server.events.RefEvent event ) { fireEvent ( branchName , event ) ; }
Source:
public static com.google.gerrit.client.reviewdb.Change.Id fromString ( final java.lang.String str ) { return new com.google.gerrit.client.reviewdb.Change.Id ( java.lang.Integer.parseInt ( str ) ) ; }

Target:
public static com.google.gerrit.client.reviewdb.Change.Id parse ( final java.lang.String str ) { final com.google.gerrit.client.reviewdb.Change.Id r = new com.google.gerrit.client.reviewdb.Change.Id ( ) ; r.fromString ( str ) ; return r ; }
Source:
protected void formatChange ( ) throws com.google.gerrit.common.errors.EmailException { appendText ( textTemplate ( "ReplacePatchSet" ) ) ; appendHtml ( soyHtmlTemplate ( "ReplacePatchSetHtml" ) ) ; }

Target:
protected void formatChange ( ) throws com.google.gerrit.common.errors.EmailException { appendText ( textTemplate ( "ReplacePatchSet" ) ) ; if ( useHtml ( ) ) { appendHtml ( soyHtmlTemplate ( "ReplacePatchSetHtml" ) ) ; } }
Source:
public void visit ( org.commonmark.node.Code node ) { html.open ( "code" ) . appendAndEscape ( node.getLiteral ( ) ) . close ( "code" ) ; }

Target:
public void visit ( org.commonmark.node.Code node ) { html.open ( "code" ) . attribute ( "class" , "code" ) . appendAndEscape ( node.getLiteral ( ) ) . close ( "code" ) ; }
Source:
public void postEvent ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.common.Event event , com.google.gerrit.reviewdb.server.ReviewDb db ) throws com.google.gwtorm.server.OrmException { fireEvent ( change , event , db ) ; }

Target:
public void postEvent ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.server.events.ChangeEvent event , com.google.gerrit.reviewdb.server.ReviewDb db ) throws com.google.gwtorm.server.OrmException { fireEvent ( change , event , db ) ; }
Source:
public void refresh ( ) { Util.DETAIL_SVC.changeDetail ( changeId , new com.google.gerrit.client.rpc.ScreenLoadCallback < com.google.gerrit.common.data.ChangeDetail > ( this ) { @ java.lang.Override protected void preDisplay ( final com.google.gerrit.common.data.ChangeDetail r ) { display ( r ) ; } } ) ; }

Target:
protected void postDisplay ( ) { patchSetsBlock.setRegisterKeys ( true ) ; }
Source:
public boolean canConnect ( org.apache.sshd.common.SshdSocketAddress address , org.apache.sshd.common.Session session ) { return false ; }

Target:
public boolean canListen ( org.apache.sshd.common.util.net.SshdSocketAddress address , org.apache.sshd.common.session.Session session ) { return false ; }
Source:
public com.google.gerrit.server.ParamertizedString.Builder replace ( ) { return new com.google.gerrit.server.ParamertizedString.Builder ( ) ; }

Target:
java.lang.String apply ( java.lang.String a ) { int at = a.indexOf ( '@' ) ; return at < 0 ? a : a.substring ( 0 , at ) ; }
Source:
public boolean isVisible ( ) { return canPerform ( com.google.gerrit.reviewdb.ApprovalCategory.READ , ( ( short ) ( 1 ) ) ) ; }

Target:
public boolean isVisible ( ) { return ( getProjectControl ( ) . visibleForReplication ( ) ) || ( canPerform ( com.google.gerrit.reviewdb.ApprovalCategory.READ , ( ( short ) ( 1 ) ) ) ) ; }
Source:
public void start ( ) { queue.getDefaultQueue ( ) . scheduleAtFixedRate ( cleaner , com.googlesource.gerrit.plugins.websession.flatfile.FlatFileWebSessionCacheCleaner.CleanerLifecycle.INITIAL_DELAY_MS , cleanupInterval , java.util.concurrent.TimeUnit.MILLISECONDS ) ; }

Target:
public void start ( ) { scheduledCleanupTask = queue.getDefaultQueue ( ) . scheduleAtFixedRate ( cleaner , com.googlesource.gerrit.plugins.websession.flatfile.FlatFileWebSessionCacheCleaner.CleanerLifecycle.INITIAL_DELAY_MS , cleanupInterval , java.util.concurrent.TimeUnit.MILLISECONDS ) ; }
Source:
public static com.google.gerrit.client.GitwebLink getGitwebLink ( ) { com.google.gerrit.common.data.GitwebConfig gw = com.google.gerrit.client.Gerrit.getConfig ( ) . getGitwebLink ( ) ; return ( gw != null ) && ( ( gw.type ) != null ) ? new com.google.gerrit.client.GitwebLink ( gw ) : null ; }

Target:
public static com.google.gerrit.client.UrlAliasMatcher getUrlAliasMatcher ( ) { return com.google.gerrit.client.Gerrit.urlAliasMatcher ; }
Source:
private static synchronized void removeFromActive ( final com.google.gerrit.git.PushQueue.PushOp op ) { com.google.gerrit.git.PushQueue.active.remove ( op.uri ) ; }

Target:
static synchronized void notifyStarting ( final com.google.gerrit.git.PushOp op ) { com.google.gerrit.git.PushQueue.pending.remove ( op.getURI ( ) ) ; }
Source:
private java.lang.String urlGet ( ) { return ( "/changes/" + ( change.getChangeId ( ) ) ) + "/edits" ; }

Target:
private java.lang.String urlEdit2 ( ) { return ( "/changes/" + ( change2.getChangeId ( ) ) ) + "/edit/" ; }
Source:
public java.lang.Boolean call ( ) throws com.google.gerrit.server.project.NoSuchProjectException { com.google.gerrit.server.project.ProjectControl projectControl = controlFor ( project ) ; return ( projectControl.isReadable ( ) ) && ( ( ! ( projectControl.isHidden ( ) ) ) || ( config.replicateHiddenProjects ( ) ) ) ; }

Target:
public java.lang.Boolean call ( ) throws com.google.gerrit.server.project.NoSuchProjectException { return shouldReplicate ( controlFor ( project ) ) ; }
Source:
public com.googlesource.gerrit.plugins.uploadvalidator.ComparableCommitValidationMessage apply ( com.google.gerrit.server.git.validators.CommitValidationMessage input ) { return new com.googlesource.gerrit.plugins.uploadvalidator.ComparableCommitValidationMessage ( input.getMessage ( ) , input.isError ( ) ) ; }

Target:
public java.lang.String apply ( com.google.gerrit.server.git.validators.CommitValidationMessage input ) { java.lang.String pre = ( input.isError ( ) ) ? "ERROR: " : "MSG: " ; return pre + ( input.getMessage ( ) ) ; }
Source:
public void fire ( com.google.gerrit.reviewdb.client.Project.NameKey project , java.lang.String ref , org.eclipse.jgit.lib.ObjectId oldObjectId , org.eclipse.jgit.lib.ObjectId newObjectId ) { fire ( project , ref , oldObjectId , newObjectId , ReceiveCommand.Type.UPDATE ) ; }

Target:
public void fire ( com.google.gerrit.reviewdb.client.Project.NameKey project , org.eclipse.jgit.lib.RefUpdate refUpdate , org.eclipse.jgit.transport.ReceiveCommand.Type type , com.google.gerrit.reviewdb.client.Account updater ) { fire ( project , refUpdate.getName ( ) , refUpdate.getOldObjectId ( ) , refUpdate.getNewObjectId ( ) , type , util.accountInfo ( updater ) ) ; }
Source:
public org.eclipse.jgit.lib.RefUpdate.Result restoreFile ( com.google.gerrit.server.edit.ChangeEdit edit , java.lang.String file ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gerrit.server.project.InvalidChangeOperationException , java.io.IOException { org.eclipse.jgit.revwalk.RevCommit editCommit = edit.getEditCommit ( ) ; return modify ( edit , new com.google.gerrit.server.edit.tree.RestoreFileModification ( editCommit , file ) ) ; }

Target:
public void restoreFile ( org.eclipse.jgit.lib.Repository repository , com.google.gerrit.server.edit.ChangeEdit edit , java.lang.String file ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gerrit.server.project.InvalidChangeOperationException , java.io.IOException { org.eclipse.jgit.revwalk.RevCommit editCommit = edit.getEditCommit ( ) ; modifyTree ( repository , edit , new com.google.gerrit.server.edit.tree.RestoreFileModification ( editCommit , file ) ) ; }
Source:
public static final javax.servlet.http.HttpServletRequest getCurrentRequest ( ) { return com.google.gwtjsonrpc.server.JsonServlet.perThreadRequest.get ( ) ; }

Target:
public static final com.google.gwtjsonrpc.server.ActiveCall getCurrentCall ( ) { return com.google.gwtjsonrpc.server.JsonServlet.perThreadCall.get ( ) ; }
Source:
public static com.google.gerrit.server.patch.PatchListKey againstParentNum ( int parentNum , org.eclipse.jgit.lib.AnyObjectId newId , com.google.gerrit.extensions.client.DiffPreferencesInfo.Whitespace ws ) { return new com.google.gerrit.server.patch.PatchListKey ( parentNum , newId , ws , com.google.gerrit.server.patch.PatchListKey.Algorithm.OPTIMIZED_DIFF ) ; }

Target:
public static com.google.gerrit.server.diff.PatchListKey againstParentNum ( int parentNum , org.eclipse.jgit.lib.AnyObjectId newId , com.google.gerrit.extensions.client.DiffPreferencesInfo.Whitespace ws ) { return new com.google.gerrit.server.diff.PatchListKey ( parentNum , newId , ws , com.google.gerrit.server.diff.PatchListKey.Algorithm.OPTIMIZED_DIFF ) ; }
Source:
public static boolean isSignedIn ( ) { return ( com.google.gwt.user.client.Cookies.getCookie ( com.google.gerrit.client.Gerrit.ACCOUNT_COOKIE ) ) != null ; }

Target:
public static boolean isSignedIn ( ) { return ( com.google.gerrit.client.Gerrit.myAccount ) != null ; }
Source:
void removeAll ( ) { if ( ( skipBars ) != null ) { for ( com.google.gerrit.client.diff.SkipBar bar : skipBars ) { bar.expandAll ( ) ; } skipBars = null ; } }

Target:
void removeAll ( ) { if ( ( skipBars ) != null ) { for ( com.google.gerrit.client.diff.SkipBar bar : skipBars ) { bar.expandAll ( ) ; } skipBars = null ; line0 = null ; } }
Source:
protected void updateRepoImpl ( com.google.gerrit.server.git.BatchUpdate.RepoContext ctx ) { args.mergeTip.moveTipTo ( toMerge , toMerge ) ; toMerge.setStatusCode ( CommitMergeStatus.CLEAN_MERGE ) ; }

Target:
protected void updateRepoImpl ( com.google.gerrit.server.git.BatchUpdate.RepoContext ctx ) throws com.google.gerrit.server.git.IntegrationException { com.google.gerrit.server.git.CodeReviewCommit newCommit = amendGitlink ( toMerge ) ; args.mergeTip.moveTipTo ( newCommit , toMerge ) ; newCommit.setStatusCode ( CommitMergeStatus.CLEAN_MERGE ) ; }
Source:
protected void onLoad ( ) { super . onLoad ( ) ; if ( ( signedInListener ) != null ) { com.google.gerrit.client.Gerrit.addSignedInListener ( signedInListener ) ; } }

Target:
protected void onLoad ( ) { super . onLoad ( ) ; if ( ( signedInListener ) != null ) { com.google.gerrit.client.Gerrit.addSignOutHandler ( signedInListener ) ; } }
Source:
private com.google.gerrit.reviewdb.server.ReviewDb unwrapDb ( ) { com.google.gerrit.reviewdb.server.ReviewDb db = dbProvider.get ( ) ; if ( db instanceof com.google.gerrit.server.schema.DisabledChangesReviewDbWrapper ) { db = ( ( com.google.gerrit.server.schema.DisabledChangesReviewDbWrapper ) ( db ) ) . unsafeGetDelegate ( ) ; } return db ; }

Target:
private com.google.gerrit.reviewdb.server.ReviewDb getUnwrappedDb ( ) { com.google.gerrit.reviewdb.server.ReviewDb db = dbProvider.get ( ) ; return com.google.gerrit.reviewdb.server.ReviewDbUtil.unwrapDb ( db ) ; }
Source:
public void onSuccess ( com.google.gerrit.common.data.ChangeDetail result ) { detailCache.set ( result ) ; }

Target:
public void onClick ( final com.google.gwt.event.dom.client.ClickEvent event ) { b.setEnabled ( false ) ; Util.MANAGE_SVC.publish ( patchSet.getId ( ) , new com.google.gerrit.client.changes.ChangeDetailCache.GerritWidgetCallback ( b ) ) ; }
Source:
protected abstract com.google.inject.Injector createInjector ( ) ;

Target:
protected abstract com.google.inject.Injector createInjector ( com.google.gerrit.lifecycle.LifecycleManager lifecycle ) ;
Source:
public com.googlecode.prolog_cafe.lang.PrologMachineCopy loadMachine ( java.lang.String name , java.io.InputStream in ) throws com.googlecode.prolog_cafe.compiler.CompileException { com.googlecode.prolog_cafe.lang.PrologMachineCopy pmc = consultRules ( name , new java.io.InputStreamReader ( in ) ) ; if ( pmc == null ) { throw new com.googlecode.prolog_cafe.compiler.CompileException ( ( "Cannot consult rules from the stream " + name ) ) ; } return pmc ; }

Target:
public com.googlecode.prolog_cafe.lang.PrologMachineCopy loadMachine ( java.lang.String name , java.io.InputStream in ) throws com.googlecode.prolog_cafe.exceptions.CompileException { com.googlecode.prolog_cafe.lang.PrologMachineCopy pmc = consultRules ( name , new java.io.InputStreamReader ( in ) ) ; if ( pmc == null ) { throw new com.googlecode.prolog_cafe.exceptions.CompileException ( ( "Cannot consult rules from the stream " + name ) ) ; } return pmc ; }
Source:
public boolean accept ( java.io.File pathname ) { java.lang.String n = pathname.getName ( ) ; return ( n.endsWith ( ".jar" ) ) && ( pathname.isFile ( ) ) ; }

Target:
public boolean accept ( java.nio.file.Path entry ) throws java.io.IOException { return ( entry.getFileName ( ) . toString ( ) . endsWith ( ".jar" ) ) && ( java.nio.file.Files.isRegularFile ( entry ) ) ; }
Source:
public java.lang.Void call ( ) throws com.google.gerrit.extensions.restapi.RestApiException , com.google.gerrit.server.git.UpdateException , com.google.gerrit.server.project.NoSuchChangeException , com.google.gwtorm.server.OrmException , java.io.IOException , org.eclipse.jgit.errors.RepositoryNotFoundException { try ( com.google.gerrit.server.git.ReceiveCommits.RequestState state = requestState ( caller ) ) { insertChange ( state ) ; } com.google.gerrit.server.git.ReceiveCommits.synchronizedIncrement ( newProgress ) ; return null ; }

Target:
com.google.gerrit.reviewdb.client.Change getChange ( ) { return ins.getChange ( ) ; }
Source:
private static boolean wouldPushRef ( final org.spearce.jgit.transport.RemoteConfig cfg , final java.lang.String ref ) { for ( final org.spearce.jgit.transport.RefSpec s : cfg.getPushRefSpecs ( ) ) { if ( s.matchSource ( ref ) ) { return true ; } } return false ; }

Target:
boolean wouldPushRef ( final java.lang.String ref ) { for ( final org.spearce.jgit.transport.RefSpec s : remote.getPushRefSpecs ( ) ) { if ( s.matchSource ( ref ) ) { return true ; } } return false ; }
Source:
public com.google.gerrit.reviewdb.client.Change getChange ( ) { return getControl ( ) . getChange ( ) ; }

Target:
public com.google.gerrit.reviewdb.client.Change getChange ( ) { return rev.getChange ( ) ; }
Source:
public java.util.List < com.google.gerrit.server.query.change.ChangeData > toList ( ) { java.util.List < com.google.gerrit.server.query.change.ChangeData > r = rs.toList ( ) ; for ( com.google.gerrit.server.query.change.ChangeData cd : r ) { cd.cacheFromSource ( source ) ; } return r ; }

Target:
public int getCardinality ( ) { return ( source ) != null ? source.getCardinality ( ) : limit ( ) ; }
Source:
public void backupTimestampRefNameForUnsupportedNamespace ( ) throws java.lang.Exception { java.lang.String ref = "refs/changes/45/12345/1" ; com.google.common.truth.Truth.assertThat ( com.googlesource.gerrit.plugins.refprotection.BackupRef.get ( null , ref ) ) . isEqualTo ( ref ) ; }

Target:
public void backupTimestampRefNameForUnsupportedNamespace ( ) throws java.lang.Exception { java.lang.String ref = "refs/changes/45/12345/1" ; com.google.common.truth.Truth.assertThat ( com.googlesource.gerrit.plugins.refprotection.BackupRef.getTimestampBranch ( ref ) ) . isEqualTo ( ref ) ; }
Source:
protected static com.google.gerrit.server.query.QueryParseException error ( java.lang.String msg ) { return new com.google.gerrit.server.query.QueryParseException ( msg ) ; }

Target:
protected static com.google.gerrit.index.query.QueryParseException error ( java.lang.String msg ) { return new com.google.gerrit.index.query.QueryParseException ( msg ) ; }
Source:
private static boolean isRewritePossible ( com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > p ) { return ( ( p.getChildCount ( ) ) > 0 ) && ( ( ( p instanceof com.google.gerrit.server.query.AndPredicate ) || ( p instanceof com.google.gerrit.server.query.OrPredicate ) ) || ( p instanceof com.google.gerrit.server.query.NotPredicate ) ) ; }

Target:
private static boolean isRewritePossible ( com.google.gerrit.index.query.Predicate < com.google.gerrit.server.query.change.ChangeData > p ) { return ( ( p.getChildCount ( ) ) > 0 ) && ( ( ( p instanceof com.google.gerrit.index.query.AndPredicate ) || ( p instanceof com.google.gerrit.index.query.OrPredicate ) ) || ( p instanceof com.google.gerrit.index.query.NotPredicate ) ) ; }
Source:
protected void init ( ) throws com.google.gerrit.common.errors.EmailException { super . init ( ) ; ccAllApprovals ( ) ; bccStarredBy ( ) ; includeWatchers ( NotifyType.ALL_COMMENTS ) ; }

Target:
protected void init ( ) throws com.google.gerrit.common.errors.EmailException { super . init ( ) ; ccAllApprovals ( ) ; bccStarredBy ( ) ; includeWatchers ( NotifyType.ABANDONED_CHANGES ) ; includeWatchers ( NotifyType.ALL_COMMENTS ) ; }