auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public static java.lang.String getGerritJarPluginName ( java.io.File srcFile ) throws java.io.IOException { java.util.jar.JarFile jarFile = new java.util.jar.JarFile ( srcFile ) ; try { return jarFile.getManifest ( ) . getMainAttributes ( ) . getValue ( "Gerrit-PluginName" ) ; } finally { jarFile.close ( ) ; } }

Target:
public static java.lang.String getGerritJarPluginName ( java.io.File srcFile ) throws java.io.IOException { try ( java.util.jar.JarFile jarFile = new java.util.jar.JarFile ( srcFile ) ) { return jarFile.getManifest ( ) . getMainAttributes ( ) . getValue ( "Gerrit-PluginName" ) ; } }
Source:
public void run ( ) throws java.lang.Exception { parseCommandLine ( ) ; validate ( ) ; setAccount ( ) ; }

Target:
public void run ( ) throws java.lang.Exception { validate ( ) ; setAccount ( ) ; }
Source:
public final java.lang.String readString ( java.lang.String def , java.lang.String fmt , java.lang.Object ... args ) { if ( ( def != null ) && ( def.isEmpty ( ) ) ) { def = null ; } return readStringImpl ( def , fmt , args ) ; }

Target:
public abstract java.lang.String readString ( java.lang.String def , java.lang.String fmt , java.lang.Object ... args ) ;
Source:
protected void configureCommands ( ) { command ( "start" ) . to ( com.googlesource.gerrit.plugins.replication.StartCommand.class ) ; }

Target:
protected void configureCommands ( ) { command ( com.googlesource.gerrit.plugins.replication.StartCommand.class ) ; }
Source:
public V get ( K key ) { com.google.gerrit.ehcache.SerializableProtobuf < V > val = cache.get ( new com.google.gerrit.ehcache.SerializableProtobuf < K > ( key , keyCodec ) ) ; return val != null ? val.toObject ( valueCodec , valueProvider ) : null ; }

Target:
public V apply ( com.google.gerrit.ehcache.SerializableProtobuf < V > val ) { return val != null ? val.toObject ( valueCodec , valueProvider ) : null ; }
Source:
java.lang.String getRemoteEmail ( javax.servlet.http.HttpServletRequest req ) { if ( ( emailHeader ) != null ) { return com.google.common.base.Strings.emptyToNull ( req.getHeader ( emailHeader ) ) ; } else { return null ; } }

Target:
java.lang.String getRemoteEmail ( javax.servlet.http.HttpServletRequest req ) { if ( ( emailHeader ) != null ) { return com.google.common.base.Strings.emptyToNull ( req.getHeader ( emailHeader ) ) ; } return null ; }
Source:
void apply ( com.google.gerrit.server.notedb.ChangeUpdate update ) throws com.google.gwtorm.server.OrmException { checkUpdate ( update ) ; update.setChangeMessage ( message.getMessage ( ) ) ; setTopic ( update ) ; setStatus ( update ) ; }

Target:
void apply ( com.google.gerrit.server.notedb.ChangeUpdate update ) throws com.google.gwtorm.server.OrmException { checkUpdate ( update ) ; update.setChangeMessage ( message.getMessage ( ) ) ; setTopic ( update ) ; }
Source:
public void emptyExceptSubject ( ) throws java.lang.Exception { com.google.gerrit.server.notedb.ChangeUpdate update = newUpdate ( newChange ( ) , changeOwner ) ; update.setSubjectForCommit ( "Create change" ) ; update.commit ( ) ; com.google.common.truth.Truth.assertThat ( update.getRevision ( ) ) . isNotNull ( ) ; }

Target:
public void emptyExceptSubject ( ) throws java.lang.Exception { com.google.gerrit.server.notedb.ChangeUpdate update = newUpdate ( newChange ( ) , changeOwner ) ; update.setSubjectForCommit ( "Create change" ) ; com.google.common.truth.Truth.assertThat ( update.commit ( ) ) . isNotNull ( ) ; }
Source:
public static java.lang.String toAccountDashboard ( final com.google.gerrit.client.reviewdb.Account.Id acct ) { return "dashboard," + ( acct.get ( ) ) ; }

Target:
public static java.lang.String toAccountDashboard ( final com.google.gerrit.client.reviewdb.Account.Id acct ) { return "dashboard," + ( acct.toString ( ) ) ; }
Source:
public com.google.gerrit.server.patch.PatchList createEntry ( final com.google.gerrit.server.patch.PatchListKey key ) throws java.lang.Exception { final org.eclipse.jgit.lib.Repository repo = repoManager.openRepository ( key.projectKey.get ( ) ) ; try { return readPatchList ( key , repo ) ; } finally { repo.close ( ) ; } }

Target:
public com.google.gerrit.server.patch.PatchList createEntry ( final com.google.gerrit.server.patch.PatchListKey key ) throws java.lang.Exception { final org.eclipse.jgit.lib.Repository repo = repoManager.openRepository ( key.projectKey ) ; try { return readPatchList ( key , repo ) ; } finally { repo.close ( ) ; } }
Source:
protected final com.google.gerrit.pgm.CmdLineParser newCmdLineParser ( ) { final com.google.gerrit.pgm.CmdLineParser parser = new com.google.gerrit.pgm.CmdLineParser ( this ) ; for ( com.google.gerrit.server.ssh.commands.CmdOption c : optionList ) { parser.addOption ( c , c ) ; } return parser ; }

Target:
protected final com.google.gerrit.pgm.CmdLineParser newCmdLineParser ( ) { final com.google.gerrit.pgm.CmdLineParser parser = super . newCmdLineParser ( ) ; for ( com.google.gerrit.server.ssh.commands.CmdOption c : optionList ) { parser.addOption ( c , c ) ; } return parser ; }
Source:
void insert ( org.apache.lucene.document.Document doc ) throws java.io.IOException { writer.addDocument ( doc ) ; commit ( ) ; }

Target:
void insert ( org.apache.lucene.document.Document doc ) throws java.io.IOException { writer.addDocument ( doc ) ; }
Source:
void onRevert ( com.google.gwt.event.dom.client.ClickEvent e ) { com.google.gerrit.client.change.RevertAction.call ( revert , changeId , revision , project , subject ) ; }

Target:
void onRevert ( com.google.gwt.event.dom.client.ClickEvent e ) { com.google.gerrit.client.change.RevertAction.call ( revert , changeId , revision , subject ) ; }
Source:
public void onDoubleClick ( com.google.gwt.event.dom.client.DoubleClickEvent arg0 ) { editArea.setText ( contentPanelMessage.getText ( ) ) ; setEdit ( ( ! ( isEdit ( ) ) ) ) ; runClickCallback ( ) ; }

