auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public void setTimeForTesting ( ) { systemTimeZone = java.lang.System.setProperty ( "user.timezone" , "US/Eastern" ) ; com.google.gerrit.testutil.TestTimeUtil.resetWithClockStep ( 1 , java.util.concurrent.TimeUnit.MILLISECONDS ) ; }

Target:
public void setTimeForTesting ( ) { resetTimeWithClockStep ( 1 , java.util.concurrent.TimeUnit.MILLISECONDS ) ; }
Source:
protected void add ( final com.google.gerrit.server.mail.RecipientType rt , final java.util.Collection < com.google.gerrit.reviewdb.client.Account.Id > list ) { for ( final com.google.gerrit.reviewdb.client.Account.Id id : list ) { add ( rt , id ) ; } }

Target:
protected void add ( final com.google.gerrit.extensions.api.changes.RecipientType rt , final java.util.Collection < com.google.gerrit.reviewdb.client.Account.Id > list ) { for ( final com.google.gerrit.reviewdb.client.Account.Id id : list ) { add ( rt , id ) ; } }
Source:
public boolean isOwnerAnyRef ( ) { return ( canPerformOnAnyRef ( Permission.OWNER ) ) || ( isAdmin ( ) ) ; }

Target:
private boolean canAddRefs ( ) { return ( canPerformOnAnyRef ( Permission.CREATE ) ) || ( isAdmin ( ) ) ; }
Source:
private static java.lang.UnsupportedOperationException noInterpreter ( java.lang.Throwable why ) { final java.lang.String msg = "Cannot create Python interpreter" ; return com.google.gerrit.pgm.shell.JythonShell.noShell ( msg , why ) ; }

Target:
private static java.lang.UnsupportedOperationException noInterpreter ( java.lang.Throwable why ) { final java.lang.String msg = "Cannot create Python interpreter" ; return com.google.gerrit.pgm.JythonShell.noShell ( msg , why ) ; }
Source:
private void checkPreconditions ( javax.servlet.http.HttpServletRequest req , com.google.gerrit.extensions.restapi.RestResource rsrc ) throws com.google.gerrit.extensions.restapi.PreconditionFailedException { if ( "*" . equals ( req.getHeader ( "If-None-Match" ) ) ) { throw new com.google.gerrit.extensions.restapi.PreconditionFailedException ( ) ; } }

Target:
private void checkPreconditions ( javax.servlet.http.HttpServletRequest req , com.google.gerrit.extensions.restapi.RestResource rsrc ) throws com.google.gerrit.extensions.restapi.PreconditionFailedException { if ( "*" . equals ( req.getHeader ( "If-None-Match" ) ) ) { throw new com.google.gerrit.extensions.restapi.PreconditionFailedException ( "Resource already exists" ) ; } }
Source:
public java.lang.String getToken ( ) { return isSignedIn ( ) ? val.getXsrfToken ( ) : null ; }

Target:
public java.lang.String getAccessToken ( ) { return isSignedIn ( ) ? key.getToken ( ) : null ; }
Source:
private static void checkRequiredMenuItemField ( java.lang.String value , java.lang.String name ) throws com.google.gerrit.extensions.restapi.BadRequestException { if ( com.google.gerrit.server.account.PreferencesConfig.isNullOrEmpty ( value ) ) { throw new com.google.gerrit.extensions.restapi.BadRequestException ( ( name + " for menu item is required" ) ) ; } }

Target:
private static void checkRequiredMenuItemField ( java.lang.String value , java.lang.String name ) throws com.google.gerrit.extensions.restapi.BadRequestException { if ( com.google.gerrit.server.account.Preferences.isNullOrEmpty ( value ) ) { throw new com.google.gerrit.extensions.restapi.BadRequestException ( ( name + " for menu item is required" ) ) ; } }
Source:
public int getContext ( ) { return settings.getContext ( ) ; }

Target:
public java.lang.Iterable < com.google.gerrit.prettify.common.EditList.Hunk > getHunks ( ) { final int ctx = settings.getContext ( ) ; return new com.google.gerrit.prettify.common.EditList ( edits , ctx , a.size ( ) , b.size ( ) ) . getHunks ( ) ; }
Source:
private static com.google.gerrit.server.index.Schema < com.google.gerrit.server.query.change.ChangeData > release ( com.google.gerrit.server.index.FieldDef < com.google.gerrit.server.query.change.ChangeData , ? > ... fields ) { return new com.google.gerrit.server.index.Schema < com.google.gerrit.server.query.change.ChangeData > ( true , java.util.Arrays.asList ( fields ) ) ; }

Target:
private static com.google.gerrit.server.index.Schema < com.google.gerrit.server.query.change.ChangeData > release ( com.google.gerrit.server.index.FieldDef < com.google.gerrit.server.query.change.ChangeData , ? > ... fields ) { return com.google.gerrit.server.index.ChangeSchemas.release ( java.util.Arrays.asList ( fields ) ) ; }
Source:
public java.lang.String apply ( com.google.gerrit.server.group.GroupResource resource ) throws com.google.gerrit.extensions.restapi.MethodNotAllowedException { com.google.gerrit.common.data.GroupDescription.Internal group = resource.asInternalGroup ( ) . orElseThrow ( MethodNotAllowedException :: new ) ; return com.google.common.base.Strings.nullToEmpty ( group.getDescription ( ) ) ; }

Target:
public java.lang.String apply ( com.google.gerrit.server.group.GroupResource resource ) throws com.google.gerrit.server.restapi.group.NotInternalGroupException { com.google.gerrit.common.data.GroupDescription.Internal group = resource.asInternalGroup ( ) . orElseThrow ( NotInternalGroupException :: new ) ; return com.google.common.base.Strings.nullToEmpty ( group.getDescription ( ) ) ; }
Source:
private void appendLineText ( final com.google.gwtexpui.safehtml.client.SafeHtmlBuilder m , final int lineNumberMinusOne , final com.google.gerrit.client.patches.PatchLine.Type type , final com.google.gerrit.prettify.common.SparseHtmlFile src , final int i ) { appendLineText ( m , lineNumberMinusOne , type , src.getSafeHtmlLine ( i ) ) ; }

Target:
private void appendLineText ( final com.google.gwtexpui.safehtml.client.SafeHtmlBuilder m , final int lineNumberMinusOne , final com.google.gerrit.client.patches.PatchLine.Type type , final com.google.gerrit.prettify.common.SparseHtmlFile src , final int i ) { appendLineText ( m , lineNumberMinusOne , type , src.getSafeHtmlLine ( i ) , src.hasTrailingEdit ( i ) ) ; }
Source:
public static java.lang.String toChange ( com.google.gerrit.reviewdb.client.Change.Id c , java.lang.String p ) { return ( ( "/c/" + c ) + "/" ) + p ; }

