auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void testLinkifyAmpersand ( ) throws java.lang.Exception { com.google.gitiles.Linkifier l = new com.google.gitiles.Linkifier ( TestGitilesUrls.URLS ) ; assertEquals ( com.google.common.collect.ImmutableList.of ( com.google.common.collect.ImmutableMap.of ( "text" , "http://my/url?a&b" , "url" , "http://my/url?a&b" ) ) , l.linkify ( com.google.gitiles.LinkifierTest.REQ , "http://my/url?a&b" ) ) ; assertEquals ( com.google.common.collect.ImmutableList.of ( com.google.common.collect.ImmutableMap.of ( "text" , "http://weird/htmlified/?url" , "url" , "http://weird/htmlified/?url" ) , com.google.common.collect.ImmutableMap.of ( "text" , "&lt;p&rt;" ) ) , l.linkify ( com.google.gitiles.LinkifierTest.REQ , "http://weird/htmlified/?url&lt;p&rt;" ) ) ; }

Target:
public void linkifyAmpersand ( ) throws java.lang.Exception { com.google.gitiles.Linkifier l = new com.google.gitiles.Linkifier ( TestGitilesUrls.URLS ) ; org.junit.Assert.assertEquals ( com.google.common.collect.ImmutableList.of ( com.google.common.collect.ImmutableMap.of ( "text" , "http://my/url?a&b" , "url" , "http://my/url?a&b" ) ) , l.linkify ( com.google.gitiles.LinkifierTest.REQ , "http://my/url?a&b" ) ) ; org.junit.Assert.assertEquals ( com.google.common.collect.ImmutableList.of ( com.google.common.collect.ImmutableMap.of ( "text" , "http://weird/htmlified/?url" , "url" , "http://weird/htmlified/?url" ) , com.google.common.collect.ImmutableMap.of ( "text" , "&lt;p&rt;" ) ) , l.linkify ( com.google.gitiles.LinkifierTest.REQ , "http://weird/htmlified/?url&lt;p&rt;" ) ) ; }
Source:
public com.google.gerrit.server.CurrentUser getUser ( ) { return user ; }

Target:
public void setUp ( ) throws java.lang.Exception { testEnv.getInjector ( ) . injectMembers ( this ) ; db = testEnv.getDb ( ) ; }
Source:
public void run ( ) { openIndex.close ( ) ; }

Target:
public void close ( ) { com.google.common.util.concurrent.MoreExecutors.shutdownAndAwaitTermination ( executor , java.lang.Long.MAX_VALUE , java.util.concurrent.TimeUnit.SECONDS ) ; try { openIndex.close ( ) ; } finally { closedIndex.close ( ) ; } }
Source:
public com.googlesource.gerrit.plugins.hooks.HookArgs createArgs ( ) { return new com.googlesource.gerrit.plugins.hooks.HookArgs ( anonymousCowardName , urlProvider ) ; }

Target:
public com.googlesource.gerrit.plugins.hooks.HookArgs createArgs ( ) { return new com.googlesource.gerrit.plugins.hooks.HookArgs ( anonymousCowardName , urlProvider , metrics ) ; }
Source:
public com.google.gerrit.pgm.util.LibraryDownloader setRequired ( final boolean required ) { this . required = required ; return this ; }

Target:
public void downloadOptional ( ) { this . required = false ; download ( ) ; }
Source:
public void run ( ) { ( header.hasNext ( ) ? header.next : header.up ) . go ( ) ; }

Target:
public void run ( ) { switch ( getIntraLineStatus ( ) ) { case OFF : case OK : toggleShowIntraline ( ) ; break ; default : break ; } }
Source:
public void evict ( com.google.gerrit.reviewdb.client.Account.Id accountId ) { if ( accountId != null ) { byId.invalidate ( accountId ) ; } }

Target:
public void evict ( com.google.gerrit.reviewdb.client.Account.Id accountId ) throws java.io.IOException { if ( accountId != null ) { byId.invalidate ( accountId ) ; indexer.get ( ) . index ( accountId ) ; } }
Source:
public void show ( ) { impl.visible ( true ) ; super . show ( ) ; }

Target:
public void show ( ) { com.google.gwtexpui.user.client.UserAgent.fireDialogVisible ( true ) ; impl.visible ( true ) ; super . show ( ) ; }
Source:
public com.google.gerrit.server.change.ChangeInserter setGroups ( java.lang.Iterable < java.lang.String > groups ) { patchSet.setGroups ( groups ) ; return this ; }

Target:
public com.google.gerrit.server.change.ChangeInserter setGroups ( java.lang.Iterable < java.lang.String > groups ) { com.google.common.base.Preconditions.checkState ( ( ( patchSet ) == null ) , "setGroups(Iterable<String>) only valid before creating change" ) ; this . groups = groups ; return this ; }
Source:
public static com.google.gwt.event.shared.HandlerRegistration addRpcCompleteHandler ( com.google.gwtjsonrpc.client.RpcCompleteHandler h ) { return com.google.gwtjsonrpc.client.JsonUtil.globalHandlers.addHandler ( com.google.gwtjsonrpc.client.RpcCompleteEvent.getType ( ) , h ) ; }

Target:
public static com.google.gwt.event.shared.HandlerRegistration addRpcCompleteHandler ( com.google.gwtjsonrpc.client.event.RpcCompleteHandler h ) { return com.google.gwtjsonrpc.client.JsonUtil.globalHandlers.addHandler ( com.google.gwtjsonrpc.client.event.RpcCompleteEvent.getType ( ) , h ) ; }
Source:
public void evict ( final com.google.gerrit.reviewdb.Account.Id accountId ) { byId.remove ( accountId ) ; }

Target:
public com.google.gerrit.server.account.AccountState getByUsername ( java.lang.String username ) { com.google.gerrit.reviewdb.Account.Id id = byName.get ( new com.google.gerrit.reviewdb.Account.Username ( username ) ) ; return id != null ? byId.get ( id ) : null ; }
Source:
protected java.lang.Iterable < com.google.gerrit.reviewdb.client.PatchLineComment > listComments ( com.google.gerrit.server.change.RevisionResource rsrc ) throws com.google.gwtorm.server.OrmException { com.google.gerrit.server.notedb.ChangeNotes notes = rsrc.getNotes ( ) ; return plcUtil.publishedByPatchSet ( db.get ( ) , notes , rsrc.getPatchSet ( ) . getId ( ) ) ; }