Target:
public void onDoubleClick ( com.google.gwt.event.dom.client.DoubleClickEvent arg0 ) { setEdit ( true ) ; }
Source:
public boolean apply ( com.google.gerrit.extensions.common.ProjectInfo info ) { return new com.google.gerrit.reviewdb.client.Project.NameKey ( ( ( info.name ) != null ? info.name : com.google.gerrit.extensions.restapi.Url.decode ( info.id ) ) ) . equals ( p ) ; }

Target:
public Project.NameKey apply ( com.google.gerrit.extensions.common.ProjectInfo in ) { return new com.google.gerrit.reviewdb.client.Project.NameKey ( in.name ) ; }
Source:
private static com.google.gerrit.client.rpc.RestApi detail ( int id ) { return com.google.gerrit.client.changes.ChangeApi.call ( id , "detail" ) ; }

Target:
public static com.google.gerrit.client.rpc.RestApi detail ( int id ) { return com.google.gerrit.client.changes.ChangeApi.call ( id , "detail" ) ; }
Source:
public void onSuccess ( com.google.gwt.core.client.JavaScriptObject result ) { com.google.gerrit.client.Gerrit.display ( com.google.gerrit.common.PageLinks.toChange ( id ) ) ; }

Target:
public void onSuccess ( com.google.gwt.core.client.JavaScriptObject result ) { com.google.gerrit.client.Gerrit.display ( com.google.gerrit.common.PageLinks.toChange ( project , id ) ) ; }
Source:
void evict ( com.google.gerrit.reviewdb.client.AccountGroup.UUID groupUuid , com.google.gerrit.reviewdb.client.AccountGroup.Id groupId , com.google.gerrit.reviewdb.client.AccountGroup.NameKey groupName ) throws java.io.IOException ;

Target:
void evict ( com.google.gerrit.reviewdb.client.AccountGroup.UUID groupUuid ) ;
Source:
public boolean match ( com.google.gerrit.server.query.change.ChangeData cd ) throws com.google.gwtorm.server.OrmException { return ( cd.change ( ) . getLastUpdatedOn ( ) . getTime ( ) ) <= ( cut.getTime ( ) ) ; }

Target:
public boolean match ( com.google.gerrit.server.query.change.ChangeData cd ) throws com.google.gwtorm.server.OrmException { return ( cd.change ( ) . getLastUpdatedOn ( ) . getTime ( ) ) >= ( cut.getTime ( ) ) ; }
Source:
protected void onLoad ( ) { super . onLoad ( ) ; display ( ) ; }

Target:
protected void onLoad ( ) { super . onLoad ( ) ; }
Source:
boolean canSubmit ( boolean isChangeOwner ) { if ( RefNames.REFS_CONFIG.equals ( refName ) ) { return projectControl.isOwner ( ) ; } return ( canPerform ( Permission.SUBMIT , isChangeOwner ) ) && ( isProjectStatePermittingWrite ( ) ) ; }

Target:
boolean canSubmit ( boolean isChangeOwner ) { if ( RefNames.REFS_CONFIG.equals ( refName ) ) { return projectControl.isOwner ( ) ; } return canPerform ( Permission.SUBMIT , isChangeOwner ) ; }
Source:
private java.lang.String encode ( java.lang.String segment ) { if ( type ( ) . urlEncode ( ) ) { return com.google.gwt.http.client.URL.encodeQueryString ( type ( ) . replacePathSeparator ( segment ) ) ; } else { return segment ; } }

Target:
private java.lang.String encode ( java.lang.String segment ) { if ( type ( ) . urlEncode ( ) ) { return com.google.gwt.http.client.URL.encodeQueryString ( type ( ) . replacePathSeparator ( segment ) ) ; } return segment ; }
Source:
public void listOneIncludeMember ( ) throws java.lang.Exception { group ( "gx" , "Administrators" ) ; group ( "gy" , "Administrators" ) ; PUT ( "/groups/Administrators/groups/gx" ) ; PUT ( "/groups/Administrators/groups/gy" ) ; org.junit.Assert.assertEquals ( GET_ONE ( "/groups/Administrators/groups/gx" ) . name , "gx" ) ; }

Target:
public void listOneIncludeMember ( ) throws java.lang.Exception { group ( "gx" , "Administrators" ) ; group ( "gy" , "Administrators" ) ; PUT ( "/groups/Administrators/groups/gx" ) ; PUT ( "/groups/Administrators/groups/gy" ) ; com.google.common.truth.Truth.assertThat ( GET_ONE ( "/groups/Administrators/groups/gx" ) . name ) . isEqualTo ( "gx" ) ; }
Source:
void setLineNumber ( com.google.gerrit.client.diff.DisplaySide side , int cmLine , int line ) { setLineNumber ( side , cmLine , java.lang.String.valueOf ( line ) , UnifiedTable.style.unifiedLineNumber ( ) ) ; }

Target:
void setLineNumber ( com.google.gerrit.client.diff.DisplaySide side , int cmLine , int line ) { setLineNumber ( side , cmLine , line , UnifiedTable.style.unifiedLineNumber ( ) ) ; }
Source:
public void merge ( com.google.gerrit.server.git.MergeOp.Factory mof , com.google.gerrit.reviewdb.client.Branch.NameKey branch ) { if ( start ( branch ) ) { mergeImpl ( mof , branch ) ; } }

Target:
public void merge ( com.google.gerrit.reviewdb.client.Branch.NameKey branch ) { if ( start ( branch ) ) { mergeImpl ( branch ) ; } }
Source:
public void setUp ( ) { synchronized ( java.util.TimeZone.class ) { systemTimeZone = java.util.TimeZone.getDefault ( ) ; java.util.TimeZone.setDefault ( java.util.TimeZone.getTimeZone ( "GMT-5:00" ) ) ; format = new java.text.SimpleDateFormat ( "yyyy-MM-dd HH:mm:ss.SSS Z" ) ; } }

Target:
public void setUp ( ) throws java.lang.Exception { synchronized ( java.util.TimeZone.class ) { systemTimeZone = java.util.TimeZone.getDefault ( ) ; java.util.TimeZone.setDefault ( java.util.TimeZone.getTimeZone ( "GMT-5:00" ) ) ; format = new java.text.SimpleDateFormat ( "yyyy-MM-dd HH:mm:ss.SSS Z" ) ; } }
Source:
public boolean canUpload ( ) { return ( projectControl.controlForRef ( ( "refs/for/" + ( getRefName ( ) ) ) ) . canPerform ( Permission.PUSH ) ) && ( isProjectStatePermittingWrite ( ) ) ; }

Target:
private boolean canUpload ( ) { return ( projectControl.controlForRef ( ( "refs/for/" + ( getRefName ( ) ) ) ) . canPerform ( Permission.PUSH ) ) && ( isProjectStatePermittingWrite ( ) ) ; }
Source:
public static java.lang.String refsDraftCommentsPrefix ( com.google.gerrit.reviewdb.client.Account.Id accountId ) { return com.google.gerrit.reviewdb.client.RefNames.buildRefsPrefix ( com.google.gerrit.reviewdb.client.RefNames.REFS_DRAFT_COMMENTS , accountId ) . toString ( ) ; }