Target:
public static java.lang.String toChange ( @ com.google.gerrit.common.Nullable com.google.gerrit.reviewdb.client.Project.NameKey project , com.google.gerrit.reviewdb.client.Change.Id c , java.lang.String p ) { return ( com.google.gerrit.common.PageLinks.toChange ( project , c ) ) + p ; }
Source:
public void onSubmit ( final com.google.gwt.user.client.ui.FormPanel.SubmitEvent event ) { event.cancel ( ) ; final java.lang.String addr = inEmail.getText ( ) . trim ( ) ; if ( ! ( addr.contains ( "@" ) ) ) { new com.google.gerrit.client.ErrorDialog ( Util.C.invalidUserEmail ( ) ) . center ( ) ; return ; } inEmail.setEnabled ( false ) ; register.setEnabled ( false ) ; Util.ACCOUNT_SEC.registerEmail ( addr , new com.google.gerrit.client.rpc.GerritCallback < com.google.gerrit.reviewdb.client.Account > ( ) { public void onSuccess ( com.google.gerrit.reviewdb.client.Account currentUser ) { box.hide ( ) ; if ( ( com.google.gerrit.client.Gerrit.getConfig ( ) . getAuthType ( ) ) == ( com.google.gerrit.reviewdb.client.AuthType.DEVELOPMENT_BECOME_ANY_ACCOUNT ) ) { currentEmail = addr ; if ( ( emailPick.getItemCount ( ) ) == 0 ) { onSaveSuccess ( currentUser ) ; } else { save.setEnabled ( true ) ; } updateEmailList ( ) ; } } @ java.lang.Override public void onFailure ( final java.lang.Throwable caught ) { inEmail.setEnabled ( true ) ; register.setEnabled ( true ) ; if ( caught.getMessage ( ) . startsWith ( EmailException.MESSAGE ) ) { final com.google.gerrit.client.ErrorDialog d = new com.google.gerrit.client.ErrorDialog ( caught.getMessage ( ) . substring ( EmailException.MESSAGE.length ( ) ) ) ; d.setText ( Util.C.errorDialogTitleRegisterNewEmail ( ) ) ; d.center ( ) ; } else { super . onFailure ( caught ) ; } } } ) ; }

Target:
public void onSubmit ( final com.google.gwt.user.client.ui.FormPanel.SubmitEvent event ) { event.cancel ( ) ; final java.lang.String addr = inEmail.getText ( ) . trim ( ) ; if ( ! ( addr.contains ( "@" ) ) ) { new com.google.gerrit.client.ErrorDialog ( Util.C.invalidUserEmail ( ) ) . center ( ) ; return ; } inEmail.setEnabled ( false ) ; register.setEnabled ( false ) ; com.google.gerrit.client.account.AccountApi.registerEmail ( "self" , addr , new com.google.gerrit.client.rpc.GerritCallback < com.google.gerrit.client.rpc.NativeString > ( ) { @ java.lang.Override public void onSuccess ( com.google.gerrit.client.rpc.NativeString result ) { box.hide ( ) ; if ( ( com.google.gerrit.client.Gerrit.getConfig ( ) . getAuthType ( ) ) == ( com.google.gerrit.reviewdb.client.AuthType.DEVELOPMENT_BECOME_ANY_ACCOUNT ) ) { currentEmail = addr ; if ( ( emailPick.getItemCount ( ) ) == 0 ) { final com.google.gerrit.reviewdb.client.Account me = com.google.gerrit.client.Gerrit.getUserAccount ( ) ; me.setPreferredEmail ( addr ) ; onSaveSuccess ( me ) ; } else { save.setEnabled ( true ) ; } updateEmailList ( ) ; } } @ java.lang.Override public void onFailure ( final java.lang.Throwable caught ) { inEmail.setEnabled ( true ) ; register.setEnabled ( true ) ; if ( caught.getMessage ( ) . startsWith ( EmailException.MESSAGE ) ) { final com.google.gerrit.client.ErrorDialog d = new com.google.gerrit.client.ErrorDialog ( caught.getMessage ( ) . substring ( EmailException.MESSAGE.length ( ) ) ) ; d.setText ( Util.C.errorDialogTitleRegisterNewEmail ( ) ) ; d.center ( ) ; } else { super . onFailure ( caught ) ; } } } ) ; }
Source:
public org.parboiled.Rule [ ] blockPluginRules ( ) { return new org.parboiled.Rule [ ] { toc ( ) , note ( ) } ; }

Target:
public org.parboiled.Rule [ ] blockPluginRules ( ) { return new org.parboiled.Rule [ ] { cols ( ) , note ( ) , toc ( ) } ; }
Source:
public boolean canInheritFromWildProject ( ) { if ( com.google.gerrit.reviewdb.ApprovalCategory.OWN.equals ( this ) ) { return false ; } return true ; }

Target:
public boolean canBeOnWildProject ( ) { if ( com.google.gerrit.reviewdb.ApprovalCategory.OWN.equals ( this ) ) { return false ; } else { return true ; } }
Source:
public com.google.gerrit.server.project.ChangeControl getUserControl ( ) { return getControl ( ) . forUser ( user ) ; }

Target:
public com.google.gerrit.server.project.ChangeControl getReviewerControl ( ) { return change.getControl ( ) . forUser ( user ) ; }
Source:
public void stop ( ) { running = false ; int discarded = config.shutdown ( ) ; if ( discarded > 0 ) { com.googlesource.gerrit.plugins.replication.ReplicationQueue.repLog.warn ( java.lang.String.format ( "Canceled %d replication events during shutdown" , discarded ) ) ; } }

Target:
public void stop ( ) { running = false ; int discarded = config.shutdown ( ) ; if ( discarded > 0 ) { com.googlesource.gerrit.plugins.replication.ReplicationQueue.repLog.warn ( "Canceled replication events during shutdown" , discarded ) ; } }
Source:
private void readObject ( final java.io.ObjectInputStream in ) throws java.io.IOException { token = in.readUTF ( ) ; }

Target:
private void readObject ( final java.io.ObjectInputStream in ) throws java.io.IOException { token = com.google.gerrit.server.ioutil.BasicSerialization.readString ( in ) ; }
Source:
public final native void setActiveLine ( int line ) ;