Target:
protected java.lang.Iterable < com.google.gerrit.reviewdb.client.Comment > listComments ( com.google.gerrit.server.change.RevisionResource rsrc ) throws com.google.gwtorm.server.OrmException { com.google.gerrit.server.notedb.ChangeNotes notes = rsrc.getNotes ( ) ; return commentsUtil.publishedByPatchSet ( db.get ( ) , notes , rsrc.getPatchSet ( ) . getId ( ) ) ; }
Source:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchLineComment > draftByChangeFileAuthor ( com.google.gerrit.reviewdb.client.Change.Id id , java.lang.String file , com.google.gerrit.reviewdb.client.Account.Id author ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.server.schema.DisabledChangesReviewDbWrapper.MSG ) ; }

Target:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchLineComment > draftByChangeFileAuthor ( com.google.gerrit.reviewdb.client.Change.Id id , java.lang.String file , com.google.gerrit.reviewdb.client.Account.Id author ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.reviewdb.server.DisabledChangesReviewDbWrapper.MSG ) ; }
Source:
public com.google.gerrit.client.reviewdb.ApprovalCategoryValue getValue ( final com.google.gerrit.client.reviewdb.ChangeApproval ca ) { initByValue ( ) ; return byValue.get ( ca.getValue ( ) ) ; }

Target:
public com.google.gerrit.client.reviewdb.ApprovalCategoryValue getValue ( final com.google.gerrit.client.reviewdb.PatchSetApproval ca ) { initByValue ( ) ; return byValue.get ( ca.getValue ( ) ) ; }
Source:
protected void configure ( ) { bind ( java.nio.file.Path.class ) . annotatedWith ( com.google.gerrit.server.config.SitePath.class ) . toProvider ( com.google.gerrit.httpd.SitePathFromSystemConfigProvider.class ) . in ( com.google.inject.Scopes.SINGLETON ) ; }

Target:
protected void configure ( ) { bind ( com.google.inject.Key.get ( javax.sql.DataSource.class , com.google.inject.name.Names.named ( "ReviewDb" ) ) ) . toProvider ( com.google.gerrit.httpd.ReviewDbDataSourceProvider.class ) . in ( com.google.inject.Scopes.SINGLETON ) ; listener ( ) . to ( com.google.gerrit.httpd.ReviewDbDataSourceProvider.class ) ; }
Source:
public static com.google.gerrit.server.patch.ComparisonType againstOtherPatchSet ( ) { return new com.google.gerrit.server.patch.ComparisonType ( null , false ) ; }

Target:
public static com.google.gerrit.server.diff.ComparisonType againstOtherPatchSet ( ) { return new com.google.gerrit.server.diff.ComparisonType ( null , false ) ; }
Source:
public static void addSignOutHandler ( final com.google.gerrit.client.SignOutHandler l ) { if ( ! ( com.google.gerrit.client.Gerrit.signOutHandlers.contains ( l ) ) ) { com.google.gerrit.client.Gerrit.signOutHandlers.add ( l ) ; } }

Target:
public static com.google.gwt.event.shared.HandlerRegistration addSignOutHandler ( final com.google.gerrit.client.SignOutHandler l ) { return com.google.gerrit.client.Gerrit.globalHandlers.addHandler ( com.google.gerrit.client.SignOutEvent.getType ( ) , l ) ; }
Source:
public static void comments ( com.google.gerrit.reviewdb.client.PatchSet.Id id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.rpc.NativeMap < com.google.gwt.core.client.JsArray < com.google.gerrit.client.changes.CommentInfo > > > cb ) { com.google.gerrit.client.changes.CommentApi.revision ( id , "comments" ) . get ( cb ) ; }

Target:
public static void updateDraft ( @ com.google.gerrit.common.Nullable java.lang.String project , com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String draftId , com.google.gerrit.client.changes.CommentInfo content , 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 ) . put ( content , cb ) ; }
Source:
public void put ( javax.servlet.http.HttpServletRequest req , java.lang.String key , java.lang.Object value ) { com.google.gitiles.BaseServlet.getData ( req ) . put ( key , value ) ; }

Target:
public static void putSoyData ( javax.servlet.http.HttpServletRequest req , java.lang.String key , java.lang.Object value ) { com.google.gitiles.BaseServlet.getData ( req ) . put ( key , value ) ; }
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.ChangeFileApi.putMessage ( id.getParentKey ( ) , m , r ) ; }

Target:
private static void putMessage ( com.google.gerrit.reviewdb.client.PatchSet.Id id , java.lang.String m , com.google.gerrit.client.rpc.GerritCallback < com.google.gerrit.client.VoidResult > r ) { com.google.gerrit.client.changes.ChangeFileApi.putMessage ( id.getParentKey ( ) , m , r ) ; }
Source:
public void changeProjectSettings ( final com.google.gerrit.reviewdb.Project update , final com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.common.data.ProjectDetail > callback ) { changeProjectSettingsFactory.create ( update ) . 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:
com.codahale.metrics.Gauge < V > gauge ( final java.lang.Runnable trigger ) { return new com.codahale.metrics.Gauge < V > ( ) { @ java.lang.Override public com.google.gerrit.metrics.dropwizard.V getValue ( ) { trigger.run ( ) ; return value ; } } ; }

Target:
public void remove ( ) { descriptions.remove ( name ) ; registry.remove ( name ) ; }
Source:
static void delete ( com.google.gerrit.reviewdb.client.Change.Id id ) { com.google.gerrit.client.changes.ChangeApi.deleteChange ( id.get ( ) , com.google.gerrit.client.change.DraftActions.mine ( ) ) ; }

Target:
static void delete ( com.google.gerrit.reviewdb.client.Change.Id id , com.google.gwt.user.client.ui.Button ... draftButtons ) { com.google.gerrit.client.changes.ChangeApi.deleteChange ( id.get ( ) , com.google.gerrit.client.change.DraftActions.mine ( draftButtons ) ) ; }
Source:
private final native void setStartCh ( int sc ) ;

Target:
private final native void set ( int sl , int sc , int el , int ec ) ;
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 ( "sidebyside" , diffBase , revision , fileName , null , 0 ) ; }

Target:
public static java.lang.String toSideBySide ( com.google.gerrit.client.DiffObject diffBase , com.google.gerrit.reviewdb.client.PatchSet.Id revision , java.lang.String fileName ) { return com.google.gerrit.client.Dispatcher.toPatch ( "sidebyside" , diffBase , revision , fileName , null , 0 ) ; }
Source:
public void getOpenChange_NotFound ( ) throws java.lang.Exception { com.google.gerrit.acceptance.PushOneCommit.Result r = pushFactory.create ( db , admin.getIdent ( ) , testRepo ) . to ( "refs/for/master" ) ; r.assertOkStatus ( ) ; assertNotFound ( r.getCommitId ( ) ) ; }