Target:
public static java.lang.String refsDraftCommentsPrefix ( com.google.gerrit.reviewdb.client.Account.Id accountId ) { return com.google.gerrit.reviewdb.client.RefNames.buildRefsPrefix ( com.google.gerrit.reviewdb.client.RefNames.REFS_DRAFT_COMMENTS , accountId.get ( ) ) . toString ( ) ; }
Source:
public com.google.gerrit.server.mail.CommentSender create ( com.google.gerrit.extensions.api.changes.ReviewInput.NotifyHandling notify , com.google.gerrit.reviewdb.client.Change change ) ;

Target:
public com.google.gerrit.server.mail.CommentSender create ( com.google.gerrit.extensions.api.changes.ReviewInput.NotifyHandling notify , com.google.gerrit.reviewdb.client.Change.Id id ) ;
Source:
public void allRefsVisibleWithRefsMetaConfig ( ) throws java.lang.Exception { allow ( Permission.READ , com.google.gerrit.server.group.SystemGroupBackend.REGISTERED_USERS , "refs/*" ) ; allow ( Permission.READ , com.google.gerrit.server.group.SystemGroupBackend.REGISTERED_USERS , "refs/meta/config" ) ; assertRefs ( "HEAD" , "refs/changes/01/1/1" , "refs/changes/02/2/1" , "refs/heads/branch" , "refs/heads/master" ) ; }

Target:
public void allRefsVisibleWithRefsMetaConfig ( ) throws java.lang.Exception { allow ( Permission.READ , com.google.gerrit.server.group.SystemGroupBackend.REGISTERED_USERS , "refs/*" ) ; allow ( Permission.READ , com.google.gerrit.server.group.SystemGroupBackend.REGISTERED_USERS , "refs/meta/config" ) ; assertRefs ( "HEAD" , "refs/changes/01/1/1" , "refs/changes/02/2/1" , "refs/heads/branch" , "refs/heads/master" , "refs/meta/config" ) ; }
Source:
public static void draft ( com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String draftId , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.changes.CommentInfo > cb ) { com.google.gerrit.client.changes.CommentApi.revision ( id , "drafts" ) . id ( draftId ) . get ( cb ) ; }

Target:
public static void draft ( @ com.google.gerrit.common.Nullable java.lang.String project , com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String draftId , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.changes.CommentInfo > cb ) { com.google.gerrit.client.changes.CommentApi.revision ( project , id , "drafts" ) . id ( draftId ) . get ( cb ) ; }
Source:
java.lang.String patchPageTitle ( int id , java.lang.String path ) ;

Target:
java.lang.String patchPageTitle ( java.lang.String changeId , java.lang.String path ) ;
Source:
private boolean match ( java.lang.String destBranch , java.lang.String refPattern ) { return com.google.gerrit.server.project.RefPatternMatcher.getMatcher ( refPattern ) . match ( destBranch , this . getRefControl ( ) . getCurrentUser ( ) . getUserName ( ) ) ; }

Target:
private boolean match ( java.lang.String destBranch , java.lang.String refPattern ) { return com.google.gerrit.server.project.RefPatternMatcher.getMatcher ( refPattern ) . match ( destBranch , getCurrentUser ( ) . getUserName ( ) ) ; }
Source:
private boolean canSkipRef ( com.google.gerrit.server.config.PluginConfig config , java.lang.String ref ) { return matchCriteria ( config , "skipRef" , ref , true ) ; }

Target:
private boolean canSkipRef ( com.google.gerrit.server.config.PluginConfig config , java.lang.String ref ) { return matchCriteria ( config , "skipRef" , ref , true , true ) ; }
Source:
public void close ( ) throws java.io.IOException { rw.release ( ) ; repo.close ( ) ; }

Target:
public void close ( ) throws java.io.IOException { rw.close ( ) ; repo.close ( ) ; }
Source:
public final boolean requireXsrfValid ( ) { if ( isXsrfValid ( ) ) { return true ; } else { onFailure ( new java.lang.Exception ( com.google.gwtjsonrpc.common.JsonConstants.ERROR_INVALID_XSRF ) ) ; return false ; } }

Target:
public final boolean requireXsrfValid ( ) { if ( isXsrfValid ( ) ) { return true ; } onFailure ( new java.lang.Exception ( com.google.gwtjsonrpc.common.JsonConstants.ERROR_INVALID_XSRF ) ) ; return false ; }
Source:
public void onSuccess ( final com.google.gerrit.client.projects.ProjectMap result ) { projectsTab.display ( result ) ; if ( firstPopupLoad ) { firstPopupLoad = false ; displayPopup ( ) ; } }

Target:
private void display ( final com.google.gerrit.client.projects.ProjectMap result ) { projectsTab.display ( result ) ; if ( firstPopupLoad ) { firstPopupLoad = false ; displayPopup ( ) ; } }
Source:
public static java.lang.String refsDraftComments ( com.google.gerrit.reviewdb.client.Account.Id accountId , com.google.gerrit.reviewdb.client.Change.Id changeId ) { java.lang.StringBuilder r = com.google.gerrit.reviewdb.client.RefNames.buildRefsPrefix ( com.google.gerrit.reviewdb.client.RefNames.REFS_DRAFT_COMMENTS , accountId ) ; r.append ( changeId.get ( ) ) ; return r.toString ( ) ; }

Target:
public static java.lang.String refsDraftComments ( com.google.gerrit.reviewdb.client.Account.Id accountId , com.google.gerrit.reviewdb.client.Change.Id changeId ) { java.lang.StringBuilder r = com.google.gerrit.reviewdb.client.RefNames.buildRefsPrefix ( com.google.gerrit.reviewdb.client.RefNames.REFS_DRAFT_COMMENTS , accountId.get ( ) ) ; r.append ( changeId.get ( ) ) ; return r.toString ( ) ; }
Source:
public void testParentHashCode ( ) { final java.lang.String str = "foo" ; final com.google.gwtorm.client.StringKeyTestCase.Parent p = new com.google.gwtorm.client.StringKeyTestCase.Parent ( str ) ; assertEquals ( str.hashCode ( ) , p.hashCode ( ) ) ; }

Target:
public void testParentHashCode ( ) { final java.lang.String str = "foo" ; final com.google.gwtorm.client.StringKeyTestCase.Parent p = new com.google.gwtorm.client.StringKeyTestCase.Parent ( str ) ; org.junit.Assert.assertEquals ( str.hashCode ( ) , p.hashCode ( ) ) ; }
Source:
public java.lang.String getBaseGerritUrl ( javax.servlet.http.HttpServletRequest req ) { return "http://test-host-review/foo/" ; }

