auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
public java.lang.String toString ( ) { return java.lang.String.format ( ( "%s, rollbackOnFailure = %s, conectivityTimeout = %s, hostNetworkQosSupported = %s, %n" + ( ( ( "\tnetworks = %s,%n" + "\tremovedNetworks=%s,%n" ) + "\tbonds=%s,%n" ) + "\tremovedBonds=%s" ) ) , super . toString ( ) , isRollbackOnFailure ( ) , getConectivityTimeout ( ) , getHostNetworkQosSupported ( ) , org.ovirt.engine.core.common.businessentities.Entities.collectionToString ( getNetworks ( ) , "\t\t" ) , getRemovedNetworks ( ) , org.ovirt.engine.core.common.businessentities.Entities.collectionToString ( getBonds ( ) , "\t\t" ) , getRemovedBonds ( ) ) ; }

Target:
protected org.ovirt.engine.core.common.utils.ToStringBuilder appendAttributes ( org.ovirt.engine.core.common.utils.ToStringBuilder tsb ) { return super . appendAttributes ( tsb ) . append ( "rollbackOnFailure" , isRollbackOnFailure ( ) ) . append ( "conectivityTimeout" , getConectivityTimeout ( ) ) . append ( "hostNetworkQosSupported" , getHostNetworkQosSupported ( ) ) . append ( "networks" , org.ovirt.engine.core.common.businessentities.Entities.collectionToString ( getNetworks ( ) , "\t\t" ) ) . append ( "removedNetworks" , getRemovedNetworks ( ) ) . append ( "bonds" , org.ovirt.engine.core.common.businessentities.Entities.collectionToString ( getBonds ( ) , "\t\t" ) ) . append ( "removedBonds" , getBonds ( ) ) ; }
Source:
public void testRemove ( ) { org.ovirt.engine.core.common.businessentities.network.HostNicVfsConfig result = dao.get ( FixturesTool.HOST_NIC_VFS_CONFIG_ALL_NETWORKS_ALLOWED ) ; org.junit.Assert.assertNotNull ( result ) ; dao.remove ( result.getId ( ) ) ; result = dao.get ( FixturesTool.HOST_NIC_VFS_CONFIG_ALL_NETWORKS_ALLOWED ) ; org.junit.Assert.assertNull ( result ) ; }

Target:
public void testRemoveLabel ( ) { org.ovirt.engine.core.common.businessentities.network.HostNicVfsConfig vfsConfig = dao.get ( FixturesTool.HOST_NIC_VFS_CONFIG_NOT_ALL_NETWORKS_ALLOWED_2 ) ; checkLabels ( vfsConfig , 3 ) ; dao.removeLabel ( FixturesTool.HOST_NIC_VFS_CONFIG_NOT_ALL_NETWORKS_ALLOWED_2 , vfsConfig.getNetworkLabels ( ) . iterator ( ) . next ( ) ) ; vfsConfig = dao.get ( FixturesTool.HOST_NIC_VFS_CONFIG_NOT_ALL_NETWORKS_ALLOWED_2 ) ; checkLabels ( vfsConfig , 2 ) ; }
Source:
public java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > runMultipleActions ( org.ovirt.engine.core.common.action.VdcActionType actionType , java.util.ArrayList < org.ovirt.engine.core.common.action.VdcActionParametersBase > parameters , boolean isRunOnlyIfAllCanDoPass ) { org.ovirt.engine.core.common.action.VdcReturnValueBase returnValue = notAllowToRunAction ( actionType ) ; if ( returnValue != null ) { java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > list = new java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > ( ) ; list.add ( returnValue ) ; return list ; } else { return runMultipleActionsImpl ( actionType , parameters , false , isRunOnlyIfAllCanDoPass ) ; } }

Target:
public java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > runMultipleActions ( org.ovirt.engine.core.common.action.VdcActionType actionType , java.util.ArrayList < org.ovirt.engine.core.common.action.VdcActionParametersBase > parameters , boolean isRunOnlyIfAllCanDoPass , boolean waitForResult ) { org.ovirt.engine.core.common.action.VdcReturnValueBase returnValue = notAllowToRunAction ( actionType ) ; if ( returnValue != null ) { java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > list = new java.util.ArrayList < org.ovirt.engine.core.common.action.VdcReturnValueBase > ( ) ; list.add ( returnValue ) ; return list ; } else { return runMultipleActionsImpl ( actionType , parameters , false , isRunOnlyIfAllCanDoPass , waitForResult ) ; } }
Source:
public void validateFailsForGlusterServerWhenNoUpServer ( ) throws java.lang.Exception { setupGlusterMock ( true , null , false ) ; org.junit.Assert.assertFalse ( command.validate ( ) ) ; org.junit.Assert.assertTrue ( command.getReturnValue ( ) . getValidationMessages ( ) . contains ( EngineMessage.ACTION_TYPE_FAILED_NO_GLUSTER_HOST_TO_PEER_PROBE.toString ( ) ) ) ; }

Target:
public void validateFailsForGlusterServerWhenNoUpServer ( ) throws java.lang.Exception { setupGlusterMock ( true , null , false ) ; org.junit.jupiter.api.Assertions.assertFalse ( command.validate ( ) ) ; org.junit.jupiter.api.Assertions.assertTrue ( command.getReturnValue ( ) . getValidationMessages ( ) . contains ( EngineMessage.ACTION_TYPE_FAILED_NO_GLUSTER_HOST_TO_PEER_PROBE.toString ( ) ) ) ; }
Source:
public void legalTimedOut ( ) { final org.ovirt.engine.core.dal.dbbroker.auditloghandling.TimeoutBaseTest.TestTimeoutBase t = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.TimeoutBaseTest.TestTimeoutBase ( ) ; t.setUseTimout ( true ) ; long c = java.lang.System.currentTimeMillis ( ) ; c -= 1 ; final java.util.Date d = new java.util.Date ( c ) ; t.setEndTime ( d ) ; final java.lang.String s = "timeout" ; t.setTimeoutObjectId ( s ) ; t.getLegal ( ) ; final boolean result = t.getLegal ( ) ; org.junit.Assert.assertTrue ( result ) ; }