Target:
public void getOpenChange_NotFound ( ) throws java.lang.Exception { com.google.gerrit.acceptance.PushOneCommit.Result r = pushFactory.create ( db , admin.getIdent ( ) , testRepo ) . to ( "refs/for/master" ) ; r.assertOkStatus ( ) ; assertNotFound ( r.getCommit ( ) ) ; }
Source:
com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > rewrite ( com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > in , int start , int limit ) throws com.google.gerrit.server.query.QueryParseException ;

Target:
com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > rewrite ( com.google.gerrit.server.query.Predicate < com.google.gerrit.server.query.change.ChangeData > in , com.google.gerrit.server.query.change.QueryOptions opts ) throws com.google.gerrit.server.query.QueryParseException ;
Source:
public void close ( ) { getRepository ( ) . close ( ) ; }

Target:
public void close ( ) { if ( closeRepository ) { getRepository ( ) . close ( ) ; } }
Source:
public static java.util.Set < java.lang.String > getPersonParts ( org.eclipse.jgit.lib.PersonIdent person ) { if ( person == null ) { return com.google.common.collect.ImmutableSet.of ( ) ; } return com.google.gerrit.server.index.SchemaUtil.getNameParts ( person.getName ( ) , java.util.Collections.singleton ( person.getEmailAddress ( ) ) ) ; }

Target:
public static java.util.Set < java.lang.String > getPersonParts ( org.eclipse.jgit.lib.PersonIdent person ) { if ( person == null ) { return com.google.common.collect.ImmutableSet.of ( ) ; } return com.google.gerrit.index.SchemaUtil.getNameParts ( person.getName ( ) , java.util.Collections.singleton ( person.getEmailAddress ( ) ) ) ; }
Source:
public void setWhitespace ( final com.google.gerrit.client.patches.PatchScriptSettings.Whitespace ws ) { assert ws != null ; whitespace = ws ; }

Target:
public void setWhitespace ( final com.google.gerrit.client.data.PatchScriptSettings.Whitespace ws ) { assert ws != null ; whitespace = ws ; }
Source:
public org.eclipse.jgit.lib.ObjectId insert ( int type , long length , java.io.InputStream in ) throws java.io.IOException { return insert ( com.google.gerrit.server.notedb.InsertedObject.create ( type , in ) ) ; }

Target:
public org.eclipse.jgit.lib.ObjectId insert ( int type , long length , java.io.InputStream in ) throws java.io.IOException { return insert ( com.google.gerrit.server.git.InsertedObject.create ( type , in ) ) ; }
Source:
private static boolean inProject ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.server.project.ProjectControl projectControl ) { if ( projectControl == null ) { return true ; } return projectControl.getProject ( ) . getNameKey ( ) . equals ( change.getProject ( ) ) ; }

Target:
private static boolean inProject ( com.google.gerrit.reviewdb.client.Change change , com.google.gerrit.server.project.ProjectState projectState ) { if ( projectState == null ) { return true ; } return projectState.getNameKey ( ) . equals ( change.getProject ( ) ) ; }
Source:
public void onFailure ( java.lang.Throwable caught ) { if ( com.google.gerrit.client.rpc.RestApi.isNotFound ( caught ) ) { } else { super . onFailure ( caught ) ; } }

Target:
public void onFailure ( java.lang.Throwable caught ) { if ( com.google.gerrit.client.rpc.RestApi.isNotFound ( caught ) ) { } else { com.google.gerrit.client.rpc.GerritCallback.showFailure ( caught ) ; } }
Source:
public void onClick ( com.google.gwt.event.dom.client.ClickEvent event ) { setOpen ( ( ! ( isOpen ( ) ) ) ) ; }

Target:
void onHeaderClick ( com.google.gwt.event.dom.client.ClickEvent e ) { setOpen ( ( ! ( isOpen ( ) ) ) ) ; }
Source:
public void testCreateGroupWithoutCapability_Forbidden ( ) throws java.lang.Exception { setApiUser ( user ) ; try { gApi.groups ( ) . create ( name ( "newGroup" ) ) ; } catch ( com.google.gerrit.extensions.restapi.AuthException expected ) { } }

Target:
public void testCreateGroupWithoutCapability_Forbidden ( ) throws java.lang.Exception { setApiUser ( user ) ; exception.expect ( com.google.gerrit.extensions.restapi.AuthException.class ) ; gApi.groups ( ) . create ( name ( "newGroup" ) ) ; }
Source:
public void emptyCommitMessage ( ) throws java.lang.Exception { com.google.common.truth.Truth.assertThat ( com.google.gerrit.server.change.HashtagsUtil.extractTags ( "" ) ) . isEmpty ( ) ; }

Target:
public void emptyCommitMessage ( ) throws java.lang.Exception { com.google.common.truth.Truth.assertThat ( ( ( java.lang.Iterable < ? > ) ( com.google.gerrit.server.change.HashtagsUtil.extractTags ( "" ) ) ) ) . isEmpty ( ) ; }
Source:
public boolean match ( java.lang.String ref , java.lang.String username ) { return ref.startsWith ( prefix ) ; }

Target:
public boolean match ( java.lang.String ref , com.google.gerrit.server.CurrentUser user ) { return ref.startsWith ( prefix ) ; }
Source:
public com.google.gitiles.GitilesView.Builder setRepositoryName ( java.lang.String repositoryName ) { switch ( type ) { case HOST_INDEX : throw new java.lang.IllegalStateException ( java.lang.String.format ( "cannot set repository name on %s view" , type ) ) ; default : this . repositoryName = com.google.common.base.Preconditions.checkNotNull ( repositoryName ) ; return this ; } }

Target:
public com.google.gitiles.GitilesView.Builder setRepositoryName ( java.lang.String repositoryName ) { if ( ( type ) == ( com.google.gitiles.GitilesView.Type.HOST_INDEX ) ) { throw new java.lang.IllegalStateException ( java.lang.String.format ( "cannot set repository name on %s view" , type ) ) ; } this . repositoryName = com.google.common.base.Preconditions.checkNotNull ( repositoryName ) ; return this ; }
Source:
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 ) ; }

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 , migration , draftsProject , changeId , accountId ) ; }
Source:
protected void saveProjectConfig ( com.google.gerrit.server.git.ProjectConfig cfg ) throws java.lang.Exception { try ( com.google.gerrit.server.git.MetaDataUpdate md = metaDataUpdateFactory.create ( cfg.getName ( ) ) ) { cfg.commit ( md ) ; } projectCache.evict ( cfg.getProject ( ) ) ; }

