auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
void sendError ( int status , java.lang.String message ) throws java.io.IOException { com.googlesource.gerrit.plugins.lfs.locks.LfsLocksContext.log.error ( message ) ; res.setStatus ( status ) ; gson.toJson ( new com.googlesource.gerrit.plugins.lfs.locks.LfsLocksContext.Error ( message ) , getWriter ( ) ) ; getWriter ( ) . flush ( ) ; }

Target:
void sendError ( int status , com.googlesource.gerrit.plugins.lfs.locks.LfsLocksContext.Error error ) throws java.io.IOException { com.googlesource.gerrit.plugins.lfs.locks.LfsLocksContext.log.error ( error.message ) ; res.setStatus ( status ) ; gson.toJson ( error , getWriter ( ) ) ; getWriter ( ) . flush ( ) ; }
Source:
final native void setToken ( java.lang.String t ) ;

Target:
final native void setToken ( java.lang.String token ) ;
Source:
private org.eclipse.jgit.lib.ObjectId createCommit ( com.google.gerrit.server.IdentifiedUser me , org.eclipse.jgit.lib.ObjectInserter inserter , org.eclipse.jgit.revwalk.RevCommit prevEdit , org.eclipse.jgit.revwalk.RevCommit base , org.eclipse.jgit.lib.ObjectId tree ) throws java.io.IOException { return createCommit ( me , inserter , prevEdit , base , tree , prevEdit.getFullMessage ( ) ) ; }

Target:
private org.eclipse.jgit.lib.ObjectId createCommit ( com.google.gerrit.server.IdentifiedUser me , org.eclipse.jgit.lib.ObjectInserter inserter , org.eclipse.jgit.revwalk.RevCommit revision , org.eclipse.jgit.lib.ObjectId tree ) throws java.io.IOException { return createCommit ( me , inserter , revision , tree , revision.getFullMessage ( ) ) ; }
Source:
public boolean match ( com.google.gerrit.server.query.change.ChangeData object ) throws com.google.gwtorm.server.OrmException { return com.google.gerrit.server.index.change.ChangeField.getAuthorParts ( object ) . contains ( getValue ( ) . toLowerCase ( ) ) ; }