Target:
public java.lang.String getBaseGerritUrl ( javax.servlet.http.HttpServletRequest req ) { return ( "http://" + ( com.google.gitiles.TestGitilesUrls.HOST_NAME ) ) + "-review/foo/" ; }
Source:
com.google.gwtorm.client.ResultSet < com.google.gerrit.client.reviewdb.ProjectRight > byProject ( com.google.gerrit.client.reviewdb.Project.Id id ) throws com.google.gwtorm.client.OrmException ;

Target:
com.google.gwtorm.client.ResultSet < com.google.gerrit.client.reviewdb.ProjectRight > byProject ( com.google.gerrit.client.reviewdb.Project.NameKey name ) throws com.google.gwtorm.client.OrmException ;
Source:
private static < T , K extends com.google.gwtorm.client.Key < ? > > com.google.common.util.concurrent.CheckedFuture < T , com.google.gwtorm.server.OrmException > emptyFuture ( ) { return com.google.common.util.concurrent.Futures.immediateCheckedFuture ( null ) ; }

Target:
private static < T > com.google.common.util.concurrent.CheckedFuture < T , com.google.gwtorm.server.OrmException > emptyFuture ( ) { return com.google.common.util.concurrent.Futures.immediateCheckedFuture ( null ) ; }
Source:
public java.lang.String format ( com.googlesource.gerrit.plugins.xdocs.ConfigSection cfg , java.lang.String raw ) { return ( "<pre>" + ( org.apache.commons.lang.StringEscapeUtils.escapeHtml ( raw ) ) ) + "</pre>" ; }

Target:
public java.lang.String format ( java.lang.String projectName , com.googlesource.gerrit.plugins.xdocs.ConfigSection cfg , java.lang.String raw ) { return ( "<pre>" + ( org.apache.commons.lang.StringEscapeUtils.escapeHtml ( raw ) ) ) + "</pre>" ; }
Source:
public abstract boolean writeChanges ( ) ;

Target:
protected abstract boolean writeChanges ( ) ;
Source:
protected < R extends com.google.gerrit.extensions.restapi.RestResource > com.google.gerrit.extensions.restapi.RestApiModule.ModifyViewBinder < R > put ( com.google.inject.TypeLiteral < com.google.gerrit.extensions.restapi.RestView < R > > viewType , java.lang.String name ) { return new com.google.gerrit.extensions.restapi.RestApiModule.ModifyViewBinder < R > ( view ( viewType , com.google.gerrit.extensions.restapi.RestApiModule.PUT , name ) ) ; }

Target:
protected < R extends com.google.gerrit.extensions.restapi.RestResource > com.google.gerrit.extensions.restapi.RestApiModule.ModifyViewBinder < R > put ( com.google.inject.TypeLiteral < com.google.gerrit.extensions.restapi.RestView < R > > viewType , java.lang.String name ) { return new com.google.gerrit.extensions.restapi.RestApiModule.ModifyViewBinder ( view ( viewType , com.google.gerrit.extensions.restapi.RestApiModule.PUT , name ) ) ; }
Source:
public void repeatedHashtag ( ) throws java.lang.Exception { java.lang.String commitMessage = "#Subject\n\n#Hashtag1\n\n#Hashtag2\n\n#Hashtag1" ; com.google.common.truth.Truth.assertThat ( ( ( java.lang.Iterable < ? > ) ( com.google.gerrit.server.change.HashtagsUtil.extractTags ( commitMessage ) ) ) ) . containsExactlyElementsIn ( com.google.common.collect.Sets.newHashSet ( "Subject" , "Hashtag1" , "Hashtag2" ) ) ; }

Target:
public void repeatedHashtag ( ) throws java.lang.Exception { java.lang.String commitMessage = "#Subject\n\n#Hashtag1\n\n#Hashtag2\n\n#Hashtag1" ; com.google.common.truth.Truth.assertThat ( com.google.gerrit.server.change.HashtagsUtil.extractTags ( commitMessage ) ) . containsExactlyElementsIn ( com.google.common.collect.Sets.newHashSet ( "Subject" , "Hashtag1" , "Hashtag2" ) ) ; }
Source:
public void index ( com.google.gerrit.server.query.change.ChangeData cd ) throws java.io.IOException { for ( com.google.gerrit.server.index.Index < ? , com.google.gerrit.server.query.change.ChangeData > i : getWriteIndexes ( ) ) { i.replace ( cd ) ; } fireChangeIndexedEvent ( cd ) ; }

Target:
public void index ( com.google.gerrit.server.query.change.ChangeData cd ) throws java.io.IOException { for ( com.google.gerrit.server.index.Index < ? , com.google.gerrit.server.query.change.ChangeData > i : getWriteIndexes ( ) ) { i.replace ( cd ) ; } fireChangeIndexedEvent ( cd.getId ( ) . get ( ) ) ; }
Source:
public void onSuccess ( com.google.gerrit.client.changes.ChangeInfo info ) { info.init ( ) ; loadConfigInfo ( info ) ; }

Target:
public void onSuccess ( com.google.gerrit.client.changes.ChangeInfo info ) { info.init ( ) ; loadConfigInfo ( info , base ) ; }
Source:
public void emptySoy ( ) throws java.lang.Exception { org.junit.Assert.assertEquals ( com.google.common.collect.ImmutableList.of ( ) , buildBranchesSoyData ( ) ) ; org.junit.Assert.assertEquals ( com.google.common.collect.ImmutableList.of ( ) , buildTagsSoyData ( ) ) ; }

Target:
public void emptySoy ( ) throws java.lang.Exception { com.google.common.truth.Truth.assertThat ( buildBranchesSoyData ( ) ) . isEmpty ( ) ; com.google.common.truth.Truth.assertThat ( buildTagsSoyData ( ) ) . isEmpty ( ) ; }
Source:
private void assertBodyEquals ( java.lang.String expected , org.eclipse.jgit.lib.ObjectId commitId ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit commit = parseCommit ( commitId ) ; org.junit.Assert.assertEquals ( expected , commit.getFullMessage ( ) ) ; }

Target:
private void assertBodyEquals ( java.lang.String expected , org.eclipse.jgit.lib.ObjectId commitId ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit commit = parseCommit ( commitId ) ; com.google.common.truth.Truth.assertThat ( commit.getFullMessage ( ) ) . isEqualTo ( expected ) ; }
Source:
private java.net.URI [ ] listenURLs ( final org.eclipse.jgit.lib.Config cfg ) { java.lang.String [ ] urls = cfg.getStringList ( "httpd" , null , "listenurl" ) ; if ( ( urls.length ) == 0 ) { urls = new java.lang.String [ ] { "http://*:8080/" } ; } final java.net.URI [ ] r = new java.net.URI [ urls.length ] ; for ( int i = 0 ; i < ( r.length ) ; i ++ ) { final java.lang.String s = urls [ i ] ; try { r [ i ] = new java.net.URI ( s ) ; } catch ( java.net.URISyntaxException e ) { throw new java.lang.IllegalArgumentException ( ( "Invalid httpd.listenurl " + s ) , e ) ; } } return r ; }