Target:
protected void saveProjectConfig ( com.google.gerrit.server.git.ProjectConfig cfg ) throws java.lang.Exception { try ( com.google.gerrit.server.git.meta.MetaDataUpdate md = metaDataUpdateFactory.create ( cfg.getName ( ) ) ) { cfg.commit ( md ) ; } projectCache.evict ( cfg.getProject ( ) ) ; }
Source:
public org.apache.sshd.server.FileSystemView createFileSystemView ( org.apache.sshd.common.Session session ) throws java.io.IOException { return new org.apache.sshd.server.FileSystemView ( ) { @ java.lang.Override public org.apache.sshd.server.SshFile getFile ( org.apache.sshd.server.SshFile baseDir , java.lang.String file ) { return null ; } @ java.lang.Override public org.apache.sshd.server.SshFile getFile ( java.lang.String file ) { return null ; } } ; }

Target:
public org.apache.sshd.common.file.FileSystemView createFileSystemView ( org.apache.sshd.common.Session session ) throws java.io.IOException { return new org.apache.sshd.common.file.FileSystemView ( ) { @ java.lang.Override public org.apache.sshd.common.file.SshFile getFile ( org.apache.sshd.common.file.SshFile baseDir , java.lang.String file ) { return null ; } @ java.lang.Override public org.apache.sshd.common.file.SshFile getFile ( java.lang.String file ) { return null ; } } ; }
Source:
public static boolean isCapability ( java.lang.String varName ) { return com.google.gerrit.common.data.GlobalCapability.NAMES_LC.contains ( varName.toLowerCase ( ) ) ; }

Target:
public static boolean isGlobalCapability ( java.lang.String varName ) { return com.google.gerrit.common.data.GlobalCapability.NAMES_LC.contains ( varName.toLowerCase ( ) ) ; }
Source:
java.lang.String get ( final java.lang.String attName ) throws javax.naming.NamingException { return java.lang.String.valueOf ( atts.get ( attName ) . get ( 0 ) ) ; }

Target:
java.util.Set < java.lang.String > attributes ( ) { return java.util.Collections.unmodifiableSet ( atts.keySet ( ) ) ; }
Source:
protected void onLoad ( ) { resizePaddingWidget ( ) ; }

Target:
com.google.gerrit.client.diff.CommentManager getCommentManager ( ) { return group.getCommentManager ( ) ; }
Source:
public Account.Id apply ( java.lang.String refPart ) { return Account.Id.fromRefPart ( refPart ) ; }

Target:
public boolean apply ( java.lang.String refPart ) { return refPart.endsWith ( ( "/" + ( accountId.get ( ) ) ) ) ; }
Source:
public java.lang.String getBaseGerritUrl ( javax.servlet.http.HttpServletRequest req ) ;

Target:
java.lang.String getHostName ( javax.servlet.http.HttpServletRequest req ) ;
Source:
public void run ( ) { setVisibleA ( ( ! ( isVisibleA ( ) ) ) ) ; }

Target:
java.lang.Runnable toggleA ( ) { return ( ) -> { setVisibleA ( ( ! ( isVisibleA ( ) ) ) ) ; } ; }
Source:
public final void insert ( final java.lang.Iterable < E > instances , final com.google.gwtorm.client.Transaction txn ) throws com.google.gwtorm.client.OrmException { if ( txn != null ) { cast ( txn ) . queueInsert ( this , instances ) ; } else { insert ( instances ) ; } }

Target:
public final void upsert ( final java.lang.Iterable < E > instances ) throws com.google.gwtorm.client.OrmException { doUpsert ( instances ) ; }
Source:
private boolean canRestore ( com.google.gerrit.reviewdb.server.ReviewDb db ) throws com.google.gwtorm.server.OrmException { return ( canAbandon ( db ) ) && ( refControl.asForRef ( ) . testOrFalse ( RefPermission.CREATE_CHANGE ) ) ; }

Target:
private boolean canRestore ( com.google.gerrit.reviewdb.server.ReviewDb db ) throws com.google.gwtorm.server.OrmException { return ( ( canAbandon ( db ) ) && ( refControl.asForRef ( ) . testOrFalse ( RefPermission.CREATE_CHANGE ) ) ) && ( getProjectControl ( ) . getProjectState ( ) . statePermitsWrite ( ) ) ; }
Source:
public org.kohsuke.github.GHMyself getMyself ( ) { return myself ; }

Target:
public org.kohsuke.github.GHMyself getMyself ( ) { if ( isLoggedIn ( scopesSet ) ) { return myself ; } else { return null ; } }
Source:
public void putComment ( com.google.gerrit.reviewdb.client.PatchLineComment c ) { verifyComment ( c ) ; com.google.common.base.Preconditions.checkArgument ( ( ( c.getStatus ( ) ) == ( PatchLineComment.Status.DRAFT ) ) , "Cannot insert a published comment into a ChangeDraftUpdate" ) ; put.add ( c ) ; }

Target:
public void putComment ( com.google.gerrit.reviewdb.client.Comment c ) { verifyComment ( c ) ; put.add ( c ) ; }
Source:
private static java.lang.String renderName ( com.google.gerrit.client.changes.ChangeInfo.GitPerson person ) { return ( ( ( person.name ( ) ) + " <" ) + ( person.email ( ) ) ) + ">" ; }

Target:
private static java.lang.String renderName ( com.google.gerrit.client.info.ChangeInfo.GitPerson person ) { return ( ( ( person.name ( ) ) + " <" ) + ( person.email ( ) ) ) + ">" ; }
Source:
public java.util.Set < com.google.gerrit.reviewdb.client.AccountGroup.UUID > getEffectiveGroups ( ) { return java.util.Collections.singleton ( AccountGroup.ANONYMOUS_USERS ) ; }

Target:
public com.google.gerrit.server.account.GroupMembership getEffectiveGroups ( ) { return new com.google.gerrit.server.account.ListGroupMembership ( java.util.Collections.singleton ( AccountGroup.ANONYMOUS_USERS ) ) ; }
Source:
public void onClick ( final com.google.gwt.user.client.ui.Widget sender ) { showCLA ( cla ) ; }

Target:
public void onClick ( final com.google.gwt.event.dom.client.ClickEvent event ) { showCLA ( cla ) ; }
Source:
public boolean canRunGC ( ) { return ( canPerform ( GlobalCapability.RUN_GC ) ) || ( canAdministrateServer ( ) ) ; }

Target:
public boolean canRunGC ( ) { return ( canPerform ( GlobalCapability.RUN_GC ) ) || ( canMaintainServer ( ) ) ; }
Source:
public void tearDown ( ) throws java.lang.Exception { com.google.gerrit.testutil.InMemoryDatabase.drop ( db ) ; }