Target:
public void legalTimedOut ( ) { final org.ovirt.engine.core.dal.dbbroker.auditloghandling.TimeoutBaseTest.TestTimeoutBase t = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.TimeoutBaseTest.TestTimeoutBase ( ) ; t.setUseTimout ( true ) ; long c = java.lang.System.currentTimeMillis ( ) ; c -= 1000 ; final java.util.Date d = new java.util.Date ( c ) ; t.setEndTime ( d ) ; final java.lang.String s = "timeout" ; t.setTimeoutObjectId ( s ) ; t.getLegal ( ) ; final boolean result = t.getLegal ( ) ; org.junit.Assert.assertTrue ( result ) ; }
Source:
public void setInSlot ( java.lang.Object slot , com.google.gwt.user.client.ui.IsWidget content ) { if ( slot == ( org.ovirt.engine.ui.webadmin.section.main.presenter.MainContentPresenter.TYPE_SetContent ) ) { if ( content instanceof org.ovirt.engine.ui.webadmin.section.main.presenter.AbstractOverlayPresenter ) { com.google.gwt.user.client.ui.IsWidget currentContent = getCurrentContent ( ) ; if ( ! ( currentContent instanceof org.ovirt.engine.ui.webadmin.section.main.presenter.AbstractOverlayPresenter ) ) { nonOverlayContent = currentContent ; } } setPanelContent ( contentContainer , content ) ; } else { super . setInSlot ( slot , content ) ; } }

Target:
public void setInSlot ( java.lang.Object slot , com.google.gwt.user.client.ui.IsWidget content ) { if ( slot == ( org.ovirt.engine.ui.webadmin.section.main.presenter.MainContentPresenter.TYPE_SetContent ) ) { if ( content instanceof org.ovirt.engine.ui.webadmin.section.main.presenter.AbstractOverlayPresenter ) { com.google.gwt.user.client.ui.IsWidget currentContent = getCurrentContent ( ) ; if ( ! ( currentContent instanceof org.gwtbootstrap3.client.ui.Container ) ) { nonOverlayContent = currentContent ; } } setPanelContent ( contentContainer , content ) ; } else { super . setInSlot ( slot , content ) ; } }
Source:
public void refuseBalloonOnPPC ( ) { setupCanAddPpcTest ( ) ; cmd.getParameters ( ) . setBalloonEnabled ( true ) ; org.mockito.Mockito.when ( osRepository.isBalloonEnabled ( cmd.getParameters ( ) . getVm ( ) . getVmOsId ( ) , cmd.getCluster ( ) . getCompatibilityVersion ( ) ) ) . thenReturn ( false ) ; cmd.init ( ) ; org.ovirt.engine.core.bll.ValidateTestUtils.runAndAssertValidateFailure ( cmd , EngineMessage.BALLOON_REQUESTED_ON_NOT_SUPPORTED_ARCH ) ; }

Target:
public void refuseBalloonOnPPC ( ) { setupCanAddPpcTest ( ) ; cmd.getParameters ( ) . setBalloonEnabled ( true ) ; org.mockito.Mockito.doNothing ( ) . when ( cmd ) . initTemplateDisks ( ) ; cmd.init ( ) ; org.ovirt.engine.core.bll.ValidateTestUtils.runAndAssertValidateFailure ( cmd , EngineMessage.BALLOON_REQUESTED_ON_NOT_SUPPORTED_ARCH ) ; }
Source:
protected org.ovirt.engine.api.model.Disk getEntity ( int index ) { org.ovirt.engine.core.common.businessentities.DiskImage entity = new org.ovirt.engine.core.common.businessentities.DiskImage ( ) ; entity.setId ( GUIDS [ index ] ) ; entity.setvolumeFormat ( VolumeFormat.RAW ) ; entity.setDiskInterface ( DiskInterface.VirtIO ) ; entity.setImageStatus ( ImageStatus.OK ) ; entity.setVolumeType ( VolumeType.Sparse ) ; entity.setBoot ( false ) ; entity.setShareable ( false ) ; entity.setPropagateErrors ( PropagateErrors.On ) ; return org.ovirt.engine.api.restapi.resource.BackendDiskResourceTest.setUpStatisticalEntityExpectations ( entity ) ; }

Target:
protected org.ovirt.engine.api.model.Disk getEntity ( int index ) { org.ovirt.engine.core.common.businessentities.DiskImage entity = new org.ovirt.engine.core.common.businessentities.DiskImage ( ) ; entity.setId ( GUIDS [ index ] ) ; entity.setImageId ( GUIDS [ 1 ] ) ; entity.setvolumeFormat ( VolumeFormat.RAW ) ; entity.setDiskInterface ( DiskInterface.VirtIO ) ; entity.setImageStatus ( ImageStatus.OK ) ; entity.setVolumeType ( VolumeType.Sparse ) ; entity.setBoot ( false ) ; entity.setShareable ( false ) ; entity.setPropagateErrors ( PropagateErrors.On ) ; return org.ovirt.engine.api.restapi.resource.BackendDiskResourceTest.setUpStatisticalEntityExpectations ( entity ) ; }
Source:
private org.ovirt.engine.core.common.action.AddSANStorageDomainParameters getSanAddParams ( org.ovirt.engine.core.common.businessentities.storage_domain_static entity , org.ovirt.engine.core.compat.Guid hostId , java.util.ArrayList < java.lang.String > lunIds ) { org.ovirt.engine.core.common.action.AddSANStorageDomainParameters params = new org.ovirt.engine.core.common.action.AddSANStorageDomainParameters ( entity ) ; params.setVdsId ( hostId ) ; params.setLunIds ( lunIds ) ; return params ; }

Target:
private org.ovirt.engine.core.common.action.AddSANStorageDomainParameters getSanAddParams ( org.ovirt.engine.core.common.businessentities.storage_domain_static entity , org.ovirt.engine.core.compat.Guid hostId , java.util.ArrayList < java.lang.String > lunIds , boolean force ) { org.ovirt.engine.core.common.action.AddSANStorageDomainParameters params = new org.ovirt.engine.core.common.action.AddSANStorageDomainParameters ( entity ) ; params.setVdsId ( hostId ) ; params.setLunIds ( lunIds ) ; params.setForce ( force ) ; return params ; }
Source:
public java.util.List < org.ovirt.engine.core.common.businessentities.VDSGroup > getAll ( ) { org.springframework.jdbc.core.namedparam.MapSqlParameterSource parameterSource = getCustomMapSqlParameterSource ( ) ; return getCallsHandler ( ) . executeReadList ( "GetAllFromVdsGroups" , org.ovirt.engine.core.dao.VdsGroupDAODbFacadeImpl.VdsGroupRowMapper.instance , parameterSource ) ; }