Target:
static java.net.URI [ ] listenURLs ( final org.eclipse.jgit.lib.Config cfg ) { java.lang.String [ ] urls = cfg.getStringList ( "httpd" , null , "listenurl" ) ; if ( ( urls.length ) == 0 ) { urls = new java.lang.String [ ] { "http://*:8080/" } ; } final java.net.URI [ ] r = new java.net.URI [ urls.length ] ; for ( int i = 0 ; i < ( r.length ) ; i ++ ) { final java.lang.String s = urls [ i ] ; try { r [ i ] = new java.net.URI ( s ) ; } catch ( java.net.URISyntaxException e ) { throw new java.lang.IllegalArgumentException ( ( "Invalid httpd.listenurl " + s ) , e ) ; } } return r ; }
Source:
private com.google.gerrit.server.git.strategy.SubmitStrategy createStrategy ( com.google.gerrit.extensions.client.SubmitType submitType , org.eclipse.jgit.lib.BatchRefUpdate branchUpdate ) throws com.google.gerrit.server.git.MergeException , com.google.gerrit.server.project.NoSuchProjectException { return submitStrategyFactory.create ( submitType , db , repo , rw , inserter , canMergeFlag , branchUpdate , getAlreadyAccepted ( branchTip ) , destBranch ) ; }

Target:
private com.google.gerrit.server.git.strategy.SubmitStrategy createStrategy ( com.google.gerrit.extensions.client.SubmitType submitType ) throws com.google.gerrit.server.git.MergeException , com.google.gerrit.server.project.NoSuchProjectException { return submitStrategyFactory.create ( submitType , db , repo , rw , inserter , canMergeFlag , getAlreadyAccepted ( branchTip ) , destBranch ) ; }
Source:
com.google.gerrit.extensions.api.changes.ChangeApi id ( java.lang.String triplet ) throws com.google.gerrit.extensions.restapi.RestApiException ;

Target:
com.google.gerrit.extensions.api.changes.ChangeApi id ( java.lang.String id ) throws com.google.gerrit.extensions.restapi.RestApiException ;
Source:
public final native boolean showWhitespaceErrors ( ) ;

Target:
private final native int get ( java.lang.String n , int d ) ;
Source:
private void display ( final com.google.gerrit.client.projects.ProjectMap result ) { projectsTab.display ( result , subname ) ; if ( firstPopupLoad ) { firstPopupLoad = false ; displayPopup ( ) ; } }

Target:
public void onSuccess ( final com.google.gerrit.client.projects.ProjectMap result ) { projectsTab.display ( result , subname ) ; if ( firstPopupLoad ) { firstPopupLoad = false ; displayPopup ( ) ; } }
Source:
protected void preDisplay ( java.lang.Void result ) { initEditor ( content ) ; renderLinks ( editFileInfo , diffLinks ) ; editFileInfo = null ; diffLinks = null ; }

Target:
protected void preDisplay ( java.lang.Void result ) { initEditor ( content ) ; content = null ; renderLinks ( editFileInfo , diffLinks ) ; editFileInfo = null ; diffLinks = null ; }
Source:
public com.google.gerrit.extensions.restapi.RestView < com.google.gerrit.server.change.RevisionResource > list ( ) throws com.google.gerrit.extensions.restapi.AuthException { checkIdentifiedUser ( ) ; return list.get ( ) ; }

Target:
public com.google.gerrit.extensions.restapi.RestView < com.google.gerrit.server.change.RevisionResource > list ( ) throws com.google.gerrit.extensions.restapi.AuthException { checkIdentifiedUser ( ) ; return list ; }
Source:
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 ) { }

Target:
public void doChangeRestoredHook ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.reviewdb.client.Account account , com.google.gerrit.reviewdb.client.PatchSet patchSet , java.lang.String reason , com.google.gerrit.reviewdb.server.ReviewDb db ) { }
Source:
private org.eclipse.jgit.lib.Repository openRepository ( final com.google.gerrit.reviewdb.client.Project.NameKey name ) { try { return repoManager.openRepository ( name ) ; } catch ( org.eclipse.jgit.errors.RepositoryNotFoundException err ) { com.google.gerrit.common.ChangeHookRunner.log.warn ( ( "Cannot open repository " + ( name.get ( ) ) ) , err ) ; return null ; } }

Target:
private org.eclipse.jgit.lib.Repository openRepository ( final com.google.gerrit.reviewdb.client.Project.NameKey name ) { try { return repoManager.openRepository ( name ) ; } catch ( java.io.IOException err ) { com.google.gerrit.common.ChangeHookRunner.log.warn ( ( "Cannot open repository " + ( name.get ( ) ) ) , err ) ; return null ; } }
Source:
public static java.lang.String messageUUID ( final com.google.gerrit.reviewdb.ReviewDb db ) throws com.google.gwtorm.client.OrmException { final byte [ ] raw = new byte [ 8 ] ; com.google.gerrit.server.ChangeUtil.fill ( raw , db ) ; return org.eclipse.jgit.util.Base64.encodeBytes ( raw ) ; }

Target:
public static java.lang.String messageUUID ( final com.google.gerrit.reviewdb.server.ReviewDb db ) throws com.google.gwtorm.server.OrmException { final byte [ ] raw = new byte [ 8 ] ; com.google.gerrit.server.ChangeUtil.fill ( raw , db ) ; return org.eclipse.jgit.util.Base64.encodeBytes ( raw ) ; }
Source:
public static org.eclipse.jgit.lib.PersonIdent newIdent ( com.google.gerrit.reviewdb.client.Account author , java.util.Date when , org.eclipse.jgit.lib.PersonIdent serverIdent , java.lang.String anonymousCowardName ) { return new org.eclipse.jgit.lib.PersonIdent ( author.getName ( anonymousCowardName ) , ( ( ( author.getId ( ) . get ( ) ) + "@" ) + ( com.google.gerrit.server.notedb.ChangeNoteUtil.GERRIT_PLACEHOLDER_HOST ) ) , when , serverIdent.getTimeZone ( ) ) ; }

Target:
public org.eclipse.jgit.lib.PersonIdent newIdent ( com.google.gerrit.reviewdb.client.Account author , java.util.Date when , org.eclipse.jgit.lib.PersonIdent serverIdent , java.lang.String anonymousCowardName ) { return new org.eclipse.jgit.lib.PersonIdent ( author.getName ( anonymousCowardName ) , ( ( ( author.getId ( ) . get ( ) ) + "@" ) + ( serverId ) ) , when , serverIdent.getTimeZone ( ) ) ; }
Source:
public void mergeByOtherNotifyNone ( ) throws java.lang.Exception { com.google.gerrit.acceptance.server.mail.StagedChange sc = stageChange ( com.google.gerrit.server.account.WatchConfig.NotifyType.ALL_COMMENTS , com.google.gerrit.server.account.WatchConfig.NotifyType.SUBMITTED_CHANGES ) ; merge ( sc.changeId , other , com.google.gerrit.extensions.api.changes.NotifyHandling.NONE ) ; assertThat ( sender ) . notSent ( ) ; }