Target:
public void tearDown ( ) throws java.lang.Exception { if ( ( lifecycle ) != null ) { lifecycle.stop ( ) ; } com.google.gerrit.testutil.InMemoryDatabase.drop ( db ) ; }
Source:
public void onClick ( com.google.gwt.user.client.ui.Widget sender ) { com.google.gerrit.client.Gerrit.doSignOut ( ) ; }

Target:
public void execute ( ) { com.google.gerrit.client.Gerrit.doSignOut ( ) ; }
Source:
protected com.google.inject.Injector createInjector ( ) { org.eclipse.jgit.lib.Config elasticsearchConfig = new org.eclipse.jgit.lib.Config ( config ) ; com.google.gerrit.testutil.InMemoryModule.setDefaults ( elasticsearchConfig ) ; com.google.gerrit.elasticsearch.ElasticTestUtils.configure ( elasticsearchConfig , com.google.gerrit.elasticsearch.ElasticQueryProjectsTest.nodeInfo.port ) ; return com.google.inject.Guice.createInjector ( new com.google.gerrit.testutil.InMemoryModule ( elasticsearchConfig , notesMigration ) ) ; }

Target:
protected com.google.inject.Injector createInjector ( ) { org.eclipse.jgit.lib.Config elasticsearchConfig = new org.eclipse.jgit.lib.Config ( config ) ; com.google.gerrit.testing.InMemoryModule.setDefaults ( elasticsearchConfig ) ; com.google.gerrit.elasticsearch.ElasticTestUtils.configure ( elasticsearchConfig , com.google.gerrit.elasticsearch.ElasticQueryProjectsTest.nodeInfo.port ) ; return com.google.inject.Guice.createInjector ( new com.google.gerrit.testing.InMemoryModule ( elasticsearchConfig , notesMigration ) ) ; }
Source:
public com.googlesrouce.gerrit.plugins.github.git.GHMilestone getMilestone ( int number ) throws java.io.IOException { return ghRepository.getMilestone ( number ) ; }