Target:
public java.util.List < org.ovirt.engine.core.common.businessentities.VDSGroup > getAll ( org.ovirt.engine.core.compat.Guid userID , boolean isFiltered ) { org.springframework.jdbc.core.namedparam.MapSqlParameterSource parameterSource = getCustomMapSqlParameterSource ( ) . addValue ( "user_id" , userID ) . addValue ( "is_filtered" , isFiltered ) ; return getCallsHandler ( ) . executeReadList ( "GetAllFromVdsGroups" , org.ovirt.engine.core.dao.VdsGroupDAODbFacadeImpl.VdsGroupRowMapper.instance , parameterSource ) ; }
Source:
public void validateFailsWithArbiterWithClusterDoesNotArbiterVolume ( ) { setVolume ( getVolume ( 3 , false , GlusterVolumeType.REPLICATE , 3 , true ) ) ; org.mockito.Mockito.doReturn ( getCluster ( true , Version.v4_0 ) ) . when ( clusterDao ) . get ( org.mockito.Matchers.any ( org.ovirt.engine.core.compat.Guid.class ) ) ; org.ovirt.engine.core.bll.ValidateTestUtils.runAndAssertValidateFailure ( cmd , EngineMessage.ACTION_TYPE_FAILED_GLUSTER_ARBITER_VOLUME_NOT_SUPPORTED ) ; }

Target:
public void validateFailsWithArbiterWithClusterDoesNotArbiterVolume ( ) { setVolume ( getVolume ( 3 , false , GlusterVolumeType.REPLICATE , 3 , true ) ) ; org.mockito.Mockito.doReturn ( getCluster ( true , Version.v4_0 ) ) . when ( clusterDao ) . get ( org.mockito.ArgumentMatchers.any ( org.ovirt.engine.core.compat.Guid.class ) ) ; org.ovirt.engine.core.bll.ValidateTestUtils.runAndAssertValidateFailure ( cmd , EngineMessage.ACTION_TYPE_FAILED_GLUSTER_ARBITER_VOLUME_NOT_SUPPORTED ) ; }
Source:
public java.lang.Void call ( ) throws org.ovirt.vdsm.jsonrpc.client.ClientConnectionException { client.updateInterestedOps ( ) ; return null ; }

Target:
private void updateOps ( byte [ ] message ) { if ( org.ovirt.vdsm.jsonrpc.client.reactors.stomp.StompCommonClient.LOG.isDebugEnabled ( ) ) { try { org.ovirt.vdsm.jsonrpc.client.reactors.stomp.StompCommonClient.LOG.debug ( ( "Message sent: " + ( org.ovirt.vdsm.jsonrpc.client.reactors.stomp.impl.Message.parse ( message ) ) ) ) ; } catch ( org.ovirt.vdsm.jsonrpc.client.ClientConnectionException ignored ) { } } final org.ovirt.vdsm.jsonrpc.client.reactors.ReactorClient client = this ; scheduleTask ( ( ) -> { client.updateInterestedOps ( ) ; return null ; } ) ; }
Source:
public void getExternalNetworkMap ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid providerId ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { if ( source == null ) { return new java.util.HashMap < org.ovirt.engine.core.common.businessentities.network.Network , java.util.Set < org.ovirt.engine.core.compat.Guid > > ( ) ; } return source ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllExternalNetworksOnProvider , new org.ovirt.engine.core.common.queries.IdQueryParameters ( providerId ) , aQuery ) ; }

Target:
public void getExternalNetworkMap ( org.ovirt.engine.ui.frontend.AsyncQuery < java.util.Map < org.ovirt.engine.core.common.businessentities.network.Network , java.util.Set < org.ovirt.engine.core.compat.Guid > > > aQuery , org.ovirt.engine.core.compat.Guid providerId ) { aQuery.converterCallback = new org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.MapConverter < > ( ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllExternalNetworksOnProvider , new org.ovirt.engine.core.common.queries.IdQueryParameters ( providerId ) , aQuery ) ; }
Source:
public void setNotSelected ( boolean vmIsUp ) { vmStatus.setStyleName ( style.machineStatusStyle ( ) ) ; if ( vmIsUp ) { mainContainer.setStyleName ( style.itemRunningStyle ( ) ) ; } else { mainContainer.setStyleName ( style.itemNotRunningStyle ( ) ) ; } }

Target:
public void setNotSelected ( boolean vmIsUp , boolean consoleInUse ) { vmStatus.setStyleName ( style.machineStatusStyle ( ) ) ; if ( vmIsUp && ( ! consoleInUse ) ) { setVmUpStyle ( ) ; } else { setVmDownStyle ( ) ; } }
Source:
public static void getStorageDomainList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.StorageDomain > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.StorageDomain > ( ) ; } } ; org.ovirt.engine.core.common.queries.SearchParameters searchParams = new org.ovirt.engine.core.common.queries.SearchParameters ( "Storage:" , org.ovirt.engine.core.common.interfaces.SearchType.StorageDomain ) ; searchParams.setMaxCount ( 9999 ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.Search , searchParams , aQuery ) ; }

Target:
public static void getCPUList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Version version ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.ServerCpu > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.ServerCpu > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllServerCpuList , new org.ovirt.engine.core.common.queries.GetAllServerCpuListParameters ( version ) , aQuery ) ; }
Source:
public void successfulFenceWithSameProxyRetry ( ) { mockProxyHost ( false ) ; mockFenceFailure ( true ) ; org.ovirt.engine.core.common.businessentities.FenceAgent agent = createAgent ( ) ; org.ovirt.engine.core.common.vdscommands.VDSFenceReturnValue result = executor.fence ( FenceActionType.Start , agent ) ; org.junit.Assert.assertTrue ( result.getSucceeded ( ) ) ; org.mockito.Mockito.verify ( proxyLocator ) . findProxyHost ( true , org.ovirt.engine.core.bll.FenceExecutorTest.PROXY_HOST_ID ) ; }