Target:
public static final native net.codemirror.lib.LineCharacter pos ( int line , int ch ) ;
Source:
public final com.google.gerrit.server.index.Schema < V > get ( int version ) { com.google.gerrit.server.index.Schema < V > schema = schemas.get ( version ) ; com.google.common.base.Preconditions.checkArgument ( ( schema != null ) , "Unrecognized %s schema version: %s" , name , version ) ; return schema ; }

Target:
public final com.google.gerrit.index.Schema < V > get ( int version ) { com.google.gerrit.index.Schema < V > schema = schemas.get ( version ) ; com.google.common.base.Preconditions.checkArgument ( ( schema != null ) , "Unrecognized %s schema version: %s" , name , version ) ; return schema ; }
Source:
public void contextInitialized ( final javax.servlet.ServletContextEvent event ) { super . contextInitialized ( event ) ; init ( ) ; manager.start ( ) ; }

Target:
public void init ( javax.servlet.FilterConfig cfg ) throws javax.servlet.ServletException { servletContext = cfg.getServletContext ( ) ; contextInitialized ( new javax.servlet.ServletContextEvent ( servletContext ) ) ; init ( ) ; manager.start ( ) ; }
Source:
private boolean isInteralGroup ( final com.google.gerrit.client.groups.GroupInfo groupInfo ) { return ( groupInfo != null ) && ( groupInfo.url ( ) . startsWith ( ( "#" + ( com.google.gerrit.common.PageLinks.ADMIN_GROUPS ) ) ) ) ; }

Target:
private boolean isInteralGroup ( final com.google.gerrit.client.info.GroupInfo groupInfo ) { return ( groupInfo != null ) && ( groupInfo.url ( ) . startsWith ( ( "#" + ( com.google.gerrit.common.PageLinks.ADMIN_GROUPS ) ) ) ) ; }
Source:
final native void add_branch ( java.lang.String b ) ;

Target:
final native void addBranch ( java.lang.String b ) ;
Source:
public com.google.gerrit.client.reviewdb.AccountAgreement.Status getStatus ( ) { return com.google.gerrit.client.reviewdb.AccountAgreement.Status.forCode ( status ) ; }

Target:
public com.google.gerrit.client.reviewdb.Status getStatus ( ) { return com.google.gerrit.client.reviewdb.Status.forCode ( status ) ; }
Source:
public boolean getBoolean ( java.lang.String name , boolean defaultValue ) { return getValue ( name , new com.google.common.base.Function < java.lang.String , java.lang.Boolean > ( ) { @ java.lang.Override public java.lang.Boolean apply ( java.lang.String stringVal ) { return java.lang.Boolean.parseBoolean ( stringVal ) ; } } , defaultValue ) ; }

Target:
public boolean getBoolean ( java.lang.String name , boolean defaultValue ) { return cfg.getBoolean ( com.google.gerrit.server.config.PluginConfig.PLUGIN , pluginName , name , defaultValue ) ; }
Source:
public static java.lang.String toAccountQuery ( final java.lang.String fullname ) { java.lang.String query = ( com.google.gerrit.common.PageLinks.op ( "owner" , fullname ) ) + " status:open" ; return com.google.gerrit.common.PageLinks.toChangeQuery ( query , com.google.gerrit.common.PageLinks.TOP ) ; }

Target:
public static java.lang.String toAccountQuery ( final java.lang.String fullname ) { return com.google.gerrit.common.PageLinks.toAccountQuery ( fullname , Status.NEW ) ; }
Source:
public com.google.gerrit.metrics.Counter newCounter ( java.lang.String name , com.google.gerrit.metrics.Description desc ) { com.google.gerrit.metrics.Counter m = root.newCounter ( ( ( prefix ) + name ) , desc ) ; cleanup.add ( m ) ; return m ; }

Target:
public com.google.gerrit.metrics.Counter0 newCounter ( java.lang.String name , com.google.gerrit.metrics.Description desc ) { com.google.gerrit.metrics.Counter0 m = root.newCounter ( ( ( prefix ) + name ) , desc ) ; cleanup.add ( m ) ; return m ; }
Source:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchSetApproval > byPatchSet ( com.google.gerrit.reviewdb.client.PatchSet.Id id ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.server.schema.DisabledChangesReviewDbWrapper.MSG ) ; }

Target:
public com.google.gwtorm.server.ResultSet < com.google.gerrit.reviewdb.client.PatchSetApproval > byPatchSet ( com.google.gerrit.reviewdb.client.PatchSet.Id id ) { throw new java.lang.UnsupportedOperationException ( com.google.gerrit.reviewdb.server.DisabledChangesReviewDbWrapper.MSG ) ; }
Source:
public void run ( ) { java.lang.String token = host.getToken ( ) ; if ( cm.hasActiveLine ( ) ) { net.codemirror.lib.CodeMirror.LineHandle handle = cm.activeLine ( ) ; int line = ( cm.getLineNumber ( handle ) ) + 1 ; token += ( "@" + ( ( cm.side ( ) ) == ( DisplaySide.A ) ? "a" : "" ) ) + line ; } com.google.gerrit.client.Gerrit.doSignIn ( token ) ; }

Target:
public void run ( ) { java.lang.String token = host.getToken ( ) ; if ( cm.extras ( ) . hasActiveLine ( ) ) { net.codemirror.lib.CodeMirror.LineHandle handle = cm.extras ( ) . activeLine ( ) ; int line = ( cm.getLineNumber ( handle ) ) + 1 ; token += ( "@" + ( ( cm.side ( ) ) == ( DisplaySide.A ) ? "a" : "" ) ) + line ; } com.google.gerrit.client.Gerrit.doSignIn ( token ) ; }
Source:
public void onSuccess ( com.googlesource.gerrit.plugins.serviceuser.client.ServiceUserInfo info ) { display ( info ) ; }

Target:
public void onSuccess ( com.googlesource.gerrit.plugins.serviceuser.client.ConfigInfo configInfo ) { display ( serviceUserInfo , configInfo.getAllowEmail ( ) ) ; }
Source:
public void sendAsync ( ) { sendEmailsExecutor.submit ( this ) ; }

Target:
public void sendAsync ( ) { @ java.lang.SuppressWarnings ( value = "unused" ) java.util.concurrent.Future < ? > possiblyIgnoredError = sendEmailsExecutor.submit ( this ) ; }
Source:
public void close ( ) { if ( closeRepo ) { revWalk.close ( ) ; inserter.close ( ) ; repo.close ( ) ; } }