Target:
public void mergeByOtherNotifyNone ( ) throws java.lang.Exception { com.google.gerrit.acceptance.server.mail.StagedChange sc = stageChange ( ) ; merge ( sc.changeId , other , com.google.gerrit.extensions.api.changes.NotifyHandling.NONE ) ; assertThat ( sender ) . notSent ( ) ; }
Source:
private void blockCreateReference ( ) throws java.lang.Exception { com.google.gerrit.server.git.ProjectConfig cfg = projectCache.checkedGet ( project ) . getConfig ( ) ; com.google.gerrit.server.project.Util.block ( cfg , Permission.CREATE , com.google.gerrit.server.group.SystemGroupBackend.ANONYMOUS_USERS , "refs/*" ) ; saveProjectConfig ( project , cfg ) ; }

Target:
private void blockCreateReference ( ) throws java.lang.Exception { block ( Permission.CREATE , com.google.gerrit.server.group.SystemGroupBackend.ANONYMOUS_USERS , "refs/*" ) ; }
Source:
public com.google.gerrit.server.notedb.DraftCommentNotes create ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.reviewdb.client.Account.Id accountId ) { return new com.google.gerrit.server.notedb.DraftCommentNotes ( repoManager , draftsProject , change , accountId ) ; }

Target:
public com.google.gerrit.server.notedb.DraftCommentNotes create ( com.google.gerrit.reviewdb.client.Change.Id changeId , com.google.gerrit.reviewdb.client.Account.Id accountId ) { return new com.google.gerrit.server.notedb.DraftCommentNotes ( repoManager , draftsProject , changeId , accountId ) ; }
Source:
private com.google.gerrit.metrics.dropwizard.MetricJson toJson ( java.lang.String q , com.codahale.metrics.Metric m ) { return dataOnly ? new com.google.gerrit.metrics.dropwizard.MetricJson ( m ) : new com.google.gerrit.metrics.dropwizard.MetricJson ( m , metrics.getAnnotations ( q ) ) ; }

Target:
private com.google.gerrit.metrics.dropwizard.MetricJson toJson ( java.lang.String q , com.codahale.metrics.Metric m ) { return new com.google.gerrit.metrics.dropwizard.MetricJson ( m , metrics.getAnnotations ( q ) , dataOnly ) ; }
Source:
void onRefReplicatedToAllNodes ( java.lang.String project , java.lang.String ref , int nodesCount ) { com.googlesource.gerrit.plugins.replication.RefReplicationDoneEvent event = new com.googlesource.gerrit.plugins.replication.RefReplicationDoneEvent ( project , ref , nodesCount ) ; postEvent ( project , ref , event ) ; }

Target:
void onRefReplicatedToAllNodes ( java.lang.String project , java.lang.String ref , int nodesCount ) { postEvent ( new com.googlesource.gerrit.plugins.replication.RefReplicationDoneEvent ( project , ref , nodesCount ) ) ; }
Source:
com.google.gwtorm.client.ResultSet < com.google.gerrit.client.reviewdb.PatchLineComment > published ( com.google.gerrit.client.reviewdb.Patch.Id id ) throws com.google.gwtorm.client.OrmException ;

Target:
com.google.gwtorm.client.ResultSet < com.google.gerrit.client.reviewdb.PatchLineComment > published ( com.google.gerrit.client.reviewdb.Patch.Key patch ) throws com.google.gwtorm.client.OrmException ;
Source:
void setDisableHttpd ( final boolean arg ) { httpd = false ; }

Target:
void setDisableHttpd ( @ java.lang.SuppressWarnings ( value = "unused" ) boolean arg ) { httpd = false ; }
Source:
public void removeFromNonExistingGroup_NotFound ( ) throws java.lang.Exception { org.junit.Assert.assertEquals ( HttpStatus.SC_NOT_FOUND , DELETE ( "/groups/non-existing/members/admin" ) ) ; }

Target:
public void removeFromNonExistingGroup_NotFound ( ) throws java.lang.Exception { com.google.common.truth.Truth.assertThat ( DELETE ( "/groups/non-existing/members/admin" ) ) . isEqualTo ( HttpStatus.SC_NOT_FOUND ) ; }
Source:
public static void deleteRevision ( int id , java.lang.String commit , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwt.core.client.JavaScriptObject > cb ) { com.google.gerrit.client.changes.ChangeApi.revision ( id , commit ) . delete ( cb ) ; }

Target:
public static void deleteRevision ( @ com.google.gerrit.common.Nullable java.lang.String project , int id , java.lang.String commit , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwt.core.client.JavaScriptObject > cb ) { com.google.gerrit.client.changes.ChangeApi.revision ( project , id , commit ) . delete ( cb ) ; }
Source:
protected void configure ( ) { cache ( com.google.gerrit.server.git.ChangeCache.ID_CACHE , Project.NameKey.class , new com.google.inject.TypeLiteral < java.util.List < com.google.gerrit.reviewdb.client.Change > > ( ) { } ) . maximumWeight ( 1024 ) . loader ( com.google.gerrit.server.git.ChangeCache.Loader.class ) ; }

Target:
protected void configure ( ) { cache ( com.google.gerrit.server.git.ChangeCache.ID_CACHE , Project.NameKey.class , new com.google.inject.TypeLiteral < java.util.List < com.google.gerrit.reviewdb.client.Change > > ( ) { } ) . maximumWeight ( 0 ) . loader ( com.google.gerrit.server.git.ChangeCache.Loader.class ) ; }
Source:
public com.google.gerrit.reviewdb.client.Change update ( com.google.gerrit.reviewdb.client.Change c ) { if ( c.getStatus ( ) . isOpen ( ) ) { if ( setStatusNew ) { c.setStatus ( Change.Status.NEW ) ; } com.google.gerrit.server.ChangeUtil.updated ( c ) ; } return c ; }

Target:
public com.google.gerrit.reviewdb.client.Change update ( com.google.gerrit.reviewdb.client.Change c ) { if ( c.getStatus ( ) . isOpen ( ) ) { c.setStatus ( Change.Status.NEW ) ; com.google.gerrit.server.ChangeUtil.updated ( c ) ; } return c ; }
Source:
protected void preDisplay ( com.google.gerrit.common.data.GroupList result ) { addPanel.setVisible ( result.isCanCreateGroup ( ) ) ; groups.display ( result.getGroups ( ) ) ; groups.finishDisplay ( ) ; }