Target:
public void successfulFenceWithSameProxyRetry ( ) { mockProxyHost ( false ) ; mockFenceFailure ( true ) ; org.ovirt.engine.core.common.businessentities.FenceAgent agent = createAgent ( ) ; org.ovirt.engine.core.common.vdscommands.VDSFenceReturnValue result = executor.fence ( FenceActionType.START , agent ) ; org.junit.Assert.assertTrue ( result.getSucceeded ( ) ) ; org.mockito.Mockito.verify ( proxyLocator ) . findProxyHost ( true , org.ovirt.engine.core.bll.FenceExecutorTest.PROXY_HOST_ID ) ; }
Source:
protected boolean validateQuota ( ) { getParameters ( ) . setQuotaId ( org.ovirt.engine.core.bll.QuotaHelper.getInstance ( ) . getQuotaIdToConsume ( getVm ( ) . getStaticData ( ) . getQuotaId ( ) , getStoragePool ( ) ) ) ; for ( org.ovirt.engine.core.common.businessentities.Disk dit : getVm ( ) . getDiskMap ( ) . values ( ) ) { ( ( org.ovirt.engine.core.common.businessentities.DiskImage ) ( dit ) ) . setQuotaId ( org.ovirt.engine.core.bll.QuotaHelper.getInstance ( ) . getQuotaIdToConsume ( getVm ( ) . getStaticData ( ) . getQuotaId ( ) , getStoragePool ( ) ) ) ; } return true ; }

Target:
public boolean validateAndSetQuota ( ) { if ( getQuotaManager ( ) . validateQuotaForStoragePool ( getStoragePool ( ) , getVdsGroupId ( ) , getQuotaId ( ) , getReturnValue ( ) . getCanDoActionMessages ( ) ) ) { return getQuotaManager ( ) . validateAndSetStorageQuota ( getStoragePool ( ) , getStorageQuotaListParameters ( ) , getReturnValue ( ) . getCanDoActionMessages ( ) ) ; } return false ; }
Source:
public void executeCommandWhenFailed ( ) { setVolume ( volumeWithRemoveBricksTask ) ; mockBackend ( false , EngineError.GlusterVolumeRemoveBricksCommitFailed ) ; org.junit.Assert.assertTrue ( cmd.validate ( ) ) ; cmd.executeCommand ( ) ; org.mockito.Mockito.verify ( cmd , org.mockito.Mockito.never ( ) ) . endStepJobCommitted ( ) ; org.mockito.Mockito.verify ( cmd , org.mockito.Mockito.never ( ) ) . releaseVolumeLock ( ) ; org.junit.Assert.assertEquals ( AuditLogType.GLUSTER_VOLUME_REMOVE_BRICKS_COMMIT_FAILED , cmd.getAuditLogTypeValue ( ) ) ; }

Target:
public void executeCommandWhenFailed ( ) { setVolume ( volumeWithRemoveBricksTask ) ; mockBackend ( false , EngineError.GlusterVolumeRemoveBricksCommitFailed ) ; org.junit.jupiter.api.Assertions.assertTrue ( cmd.validate ( ) ) ; cmd.executeCommand ( ) ; org.mockito.Mockito.verify ( cmd , org.mockito.Mockito.never ( ) ) . endStepJobCommitted ( ) ; org.mockito.Mockito.verify ( cmd , org.mockito.Mockito.never ( ) ) . releaseVolumeLock ( ) ; org.junit.jupiter.api.Assertions.assertEquals ( AuditLogType.GLUSTER_VOLUME_REMOVE_BRICKS_COMMIT_FAILED , cmd.getAuditLogTypeValue ( ) ) ; }
Source:
public static void GetoVirtISOsList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid id ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? new java.util.ArrayList < org.ovirt.engine.core.compat.RpmVersion > ( ( ( java.util.ArrayList < org.ovirt.engine.core.compat.RpmVersion > ) ( source ) ) ) : new java.util.ArrayList < org.ovirt.engine.core.compat.RpmVersion > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetoVirtISOs , new org.ovirt.engine.core.common.queries.VdsIdParametersBase ( id ) , aQuery ) ; }

Target:
public static void GetLunsByVgId ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , java.lang.String vgId , org.ovirt.engine.core.compat.Guid vdsId ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.LUNs > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.LUNs > ( ) ; } } ; org.ovirt.engine.core.common.queries.GetLunsByVgIdParameters params = new org.ovirt.engine.core.common.queries.GetLunsByVgIdParameters ( vgId , vdsId ) ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetLunsByVgId , params , aQuery ) ; }
Source:
public static void isSoundcardEnabled ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid vmId ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { if ( source != null ) { return ( ( ( java.util.List < java.lang.String > ) ( source ) ) . size ( ) ) > 0 ; } return false ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetSoundDevices , new org.ovirt.engine.core.common.queries.IdQueryParameters ( vmId ) , aQuery ) ; }

Target:
public void getDataCenterListByName ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , java.lang.String name ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { if ( source == null ) { return new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.StoragePool > ( ) ; } return source ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.Search , new org.ovirt.engine.core.common.queries.SearchParameters ( ( ( "DataCenter: name=" + name ) + " sortby name" ) , org.ovirt.engine.core.common.interfaces.SearchType.StoragePool ) , aQuery ) ; }
Source:
public org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc registerSecrets ( java.util.Map < java.lang.String , java.lang.String > [ ] libvirtSecrets , boolean clearUnusedSecrets ) { org.ovirt.vdsm.jsonrpc.client.JsonRpcRequest request = new org.ovirt.vdsm.jsonrpc.client.RequestBuilder ( "Host.registerSecrets" ) . withParameter ( "secrets" , libvirtSecrets ) . withParameter ( "clear" , clearUnusedSecrets ) . build ( ) ; java.util.Map < java.lang.String , java.lang.Object > response = new org.ovirt.engine.core.vdsbroker.jsonrpc.FutureMap ( this . client , request ) ; return new org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc ( response ) ; }