Target:
public void close ( ) { if ( closeRepo ) { revWalk.getObjectReader ( ) . close ( ) ; revWalk.close ( ) ; inserter.close ( ) ; repo.close ( ) ; } }
Source:
public boolean isSubmit ( ) { return com.google.gerrit.reviewdb.client.PatchSetApproval.LabelId.SUBMIT.get ( ) . equals ( getLabelId ( ) . get ( ) ) ; }

Target:
public java.lang.String getLabel ( ) { return getLabelId ( ) . get ( ) ; }
Source:
public static void deleteChange ( int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwt.core.client.JavaScriptObject > cb ) { com.google.gerrit.client.changes.ChangeApi.change ( id ) . delete ( cb ) ; }

Target:
public static void deleteEdit ( @ com.google.gerrit.common.Nullable java.lang.String project , int id , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwt.core.client.JavaScriptObject > cb ) { com.google.gerrit.client.changes.ChangeApi.edit ( project , id ) . delete ( cb ) ; }
Source:
public void testRightEventBitItIsForwarded ( ) throws java.lang.Exception { setUpMocks ( false , true ) ; com.ericsson.gerrit.plugins.syncevents.Context.setForwardedEvent ( ) ; eventHandler.onEvent ( event ) ; com.ericsson.gerrit.plugins.syncevents.Context.unsetForwardedEvent ( ) ; verifyAll ( ) ; }

Target:
public void testBadEventAndNotForwarded ( ) throws java.lang.Exception { setUpMocks ( false ) ; eventHandler.onEvent ( event ) ; org.mockito.Mockito.verifyZeroInteractions ( restSession ) ; }
Source:
public abstract void renameColumn ( java.sql.Statement stmt , java.lang.String tableName , java.lang.String fromColumn , com.google.gwtorm.schema.ColumnModel col ) throws java.sql.SQLException ;

Target:
public abstract void renameColumn ( com.google.gwtorm.client.StatementExecutor e , java.lang.String tableName , java.lang.String fromColumn , com.google.gwtorm.schema.ColumnModel col ) throws com.google.gwtorm.client.OrmException ;
Source:
public java.util.List < com.google.gerrit.server.patch.PatchListEntry > getPatches ( ) { return java.util.Collections.unmodifiableList ( java.util.Arrays.asList ( patches ) ) ; }

Target:
public java.util.List < com.google.gerrit.server.diff.PatchListEntry > getPatches ( ) { return java.util.Collections.unmodifiableList ( java.util.Arrays.asList ( patches ) ) ; }
Source:
public void setMinusOne ( java.lang.String project , int number , java.lang.String commentTemplate ) throws java.lang.Exception { com.google.gerrit.extensions.api.changes.ReviewInput message = createComment ( commentTemplate ) . label ( "Code-Review" , ( - 1 ) ) ; applyComment ( project , number , message ) ; }

Target:
private void applyComment ( java.lang.String project , int number , com.google.gerrit.extensions.api.changes.ReviewInput comment ) throws java.lang.Exception { com.google.gerrit.server.change.RevisionResource r = atomicityHelper.getRevisionResource ( project , number ) ; reviewer.get ( ) . apply ( r , comment ) ; }
Source:
private static boolean isEncodedBase64 ( com.google.gwt.http.client.Response res ) { return ( "base64" . equals ( res.getHeader ( "X-FYI-Content-Encoding" ) ) ) && ( com.google.gerrit.client.rpc.RestApi.isTextBody ( res ) ) ; }

Target:
private static boolean isJsonEncoded ( com.google.gwt.http.client.Response res ) { return "json" . equals ( res.getHeader ( "X-FYI-Content-Encoding" ) ) ; }
Source:
public void invalidGitUrlLink ( ) throws java.lang.Exception { repo.branch ( "master" ) . commit ( ) . add ( "README.md" , "[c](git://example.com/repo/..)" ) . create ( ) ; java.lang.String html = buildHtml ( "/repo/+doc/master/README.md" ) ; com.google.common.truth.Truth.assertThat ( html ) . contains ( "<a href=\"#zSoyz\">c</a>" ) ; }

Target:
public void invalidGitUrlLink ( ) throws java.lang.Exception { repo.branch ( "master" ) . commit ( ) . add ( "README.md" , "[c](git://example.com/repo/..)" ) . create ( ) ; java.lang.String html = buildHtml ( "/repo/+doc/master/README.md" ) ; com.google.common.truth.Truth.assertThat ( html ) . contains ( "<a href=\"about:invalid#zSoyz\">c</a>" ) ; }
Source:
public static void createEdit ( 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.call ( id , commit , "create_edit" ) . post ( com.google.gwt.core.client.JavaScriptObject.createObject ( ) , cb ) ; }

Target:
public static com.google.gerrit.client.rpc.RestApi edit ( int id ) { return com.google.gerrit.client.changes.ChangeApi.change ( id ) . view ( "edit" ) ; }
Source:
com.google.gerrit.server.project.ChangeControl forUser ( com.google.gerrit.server.CurrentUser who ) { if ( getUser ( ) . equals ( who ) ) { return this ; } return new com.google.gerrit.server.project.ChangeControl ( changeDataFactory , approvalsUtil , getRefControl ( ) . forUser ( who ) , notes , patchSetUtil ) ; }

Target:
private com.google.gerrit.server.project.ChangeControl forUser ( com.google.gerrit.server.CurrentUser who ) { if ( getUser ( ) . equals ( who ) ) { return this ; } return new com.google.gerrit.server.project.ChangeControl ( changeDataFactory , approvalsUtil , refControl.forUser ( who ) , notes , patchSetUtil ) ; }
Source:
public void testPushDraftChangeMagic_Blocked ( ) throws com.google.gwtorm.server.OrmException , java.io.IOException , org.eclipse.jgit.api.errors.GitAPIException { com.google.gerrit.acceptance.PushOneCommit.Result r = pushTo ( "refs/for/master%draft" ) ; r.assertErrorStatus ( "cannot upload drafts" ) ; }

Target:
public void testPushDraftChange_Blocked ( ) throws com.google.gwtorm.server.OrmException , java.io.IOException , org.eclipse.jgit.api.errors.GitAPIException { com.google.gerrit.acceptance.PushOneCommit.Result r = pushTo ( "refs/drafts/master" ) ; r.assertErrorStatus ( "cannot upload drafts" ) ; }
Source:
boolean hasNext ( ) { return hasNext ; }