Target:
public boolean match ( com.google.gerrit.server.query.change.ChangeData object ) throws com.google.gwtorm.server.OrmException { try { return com.google.gerrit.server.index.change.ChangeField.getAuthorParts ( object ) . contains ( getValue ( ) . toLowerCase ( ) ) ; } catch ( java.io.IOException e ) { throw new com.google.gwtorm.server.OrmException ( e ) ; } }
Source:
public void multipleHashtags ( ) throws java.lang.Exception { java.lang.String commitMessage = "#Subject\n\n#Hashtag\n\nLine 2" ; 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" , "Hashtag" ) ) ; }

Target:
public void multipleHashtags ( ) throws java.lang.Exception { java.lang.String commitMessage = "#Subject\n\n#Hashtag\n\nLine 2" ; com.google.common.truth.Truth.assertThat ( com.google.gerrit.server.change.HashtagsUtil.extractTags ( commitMessage ) ) . containsExactlyElementsIn ( com.google.common.collect.Sets.newHashSet ( "Subject" , "Hashtag" ) ) ; }
Source:
public void execute ( ) { com.google.gerrit.client.Gerrit.doSignIn ( null ) ; }

Target:
public void execute ( ) { com.google.gerrit.client.Gerrit.doSignIn ( ) ; }
Source:
void onChangeIndexed ( com.google.gerrit.server.query.change.ChangeData change ) ;

Target:
void onChangeIndexed ( int id ) ;
Source:
java.nio.file.Path getSharedDirectory ( ) throws java.io.IOException { java.nio.file.Path sharedDirectoryPath = java.nio.file.Paths.get ( config.main ( ) . sharedDirectory ( ) ) ; java.nio.file.Files.createDirectories ( sharedDirectoryPath ) ; return sharedDirectoryPath ; }

Target:
java.nio.file.Path getSharedDirectory ( ) throws java.io.IOException { java.nio.file.Path sharedDirectoryPath = config.main ( ) . sharedDirectory ( ) ; java.nio.file.Files.createDirectories ( sharedDirectoryPath ) ; return sharedDirectoryPath ; }
Source:
public com.google.gerrit.server.notedb.ChangeNotes notes ( ) { return getControl ( ) . getNotes ( ) ; }

Target:
public com.google.gerrit.server.notedb.ChangeNotes notes ( ) { return notes ; }
Source:
public com.google.gerrit.extensions.restapi.Response < java.lang.String > apply ( com.google.gerrit.server.account.AccountResource rsrc , com.google.gerrit.server.account.PutActive.Input input ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException , com.google.gwtorm.server.OrmException , java.io.IOException , org.eclipse.jgit.errors.ConfigInvalidException { return setInactiveFlag.activate ( rsrc.getUser ( ) ) ; }

Target:
public com.google.gerrit.extensions.restapi.Response < java.lang.String > apply ( com.google.gerrit.server.account.AccountResource rsrc , com.google.gerrit.server.account.PutActive.Input input ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException , com.google.gwtorm.server.OrmException , java.io.IOException , org.eclipse.jgit.errors.ConfigInvalidException { return setInactiveFlag.activate ( rsrc.getUser ( ) . getAccountId ( ) ) ; }
Source:
public void onResize ( com.google.gwt.event.logical.shared.ResizeEvent event ) { resizeCodeMirror ( ) ; resizeBoxPaddings ( ) ; }

Target:
public void onResize ( com.google.gwt.event.logical.shared.ResizeEvent event ) { resizeCodeMirror ( ) ; }
Source:
protected void preDisplay ( final com.google.gerrit.client.data.ChangeDetail r ) { if ( ( starChange ) != null ) { setStarred ( r.isStarred ( ) ) ; } display ( r ) ; }

Target:
protected void preDisplay ( final com.google.gerrit.client.data.ChangeDetail r ) { display ( r ) ; }
Source:
private static void noCache ( javax.servlet.http.HttpServletResponse res ) { res.setHeader ( "Expires" , "Fri, 01 Jan 1980 00:00:00 GMT" ) ; res.setHeader ( "Pragma" , "no-cache" ) ; res.setHeader ( "Cache-Control" , "no-cache, must-revalidate" ) ; res.setHeader ( "Content-Disposition" , "attachment" ) ; }

Target:
static void noCache ( javax.servlet.http.HttpServletResponse res ) { res.setHeader ( "Expires" , "Fri, 01 Jan 1980 00:00:00 GMT" ) ; res.setHeader ( "Pragma" , "no-cache" ) ; res.setHeader ( "Cache-Control" , "no-cache, must-revalidate" ) ; res.setHeader ( "Content-Disposition" , "attachment" ) ; }
Source:
static com.google.gerrit.client.changes.ChangeApi.Input create ( ) { return ( ( com.google.gerrit.client.changes.ChangeApi.Input ) ( com.google.gwt.core.client.JavaScriptObject.createObject ( ) ) ) ; }

Target:
static com.google.gerrit.client.changes.ChangeApi.Input create ( ) { return ( ( com.google.gerrit.client.changes.ChangeApi.Input ) ( createObject ( ) ) ) ; }
Source:
public void start ( ) { graphiteReporter.start ( rate , com.googlesource.gerrit.plugins.metricsreporters.GerritGraphiteReporter.DEFAULT_RATE_UNIT ) ; }

Target:
public void start ( ) { if ( ( graphiteReporter ) != null ) { graphiteReporter.start ( rate , com.googlesource.gerrit.plugins.metricsreporters.GerritGraphiteReporter.DEFAULT_RATE_UNIT ) ; } }
Source:
public static com.criteo.gerrit.plugins.automerge.Change from ( com.google.gerrit.extensions.common.ChangeInfo changeInfo ) { return new com.criteo.gerrit.plugins.automerge.Change ( changeInfo.project , changeInfo._number , changeInfo.topic ) ; }

Target:
public static com.criteo.gerrit.plugins.automerge.Change from ( com.google.gerrit.extensions.common.ChangeInfo changeInfo ) { return new com.criteo.gerrit.plugins.automerge.Change ( changeInfo.project , changeInfo._number , changeInfo.id , changeInfo.topic , changeInfo.branch ) ; }
Source:
public < A extends com.google.gwtorm.client.Access < ? , ? > > java.lang.Class < A > create ( com.google.gwtorm.server.GeneratedClassLoader loader , com.google.gwtorm.schema.RelationModel rm ) throws com.google.gwtorm.client.OrmException { return new com.google.gwtorm.jdbc.AccessGen ( loader , rm , dialect ) . create ( ) ; }

Target:
public java.lang.Class < ? > create ( com.google.gwtorm.server.GeneratedClassLoader loader , com.google.gwtorm.schema.RelationModel rm ) throws com.google.gwtorm.client.OrmException { return new com.google.gwtorm.jdbc.AccessGen ( loader , rm , dialect ) . create ( ) ; }
Source:
public static com.google.gerrit.client.rpc.RestApi edit ( int id ) { return com.google.gerrit.client.changes.ChangeApi.change ( id ) . view ( "edit" ) ; }

Target:
public static com.google.gerrit.client.rpc.RestApi edit ( @ com.google.gerrit.common.Nullable java.lang.String project , int id ) { return com.google.gerrit.client.changes.ChangeApi.change ( project , id ) . view ( "edit" ) ; }
Source:
final native void setTopic ( java.lang.String t ) ;

Target:
final native void topic ( java.lang.String t ) ;
Source:
public static boolean useRecursiveMerge ( org.eclipse.jgit.lib.Config cfg ) { return cfg.getBoolean ( "core" , null , "useRecursiveMerge" , false ) ; }

Target:
public static boolean useRecursiveMerge ( org.eclipse.jgit.lib.Config cfg ) { return cfg.getBoolean ( "core" , null , "useRecursiveMerge" , true ) ; }
Source:
com.google.gerrit.extensions.client.ChangeKind getChangeKind ( com.google.gerrit.reviewdb.client.Project.NameKey project , @ com.google.gerrit.common.Nullable org.eclipse.jgit.lib.Repository repo , org.eclipse.jgit.lib.ObjectId prior , org.eclipse.jgit.lib.ObjectId next ) ;

Target:
com.google.gerrit.extensions.client.ChangeKind getChangeKind ( com.google.gerrit.reviewdb.client.Project.NameKey project , @ com.google.gerrit.common.Nullable org.eclipse.jgit.lib.Repository repo , @ com.google.gerrit.common.Nullable org.eclipse.jgit.revwalk.RevWalk rw , org.eclipse.jgit.lib.ObjectId prior , org.eclipse.jgit.lib.ObjectId next ) ;
Source:
public boolean isVisibleTo ( com.google.gerrit.reviewdb.client.Account.Id account ) throws com.google.gwtorm.server.OrmException { com.google.gerrit.server.IdentifiedUser who = identifiedUserFactory.create ( dbProvider , account ) ; return rsrc.getControl ( ) . forUser ( who ) . isRefVisible ( ) ; }

Target:
public boolean isVisibleTo ( com.google.gerrit.reviewdb.client.Account.Id account ) throws com.google.gwtorm.server.OrmException { com.google.gerrit.server.IdentifiedUser who = identifiedUserFactory.create ( account ) ; return rsrc.getControl ( ) . forUser ( who ) . isRefVisible ( ) ; }
Source:
private static org.eclipse.jgit.revwalk.RevCommit lookupCommit ( org.eclipse.jgit.lib.Repository repository , com.google.gerrit.reviewdb.client.PatchSet patchSet ) throws java.io.IOException { org.eclipse.jgit.lib.ObjectId patchSetCommitId = com.google.gerrit.server.edit.ChangeEditModifier.getPatchSetCommitId ( patchSet ) ; try ( org.eclipse.jgit.revwalk.RevWalk revWalk = new org.eclipse.jgit.revwalk.RevWalk ( repository ) ) { return revWalk.parseCommit ( patchSetCommitId ) ; } }

Target:
private static org.eclipse.jgit.revwalk.RevCommit lookupCommit ( org.eclipse.jgit.lib.Repository repository , com.google.gerrit.reviewdb.client.PatchSet patchSet ) throws java.io.IOException { org.eclipse.jgit.lib.ObjectId patchSetCommitId = com.google.gerrit.server.edit.ChangeEditModifier.getPatchSetCommitId ( patchSet ) ; return com.google.gerrit.server.edit.ChangeEditModifier.lookupCommit ( repository , patchSetCommitId ) ; }
Source:
java.lang.String emailOnlyAuthors ( ) ;

Target:
java.lang.String projects ( ) ;
Source:
public com.google.gerrit.server.patch.DiffSummary call ( ) throws java.lang.Exception { com.google.gerrit.server.patch.PatchList patchList = patchListCache.get ( key.toPatchListKey ( ) , project ) ; return com.google.gerrit.server.patch.DiffSummaryLoader.toDiffSummary ( patchList ) ; }

Target:
public com.google.gerrit.server.patch.DiffSummary call ( ) throws java.lang.Exception { com.google.gerrit.server.patch.PatchList patchList = patchListCache.get ( key.toPatchListKey ( ) , project ) ; return toDiffSummary ( patchList ) ; }
Source:
public void onChangeDeleted ( com.google.gerrit.reviewdb.client.Change.Id id ) { executeIndexTask ( id , true ) ; }

Target:
public void onChangeDeleted ( int id ) { executeIndexTask ( id , true ) ; }
Source:
void setReviewed ( boolean r ) { reviewed.setValue ( r , true ) ; }

Target:
public void run ( ) { reviewed.setValue ( ( ! ( reviewed.getValue ( ) ) ) , true ) ; }
Source:
public AccountGroup.UUID getGroupUUID ( ) { return control.getGroup ( ) . getGroupUUID ( ) ; }

Target:
public AccountGroup.UUID getGroupUUID ( ) { return getGroup ( ) . getGroupUUID ( ) ; }
Source:
public void setVisible ( final boolean show ) { com.google.gwtexpui.user.client.UserAgent.fireDialogVisible ( show ) ; super . setVisible ( show ) ; }

Target:
public void setVisible ( final boolean show ) { com.google.gwtexpui.user.client.UserAgent.fireDialogVisible ( this , show ) ; super . setVisible ( show ) ; }
Source:
public static com.google.gerrit.client.rpc.RestApi hashtag ( int changeId , java.lang.String hashtag ) { return com.google.gerrit.client.changes.ChangeApi.change ( changeId ) . view ( "hashtags" ) . id ( hashtag ) ; }

Target:
public static com.google.gerrit.client.rpc.RestApi hashtag ( @ com.google.gerrit.common.Nullable java.lang.String project , int changeId , java.lang.String hashtag ) { return com.google.gerrit.client.changes.ChangeApi.change ( project , changeId ) . view ( "hashtags" ) . id ( hashtag ) ; }
Source:
public void go ( ) { com.google.gerrit.client.Gerrit.display ( getTargetHistoryToken ( ) , createScreen ( ) ) ; }

Target:
public void go ( ) { com.google.gerrit.client.Gerrit.display ( getTargetHistoryToken ( ) ) ; }
Source:
private static java.lang.String replace ( java.lang.String project , java.lang.String query ) { return query.replace ( "${project}" , project ) ; }

Target:
private static java.lang.String replace ( java.lang.String project , java.lang.String input ) { return input.replace ( "${project}" , project ) ; }
Source:
protected java.lang.String prettify ( java.lang.String html ) { return com.google.gerrit.prettify.client.ClientSideFormatter.go ( html , settings.getFilename ( ) , settings.getTabSize ( ) ) ; }

Target:
protected java.lang.String prettify ( java.lang.String html , java.lang.String type ) { return com.google.gerrit.prettify.client.ClientSideFormatter.go ( html , type , settings.getTabSize ( ) ) ; }
Source:
public org.eclipse.jgit.lib.Config getProjectPluginConfigWithInheritance ( com.google.gerrit.reviewdb.client.Project.NameKey projectName , java.lang.String pluginName ) throws com.google.gerrit.server.project.NoSuchProjectException { return getPluginConfig ( projectName , pluginName ) . getWithInheritance ( ) ; }

Target:
public org.eclipse.jgit.lib.Config getProjectPluginConfigWithInheritance ( com.google.gerrit.reviewdb.client.Project.NameKey projectName , java.lang.String pluginName ) throws com.google.gerrit.server.project.NoSuchProjectException { return getPluginConfig ( projectName , pluginName ) . getWithInheritance ( false ) ; }
Source:
public boolean writeChanges ( ) { return writeChanges ; }

Target:
protected boolean writeChanges ( ) { return writeChanges ; }
Source:
public java.lang.Boolean apply ( com.googlesource.gerrit.plugins.lfs.locks.LfsLock input ) { return input.owner.name.equals ( user.getUserName ( ) ) ; }

Target:
public java.lang.Boolean apply ( com.googlesource.gerrit.plugins.lfs.locks.LfsLock input ) { return input.owner.name.equals ( user.getUserName ( ) . get ( ) ) ; }
Source:
public java.lang.String apply ( com.google.gerrit.extensions.common.ChangeInfo input ) { return ( input.changeId ) != null ? input.changeId : input.subject ; }

Target:
public java.lang.String apply ( com.google.gerrit.extensions.common.ChangeInfo input ) { return input.changeId ; }
Source:
public void setUp ( ) throws java.lang.Exception { org.eclipse.jgit.internal.storage.dfs.DfsRepository r = new org.eclipse.jgit.internal.storage.dfs.InMemoryRepository ( new org.eclipse.jgit.internal.storage.dfs.DfsRepositoryDescription ( "test" ) ) ; repo = new org.eclipse.jgit.junit.TestRepository < org.eclipse.jgit.internal.storage.dfs.DfsRepository > ( r ) ; servlet = com.google.gitiles.TestGitilesServlet.create ( repo ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { org.eclipse.jgit.internal.storage.dfs.DfsRepository r = new org.eclipse.jgit.internal.storage.dfs.InMemoryRepository ( new org.eclipse.jgit.internal.storage.dfs.DfsRepositoryDescription ( "test" ) ) ; repo = new org.eclipse.jgit.junit.TestRepository ( r ) ; servlet = com.google.gitiles.TestGitilesServlet.create ( repo ) ; }
Source:
public com.google.gerrit.server.CurrentUser getUser ( ) { if ( ( submitter ) != null ) { return identifiedUserFactory.create ( getReviewDbProvider ( ) , submitter ) . getRealUser ( ) ; } throw new com.google.inject.OutOfScopeException ( "No user on email thread" ) ; }

Target:
public com.google.gerrit.server.CurrentUser getUser ( ) { if ( ( submitter ) != null ) { return identifiedUserFactory.create ( submitter ) . getRealUser ( ) ; } throw new com.google.inject.OutOfScopeException ( "No user on email thread" ) ; }
Source:
private static java.lang.String id ( final java.lang.Integer id ) { return id != null ? com.google.gerrit.server.util.IdGenerator.format ( id ) : "" ; }

Target:
private static java.lang.String id ( final int id ) { return com.google.gerrit.server.util.IdGenerator.format ( id ) ; }
Source:
public void onClick ( final com.google.gwt.event.dom.client.ClickEvent event ) { doSave ( null ) ; }

Target:
public void onClick ( final com.google.gwt.event.dom.client.ClickEvent event ) { doSave ( ) ; }
Source:
com.google.gitiles.doc.Navbar setMarkdown ( com.google.gitiles.doc.MarkdownConfig cfg , byte [ ] md ) { if ( ( md != null ) && ( ( md.length ) > 0 ) ) { parse ( cfg , org.eclipse.jgit.util.RawParseUtils.decode ( md ) ) ; } return this ; }

Target:
com.google.gitiles.doc.Navbar setMarkdown ( byte [ ] md ) { if ( ( md != null ) && ( ( md.length ) > 0 ) ) { parse ( org.eclipse.jgit.util.RawParseUtils.decode ( md ) ) ; } return this ; }
Source:
private com.google.gerrit.server.query.change.InternalChangeQuery query ( ) { java.util.Set < java.lang.String > fields = com.google.common.collect.ImmutableSet.of ( ChangeField.CHANGE.getName ( ) , ChangeField.PATCH_SET.getName ( ) , ChangeField.REVIEWER.getName ( ) ) ; return queryProvider.get ( ) . setRequestedFields ( fields ) ; }

Target:
private com.google.gerrit.server.query.change.InternalChangeQuery query ( ) { java.util.Set < java.lang.String > fields = com.google.common.collect.ImmutableSet.of ( ChangeField.CHANGE.getName ( ) , ChangeField.PATCH_SET.getName ( ) ) ; return queryProvider.get ( ) . setRequestedFields ( fields ) ; }
Source:
public void setChangeId ( java.lang.String changeId ) { java.lang.String old = ctl.getChange ( ) . getKey ( ) . get ( ) ; com.google.common.base.Preconditions.checkArgument ( old.equals ( changeId ) , "The Change-Id was already set to %s, so we cannot set this Change-Id: %s" , old , changeId ) ; this . changeId = changeId ; }

Target:
public void setChangeId ( java.lang.String changeId ) { java.lang.String old = getChange ( ) . getKey ( ) . get ( ) ; com.google.common.base.Preconditions.checkArgument ( old.equals ( changeId ) , "The Change-Id was already set to %s, so we cannot set this Change-Id: %s" , old , changeId ) ; this . changeId = changeId ; }
Source:
private void initCodeRepo ( ) throws java.io.IOException { if ( ( codeRepo ) == null ) { codeRepo = openRepo ( projectName , false ) ; } }

Target:
private void initCodeRepo ( ) throws java.io.IOException { if ( ( codeRepo ) == null ) { codeRepo = openRepo ( projectName ) ; } }
Source:
public com.google.gerrit.server.project.TagResource parse ( com.google.gerrit.server.project.ProjectResource resource , com.google.gerrit.extensions.restapi.IdString id ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException , java.io.IOException { return new com.google.gerrit.server.project.TagResource ( resource.getControl ( ) , list.get ( resource , id ) ) ; }

Target:
public com.google.gerrit.server.project.TagResource parse ( com.google.gerrit.server.project.ProjectResource resource , com.google.gerrit.extensions.restapi.IdString id ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException , java.io.IOException { return new com.google.gerrit.server.project.TagResource ( resource.getControl ( ) , list.get ( ) . get ( resource , id ) ) ; }
Source:
protected abstract com.google.gerrit.server.notedb.AbstractChangeUpdate.Status applyImpl ( org.eclipse.jgit.lib.CommitBuilder cb , org.eclipse.jgit.lib.ObjectInserter ins ) throws com.google.gwtorm.server.OrmException , java.io.IOException ;

Target:
protected abstract org.eclipse.jgit.lib.CommitBuilder applyImpl ( org.eclipse.jgit.lib.ObjectInserter ins ) throws com.google.gwtorm.server.OrmException , java.io.IOException ;
Source:
public com.google.gerrit.common.data.PermissionRange getRange ( java.lang.String permission ) { if ( com.google.gerrit.common.data.Permission.hasRange ( permission ) ) { return toRange ( permission , access ( permission ) ) ; } return null ; }

Target:
public com.google.gerrit.common.data.PermissionRange getRange ( java.lang.String permission ) { return getRange ( permission , false ) ; }
Source:
public static void ensureAllPatchSetsLoaded ( com.google.inject.Provider < com.google.gerrit.reviewdb.server.ReviewDb > db , java.lang.Iterable < com.google.gerrit.server.query.change.ChangeData > changes ) throws com.google.gwtorm.server.OrmException { for ( com.google.gerrit.server.query.change.ChangeData cd : changes ) { cd.patches ( ) ; } }

Target:
public static void ensureAllPatchSetsLoaded ( java.lang.Iterable < com.google.gerrit.server.query.change.ChangeData > changes ) throws com.google.gwtorm.server.OrmException { for ( com.google.gerrit.server.query.change.ChangeData cd : changes ) { cd.patches ( ) ; } }
Source:
public void setEditPreferences ( com.google.gerrit.extensions.client.EditPreferencesInfo in ) throws com.google.gerrit.extensions.restapi.RestApiException { try { setEditPreferences.apply ( account , in ) ; } catch ( java.io.IOException | org.eclipse.jgit.errors.ConfigInvalidException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot set edit preferences" , e ) ; } }

Target:
public com.google.gerrit.extensions.client.EditPreferencesInfo setEditPreferences ( com.google.gerrit.extensions.client.EditPreferencesInfo in ) throws com.google.gerrit.extensions.restapi.RestApiException { try { return setEditPreferences.apply ( account , in ) ; } catch ( java.io.IOException | org.eclipse.jgit.errors.ConfigInvalidException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot set edit preferences" , e ) ; } }
Source:
private java.lang.String getPassword ( ) { final java.lang.String pass = gerritConfig.getString ( pluginName , null , com.googlesource.gerrit.plugins.hooks.jira.JiraItsFacade.GERRIT_CONFIG_PASSWORD ) ; return pass ; }

Target:
private java.lang.String getPassword ( ) { return gerritConfig.getString ( pluginName , null , com.googlesource.gerrit.plugins.hooks.jira.JiraItsFacade.GERRIT_CONFIG_PASSWORD ) ; }
Source:
public static java.lang.String toEditScreen ( com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName ) { return com.google.gerrit.client.Dispatcher.toEditScreen ( revision , fileName , 0 ) ; }

Target:
public static java.lang.String toEditScreen ( @ com.google.gerrit.common.Nullable com.google.gerrit.reviewdb.client.Project.NameKey project , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName ) { return com.google.gerrit.client.Dispatcher.toEditScreen ( project , revision , fileName , 0 ) ; }
Source:
private boolean checkConnection ( ) { com.ericsson.gerrit.plugins.eventslog.sql.SQLStore.log.info ( "Checking database connection..." ) ; try { eventsDb.queryOne ( ) ; return true ; } catch ( java.sql.SQLException e ) { com.ericsson.gerrit.plugins.eventslog.sql.SQLStore.log.debug ( "Problem checking database connection" , e ) ; return false ; } }

Target:
private boolean checkConnection ( ) { com.ericsson.gerrit.plugins.eventslog.sql.SQLStore.log.debug ( "Checking database connection..." ) ; try { eventsDb.queryOne ( ) ; return true ; } catch ( java.sql.SQLException e ) { com.ericsson.gerrit.plugins.eventslog.sql.SQLStore.log.error ( "Problem checking database connection" , e ) ; return false ; } }
Source:
public void onKeyPress ( com.google.gwt.event.dom.client.KeyPressEvent event ) { header.toggleReviewed ( ) . run ( ) ; }

Target:
public void onKeyPress ( com.google.gwt.event.dom.client.KeyPressEvent event ) { toggleReviewed ( ) . run ( ) ; }
Source:
public com.google.gerrit.server.config.ConfigResource parse ( com.google.gerrit.extensions.restapi.TopLevelResource root , com.google.gerrit.extensions.restapi.IdString id ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException { if ( id.equals ( "server" ) ) { return new com.google.gerrit.server.config.ConfigResource ( ) ; } throw new com.google.gerrit.extensions.restapi.ResourceNotFoundException ( id ) ; }

Target:
public com.google.gerrit.server.config.ConfigResource parse ( com.google.gerrit.extensions.restapi.TopLevelResource root , com.google.gerrit.extensions.restapi.IdString id ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException { if ( id.get ( ) . equals ( "server" ) ) { return new com.google.gerrit.server.config.ConfigResource ( ) ; } throw new com.google.gerrit.extensions.restapi.ResourceNotFoundException ( id ) ; }
Source:
public com.google.gerrit.server.change.PatchSetInserter setSshInfo ( com.google.gerrit.server.ssh.SshInfo sshInfo ) { if ( sshInfo == null ) { sshInfo = new com.google.gerrit.server.ssh.NoSshInfo ( ) ; } this . sshInfo = sshInfo ; return this ; }

Target:
public com.google.gerrit.server.change.PatchSetInserter setSshInfo ( com.google.gerrit.server.ssh.SshInfo sshInfo ) { this . sshInfo = sshInfo ; return this ; }
Source:
public static void init ( ) { com.google.gerrit.client.api.ApiGlue.init0 ( ) ; com.google.gerrit.client.api.ActionContext.init ( ) ; com.google.gerrit.client.api.HtmlTemplate.init ( ) ; com.google.gerrit.client.api.Plugin.init ( ) ; com.google.gerrit.client.api.ApiGlue.addHistoryHook ( ) ; }

Target:
public static void init ( ) { com.google.gerrit.client.api.ApiGlue.init0 ( ) ; com.google.gerrit.client.api.ActionContext.init ( ) ; com.google.gerrit.client.api.HtmlTemplate.init ( ) ; com.google.gerrit.client.api.Plugin.init ( ) ; }
Source:
private com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig getConfig ( java.lang.String defaultConfig ) throws org.eclipse.jgit.errors.ConfigInvalidException { com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig config = new com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig ( new com.googlesource.gerrit.plugins.uploadvalidator.FakeConfigFactory ( projectName , defaultConfig ) , new com.googlesource.gerrit.plugins.uploadvalidator.FakeUserProvider ( ) , new com.googlesource.gerrit.plugins.uploadvalidator.FakeGroupCacheUUIDByName ( ) ) ; return config ; }

Target:
private com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig getConfig ( java.lang.String defaultConfig ) throws org.eclipse.jgit.errors.ConfigInvalidException { com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig config = new com.googlesource.gerrit.plugins.uploadvalidator.ValidatorConfig ( new com.googlesource.gerrit.plugins.uploadvalidator.FakeConfigFactory ( projectName , defaultConfig ) , new com.googlesource.gerrit.plugins.uploadvalidator.FakeGroupCacheUUIDByName ( ) ) ; return config ; }
Source:
public void configure ( ) { factory ( ReviewDbBatchUpdate.AssistedFactory.class ) ; factory ( NoteDbBatchUpdate.AssistedFactory.class ) ; }

Target:
public void configure ( ) { factory ( ReviewDbBatchUpdate.AssistedFactory.class ) ; }
Source:
private void openLine ( final com.google.gwtexpui.safehtml.client.SafeHtmlBuilder m ) { m.openTr ( ) ; m.setAttribute ( "valign" , "top" ) ; m.openTd ( ) ; m.setStyleName ( com.google.gerrit.client.patches.S_ICON_CELL ) ; m.nbsp ( ) ; m.closeTd ( ) ; }

Target:
private void openLine ( final com.google.gwtexpui.safehtml.client.SafeHtmlBuilder m ) { m.openTr ( ) ; m.setAttribute ( "valign" , "top" ) ; m.openTd ( ) ; m.setStyleName ( com.google.gerrit.client.patches.S_ICON_CELL ) ; m.closeTd ( ) ; }
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" ) ) ) ; walk = new org.eclipse.jgit.revwalk.RevWalk ( repo.getRepository ( ) ) ; }

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" ) ) ) ; walk = new org.eclipse.jgit.revwalk.RevWalk ( repo.getRepository ( ) ) ; }
Source:
protected abstract void onLoad ( com.google.gerrit.server.notedb.AbstractChangeNotes.LoadHandle handle ) throws java.io.IOException , org.eclipse.jgit.errors.ConfigInvalidException ;

Target:
protected abstract void onLoad ( org.eclipse.jgit.revwalk.RevWalk walk ) throws java.io.IOException , org.eclipse.jgit.errors.ConfigInvalidException ;
Source:
public java.lang.String getProjectDescription ( final com.google.gerrit.reviewdb.client.Project.NameKey name ) throws java.io.IOException , org.eclipse.jgit.errors.RepositoryNotFoundException { final org.eclipse.jgit.lib.Repository e = openRepository ( name ) ; try { return getProjectDescription ( e ) ; } finally { e.close ( ) ; } }

Target:
public java.lang.String getProjectDescription ( final com.google.gerrit.reviewdb.client.Project.NameKey name ) throws java.io.IOException , org.eclipse.jgit.errors.RepositoryNotFoundException { try ( org.eclipse.jgit.lib.Repository e = openRepository ( name ) ) { return getProjectDescription ( e ) ; } }
Source:
protected void configure ( ) { bind ( com.google.gerrit.httpd.GerritOptions.class ) . toInstance ( new com.google.gerrit.httpd.GerritOptions ( false , false ) ) ; }

Target:
protected void configure ( ) { bind ( com.google.gerrit.httpd.GerritOptions.class ) . toInstance ( new com.google.gerrit.httpd.GerritOptions ( config , false , false ) ) ; }
Source:
public static com.google.gerrit.index.query.Predicate < com.google.gerrit.server.group.InternalGroup > name ( java.lang.String name ) { return new com.google.gerrit.server.query.group.GroupPredicates.GroupPredicate ( com.google.gerrit.server.index.group.GroupField.NAME , GroupQueryBuilder.FIELD_NAME , name.toLowerCase ( java.util.Locale.US ) ) ; }

Target:
public static com.google.gerrit.index.query.Predicate < com.google.gerrit.reviewdb.client.AccountGroup > name ( java.lang.String name ) { return new com.google.gerrit.server.query.group.GroupPredicates.GroupPredicate ( com.google.gerrit.server.index.group.GroupField.NAME , GroupQueryBuilder.FIELD_NAME , name ) ; }
Source:
public com.google.gerrit.extensions.restapi.Response < ? > apply ( com.google.gerrit.server.change.ChangeResource rsrc , com.google.gerrit.server.change.ChangeEdits.DeleteFile.Input in ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gerrit.extensions.restapi.ResourceConflictException , com.google.gerrit.server.permissions.PermissionBackendException , com.google.gwtorm.server.OrmException , java.io.IOException { return deleteContent.apply ( rsrc.getControl ( ) , path ) ; }

Target:
public com.google.gerrit.extensions.restapi.Response < ? > apply ( com.google.gerrit.server.change.ChangeResource rsrc , com.google.gerrit.server.change.ChangeEdits.DeleteFile.Input in ) throws com.google.gerrit.extensions.restapi.AuthException , com.google.gerrit.extensions.restapi.ResourceConflictException , com.google.gerrit.server.permissions.PermissionBackendException , com.google.gwtorm.server.OrmException , java.io.IOException { return deleteContent.apply ( rsrc , path ) ; }
Source:
public static void editWithFiles ( int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.info.ChangeInfo.EditInfo > cb ) { com.google.gerrit.client.changes.ChangeApi.edit ( id ) . addParameterTrue ( "list" ) . get ( cb ) ; }

Target:
public static void editWithFiles ( @ com.google.gerrit.common.Nullable java.lang.String project , int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.info.ChangeInfo.EditInfo > cb ) { com.google.gerrit.client.changes.ChangeApi.edit ( project , id ) . addParameterTrue ( "list" ) . get ( cb ) ; }
Source:
public com.google.gerrit.server.permissions.PermissionBackend.ForChange change ( com.google.gerrit.server.notedb.ChangeNotes cd ) { return new com.google.gerrit.server.permissions.FailedPermissionBackend.FailedChange ( message , cause ) ; }

Target:
public com.google.gerrit.server.permissions.PermissionBackend.ForChange change ( com.google.gerrit.server.notedb.ChangeNotes notes ) { return new com.google.gerrit.server.permissions.FailedPermissionBackend.FailedChange ( message , cause ) ; }
Source:
public void onLoad ( ) { super . onLoad ( ) ; Util.LIST_SVC.myDraftChanges ( loadCallback ( ) ) ; }

Target:
protected void onLoad ( ) { super . onLoad ( ) ; Util.LIST_SVC.myDraftChanges ( loadCallback ( ) ) ; }
Source:
public com.google.gerrit.extensions.common.CommentInfo apply ( com.google.gerrit.server.change.CommentResource rsrc ) throws com.google.gwtorm.server.OrmException { return commentJson.format ( rsrc.getComment ( ) ) ; }

Target:
public com.google.gerrit.extensions.common.CommentInfo apply ( com.google.gerrit.server.change.CommentResource rsrc ) throws com.google.gwtorm.server.OrmException { return commentJson.get ( ) . format ( rsrc.getComment ( ) ) ; }
Source:
public void setUp ( ) throws java.lang.Exception { project2 = new com.google.gerrit.reviewdb.client.Project.NameKey ( "p2" ) ; com.google.gerrit.acceptance.GitUtil.createProject ( sshSession , project2.get ( ) ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { project2 = new com.google.gerrit.reviewdb.client.Project.NameKey ( "p2" ) ; createProject ( project2.get ( ) ) ; }
Source:
public void setUserAccountId ( com.google.gerrit.reviewdb.client.Account.Id id ) { key = new com.google.gerrit.httpd.WebSessionManager.Key ( ( "id:" + id ) ) ; val = new com.google.gerrit.httpd.WebSessionManager.Val ( id , 0 , false , null , 0 , null ) ; }

Target:
public void setUserAccountId ( com.google.gerrit.reviewdb.client.Account.Id id ) { key = new com.google.gerrit.httpd.WebSessionManager.Key ( ( "id:" + id ) ) ; val = new com.google.gerrit.httpd.WebSessionManager.Val ( id , 0 , false , null , 0 , null , null ) ; user = null ; }
Source:
public java.lang.String getNextSequenceValueSql ( final java.lang.String seqname ) { return ( "SELECT nextval('" + seqname ) + "')" ; }

Target:
protected java.lang.String getNextSequenceValueSql ( final java.lang.String seqname ) { return ( "SELECT nextval('" + seqname ) + "')" ; }
Source:
private static void doCreateTable ( java.sql.Statement stmt ) throws java.sql.SQLException { stmt.executeUpdate ( ( "CREATE TABLE IF NOT EXISTS account_patch_reviews (" + ( ( ( ( ( ( "account_id INTEGER DEFAULT 0 NOT NULL, " + "change_id INTEGER DEFAULT 0 NOT NULL, " ) + "patch_set_id INTEGER DEFAULT 0 NOT NULL, " ) + "file_name VARCHAR(4096) DEFAULT '' NOT NULL, " ) + "CONSTRAINT primary_key_account_patch_reviews " ) + "PRIMARY KEY (change_id, patch_set_id, account_id, file_name)" ) + ")" ) ) ) ; }

Target:
protected void doCreateTable ( java.sql.Statement stmt ) throws java.sql.SQLException { stmt.executeUpdate ( ( "CREATE TABLE IF NOT EXISTS account_patch_reviews (" + ( ( ( ( ( ( "account_id INTEGER DEFAULT 0 NOT NULL, " + "change_id INTEGER DEFAULT 0 NOT NULL, " ) + "patch_set_id INTEGER DEFAULT 0 NOT NULL, " ) + "file_name VARCHAR(4096) DEFAULT '' NOT NULL, " ) + "CONSTRAINT primary_key_account_patch_reviews " ) + "PRIMARY KEY (change_id, patch_set_id, account_id, file_name)" ) + ")" ) ) ) ; }
Source:
com.google.gerrit.git.PatchSetImporter create ( com.google.gerrit.client.reviewdb.ReviewDb dstDb , com.google.gerrit.client.reviewdb.Project.NameKey proj , org.spearce.jgit.lib.Repository srcRepo , org.spearce.jgit.revwalk.RevCommit srcCommit , com.google.gerrit.client.reviewdb.PatchSet dstPatchSet , boolean isNewPatchSet ) ;

Target:
com.google.gerrit.git.PatchSetImporter create ( com.google.gerrit.client.reviewdb.ReviewDb dstDb , org.spearce.jgit.revwalk.RevCommit srcCommit , com.google.gerrit.client.reviewdb.PatchSet dstPatchSet , boolean isNewPatchSet ) ;
Source:
public void onSuccess ( com.google.gerrit.client.rpc.NativeMap < com.google.gwt.core.client.JsArray < com.google.gerrit.client.changes.CommentInfo > > result ) { publishedBase = com.google.gerrit.client.diff.CommentsCollections.sort ( result.get ( path ) ) ; }

Target:
public void onSuccess ( com.google.gerrit.client.rpc.NativeMap < com.google.gwt.core.client.JsArray < com.google.gerrit.client.changes.CommentInfo > > result ) { publishedBase = sort ( result.get ( path ) ) ; }
Source:
public void setAction ( com.google.gerrit.common.data.PermissionRule.Action action ) { if ( action == null ) { throw new java.lang.NullPointerException ( "action" ) ; } setDeny ( ( action == ( com.google.gerrit.common.data.PermissionRule.Action.DENY ) ) ) ; }

Target:
public void setAction ( com.google.gerrit.common.data.PermissionRule.Action action ) { if ( action == null ) { throw new java.lang.NullPointerException ( "action" ) ; } this . action = action ; }
Source:
private com.google.gerrit.server.notedb.RepoSequence newSequence ( java.lang.String name , int start , int batchSize , java.lang.Runnable afterReadRef , com.github.rholder.retry.Retryer < org.eclipse.jgit.lib.RefUpdate.Result > retryer ) { return new com.google.gerrit.server.notedb.RepoSequence ( repoManager , project , name , start , batchSize , afterReadRef , retryer ) ; }

Target:
public int get ( ) { return start ; }
Source:
public boolean isBatch ( ) { return false ; }

Target:
public boolean isBatch ( ) { return true ; }
Source:
public void run ( ) throws java.lang.Exception { parseCommandLine ( ) ; this . service ( ) ; }

Target:
public void run ( ) throws java.lang.Exception { this . service ( ) ; }
Source:
public boolean dryRun ( final com.google.gerrit.server.git.CodeReviewCommit mergeTip , final com.google.gerrit.server.git.CodeReviewCommit toMerge ) throws com.google.gerrit.server.git.MergeException { return args.mergeUtil.canCherryPick ( args.mergeSorter , args.repo , mergeTip , args.rw , toMerge ) ; }

Target:
public boolean dryRun ( com.google.gerrit.server.git.CodeReviewCommit mergeTip , com.google.gerrit.server.git.CodeReviewCommit toMerge ) throws com.google.gerrit.server.git.MergeException { return args.mergeUtil.canCherryPick ( args.mergeSorter , args.repo , mergeTip , args.rw , toMerge ) ; }
Source:
public static java.lang.String toSideBySide ( com.google.gerrit.reviewdb.client.PatchSet.Id diffBase , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName ) { return com.google.gerrit.client.Dispatcher.toPatch ( "" , diffBase , revision , fileName ) ; }

Target:
public static java.lang.String toSideBySide ( com.google.gerrit.reviewdb.client.PatchSet.Id diffBase , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName ) { return com.google.gerrit.client.Dispatcher.toPatch ( "" , diffBase , revision , fileName , null , 0 ) ; }
Source:
public final native java.lang.String parameters ( ) ;

Target:
public final native java.lang.String url ( ) ;
Source:
public boolean isOAuthFinal ( javax.servlet.http.HttpServletRequest request ) { return ( ( com.google.common.base.Strings.emptyToNull ( request.getParameter ( "code" ) ) ) != null ) && ( wasInitiatedByMe ( request ) ) ; }

Target:
public static boolean isOAuthFinal ( javax.servlet.http.HttpServletRequest request ) { return ( com.google.common.base.Strings.emptyToNull ( request.getParameter ( "code" ) ) ) != null ; }