Target:
public org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturn registerSecrets ( java.util.Map < java.lang.String , java.lang.String > [ ] libvirtSecrets , boolean clearUnusedSecrets ) { org.ovirt.vdsm.jsonrpc.client.JsonRpcRequest request = new org.ovirt.vdsm.jsonrpc.client.RequestBuilder ( "Host.registerSecrets" ) . withParameter ( "secrets" , libvirtSecrets ) . withParameter ( "clear" , clearUnusedSecrets ) . build ( ) ; java.util.Map < java.lang.String , java.lang.Object > response = new org.ovirt.engine.core.vdsbroker.jsonrpc.FutureMap ( this . client , request ) ; return new org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturn ( response ) ; }
Source:
public void createObjects ( ) { existingServer1 = createServer ( org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_ID_1 , org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_NAME_1 ) ; existingServer2 = createServer ( org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_ID_2 , org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_NAME_2 ) ; existingServers.add ( existingServer1 ) ; existingServers.add ( existingServer2 ) ; existingServers.add ( createServer ( org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_ID_3 , org.ovirt.engine.core.bll.gluster.GlusterManagerTest.SERVER_NAME_3 ) ) ; createCluster ( ) ; existingDistVol = createDistVol ( org.ovirt.engine.core.bll.gluster.GlusterManagerTest.DIST_VOL_NAME , org.ovirt.engine.core.bll.gluster.GlusterManagerTest.EXISTING_VOL_DIST_ID ) ; existingReplVol = createReplVol ( ) ; }

Target:
private void createCluster ( org.ovirt.engine.core.compat.Version version ) { existingCluster = new org.ovirt.engine.core.common.businessentities.VDSGroup ( ) ; existingCluster.setId ( org.ovirt.engine.core.bll.gluster.GlusterManagerTest.CLUSTER_ID ) ; existingCluster.setname ( "cluster" ) ; existingCluster.setGlusterService ( true ) ; existingCluster.setVirtService ( false ) ; existingCluster.setcompatibility_version ( version ) ; }
Source:
private org.ovirt.engine.core.compat.Guid getStorageDomainIdByName ( java.lang.String storageDomainName ) { java.util.List < org.ovirt.engine.api.model.StorageDomain > storageDomains = getBackendCollection ( org.ovirt.engine.api.model.StorageDomain.class , QueryType.GetAllStorageDomains , new org.ovirt.engine.core.common.queries.VdcQueryParametersBase ( ) ) ; for ( org.ovirt.engine.api.model.StorageDomain storageDomain : storageDomains ) { if ( storageDomain.getStorageName ( ) . equals ( storageDomainName ) ) { return storageDomain.getId ( ) ; } } return null ; }

Target:
private org.ovirt.engine.core.compat.Guid getStorageDomainIdByName ( java.lang.String storageDomainName ) { java.util.List < org.ovirt.engine.api.model.StorageDomain > storageDomains = getBackendCollection ( org.ovirt.engine.api.model.StorageDomain.class , QueryType.GetAllStorageDomains , new org.ovirt.engine.core.common.queries.QueryParametersBase ( ) ) ; for ( org.ovirt.engine.api.model.StorageDomain storageDomain : storageDomains ) { if ( storageDomain.getStorageName ( ) . equals ( storageDomainName ) ) { return storageDomain.getId ( ) ; } } return null ; }
Source:
public void testGetBrickByQualifiedName ( ) { java.util.List < org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity > bricks = new java.util.ArrayList < > ( ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick1 ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick2 ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick3 ) ; org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity brick = org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtil.getBrickByQualifiedName ( bricks , ( ( ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.SERVER_1 ) + ":" ) + ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.DIR_1 ) ) ) ; org.junit.Assert.assertNotNull ( brick ) ; org.junit.Assert.assertEquals ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick1.getId ( ) , brick.getId ( ) ) ; }

Target:
public void testGetBrickByQualifiedName ( ) { java.util.List < org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity > bricks = new java.util.ArrayList < > ( ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick1 ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick2 ) ; bricks.add ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick3 ) ; org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity brick = org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtil.getBrickByQualifiedName ( bricks , ( ( ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.SERVER_1 ) + ":" ) + ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.DIR_1 ) ) ) ; org.junit.jupiter.api.Assertions.assertNotNull ( brick ) ; org.junit.jupiter.api.Assertions.assertEquals ( org.ovirt.engine.core.common.utils.gluster.GlusterCoreUtilTest.brick1.getId ( ) , brick.getId ( ) ) ; }
Source:
public void canDoActionPreallocatedSpaceCheckFailsSize ( ) { final int availableSize = 3 ; final int usedSize = 7 ; org.ovirt.engine.core.compat.Guid sdid = org.ovirt.engine.core.compat.Guid.newGuid ( ) ; initializeCommand ( sdid , VolumeType.Preallocated ) ; mockVm ( ) ; mockStorageDomain ( sdid , availableSize , usedSize ) ; mockStoragePoolIsoMap ( ) ; org.junit.Assert.assertFalse ( command.canDoAction ( ) ) ; org.junit.Assert.assertTrue ( command.getReturnValue ( ) . getCanDoActionMessages ( ) . contains ( VdcBllMessages.ACTION_TYPE_FAILED_DISK_SPACE_LOW_ON_TARGET_STORAGE_DOMAIN.toString ( ) ) ) ; }

Target:
public void testCanDoFailOnAddFloatingDiskWithPlugSet ( ) { org.ovirt.engine.core.common.businessentities.DiskImage disk = org.ovirt.engine.core.bll.AddDiskToVmCommandTest.createDiskImage ( 1 ) ; org.ovirt.engine.core.common.action.AddDiskParameters parameters = org.ovirt.engine.core.bll.AddDiskToVmCommandTest.createParameters ( ) ; parameters.setDiskInfo ( disk ) ; parameters.setVmId ( Guid.Empty ) ; parameters.setPlugDiskToVm ( true ) ; initializeCommand ( null , parameters ) ; org.ovirt.engine.core.bll.CanDoActionTestUtils.runAndAssertCanDoActionFailure ( command , VdcBllMessages.CANNOT_ADD_FLOATING_DISK_WITH_PLUG_VM_SET ) ; }
Source:
public void canDoActionSameSourceAndDest ( ) throws java.lang.Exception { destStorageId = srcStorageId ; initializeCommand ( ImageOperation.Move ) ; initVmDiskImage ( ) ; initVmForFail ( ) ; initSrcStorageDomain ( ) ; org.junit.Assert.assertFalse ( command.canDoAction ( ) ) ; org.junit.Assert.assertTrue ( command.getReturnValue ( ) . getCanDoActionMessages ( ) . contains ( VdcBllMessages.ACTION_TYPE_FAILED_SOURCE_AND_TARGET_SAME.toString ( ) ) ) ; }