Target:
public void run ( ) { ( hasNext ? next : up ) . go ( ) ; }
Source:
public java.lang.String apply ( com.google.gerrit.server.group.GroupResource resource ) throws com.google.gerrit.extensions.restapi.ResourceNotFoundException { com.google.gerrit.reviewdb.client.AccountGroup group = resource.toAccountGroup ( ) ; if ( group == null ) { throw new com.google.gerrit.extensions.restapi.ResourceNotFoundException ( ) ; } return com.google.common.base.Strings.nullToEmpty ( group.getDescription ( ) ) ; }

Target:
public java.lang.String apply ( com.google.gerrit.server.group.GroupResource resource ) throws com.google.gerrit.extensions.restapi.MethodNotAllowedException { com.google.gerrit.reviewdb.client.AccountGroup group = resource.toAccountGroup ( ) ; if ( group == null ) { throw new com.google.gerrit.extensions.restapi.MethodNotAllowedException ( ) ; } return com.google.common.base.Strings.nullToEmpty ( group.getDescription ( ) ) ; }
Source:
protected static java.io.Writer newWriter ( java.io.OutputStream os , javax.servlet.http.HttpServletResponse res ) throws java.io.IOException { return new java.io.OutputStreamWriter ( os , res.getCharacterEncoding ( ) ) ; }

Target:
protected static java.io.Writer newWriter ( java.io.OutputStream os , javax.servlet.http.HttpServletResponse res ) throws java.io.IOException { return new java.io.BufferedWriter ( new java.io.OutputStreamWriter ( os , res.getCharacterEncoding ( ) ) ) ; }
Source:
private static java.lang.String describe ( com.google.gerrit.server.CurrentUser user ) { if ( user instanceof com.google.gerrit.server.IdentifiedUser ) { return ( ( com.google.gerrit.server.IdentifiedUser ) ( user ) ) . getAccountId ( ) . toString ( ) ; } return user.toString ( ) ; }

Target:
private static java.lang.String describe ( com.google.gerrit.server.CurrentUser user ) { if ( user.isIdentifiedUser ( ) ) { return ( ( com.google.gerrit.server.IdentifiedUser ) ( user ) ) . getAccountId ( ) . toString ( ) ; } return user.toString ( ) ; }
Source:
public int hashCode ( ) { return java.util.Objects.hash ( key , value , granted ) ; }

Target:
public int hashCode ( ) { return java.util.Objects.hash ( key , value , granted , tag ) ; }
Source:
private void setRefLogIdent ( final com.google.gerrit.client.reviewdb.ChangeApproval submitAudit ) { if ( submitAudit != null ) { branchUpdate.setRefLogIdent ( identifiedUserFactory.create ( submitAudit.getAccountId ( ) ) . newPersonIdent ( ) ) ; } }

Target:
private void setRefLogIdent ( final com.google.gerrit.client.reviewdb.PatchSetApproval submitAudit ) { if ( submitAudit != null ) { branchUpdate.setRefLogIdent ( identifiedUserFactory.create ( submitAudit.getAccountId ( ) ) . newPersonIdent ( ) ) ; } }
Source:
void changeSshUserName ( java.lang.String newName , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwtjsonrpc.client.VoidResult > callback ) ;

Target:
void changeUserName ( java.lang.String newName , com.google.gwt.user.client.rpc.AsyncCallback < com.google.gwtjsonrpc.client.VoidResult > callback ) ;
Source:
private void assertCreateFails ( com.google.gerrit.extensions.common.ChangeInfo in , java.lang.Class < ? extends com.google.gerrit.extensions.restapi.RestApiException > errType , java.lang.String errSubstring ) throws java.lang.Exception { exception.expect ( errType ) ; exception.expectMessage ( errSubstring ) ; gApi.changes ( ) . create ( in ) ; }

Target:
private void assertCreateFails ( com.google.gerrit.extensions.common.ChangeInput in , java.lang.Class < ? extends com.google.gerrit.extensions.restapi.RestApiException > errType , java.lang.String errSubstring ) throws java.lang.Exception { exception.expect ( errType ) ; exception.expectMessage ( errSubstring ) ; gApi.changes ( ) . create ( in ) ; }
Source:
public com.google.gerrit.server.IdentifiedUser create ( final com.google.gerrit.client.reviewdb.Account.Id id ) { return new com.google.gerrit.server.IdentifiedUser ( systemConfig , null , null , id ) ; }

Target:
public com.google.gerrit.server.IdentifiedUser create ( final com.google.gerrit.client.reviewdb.Account.Id id ) { return new com.google.gerrit.server.IdentifiedUser ( systemConfig , accountCache , null , null , id ) ; }
Source:
public void reindexEmptySiteWithRecheckMergeable ( ) throws java.lang.Exception { initSite ( ) ; com.google.gerrit.acceptance.pgm.ReindexIT.runGerrit ( "reindex" , "-d" , sitePath.toString ( ) , "--show-stack-trace" , "--recheck-mergeable" ) ; }

Target:
public void reindexEmptySite ( ) throws java.lang.Exception { initSite ( ) ; com.google.gerrit.acceptance.pgm.ReindexIT.runGerrit ( "reindex" , "-d" , sitePath.toString ( ) , "--show-stack-trace" ) ; }
Source:
public WorkQueue.Executor createEmailReviewCommentsExecutor ( @ com.google.gerrit.server.config.GerritServerConfig org.eclipse.jgit.lib.Config config , com.google.gerrit.server.git.WorkQueue queues ) { int poolSize = config.getInt ( "sendemail" , null , "threadPoolSize" , 1 ) ; return queues.createQueue ( poolSize , "EmailReviewComments" ) ; }

Target:
public java.util.concurrent.ExecutorService createEmailReviewCommentsExecutor ( ) { return com.google.common.util.concurrent.MoreExecutors.newDirectExecutorService ( ) ; }
Source:
public com.google.gerrit.common.data.LabelType byId ( java.lang.String id ) { return byId ( ) . get ( id ) ; }

Target:
public com.google.gerrit.common.data.LabelType byLabel ( com.google.gerrit.reviewdb.client.PatchSetApproval.LabelId labelId ) { com.google.gerrit.common.data.LabelType t = byId ( ) . get ( labelId.get ( ) ) ; return t != null ? t : byLabel ( ) . get ( labelId.get ( ) . toLowerCase ( ) ) ; }
Source:
public static org.apache.lucene.index.Term idTerm ( com.google.gerrit.reviewdb.client.Change.Id id ) { return com.google.gerrit.lucene.QueryBuilder.intTerm ( com.google.gerrit.lucene.QueryBuilder.ID_FIELD , id.get ( ) ) ; }