Target:
protected void preDisplay ( com.google.gerrit.common.data.GroupList result ) { groups.display ( result.getGroups ( ) ) ; groups.finishDisplay ( ) ; }
Source:
public com.google.gerrit.server.IdentifiedUser create ( com.google.inject.Provider < com.google.gerrit.reviewdb.server.ReviewDb > db , com.google.gerrit.reviewdb.client.Account.Id id ) { return new com.google.gerrit.server.IdentifiedUser ( capabilityControlFactory , AccessPath.UNKNOWN , authConfig , anonymousCowardName , canonicalUrl , realm , accountCache , groupBackend , null , db , id ) ; }

Target:
public com.google.gerrit.server.IdentifiedUser create ( com.google.inject.Provider < com.google.gerrit.reviewdb.server.ReviewDb > db , com.google.gerrit.reviewdb.client.Account.Id id ) { return new com.google.gerrit.server.IdentifiedUser ( capabilityControlFactory , authConfig , anonymousCowardName , canonicalUrl , realm , accountCache , groupBackend , null , db , id ) ; }
Source:
protected void configure ( ) { listener ( ) . to ( CachePool.Lifecycle.class ) ; listener ( ) . to ( LocalDiskRepositoryManager.Lifecycle.class ) ; }

Target:
protected void configure ( ) { listener ( ) . to ( LocalDiskRepositoryManager.Lifecycle.class ) ; }
Source:
private java.lang.String getBaseName ( java.lang.String project ) { int i = project.lastIndexOf ( '/' ) ; if ( i < 0 ) { return project ; } else { return project.substring ( ( i + 1 ) ) ; } }

Target:
private static java.lang.String getBaseName ( java.lang.String project ) { return project.substring ( ( ( project.lastIndexOf ( '/' ) ) + 1 ) ) ; }
Source:
public void flushCacheWithGerritPrefix ( ) throws java.lang.Exception { com.google.gerrit.acceptance.RestResponse r = adminSession.post ( "/config/server/caches/gerrit-accounts/flush" ) ; org.junit.Assert.assertEquals ( HttpStatus.SC_OK , r.getStatusCode ( ) ) ; }

Target:
public void flushCacheWithGerritPrefix ( ) throws java.lang.Exception { com.google.gerrit.acceptance.RestResponse r = adminSession.post ( "/config/server/caches/gerrit-accounts/flush" ) ; com.google.common.truth.Truth.assertThat ( r.getStatusCode ( ) ) . isEqualTo ( HttpStatus.SC_OK ) ; }
Source:
public void testIndexPredicate ( ) throws java.lang.Exception { com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > in = parse ( "file:a" ) ; org.junit.Assert.assertEquals ( query ( in ) , rewrite ( in ) ) ; }

Target:
public void testIndexPredicate ( ) throws java.lang.Exception { com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > in = parse ( "file:a" ) ; com.google.common.truth.Truth.assertThat ( rewrite ( in ) ) . isEqualTo ( query ( in ) ) ; }
Source:
public com.google.inject.Module create ( ) throws com.google.gerrit.server.plugins.InvalidPluginException { com.google.common.base.Preconditions.checkState ( ( ( command ) != null ) , "pluginName must be provided" ) ; return this ; }

Target:
public com.google.inject.Module create ( ) throws com.google.gerrit.server.plugins.InvalidPluginException { com.google.common.base.Preconditions.checkState ( ( ( command ) != null ) , "pluginName must be provided" ) ; return ! ( commands.isEmpty ( ) ) ? this : null ; }
Source:
protected PushOneCommit.Result createChange ( org.eclipse.jgit.api.Git git ) throws java.io.IOException , org.eclipse.jgit.api.errors.GitAPIException { com.google.gerrit.acceptance.PushOneCommit push = pushFactory.create ( db , admin.getIdent ( ) ) ; return push.to ( git , "refs/for/master" ) ; }

Target:
protected PushOneCommit.Result createChange ( org.eclipse.jgit.api.Git git ) 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/for/master" ) ; }
Source:
protected com.google.gerrit.server.change.ChangeInserter newChangeWithStatus ( org.eclipse.jgit.junit.TestRepository < com.google.gerrit.testutil.InMemoryRepositoryManager.Repo > repo , com.google.gerrit.reviewdb.client.Change.Status status ) throws java.lang.Exception { return newChange ( repo , null , null , null , status , null ) ; }

Target:
protected com.google.gerrit.server.change.ChangeInserter newChangeWithStatus ( org.eclipse.jgit.junit.TestRepository < com.google.gerrit.testutil.InMemoryRepositoryManager.Repo > repo , com.google.gerrit.reviewdb.client.Change.Status status ) throws java.lang.Exception { return newChange ( repo , null , null , status , null ) ; }
Source:
private com.google.gerrit.common.data.PermissionRule rule ( com.google.gerrit.server.git.ProjectConfig config , com.google.gerrit.reviewdb.AccountGroup group ) { return new com.google.gerrit.common.data.PermissionRule ( config.resolve ( group ) ) ; }

Target:
private com.google.gerrit.common.data.PermissionRule rule ( com.google.gerrit.server.git.ProjectConfig config , com.google.gerrit.reviewdb.client.AccountGroup group ) { return new com.google.gerrit.common.data.PermissionRule ( config.resolve ( group ) ) ; }
Source:
public static com.google.gerrit.plugin.client.rpc.RestApi change ( java.lang.String id ) { return new com.google.gerrit.plugin.client.rpc.RestApi ( "/changes/" ) . id ( id ) ; }

Target:
private static com.google.gerrit.plugin.client.rpc.RestApi change ( java.lang.String id ) { return new com.google.gerrit.plugin.client.rpc.RestApi ( "/changes/" ) . id ( id ) ; }
Source:
private org.eclipse.jgit.lib.Repository openRepository ( final com.google.gerrit.reviewdb.client.Project.NameKey name ) { try { return repoManager.openRepository ( name ) ; } catch ( java.io.IOException err ) { com.google.gerrit.common.ChangeHookRunner.log.warn ( ( "Cannot open repository " + ( name.get ( ) ) ) , err ) ; return null ; } }

Target:
private org.eclipse.jgit.lib.Repository openRepository ( com.google.gerrit.reviewdb.client.Project.NameKey name ) { try { return repoManager.openRepository ( name ) ; } catch ( java.io.IOException err ) { com.google.gerrit.common.ChangeHookRunner.log.warn ( ( "Cannot open repository " + ( name.get ( ) ) ) , err ) ; return null ; } }
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 starChange ( java.lang.String changeId ) throws com.google.gerrit.extensions.restapi.RestApiException { throw new com.google.gerrit.extensions.restapi.NotImplementedException ( ) ; }
Source:
public com.google.gerrit.extensions.api.accounts.Accounts accounts ( ) { return accounts.get ( ) ; }

Target:
public com.google.gerrit.extensions.api.accounts.Accounts accounts ( ) { return accounts ; }
Source:
private static boolean isOff ( java.lang.String listenHostname ) { return ( ( "off" . equalsIgnoreCase ( listenHostname ) ) || ( "none" . equalsIgnoreCase ( listenHostname ) ) ) || ( "no" . equalsIgnoreCase ( listenHostname ) ) ; }