Target:
public void moveDiskToGluster ( ) { initializeCommand ( ImageOperation.Move ) ; initSrcStorageDomain ( ) ; initDestStorageDomain ( StorageType.GLUSTERFS ) ; initVmDiskImage ( false ) ; org.junit.Assert.assertTrue ( command.canDoAction ( ) ) ; }
Source:
private static java.util.List < org.ovirt.engine.core.aaa.DirectoryUser > queryDirectoryUsers ( final org.ovirt.engine.core.extensions.mgr.ExtensionProxy extension , final java.lang.String namespace , final org.ovirt.engine.api.extensions.ExtMap filter , boolean groupsResolving , boolean groupsResolvingRecursive ) { return org.ovirt.engine.core.aaa.DirectoryUtils.mapPrincipalRecordsToDirectoryUsers ( org.ovirt.engine.core.aaa.AuthzUtils.getName ( extension ) , org.ovirt.engine.core.aaa.AuthzUtils.queryPrincipalRecords ( extension , namespace , filter , groupsResolving , groupsResolvingRecursive ) ) ; }

Target:
private static java.util.Collection < org.ovirt.engine.core.aaa.DirectoryUser > queryDirectoryUsers ( final org.ovirt.engine.core.extensions.mgr.ExtensionProxy extension , final java.lang.String namespace , final org.ovirt.engine.api.extensions.ExtMap filter , boolean groupsResolving , boolean groupsResolvingRecursive ) { return org.ovirt.engine.core.aaa.DirectoryUtils.mapPrincipalRecordsToDirectoryUsers ( org.ovirt.engine.core.aaa.AuthzUtils.getName ( extension ) , org.ovirt.engine.core.aaa.AuthzUtils.queryPrincipalRecords ( extension , namespace , filter , groupsResolving , groupsResolvingRecursive ) ) ; }
Source:
private void storeVm ( org.ovirt.engine.core.common.businessentities.VM vm ) { org.ovirt.engine.core.dal.dbbroker.DbFacade.getInstance ( ) . getVmDynamicDao ( ) . update ( vm.getDynamicData ( ) ) ; org.ovirt.engine.core.dal.dbbroker.DbFacade.getInstance ( ) . getVmStatisticsDao ( ) . update ( vm.getStatisticsData ( ) ) ; java.util.List < org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface > interfaces = vm.getInterfaces ( ) ; if ( interfaces != null ) { for ( org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface ifc : interfaces ) { org.ovirt.engine.core.common.businessentities.network.VmNetworkStatistics stats = ifc.getStatistics ( ) ; org.ovirt.engine.core.dal.dbbroker.DbFacade.getInstance ( ) . getVmNetworkStatisticsDao ( ) . update ( stats ) ; } } }

Target:
private void storeVm ( org.ovirt.engine.core.common.businessentities.VM vm ) { vmDynamicDao.update ( vm.getDynamicData ( ) ) ; vmStatisticsDao.update ( vm.getStatisticsData ( ) ) ; java.util.List < org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface > interfaces = vm.getInterfaces ( ) ; if ( interfaces != null ) { for ( org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface ifc : interfaces ) { org.ovirt.engine.core.common.businessentities.network.VmNetworkStatistics stats = ifc.getStatistics ( ) ; vmNetworkStatisticsDao.update ( stats ) ; } } }
Source:
public void canDoActionFailsForGlusterServerWhenNoUpServer ( ) throws java.lang.Exception { setupGlusterMock ( true , null , false ) ; org.junit.Assert.assertFalse ( commandMock.canDoAction ( ) ) ; org.junit.Assert.assertTrue ( commandMock.getReturnValue ( ) . getCanDoActionMessages ( ) . contains ( EngineMessage.ACTION_TYPE_FAILED_NO_GLUSTER_HOST_TO_PEER_PROBE.toString ( ) ) ) ; }

Target:
public void validateSuccessForGlusterServerWhenUpServerExists ( ) throws java.lang.Exception { setupGlusterMock ( true , new org.ovirt.engine.core.common.businessentities.VDS ( ) , false ) ; org.junit.Assert.assertTrue ( commandMock.validate ( ) ) ; }
Source:
public void testIscsiLunCannotBeAddedIfSgioIsFilteredAndScsiReservationEnabled ( ) { org.ovirt.engine.core.common.businessentities.storage.LunDisk disk = createISCSILunDisk ( ScsiGenericIO.FILTERED , true , DiskInterface.IDE ) ; org.ovirt.engine.core.common.action.AddDiskParameters parameters = org.ovirt.engine.core.bll.AddDiskCommandTest.createParameters ( ) ; parameters.setDiskInfo ( disk ) ; initializeCommand ( org.ovirt.engine.core.compat.Guid.newGuid ( ) , parameters ) ; mockVm ( ) ; mockInterfaceList ( ) ; org.junit.Assert.assertFalse ( "Lun disk added successfully WHILE sgio is filtered and scsi reservation is enabled" , command.checkIfLunDiskCanBeAdded ( spyDiskValidator ( disk ) ) ) ; verifyCanDoActionMessagesContainMessage ( VdcBllMessages.ACTION_TYPE_FAILED_SGIO_IS_FILTERED ) ; }

Target:
public void testIscsiLunCannotBeAddedIfSgioIsFilteredAndScsiReservationEnabled ( ) { org.ovirt.engine.core.common.businessentities.storage.LunDisk disk = createISCSILunDisk ( ScsiGenericIO.FILTERED , true , DiskInterface.IDE ) ; org.ovirt.engine.core.common.action.AddDiskParameters parameters = org.ovirt.engine.core.bll.AddDiskCommandTest.createParameters ( ) ; parameters.setDiskInfo ( disk ) ; initializeCommand ( org.ovirt.engine.core.compat.Guid.newGuid ( ) , parameters ) ; mockVm ( ) ; mockInterfaceList ( ) ; org.junit.Assert.assertFalse ( "Lun disk added successfully WHILE sgio is filtered and scsi reservation is enabled" , command.checkIfLunDiskCanBeAdded ( spyDiskValidator ( disk ) ) ) ; verifyCanDoActionMessagesContainMessage ( EngineMessage.ACTION_TYPE_FAILED_SGIO_IS_FILTERED ) ; }
Source:
protected void UpdateCustomProperties ( ) { super . UpdateCustomProperties ( ) ; updateCustomPropertySheet ( ) ; }