Target:
public static org.apache.lucene.index.Term idTerm ( com.google.gerrit.server.index.Schema < com.google.gerrit.server.query.change.ChangeData > schema , com.google.gerrit.reviewdb.client.Change.Id id ) { return com.google.gerrit.lucene.QueryBuilder.intTerm ( com.google.gerrit.server.query.change.LegacyChangeIdPredicate.idField ( schema ) . getName ( ) , id.get ( ) ) ; }
Source:
public java.lang.String getPluginName ( java.io.File srcFile ) throws java.io.IOException { return com.google.common.base.Objects.firstNonNull ( getGerritPluginName ( srcFile ) , com.google.gerrit.server.plugins.PluginLoader.nameOf ( srcFile ) ) ; }

Target:
public java.lang.String getPluginName ( java.io.File srcFile ) throws java.io.IOException { return com.google.common.base.MoreObjects.firstNonNull ( getGerritPluginName ( srcFile ) , com.google.gerrit.server.plugins.PluginLoader.nameOf ( srcFile ) ) ; }
Source:
public void write ( int c ) throws java.io.IOException { osWriter.write ( c ) ; osWriter.flush ( ) ; }

Target:
public void write ( int c ) throws java.io.IOException { actualBody.write ( c ) ; }
Source:
private com.google.gerrit.server.notedb.ChangeNotesParser newParser ( org.eclipse.jgit.lib.ObjectId tip ) throws java.lang.Exception { return new com.google.gerrit.server.notedb.ChangeNotesParser ( newChange ( ) . getId ( ) , tip , walk , noteUtil , args.metrics ) ; }

Target:
private com.google.gerrit.server.notedb.ChangeNotesParser newParser ( org.eclipse.jgit.lib.ObjectId tip ) throws java.lang.Exception { walk.reset ( ) ; return new com.google.gerrit.server.notedb.ChangeNotesParser ( newChange ( ) . getId ( ) , tip , walk , noteUtil , args.metrics ) ; }
Source:
private boolean sshEnabled ( ) { return downloadConfig.getDownloadSchemes ( ) . contains ( DownloadScheme.SSH ) ; }

Target:
private boolean sshEnabled ( ) { return downloadConfig.getDownloadSchemes ( ) . contains ( CoreDownloadSchemes.SSH ) ; }
Source:
private void postInitPlugins ( ) throws java.lang.Exception { for ( com.google.gerrit.pgm.init.InitStep initStep : pluginLoader.getInitSteps ( ) ) { initStep.postRun ( ) ; } }

Target:
private void postInitPlugins ( ) throws java.lang.Exception { for ( com.google.gerrit.pgm.init.api.InitStep initStep : pluginLoader.getInitSteps ( ) ) { initStep.postRun ( ) ; } }
Source:
public void remove ( K key ) { self.remove ( key ) ; }

Target:
public com.google.common.util.concurrent.ListenableFuture < java.lang.Void > removeAsync ( K key ) { return self.removeAsync ( key ) ; }
Source:
public void noNotificationForChangeThatIsTurnedPrivateForWatchersInNotifyConfig ( ) 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 ) ) ; BRANCH ( efc835 ) ; com.google.gerrit.acceptance.server.project.Fix notifications ; com.google.gerrit.acceptance.server.project.comments on ; com.google.gerrit.acceptance.server.project.patch sets ; 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%private" ) ; 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 ( ) ; }

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 com.googlesrouce.gerrit.plugins.github.git.GHContent getReadme ( ) throws java.lang.Exception { return ghRepository.getReadme ( ) ; }

Target:
public com.googlesource.gerrit.plugins.github.git.GHContent getReadme ( ) throws java.lang.Exception { return ghRepository.getReadme ( ) ; }
Source:
public void tearDown ( ) { com.google.gerrit.testutil.TestTimeUtil.useSystemTime ( ) ; }

Target:
public void tearDown ( ) { com.google.gerrit.testing.TestTimeUtil.useSystemTime ( ) ; }
Source:
public com.google.gerrit.server.CurrentUser getCurrentUser ( ) { return user ; }

Target:
public com.google.gerrit.server.CurrentUser getUser ( ) { return user ; }
Source:
public static final void uploadImage ( java.lang.String imageData , java.lang.String fileName ) { com.googlesource.gerrit.plugins.imagare.client.ImageUploader.uploadImage ( "All-Projects" , imageData , fileName ) ; }

Target:
public static final void uploadImage ( java.lang.String imageData , java.lang.String fileName ) { com.googlesource.gerrit.plugins.imagare.client.ImageUploader.uploadImage ( ImageUploadScreen.projectBox.getValue ( ) , imageData , fileName ) ; }
Source:
public com.googlesource.gerrit.plugins.lfs.LfsBackend getBackend ( ) { return cfg.getEnum ( "storage" , null , "backend" , LfsBackend.FS ) ; }

Target:
public com.googlesource.gerrit.plugins.lfs.LfsBackend getDefaultBackend ( ) { com.googlesource.gerrit.plugins.lfs.LfsBackendType type = cfg.getEnum ( "storage" , null , "backend" , LfsBackendType.FS ) ; return new com.googlesource.gerrit.plugins.lfs.LfsBackend ( null , type ) ; }
Source:
public void deleteGroups ( java.lang.String ... groups ) throws com.google.gerrit.extensions.restapi.RestApiException { try { deleteGroups.apply ( rsrc , AddIncludedGroups.Input.fromGroups ( java.util.Arrays.asList ( groups ) ) ) ; } catch ( com.google.gwtorm.server.OrmException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot delete group members" , e ) ; } }

Target:
public void removeMembers ( java.lang.String ... members ) throws com.google.gerrit.extensions.restapi.RestApiException { try { deleteMembers.apply ( rsrc , AddMembers.Input.fromMembers ( java.util.Arrays.asList ( members ) ) ) ; } catch ( com.google.gwtorm.server.OrmException e ) { throw new com.google.gerrit.extensions.restapi.RestApiException ( "Cannot remove group members" , e ) ; } }
Source:
public int hashCode ( ) { return java.util.Objects.hash ( change.getId ( ) , changeMessages.keySet ( ) , patchSets.keySet ( ) , patchSetApprovals.keySet ( ) , patchLineComments.keySet ( ) ) ; }

Target:
public int hashCode ( ) { return java.util.Objects.hash ( change.getId ( ) , normalizeChangeMessages ( ) , patchSets.keySet ( ) , patchSetApprovals.keySet ( ) , patchLineComments.keySet ( ) ) ; }
Source:
public void matchesEmailDomain ( ) throws java.lang.Exception { com.google.gitiles.IdentRevFilter filter = com.google.gitiles.IdentRevFilter.author ( "eSt" ) ; org.junit.Assert.assertTrue ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@eSt.com" ) ) ) ; org.junit.Assert.assertTrue ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@eStablish.com" ) ) ) ; org.junit.Assert.assertTrue ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@teSt.com" ) ) ) ; org.junit.Assert.assertTrue ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@teSting.com" ) ) ) ; }