Target:
public static boolean isOff ( java.lang.String listenHostname ) { return ( ( "off" . equalsIgnoreCase ( listenHostname ) ) || ( "none" . equalsIgnoreCase ( listenHostname ) ) ) || ( "no" . equalsIgnoreCase ( listenHostname ) ) ; }
Source:
protected void run ( ) { loader.rescan ( ) ; }

Target:
protected void run ( ) { loader.rescan ( true ) ; }
Source:
public com.google.gerrit.server.project.ListProjects setMatchPrefix ( java.lang.String prefix ) { this . matchPrefix = prefix ; return this ; }

Target:
public void setMatchPrefix ( java.lang.String matchPrefix ) { this . matchPrefix = matchPrefix ; }
Source:
private < S extends java.lang.Comparable < ? > > com.google.common.collect.Ordering < S > createOrdering ( ) { if ( nullsLast ) { return com.google.common.collect.Ordering.natural ( ) . nullsLast ( ) ; } else { return com.google.common.collect.Ordering.natural ( ) . nullsFirst ( ) ; } }

Target:
private < S extends java.lang.Comparable < ? > > com.google.common.collect.Ordering < S > createOrdering ( ) { if ( nullsLast ) { return com.google.common.collect.Ordering.natural ( ) . nullsLast ( ) ; } return com.google.common.collect.Ordering.natural ( ) . nullsFirst ( ) ; }
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 ( "Mute" ) . setTitle ( "Mute the change to unhighlight it in the dashboard" ) . setVisible ( ( ( ! ( rsrc.isUserOwner ( ) ) ) && ( isMuteable ( 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 ( "Mute" ) . setTitle ( "Mute the change to unhighlight it in the dashboard" ) . setVisible ( isMuteable ( rsrc ) ) ; }
Source:
protected < K extends java.io.Serializable , V extends java.io.Serializable > com.google.gerrit.server.cache.UnnamedCacheBinding < K , V > disk ( final com.google.inject.TypeLiteral < com.google.gerrit.server.cache.Cache < K , V > > type ) { return disk ( com.google.inject.Key.get ( type ) ) ; }

Target:
protected < K extends java.io.Serializable , V extends java.io.Serializable > com.google.gerrit.server.cache.UnnamedCacheBinding < K , V > disk ( final com.google.inject.TypeLiteral < com.google.gerrit.server.cache.Cache < K , V > > type ) { return disk ( com.google.inject.Key.get ( type ) , type ) ; }
Source:
protected com.google.gerrit.acceptance.StandaloneSiteTest.ServerContext startServer ( ) throws java.lang.Exception { return new com.google.gerrit.acceptance.StandaloneSiteTest.ServerContext ( startImpl ( ) ) ; }

Target:
protected com.google.gerrit.acceptance.StandaloneSiteTest.ServerContext startServer ( ) throws java.lang.Exception { return startServer ( null ) ; }
Source:
public void onSuccess ( com.google.gerrit.common.data.ChangeDetail result ) { buttonClicked = true ; if ( callback != null ) { callback.onSuccess ( result ) ; } hide ( ) ; }

Target:
public void onSuccess ( com.google.gerrit.common.data.ChangeDetail result ) { buttonClicked = true ; if ( ( callback ) != null ) { callback.onSuccess ( result ) ; } hide ( ) ; }
Source:
protected com.google.gwtjsonrpc.server.SignedToken createXsrfSignedToken ( ) throws com.google.gwtjsonrpc.server.XsrfException { try { return com.google.gerrit.server.GerritServer.getInstance ( ) . getXsrfToken ( ) ; } catch ( com.google.gwtorm.client.OrmException e ) { throw new com.google.gwtjsonrpc.server.XsrfException ( "Cannot configure GerritServer" , e ) ; } }

Target:
protected com.google.gwtjsonrpc.server.SignedToken createXsrfSignedToken ( ) { return server.getXsrfToken ( ) ; }
Source:
public com.google.gerrit.extensions.restapi.BinaryResult submitPreview ( ) throws com.google.gerrit.extensions.restapi.RestApiException { submitPreview.setFormat ( "zip" ) ; return submitPreview.apply ( revision ) ; }

Target:
public com.google.gerrit.extensions.restapi.BinaryResult submitPreview ( java.lang.String format ) throws com.google.gerrit.extensions.restapi.RestApiException { submitPreview.setFormat ( format ) ; return submitPreview.apply ( revision ) ; }
Source:
void onRevert ( @ java.lang.SuppressWarnings ( value = "unused" ) com.google.gwt.event.dom.client.ClickEvent e ) { com.google.gerrit.client.change.RevertAction.call ( revert , changeId , revision , subject ) ; }

Target:
void onRevert ( @ java.lang.SuppressWarnings ( value = "unused" ) com.google.gwt.event.dom.client.ClickEvent e ) { com.google.gerrit.client.change.RevertAction.call ( revert , changeId , project , revision , subject ) ; }
Source:
public org.kohsuke.github.GHMyself getMyself ( ) throws java.io.IOException { if ( isLoggedIn ( ) ) { return getHub ( ) . getMyself ( ) ; } else { return null ; } }

Target:
public org.kohsuke.github.GHMyself getMyself ( ) throws java.io.IOException { if ( isLoggedIn ( ) ) { return getHub ( ) . getMyself ( ) ; } return null ; }
Source:
protected void setUp ( ) throws java.lang.Exception { repo = new org.eclipse.jgit.junit.TestRepository < org.eclipse.jgit.internal.storage.dfs.DfsRepository > ( new org.eclipse.jgit.internal.storage.dfs.InMemoryRepository ( new org.eclipse.jgit.internal.storage.dfs.DfsRepositoryDescription ( "test" ) ) ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { repo = new org.eclipse.jgit.junit.TestRepository < org.eclipse.jgit.internal.storage.dfs.DfsRepository > ( new org.eclipse.jgit.internal.storage.dfs.InMemoryRepository ( new org.eclipse.jgit.internal.storage.dfs.DfsRepositoryDescription ( "test" ) ) ) ; }
Source:
private java.util.Map < java.lang.String , com.google.gerrit.extensions.common.LabelInfo > getChangeLabels ( java.lang.String changeId ) throws java.lang.Exception { return gApi.changes ( ) . id ( changeId ) . get ( java.util.EnumSet.of ( com.google.gerrit.extensions.client.ListChangesOption.DETAILED_LABELS ) ) . labels ; }

Target:
private java.util.Map < java.lang.String , com.google.gerrit.extensions.common.LabelInfo > getChangeLabels ( java.lang.String changeId ) throws java.lang.Exception { return gApi.changes ( ) . id ( changeId ) . get ( com.google.gerrit.extensions.client.ListChangesOption.DETAILED_LABELS ) . labels ; }