Target:
public void Cluster_SelectedItemChanged ( ) { UpdateDefaultHost ( ) ; updateCustomPropertySheet ( ) ; UpdateMinAllocatedMemory ( ) ; UpdateNumOfSockets ( ) ; if ( ( ( org.ovirt.engine.core.common.businessentities.VmTemplate ) ( getModel ( ) . getTemplate ( ) . getSelectedItem ( ) ) ) != null ) { org.ovirt.engine.core.common.businessentities.VmTemplate template = ( ( org.ovirt.engine.core.common.businessentities.VmTemplate ) ( getModel ( ) . getTemplate ( ) . getSelectedItem ( ) ) ) ; updateQuotaByCluster ( template.getQuotaId ( ) , template.getQuotaName ( ) ) ; } }
Source:
public void init ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.DiskImage > diskImages ) { setDiskImages ( diskImages ) ; org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.GetDiskList ( new org.ovirt.engine.ui.frontend.AsyncQuery ( this , new org.ovirt.engine.ui.frontend.INewAsyncCallback ( ) { @ java.lang.Override public void onSuccess ( java.lang.Object target , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.models.vms.MoveDiskModel moveDiskModel = ( ( org.ovirt.engine.ui.uicommonweb.models.vms.MoveDiskModel ) ( target ) ) ; java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Disk > diskImages = ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Disk > ) ( returnValue ) ) ; moveDiskModel.onInitAllDisks ( diskImages ) ; moveDiskModel.onInitDisks ( ) ; } } ) ) ; }

Target:
public void init ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.DiskImage > diskImages ) { setDiskImages ( diskImages ) ; org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.getDiskList ( new org.ovirt.engine.ui.frontend.AsyncQuery ( this , new org.ovirt.engine.ui.frontend.INewAsyncCallback ( ) { @ java.lang.Override public void onSuccess ( java.lang.Object target , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.models.vms.MoveDiskModel moveDiskModel = ( ( org.ovirt.engine.ui.uicommonweb.models.vms.MoveDiskModel ) ( target ) ) ; java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Disk > diskImages = ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Disk > ) ( returnValue ) ) ; moveDiskModel.onInitAllDisks ( diskImages ) ; moveDiskModel.onInitDisks ( ) ; } } ) ) ; }
Source:
public void getAllAttachableDisks ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid storagePoolId , org.ovirt.engine.core.compat.Guid vmId ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.storage.Disk > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.storage.Disk > ( ) ; } } ; org.ovirt.engine.core.common.queries.GetAllAttachableDisksForVmQueryParameters params = new org.ovirt.engine.core.common.queries.GetAllAttachableDisksForVmQueryParameters ( storagePoolId ) ; params.setVmId ( vmId ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllAttachableDisksForVm , params , aQuery ) ; }

Target:
public void getAllAttachableDisks ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid storagePoolId , org.ovirt.engine.core.compat.Guid vmId ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter ( ) { @ java.lang.Override public java.lang.Object convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return source != null ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.storage.Disk > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.storage.Disk > ( ) ; } } ; org.ovirt.engine.core.common.queries.GetAllAttachableDisksForVmQueryParameters params = new org.ovirt.engine.core.common.queries.GetAllAttachableDisksForVmQueryParameters ( storagePoolId ) ; params.setVmId ( vmId ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllAttachableDisksForVm , params , aQuery ) ; }
Source:
private java.util.List < org.ovirt.engine.core.common.businessentities.storage.DiskImage > getMovedDisks ( ) { java.util.Set < org.ovirt.engine.core.compat.Guid > movedDiskIds = getMovedDiskIds ( ) ; java.util.List < org.ovirt.engine.core.common.businessentities.storage.DiskImage > disks = new java.util.ArrayList < > ( ) ; for ( org.ovirt.engine.core.compat.Guid diskId : movedDiskIds ) { org.ovirt.engine.core.common.businessentities.storage.DiskImage disk = new org.ovirt.engine.core.common.businessentities.storage.DiskImage ( ) ; disk.setId ( diskId ) ; disks.add ( disk ) ; } return disks ; }

Target:
public java.util.Map < java.lang.String , java.lang.String > getJobMessageProperties ( ) { if ( ( jobProperties ) == null ) { jobProperties = super . getJobMessageProperties ( ) ; jobProperties.put ( VdcObjectType.VM.name ( ) . toLowerCase ( ) , org.ovirt.engine.core.bll.storage.lsm.LiveMigrateVmDisksCommand.getVmName ( ) ) ; } return jobProperties ; }
Source:
protected void analyze ( ) { proceedDownVms ( ) ; proceedWatchdogEvents ( ) ; proceedBalloonCheck ( ) ; proceedGuaranteedMemoryCheck ( ) ; updateRepository ( ) ; prepareGuestAgentNetworkDevicesForUpdate ( ) ; updateLunDisks ( ) ; updateVmJobs ( ) ; analyzeExternalVms ( ) ; analyzeHostedEngineVm ( ) ; }

Target:
protected void analyze ( ) { proceedDownVms ( ) ; proceedWatchdogEvents ( ) ; proceedBalloonCheck ( ) ; proceedGuaranteedMemoryCheck ( ) ; updateRepository ( ) ; prepareGuestAgentNetworkDevicesForUpdate ( ) ; updateLunDisks ( ) ; updateVmJobs ( ) ; analyzeExternalVms ( ) ; analyzeHostedEngineVm ( ) ; if ( ( vmDynamicToSave ) != null ) { vmsMonitoring.addVmDynamicToList ( vmDynamicToSave ) ; } }
Source:
public java.util.List < org.ovirt.engine.core.common.businessentities.VmTemplate > getAll ( org.ovirt.engine.core.compat.Guid userID , boolean isFiltered ) { return getCallsHandler ( ) . executeReadList ( "GetAllFromVmTemplates" , org.ovirt.engine.core.dao.VmTemplateDAODbFacadeImpl.VMTemplateRowMapper.instance , getCustomMapSqlParameterSource ( ) . addValue ( "user_id" , userID ) . addValue ( "is_filtered" , isFiltered ) ) ; }