Target:
public void matchesEmailDomain ( ) throws java.lang.Exception { com.google.gitiles.IdentRevFilter filter = com.google.gitiles.IdentRevFilter.author ( "eSt" ) ; com.google.common.truth.Truth.assertThat ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@eSt.com" ) ) ) . isTrue ( ) ; com.google.common.truth.Truth.assertThat ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@eStablish.com" ) ) ) . isTrue ( ) ; com.google.common.truth.Truth.assertThat ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@teSt.com" ) ) ) . isTrue ( ) ; com.google.common.truth.Truth.assertThat ( filter.matchesPerson ( new org.eclipse.jgit.lib.PersonIdent ( "null" , "null@teSting.com" ) ) ) . isTrue ( ) ; }
Source:
private com.google.gerrit.client.change.RelatedChangesTab getTab ( ) { if ( ( conflictingChangesTab ) == null ) { conflictingChangesTab = createTab ( Resources.C.conflictingChanges ( ) , Resources.C.conflictingChangesTooltip ( ) ) ; conflictingChangesTab.registerKeys ( ) ; } return conflictingChangesTab ; }

Target:
private com.google.gerrit.client.change.RelatedChangesTab getTab ( ) { if ( ( sameTopicTab ) == null ) { sameTopicTab = createTab ( Resources.C.sameTopic ( ) , Resources.C.sameTopicTooltip ( ) ) ; } return sameTopicTab ; }
Source:
public com.google.gerrit.server.query.Predicate < T > parse ( final java.lang.String query ) throws com.google.gerrit.server.query.QueryParseException { return toPredicate ( com.google.gerrit.server.query.QueryParser.parse ( query ) ) ; }

Target:
public com.google.gerrit.server.query.Predicate < T > parse ( final java.lang.String query ) throws com.google.gerrit.server.query.QueryParseException { if ( com.google.common.base.Strings.isNullOrEmpty ( query ) ) { throw new com.google.gerrit.server.query.QueryParseException ( "query is empty" ) ; } return toPredicate ( com.google.gerrit.server.query.QueryParser.parse ( query ) ) ; }
Source:
protected void formatChange ( ) throws com.google.gerrit.common.errors.EmailException { appendText ( textTemplate ( "Merged" ) ) ; }

Target:
protected void formatChange ( ) throws com.google.gerrit.common.errors.EmailException { appendText ( textTemplate ( "Merged" ) ) ; if ( useHtml ( ) ) { appendHtml ( soyHtmlTemplate ( "MergedHtml" ) ) ; } }
Source:
private boolean isProjectStatePermittingRead ( ) { return ( getProjectControl ( ) . getProject ( ) . getState ( ) . equals ( ProjectState.READ_ONLY ) ) || ( isProjectStatePermittingWrite ( ) ) ; }

Target:
private boolean isProjectStatePermittingRead ( ) { return getProjectControl ( ) . getProject ( ) . getState ( ) . permitsRead ( ) ; }
Source:
public Response.Action getDownloadAction ( org.eclipse.jgit.lfs.lib.AnyLongObjectId id ) { org.eclipse.jgit.lfs.server.Response.Action action = super . getDownloadAction ( id ) ; com.googlesource.gerrit.plugins.lfs.LfsAuthTokenHandler.Token token = authorizer.generateToken ( com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.DOWNLOAD , id , expirationSeconds ) ; return new com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.ExpiringAction ( action.href , token ) ; }

Target:
public Response.Action getDownloadAction ( org.eclipse.jgit.lfs.lib.AnyLongObjectId id ) { org.eclipse.jgit.lfs.server.Response.Action action = super . getDownloadAction ( id ) ; com.googlesource.gerrit.plugins.lfs.AuthInfo authInfo = authorizer.generateAuthInfo ( com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.DOWNLOAD , id , expirationSeconds ) ; return new com.googlesource.gerrit.plugins.lfs.ExpiringAction ( action.href , authInfo ) ; }
Source:
private static < T > com.google.gwtorm.jdbc.gen.GeneratedClassLoader newLoader ( final java.lang.Class < T > type ) { return new com.google.gwtorm.jdbc.gen.GeneratedClassLoader ( type.getClassLoader ( ) ) ; }

Target:
private static < T > com.google.gwtorm.server.GeneratedClassLoader newLoader ( final java.lang.Class < T > type ) { return new com.google.gwtorm.server.GeneratedClassLoader ( type.getClassLoader ( ) ) ; }
Source:
private final native void setThemeRaw ( java.lang.String i ) ;

Target:
public final native void matchBrackets ( java.lang.Boolean m ) ;
Source:
private static com.google.gerrit.server.query.change.ChangeData change ( java.lang.String ... files ) { java.util.Arrays.sort ( files ) ; com.google.gerrit.server.query.change.ChangeData cd = new com.google.gerrit.server.query.change.ChangeData ( new com.google.gerrit.reviewdb.client.Change.Id ( 1 ) ) ; cd.setCurrentFilePaths ( files ) ; return cd ; }

Target:
private static com.google.gerrit.server.query.change.ChangeData change ( java.lang.String ... files ) { java.util.Arrays.sort ( files ) ; com.google.gerrit.server.query.change.ChangeData cd = new com.google.gerrit.server.query.change.ChangeData ( new com.google.gerrit.reviewdb.client.Change.Id ( 1 ) ) ; cd.setCurrentFilePaths ( java.util.Arrays.asList ( files ) ) ; return cd ; }
Source:
public Response.Action getUploadAction ( org.eclipse.jgit.lfs.lib.AnyLongObjectId id , long size ) { org.eclipse.jgit.lfs.server.Response.Action action = super . getUploadAction ( id , size ) ; com.googlesource.gerrit.plugins.lfs.LfsAuthTokenHandler.Token token = authorizer.generateToken ( com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.UPLOAD , id , expirationSeconds ) ; return new com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.ExpiringAction ( action.href , token ) ; }