Target:
public com.googlesource.gerrit.plugins.github.git.GHMilestone getMilestone ( int number ) throws java.io.IOException { return ghRepository.getMilestone ( number ) ; }
Source:
public void description ( com.google.gerrit.extensions.api.projects.PutDescriptionInput in ) throws com.google.gerrit.extensions.restapi.RestApiException { try { putDescription.apply ( checkExists ( ) , in ) ; } catch ( java.io.IOException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot put project description" , e ) ; } }

Target:
public void description ( com.google.gerrit.extensions.api.projects.DescriptionInput in ) throws com.google.gerrit.extensions.restapi.RestApiException { try { putDescription.apply ( checkExists ( ) , in ) ; } catch ( java.io.IOException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot put project description" , e ) ; } }
Source:
com.google.gerrit.common.data.PatchScript toPatchScript ( com.google.gerrit.server.diff.PatchListEntry content , com.google.gerrit.common.data.CommentDetail comments , java.util.List < com.google.gerrit.reviewdb.client.Patch > history ) throws java.io.IOException { reader = db.newObjectReader ( ) ; try { return build ( content , comments , history ) ; } finally { reader.close ( ) ; } }

Target:
com.google.gerrit.common.data.PatchScript toPatchScript ( com.google.gerrit.server.patch.PatchListEntry content , com.google.gerrit.common.data.CommentDetail comments , java.util.List < com.google.gerrit.reviewdb.client.Patch > history ) throws java.io.IOException { reader = db.newObjectReader ( ) ; try { return build ( content , comments , history ) ; } finally { reader.close ( ) ; } }
Source:
public static java.util.List < com.google.gerrit.pgm.init.InitPlugins.PluginData > listPluginsAndRemoveTempFiles ( com.google.gerrit.server.config.SitePaths site ) throws java.io.IOException { return com.google.gerrit.pgm.init.InitPlugins.listPlugins ( site , true ) ; }

Target:
public static java.util.List < com.google.gerrit.pgm.init.InitPlugins.PluginData > listPluginsAndRemoveTempFiles ( com.google.gerrit.server.config.SitePaths site , com.google.gerrit.pgm.init.PluginsDistribution pluginsDistribution ) throws java.io.IOException { return com.google.gerrit.pgm.init.InitPlugins.listPlugins ( site , true , pluginsDistribution ) ; }
Source:
public com.google.gerrit.metrics.dropwizard.V getValue ( ) { trigger.run ( ) ; return value ; }

Target:
public void remove ( ) { descriptions.remove ( name ) ; registry.remove ( name ) ; }
Source:
public void configure ( ) { factory ( ChangeUpdate.Factory.class ) ; factory ( ChangeDraftUpdate.Factory.class ) ; }

Target:
public void configure ( ) { factory ( ChangeUpdate.Factory.class ) ; factory ( ChangeDraftUpdate.Factory.class ) ; factory ( NoteDbUpdateManager.Factory.class ) ; }
Source:
public void testEventSentThrowsException ( ) throws java.lang.Exception { com.google.gerrit.server.events.Event event = setUpMocksForEvent ( false , "Exception" , true ) ; com.google.common.truth.Truth.assertThat ( restForwarder.send ( event ) ) . isFalse ( ) ; }

Target:
public void testEventSentFailed ( ) throws java.lang.Exception { com.google.gerrit.server.events.Event event = setUpMocksForEvent ( com.ericsson.gerrit.plugins.highavailability.forwarder.rest.RestForwarderTest.FAILED , com.ericsson.gerrit.plugins.highavailability.forwarder.rest.RestForwarderTest.ERROR_MSG , com.ericsson.gerrit.plugins.highavailability.forwarder.rest.RestForwarderTest.DO_NOT_THROW_EXCEPTION ) ; com.google.common.truth.Truth.assertThat ( restForwarder.send ( event ) ) . isFalse ( ) ; }
Source:
public void testGetSharedDirectory ( ) throws java.lang.Exception { initializeConfiguration ( ) ; com.google.common.truth.Truth.assertThat ( configuration.main ( ) . sharedDirectory ( ) ) . isEqualTo ( com.ericsson.gerrit.plugins.highavailability.ConfigurationTest.SHARED_DIRECTORY ) ; }

Target:
public void testGetSharedDirectory ( ) throws java.lang.Exception { initializeConfiguration ( ) ; org.junit.Assert.assertEquals ( configuration.main ( ) . sharedDirectory ( ) , com.ericsson.gerrit.plugins.highavailability.ConfigurationTest.SHARED_DIR_PATH ) ; }
Source:
public void onHeadUpdated ( com.google.gerrit.extensions.events.HeadUpdatedListener.Event event ) { for ( org.eclipse.jgit.transport.URIish uri : getURIs ( new com.google.gerrit.reviewdb.client.Project.NameKey ( event.getProjectName ( ) ) , FilterType.ALL ) ) { updateHead ( uri , event.getNewHeadName ( ) ) ; } }

Target:
void updateHead ( com.google.gerrit.reviewdb.client.Project.NameKey project , java.lang.String newHeadName ) { for ( org.eclipse.jgit.transport.URIish uri : getURIs ( project , FilterType.ALL ) ) { updateHead ( uri , newHeadName ) ; } }
Source:
public com.googlecode.prolog_cafe.lang.NumberTerm or ( com.googlecode.prolog_cafe.lang.NumberTerm t ) { if ( t.isDouble ( ) ) throw new com.googlecode.prolog_cafe.exceptions.IllegalTypeException ( "integer" , t ) ; return new com.googlecode.prolog_cafe.lang.IntegerTerm ( ( ( this . val ) | ( t.intValue ( ) ) ) ) ; }

Target:
public com.googlecode.prolog_cafe.lang.NumberTerm or ( com.googlecode.prolog_cafe.lang.NumberTerm t ) { if ( t instanceof com.googlecode.prolog_cafe.lang.DoubleTerm ) throw new com.googlecode.prolog_cafe.exceptions.IllegalTypeException ( "integer" , t ) ; return new com.googlecode.prolog_cafe.lang.IntegerTerm ( ( ( this . val ) | ( t.intValue ( ) ) ) ) ; }
Source:
void setTabTitle ( int index , java.lang.String title ) { getTabBar ( ) . setTabText ( index , title ) ; }

Target:
private void setTabTitle ( com.google.gerrit.client.change.RelatedChanges.Tab tabInfo , java.lang.String title ) { getTabBar ( ) . setTabText ( tabInfo.ordinal ( ) , title ) ; }
Source:
int getHeaderHeight ( ) { return patchSetSelectBoxA.getOffsetHeight ( ) ; }

Target:
int getHeaderHeight ( ) { int h = patchSetSelectBoxA.getOffsetHeight ( ) ; if ( header ) { h += diffHeaderRow.getOffsetHeight ( ) ; } return h ; }
Source:
public void normalize ( final com.google.gerrit.client.data.ApprovalType at , final com.google.gerrit.client.reviewdb.ChangeApproval ca ) { applyTypeFloor ( at , ca ) ; applyRightFloor ( ca ) ; }

Target:
public void normalize ( final com.google.gerrit.client.data.ApprovalType at , final com.google.gerrit.client.reviewdb.PatchSetApproval ca ) { applyTypeFloor ( at , ca ) ; applyRightFloor ( ca ) ; }
Source:
public void fire ( com.google.gerrit.reviewdb.client.Project.NameKey project , org.eclipse.jgit.lib.RefUpdate refUpdate , org.eclipse.jgit.transport.ReceiveCommand.Type type ) { fire ( project , refUpdate.getName ( ) , refUpdate.getOldObjectId ( ) , refUpdate.getNewObjectId ( ) , type ) ; }

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:
private static native void init0 ( ) ;

Target:
private static native void init0 ( java.lang.String serverUrl , com.google.gwt.core.client.JavaScriptObject JsonString ) ;
Source:
public void onSuccess ( final com.google.gwtjsonrpc.client.VoidResult result ) { com.google.gerrit.client.Gerrit.getUserAccount ( ) . setShowSiteHeader ( val ) ; com.google.gerrit.client.Gerrit.refreshMenuBar ( ) ; }

Target:
public void onSuccess ( final com.google.gwtjsonrpc.client.VoidResult result ) { com.google.gerrit.client.Gerrit.getUserAccount ( ) . setShowSiteHeader ( val ) ; com.google.gerrit.client.Gerrit.applyUserPreferences ( ) ; }
Source:
public void deleteReviewerFromWipChange ( ) throws java.lang.Exception { com.google.gerrit.acceptance.server.mail.StagedChange sc = stageWipChange ( ) ; removeReviewer ( sc , extraReviewer ) ; assertThat ( sender ) . notSent ( ) ; }

Target:
public void deleteReviewerFromReviewableWipChange ( ) throws java.lang.Exception { com.google.gerrit.acceptance.server.mail.StagedChange sc = stageReviewableWipChangeWithExtraReviewer ( ) ; removeReviewer ( sc , extraReviewer ) ; assertThat ( sender ) . notSent ( ) ; }
Source:
public org.apache.sshd.common.file.SshFile getFile ( org.apache.sshd.common.file.SshFile baseDir , java.lang.String file ) { return null ; }

Target:
public java.nio.file.Path getPath ( java.lang.String arg0 , java.lang.String ... arg1 ) { return null ; }
Source:
public final com.google.gerrit.server.index.Schema < V > getLatest ( ) { return schemas.lastEntry ( ) . getValue ( ) ; }

Target:
public final com.google.gerrit.index.Schema < V > getLatest ( ) { return schemas.lastEntry ( ) . getValue ( ) ; }
Source:
public com.google.gerrit.server.change.PatchSetInserter setNotify ( com.google.gerrit.extensions.api.changes.NotifyHandling notify ) { this . notify = notify ; return this ; }

Target:
public com.google.gerrit.server.change.PatchSetInserter setNotify ( com.google.gerrit.extensions.api.changes.NotifyHandling notify ) { this . notify = com.google.common.base.Preconditions.checkNotNull ( notify ) ; return this ; }
Source:
final native int _revision_number ( ) ;

Target:
final native int _revisionNumber ( ) ;
Source:
private static java.lang.String queryClosed ( java.lang.String who ) { return ( ( ( "is:closed (owner:" + who ) + " OR reviewer:" ) + who ) + ")" ; }

Target:
private static java.lang.String queryClosed ( java.lang.String who ) { return ( ( ( ( ( "is:closed (owner:" + who ) + " OR reviewer:" ) + who ) + " OR assignee:" ) + who ) + ")" ; }
Source:
public void configure ( ) { factory ( ChangeUpdate.Factory.class ) ; }

Target:
public void configure ( ) { factory ( ChangeUpdate.Factory.class ) ; factory ( ChangeDraftUpdate.Factory.class ) ; }
Source:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchLineComment > publishedByChangeFile ( com.google.gerrit.reviewdb.client.Change.Id id , java.lang.String file ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.server.schema.DisabledChangesReviewDbWrapper.MSG ) ; }

Target:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchLineComment > publishedByChangeFile ( com.google.gerrit.reviewdb.client.Change.Id id , java.lang.String file ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.reviewdb.server.DisabledChangesReviewDbWrapper.MSG ) ; }
Source:
public void onSuccess ( com.google.gerrit.client.VoidResult result ) { com.google.gerrit.client.Gerrit.display ( com.google.gerrit.common.PageLinks.toChange ( curr.getParentKey ( ) ) ) ; }

Target:
public void onSuccess ( com.google.gerrit.client.VoidResult result ) { com.google.gerrit.client.Gerrit.display ( com.google.gerrit.common.PageLinks.toChangeInEditMode ( curr.getParentKey ( ) ) ) ; }
Source:
private java.io.FileNotFoundException badWebRoot ( java.net.URL u ) { return new java.io.FileNotFoundException ( ( "Cannot find web root from " + u ) ) ; }

Target:
private static java.io.FileNotFoundException badSourceRoot ( java.net.URI u ) { return new java.io.FileNotFoundException ( ( "Cannot find source root from " + u ) ) ; }
Source:
public void index ( com.google.gerrit.reviewdb.server.ReviewDb db , com.google.gerrit.reviewdb.client.Change change ) throws com.google.gwtorm.server.OrmException , java.io.IOException { index ( newChangeData ( db , change ) ) ; reindexAfterIndexUpdate ( change.getProject ( ) , change.getId ( ) ) ; }

Target:
public void index ( com.google.gerrit.reviewdb.server.ReviewDb db , com.google.gerrit.reviewdb.client.Change change ) throws com.google.gwtorm.server.OrmException , java.io.IOException { index ( newChangeData ( db , change ) ) ; autoReindexIfStale ( change.getProject ( ) , change.getId ( ) ) ; }
Source:
public void noNotificationForDraftPatchSetsForWatchersInNotifyConfig ( ) throws java.lang.Exception { com.google.gerrit.server.mail.Address addr = new com.google.gerrit.server.mail.Address ( "Watcher" , "watcher@example.com" ) ; com.google.gerrit.server.git.NotifyConfig nc = new com.google.gerrit.server.git.NotifyConfig ( ) ; nc.addEmail ( addr ) ; nc.setName ( "team" ) ; nc.setHeader ( NotifyConfig.Header.TO ) ; nc.setTypes ( java.util.EnumSet.of ( NotifyType.NEW_PATCHSETS , NotifyType.ALL_COMMENTS ) ) ; HEAD ( 297 ) ; com.google.gerrit.acceptance.server.project.c74 Merge ; }

Target:
public void noNotificationForDraftPatchSetsForWatchersInNotifyConfig ( ) throws java.lang.Exception { com.google.gerrit.server.mail.Address addr = new com.google.gerrit.server.mail.Address ( "Watcher" , "watcher@example.com" ) ; com.google.gerrit.server.git.NotifyConfig nc = new com.google.gerrit.server.git.NotifyConfig ( ) ; nc.addEmail ( addr ) ; nc.setName ( "team" ) ; nc.setHeader ( NotifyConfig.Header.TO ) ; nc.setTypes ( java.util.EnumSet.of ( NotifyType.NEW_PATCHSETS , NotifyType.ALL_COMMENTS ) ) ; com.google.gerrit.server.git.ProjectConfig cfg = projectCache.checkedGet ( project ) . getConfig ( ) ; cfg.putNotifyConfig ( "team" , nc ) ; saveProjectConfig ( project , cfg ) ; com.google.gerrit.acceptance.PushOneCommit.Result r = pushFactory.create ( db , admin.getIdent ( ) , testRepo , "subject" , "a" , "a1" ) . to ( "refs/for/master" ) ; r.assertOkStatus ( ) ; sender.clear ( ) ; r = pushFactory.create ( db , admin.getIdent ( ) , testRepo , "subject" , "a" , "a2" , r.getChangeId ( ) ) . to ( "refs/for/master%draft" ) ; r.assertOkStatus ( ) ; com.google.common.truth.Truth.assertThat ( sender.getMessages ( ) ) . isEmpty ( ) ; setApiUser ( admin ) ; com.google.gerrit.extensions.api.changes.ReviewInput in = new com.google.gerrit.extensions.api.changes.ReviewInput ( ) ; in.message = "comment" ; gApi.changes ( ) . id ( r.getChangeId ( ) ) . current ( ) . review ( in ) ; com.google.common.truth.Truth.assertThat ( sender.getMessages ( ) ) . isEmpty ( ) ; }
Source:
public void resolvingEmailToAccountIdMocking ( ) throws java.lang.Exception { resolveEmail ( "user-a@email.com" , com.vmware.gerrit.owners.common.ClassicConfig.USERA ) ; resolveEmail ( "user-b@email.com" , com.vmware.gerrit.owners.common.ClassicConfig.USERB ) ; resolveEmail ( "user-c@email.com" , com.vmware.gerrit.owners.common.ClassicConfig.USERC ) ; }

Target:
public void setup ( ) throws java.lang.Exception { accounts.put ( com.vmware.gerrit.owners.common.ClassicConfig.USER_A_EMAIL_COM , com.vmware.gerrit.owners.common.ClassicConfig.USER_A_ID ) ; accounts.put ( com.vmware.gerrit.owners.common.ClassicConfig.USER_B_EMAIL_COM , com.vmware.gerrit.owners.common.ClassicConfig.USER_B_ID ) ; accounts.put ( com.vmware.gerrit.owners.common.ClassicConfig.USER_C_EMAIL_COM , com.vmware.gerrit.owners.common.ClassicConfig.USER_C_ID ) ; super . setup ( ) ; }
Source:
public static java.lang.String getVersion ( ) { return com.google.gerrit.common.Version.version ; }

Target:
public static java.lang.String getVersion ( ) { return com.google.gerrit.common.Version.VERSION ; }
Source:
public com.google.gerrit.lucene.LuceneChangeIndex getChangeIndex ( com.google.gerrit.server.config.SitePaths sitePaths , com.google.gerrit.server.index.FieldDef.FillArgs fillArgs ) throws java.io.IOException { return new com.google.gerrit.lucene.LuceneChangeIndex ( sitePaths , fillArgs , readOnly ) ; }

Target:
public com.google.gerrit.lucene.LuceneChangeIndex getChangeIndex ( @ com.google.gerrit.server.config.GerritServerConfig org.eclipse.jgit.lib.Config cfg , com.google.gerrit.server.config.SitePaths sitePaths , com.google.gerrit.server.index.FieldDef.FillArgs fillArgs ) throws java.io.IOException { return new com.google.gerrit.lucene.LuceneChangeIndex ( cfg , sitePaths , fillArgs , readOnly ) ; }
Source:
public com.google.common.base.Optional < com.google.gerrit.reviewdb.client.AccountGroup > load ( final com.google.gerrit.reviewdb.client.AccountGroup.Id key ) throws java.lang.Exception { try ( com.google.gerrit.reviewdb.server.ReviewDb db = schema.open ( ) ) { return com.google.common.base.Optional.fromNullable ( db.accountGroups ( ) . get ( key ) ) ; } }

Target:
public java.util.Optional < com.google.gerrit.reviewdb.client.AccountGroup > load ( final com.google.gerrit.reviewdb.client.AccountGroup.Id key ) throws java.lang.Exception { try ( com.google.gerrit.reviewdb.server.ReviewDb db = schema.open ( ) ) { return java.util.Optional.ofNullable ( db.accountGroups ( ) . get ( key ) ) ; } }
Source:
public void readCommentLinkInvalidPattern ( ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit rev = tr.commit ( ) . add ( "project.config" , ( "[commentlink \"bugzilla\"]\n" + ( "\tmatch = \"(bugs{+#?)(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 ( ) ) . isEmpty ( ) ; com.google.common.truth.Truth.assertThat ( cfg.getValidationErrors ( ) . stream ( ) . map ( ValidationError :: getMessage ) ) . containsExactly ( ( "project.config: Invalid pattern \"(bugs{+#?)(d+)\" in commentlink.bugzilla.match: " + ( ( "Illegal repetition near index 4\n" + "(bugs{+#?)(d+)\n" ) + " ^" ) ) ) ; }

Target:
public void readCommentLinkInvalidPattern ( ) throws java.lang.Exception { org.eclipse.jgit.revwalk.RevCommit rev = tr.commit ( ) . add ( "project.config" , ( "[commentlink \"bugzilla\"]\n" + ( "\tmatch = \"(bugs{+#?)(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 ( ) ) . isEmpty ( ) ; com.google.common.truth.Truth.assertThat ( cfg.getValidationErrors ( ) ) . containsExactly ( new com.google.gerrit.server.git.ValidationError ( ( "project.config: Invalid pattern \"(bugs{+#?)(d+)\" in commentlink.bugzilla.match: " + ( ( "Illegal repetition near index 4\n" + "(bugs{+#?)(d+)\n" ) + " ^" ) ) ) ) ; }
Source:
public void onChangeEvent ( final com.google.gerrit.common.ChangeHookRunner.ChangeEvent event ) { offer ( event ) ; }

Target:
public void onChangeEvent ( final com.google.gerrit.server.events.ChangeEvent event ) { offer ( event ) ; }
Source:
public void onClick ( com.google.gwt.event.dom.client.ClickEvent event ) { l.setVisible ( false ) ; edit.setVisible ( false ) ; input.setVisible ( true ) ; save.setVisible ( true ) ; cancel.setVisible ( true ) ; }

Target:
public void onClick ( com.google.gwt.event.dom.client.ClickEvent event ) { tagTable.deleteChecked ( ) ; }
Source:
public void run ( ) throws java.lang.Exception { parseCommandLine ( impl ) ; final java.io.PrintWriter stdout = toPrintWriter ( out ) ; try { impl.display ( stdout ) ; } finally { stdout.flush ( ) ; } }

Target:
protected void parseCommandLine ( ) throws com.google.gerrit.sshd.commands.UnloggedFailure { parseCommandLine ( impl ) ; }
Source:
public void deleteBranchByAdminForcePushBlocked ( ) throws java.lang.Exception { blockForcePush ( ) ; assertDeleteSucceeds ( ) ; }

Target:
public void deleteBranchByAdminForcePushBlocked ( ) throws java.lang.Exception { blockForcePush ( ) ; assertDeleteSucceeds ( testBranch ) ; }
Source:
public void getCache_Forbidden ( ) throws java.lang.Exception { com.google.gerrit.acceptance.RestResponse r = userSession.get ( "/config/server/caches/accounts" ) ; org.junit.Assert.assertEquals ( HttpStatus.SC_FORBIDDEN , r.getStatusCode ( ) ) ; }

Target:
public void getCacheWithGerritPrefix ( ) throws java.lang.Exception { com.google.gerrit.acceptance.RestResponse r = adminSession.get ( "/config/server/caches/gerrit-accounts" ) ; com.google.common.truth.Truth.assertThat ( r.getStatusCode ( ) ) . isEqualTo ( HttpStatus.SC_OK ) ; }
Source:
public void put ( K key , V value ) { cache.put ( new com.google.gerrit.ehcache.SerializableProtobuf < K > ( key , keyCodec ) , new com.google.gerrit.ehcache.SerializableProtobuf < V > ( value , valueCodec ) ) ; }

Target:
private com.google.gerrit.ehcache.SerializableProtobuf < V > wrapValue ( final V value ) { return new com.google.gerrit.ehcache.SerializableProtobuf < V > ( value , valueCodec ) ; }
Source:
public final native void setHeight ( java.lang.String h ) ;

Target:
public final native int changeGeneration ( boolean closeEvent ) ;
Source:
public static com.google.gerrit.client.rpc.RestApi detail ( int id ) { return com.google.gerrit.client.changes.ChangeApi.call ( id , "detail" ) ; }

Target:
public static void detail ( @ com.google.gerrit.common.Nullable java.lang.String project , int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gerrit.client.info.ChangeInfo > cb ) { com.google.gerrit.client.changes.ChangeApi.detail ( project , id ) . get ( cb ) ; }
Source:
public com.google.gerrit.extensions.common.ProjectInfo apply ( com.google.gerrit.server.project.ProjectResource rsrc ) { return json.format ( rsrc ) ; }

Target:
public com.google.gerrit.extensions.common.ProjectInfo apply ( com.google.gerrit.server.project.ProjectResource rsrc ) { return json.format ( rsrc.getControl ( ) ) ; }
Source:
public java.util.Optional < com.google.gerrit.reviewdb.client.AccountGroup > load ( java.lang.String uuid ) throws java.lang.Exception { try ( com.google.gerrit.reviewdb.server.ReviewDb db = schema.open ( ) ) { return groups.get ( db , new com.google.gerrit.reviewdb.client.AccountGroup.UUID ( uuid ) ) ; } }

Target:
public java.util.Optional < com.google.gerrit.reviewdb.client.AccountGroup > load ( java.lang.String uuid ) throws java.lang.Exception { try ( com.google.gerrit.reviewdb.server.ReviewDb db = schema.open ( ) ) { return groups.getGroup ( db , new com.google.gerrit.reviewdb.client.AccountGroup.UUID ( uuid ) ) ; } }
Source:
public void onFailure ( java.lang.Throwable caught ) { enableOnFailure.setEnabled ( true ) ; }

Target:
public void onSuccess ( com.google.gerrit.client.rpc.NativeString msg ) { b.setEnabled ( true ) ; if ( msg != null ) { com.google.gwt.user.client.Window.alert ( msg.asString ( ) ) ; } }