Target:
public java.util.List < org.ovirt.engine.core.common.businessentities.VmTemplate > getAll ( org.ovirt.engine.core.compat.Guid userID , boolean isFiltered , org.ovirt.engine.core.common.businessentities.VmEntityType entityType ) { return getCallsHandler ( ) . executeReadList ( "GetAllFromVmTemplates" , org.ovirt.engine.core.dao.VmTemplateDAODbFacadeImpl.VMTemplateRowMapper.instance , getCustomMapSqlParameterSource ( ) . addValue ( "entity_type" , entityType.name ( ) ) . addValue ( "user_id" , userID ) . addValue ( "is_filtered" , isFiltered ) ) ; }
Source:
private static org.ovirt.vdsm.jsonrpc.client.reactors.Reactor getSslReactor ( org.ovirt.vdsm.jsonrpc.client.reactors.ManagerProvider provider ) throws org.ovirt.vdsm.jsonrpc.client.ClientConnectionException { if ( ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor ) != null ) { return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor ; } synchronized ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.class ) { if ( ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor ) != null ) { return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor ; } try { org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor = new org.ovirt.vdsm.jsonrpc.client.reactors.SSLReactor ( provider.getSSLContext ( ) ) ; } catch ( java.io.IOException | java.security.GeneralSecurityException e ) { throw new org.ovirt.vdsm.jsonrpc.client.ClientConnectionException ( e ) ; } } return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslReactor ; }

Target:
private static org.ovirt.vdsm.jsonrpc.client.reactors.Reactor getSslStompReactor ( org.ovirt.vdsm.jsonrpc.client.reactors.ManagerProvider provider ) throws org.ovirt.vdsm.jsonrpc.client.ClientConnectionException { if ( ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor ) != null ) { return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor ; } synchronized ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.class ) { if ( ( org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor ) != null ) { return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor ; } try { org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor = new org.ovirt.vdsm.jsonrpc.client.reactors.stomp.SSLStompReactor ( provider.getSSLContext ( ) ) ; } catch ( java.io.IOException | java.security.GeneralSecurityException e ) { throw new org.ovirt.vdsm.jsonrpc.client.ClientConnectionException ( e ) ; } } return org.ovirt.vdsm.jsonrpc.client.reactors.ReactorFactory.sslStompReactor ; }
Source:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; dao = dbFacade.getStorageServerConnectionLunMapDao ( ) ; storageServerConnectionDao = dbFacade.getStorageServerConnectionDao ( ) ; existingConnection = storageServerConnectionDao.get ( "0cc146e8-e5ed-482c-8814-270bc48c297e" ) ; newServerConnection = new org.ovirt.engine.core.common.businessentities.StorageServerConnections ( ) ; newServerConnection.setid ( "0cc146e8-e5ed-482c-8814-270bc48c2980" ) ; newServerConnection.setconnection ( org.ovirt.engine.core.dao.StorageServerConnectionLunMapDAOTest.EXISTING_DOMAIN_STORAGE_NAME ) ; existingLUNStorageMap = dao.get ( new org.ovirt.engine.core.common.businessentities.storage.LUN_storage_server_connection_map_id ( "1IET_00180001" , existingConnection.getid ( ) ) ) ; newLUNStorageMap = new org.ovirt.engine.core.common.businessentities.storage.LUN_storage_server_connection_map ( org.ovirt.engine.core.dao.StorageServerConnectionLunMapDAOTest.FREE_LUN_ID , existingConnection.getid ( ) ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { super . setUp ( ) ; dao = dbFacade.getStorageServerConnectionLunMapDao ( ) ; storageServerConnectionDao = dbFacade.getStorageServerConnectionDao ( ) ; existingConnection = storageServerConnectionDao.get ( "0cc146e8-e5ed-482c-8814-270bc48c297e" ) ; newServerConnection = new org.ovirt.engine.core.common.businessentities.StorageServerConnections ( ) ; newServerConnection.setid ( "0cc146e8-e5ed-482c-8814-270bc48c2980" ) ; newServerConnection.setconnection ( org.ovirt.engine.core.dao.StorageServerConnectionLunMapDAOTest.EXISTING_DOMAIN_STORAGE_NAME ) ; existingLUNStorageMap = dao.get ( new org.ovirt.engine.core.common.businessentities.storage.LUNStorageServerConnectionMapId ( "1IET_00180001" , existingConnection.getid ( ) ) ) ; newLUNStorageMap = new org.ovirt.engine.core.common.businessentities.storage.LUNStorageServerConnectionMap ( org.ovirt.engine.core.dao.StorageServerConnectionLunMapDAOTest.FREE_LUN_ID , existingConnection.getid ( ) ) ; }
Source:
public void onClick ( com.google.gwt.event.dom.client.ClickEvent event ) { java.util.List models = ( ( java.util.List < org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel > ) ( getValue ( ) . getItems ( ) ) ) ; org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel existingProfileModel = ( ( org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel ) ( value ) ) ; models.add ( ( ( models.indexOf ( existingProfileModel ) ) + 1 ) , new org.ovirt.engine.ui.uicommonweb.models.profiles.NewVnicProfileModel ( existingProfileModel.getSourceModel ( ) , existingProfileModel.getDcCompatibilityVersion ( ) ) ) ; setAcceptableValues ( models ) ; }

Target:
public void onClick ( com.google.gwt.event.dom.client.ClickEvent event ) { java.util.List models = ( ( java.util.List < org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel > ) ( getValue ( ) . getItems ( ) ) ) ; org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel existingProfileModel = ( ( org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel ) ( value ) ) ; org.ovirt.engine.ui.uicommonweb.models.profiles.VnicProfileModel newVnicProfileModel = new org.ovirt.engine.ui.uicommonweb.models.profiles.NewVnicProfileModel ( existingProfileModel.getSourceModel ( ) , existingProfileModel.getDcCompatibilityVersion ( ) , dcId ) ; models.add ( ( ( models.indexOf ( existingProfileModel ) ) + 1 ) , newVnicProfileModel ) ; setAcceptableValues ( models ) ; }