Target:
public Response.Action getUploadAction ( org.eclipse.jgit.lfs.lib.AnyLongObjectId id , long size ) { org.eclipse.jgit.lfs.server.Response.Action action = super . getUploadAction ( id , size ) ; com.googlesource.gerrit.plugins.lfs.AuthInfo authInfo = authorizer.generateAuthInfo ( com.googlesource.gerrit.plugins.lfs.fs.LocalLargeFileRepository.UPLOAD , id , expirationSeconds ) ; return new com.googlesource.gerrit.plugins.lfs.ExpiringAction ( action.href , authInfo ) ; }
Source:
void onMatchBrackets ( com.google.gwt.event.logical.shared.ValueChangeEvent < java.lang.Boolean > e ) { prefs.matchBrackets ( e.getValue ( ) ) ; if ( ( view ) != null ) { view.getEditor ( ) . setOption ( "matchBrackets" , prefs.matchBrackets ( ) ) ; } }

Target:
void onMatchBrackets ( com.google.gwt.event.logical.shared.ValueChangeEvent < java.lang.Boolean > e ) { prefs.matchBrackets ( e.getValue ( ) ) ; if ( ( view ) != null ) { view.setOption ( "matchBrackets" , prefs.matchBrackets ( ) ) ; } }
Source:
protected java.util.Set < com.google.gerrit.reviewdb.AccountGroup.Id > missing ( final java.lang.String key ) { return java.util.Collections.emptySet ( ) ; }

Target:
public java.util.Set < com.google.gerrit.reviewdb.AccountGroup.Id > missing ( final java.lang.String key ) { return java.util.Collections.emptySet ( ) ; }
Source:
public void testOwnerGroupsWhenNotConfigured ( ) { com.google.common.truth.Truth.assertThat ( repoCfg.getOwnerGroups ( new com.google.gerrit.reviewdb.client.Project.NameKey ( "someProject" ) ) ) . isEqualTo ( new java.lang.String [ ] { } ) ; }

Target:
public void testOwnerGroupsWhenNotConfigured ( ) { com.google.common.truth.Truth.assertThat ( repoCfg.getOwnerGroups ( new com.google.gerrit.reviewdb.client.Project.NameKey ( "someProject" ) ) ) . isEmpty ( ) ; }
Source:
private void failAndThrow ( com.google.gerrit.reviewdb.client.Change change , java.lang.RuntimeException e ) { fail ( change , e ) ; throw e ; }

Target:
private void failAndThrow ( com.google.gerrit.reviewdb.client.Project.NameKey project , java.lang.RuntimeException e ) { fail ( project , e ) ; throw e ; }
Source:
public java.util.List < com.google.gerrit.reviewdb.client.PatchSetApproval > allApprovals ( com.google.inject.Provider < com.google.gerrit.reviewdb.server.ReviewDb > db ) throws com.google.gwtorm.server.OrmException { return com.google.common.collect.ImmutableList.copyOf ( allApprovalsMap ( db ) . values ( ) ) ; }

Target:
public java.util.List < com.google.gerrit.reviewdb.client.PatchSetApproval > allApprovals ( ) throws com.google.gwtorm.server.OrmException { return com.google.common.collect.ImmutableList.copyOf ( allApprovalsMap ( ) . values ( ) ) ; }
Source:
protected static com.google.gerrit.server.query.change.ChangeData newChangeData ( com.google.gerrit.server.mail.EmailArguments ea , com.google.gerrit.reviewdb.client.Change.Id id ) { return ea.changeDataFactory.create ( ea.db.get ( ) , id ) ; }

Target:
protected static com.google.gerrit.server.query.change.ChangeData newChangeData ( com.google.gerrit.server.mail.EmailArguments ea , com.google.gerrit.reviewdb.client.Project.NameKey project , com.google.gerrit.reviewdb.client.Change.Id id ) { return ea.changeDataFactory.create ( ea.db.get ( ) , project , id ) ; }
Source:
private static void initDisableUnwantedKeys ( ) { for ( java.lang.String s : new java.lang.String [ ] { "C" , "J" , "K" , "O" , "R" , "U" , "Ctrl-C" , "Enter" } ) { net.codemirror.lib.CodeMirror.disableUnwantedKey ( "vim" , s ) ; } }

Target:
private static void initDisableUnwantedKeys ( ) { for ( java.lang.String s : new java.lang.String [ ] { "C" , "J" , "K" , "O" , "R" , "U" , "Ctrl-C" } ) { net.codemirror.lib.CodeMirror.disableUnwantedKey ( "vim" , s ) ; } }
Source:
public java.util.List < com.google.gerrit.common.data.SubmitRecord > getSubmitRecords ( com.google.gerrit.reviewdb.server.ReviewDb db , com.google.gerrit.reviewdb.client.PatchSet patchSet ) { return canSubmit ( db , patchSet , null , false , true ) ; }

Target:
public java.util.List < com.google.gerrit.common.data.SubmitRecord > getSubmitRecords ( com.google.gerrit.reviewdb.server.ReviewDb db , com.google.gerrit.reviewdb.client.PatchSet patchSet ) { return canSubmit ( db , patchSet , null , false , true , false ) ; }
Source:
public void resetDomainValidator ( ) throws java.lang.Exception { java.lang.Class < ? > c = java.lang.Class.forName ( "org.apache.commons.validator.routines.DomainValidator" ) ; java.lang.reflect.Field f = c.getDeclaredField ( "inUse" ) ; f.setAccessible ( true ) ; f.setBoolean ( c , false ) ; }

Target:
private static void resetDomainValidator ( ) throws java.lang.Exception { java.lang.Class < ? > c = java.lang.Class.forName ( "org.apache.commons.validator.routines.DomainValidator" ) ; java.lang.reflect.Field f = c.getDeclaredField ( "inUse" ) ; f.setAccessible ( true ) ; f.setBoolean ( c , false ) ; }
Source:
protected static java.lang.String padTwo ( final int v ) { if ( v < 10 ) { return "0" + v ; } else { return java.lang.String.valueOf ( v ) ; } }

Target:
protected static java.lang.String padTwo ( final int v ) { if ( v < 10 ) { return "0" + v ; } return java.lang.String.valueOf ( v ) ; }
Source:
private org.eclipse.jgit.revwalk.RevWalk getRevWalk ( ) throws java.io.IOException { initRepository ( ) ; return revWalk ; }

Target:
protected org.eclipse.jgit.revwalk.RevWalk getRevWalk ( ) throws java.io.IOException { initRepository ( ) ; return revWalk ; }