auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
private void sleepOnReboot ( final org.ovirt.engine.core.common.businessentities.VDSStatus status ) { int sleepTimeInSec = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > getValue ( ConfigValues.ServerRebootTimeout ) ; log.info ( "Waiting seconds, for server to finish reboot process." , sleepTimeInSec ) ; org.ovirt.engine.core.utils.ThreadUtils.sleep ( ( sleepTimeInSec * 1000 ) ) ; runVdsCommand ( VDSCommandType.SetVdsStatus , new org.ovirt.engine.core.common.vdscommands.SetVdsStatusVDSCommandParameters ( org.ovirt.engine.core.bll.VdsCommand.getVdsId ( ) , status ) ) ; }

Target:
private void sleepOnReboot ( final org.ovirt.engine.core.common.businessentities.VDSStatus status ) { int sleepTimeInSec = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > getValue ( ConfigValues.ServerRebootTimeout ) ; log.info ( "Waiting seconds, for server to finish reboot process." , sleepTimeInSec ) ; org.ovirt.engine.core.utils.ThreadUtils.sleep ( ( sleepTimeInSec * 1000 ) ) ; setVdsStatus ( status ) ; }
Source:
public void syncWithBackend ( ) { final org.ovirt.engine.core.common.businessentities.StoragePool dc = getSelectedDc ( ) ; if ( dc == null ) { return ; } boolean isSupportBridgesReportByVDSM = ( ( java.lang.Boolean ) ( org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.getConfigValuePreConverted ( ConfigurationValues.SupportBridgesReportByVDSM , dc.getcompatibility_version ( ) . toString ( ) ) ) ) ; setSupportBridgesReportByVDSM ( isSupportBridgesReportByVDSM ) ; boolean isMTUOverrideSupported = ( ( java.lang.Boolean ) ( org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.getConfigValuePreConverted ( ConfigurationValues.MTUOverrideSupported , dc.getcompatibility_version ( ) . toString ( ) ) ) ) ; setMTUOverrideSupported ( isMTUOverrideSupported ) ; onExportChanged ( ) ; }

Target:
public void syncWithBackend ( ) { final org.ovirt.engine.core.common.businessentities.StoragePool dc = getSelectedDc ( ) ; if ( dc == null ) { return ; } boolean isSupportBridgesReportByVDSM = ( ( java.lang.Boolean ) ( org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.getConfigValuePreConverted ( ConfigurationValues.SupportBridgesReportByVDSM , dc.getcompatibility_version ( ) . toString ( ) ) ) ) ; setSupportBridgesReportByVDSM ( isSupportBridgesReportByVDSM ) ; boolean isMTUOverrideSupported = ( ( java.lang.Boolean ) ( org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.getConfigValuePreConverted ( ConfigurationValues.MTUOverrideSupported , dc.getcompatibility_version ( ) . toString ( ) ) ) ) ; setMTUOverrideSupported ( isMTUOverrideSupported ) ; onExportChanged ( ) ; initProfiles ( ) ; }
Source:
public void labelBeingAttachedToValidBondExistingBondValid ( ) { org.ovirt.engine.core.common.businessentities.network.Bond bond = new org.ovirt.engine.core.common.businessentities.network.Bond ( "bond" ) ; bond.setSlaves ( java.util.Arrays.asList ( "slave1" , "slave2" ) ) ; java.util.List < org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface > nics = new java.util.ArrayList ( java.util.Collections.singletonList ( bond ) ) ; org.ovirt.engine.core.common.businessentities.network.NicLabel nicLabel = new org.ovirt.engine.core.common.businessentities.network.NicLabel ( bond.getId ( ) , bond.getName ( ) , "lbl1" ) ; org.junit.Assert.assertThat ( createNicLabelValidator ( nics ) . labelBeingAttachedToValidBond ( nicLabel ) , org.ovirt.engine.core.bll.validator.ValidationResultMatchers.isValid ( ) ) ; }

Target:
public void labelBeingAttachedToValidBondExistingBondValid ( ) { org.ovirt.engine.core.common.businessentities.network.Bond bond = new org.ovirt.engine.core.common.businessentities.network.Bond ( "bond" ) ; bond.setSlaves ( java.util.Arrays.asList ( "slave1" , "slave2" ) ) ; java.util.List < org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface > nics = new java.util.ArrayList ( java.util.Collections.singletonList ( bond ) ) ; org.ovirt.engine.core.common.businessentities.network.NicLabel nicLabel = new org.ovirt.engine.core.common.businessentities.network.NicLabel ( bond.getId ( ) , bond.getName ( ) , "lbl1" ) ; org.hamcrest.MatcherAssert.assertThat ( createNicLabelValidator ( nics ) . labelBeingAttachedToValidBond ( nicLabel ) , org.ovirt.engine.core.bll.validator.ValidationResultMatchers.isValid ( ) ) ; }
Source:
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 ) ; }

Target:
public static void GetLunsByVgId ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , java.lang.String vgId ) { 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 tempVar = new org.ovirt.engine.core.common.queries.GetLunsByVgIdParameters ( ) ; tempVar.setVgId ( vgId ) ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetLunsByVgId , tempVar , aQuery ) ; }
Source:
private org.ovirt.engine.core.common.job.Step createStep ( ) { org.ovirt.engine.core.common.job.Step step = new org.ovirt.engine.core.common.job.Step ( ) ; step.setStepType ( StepEnum.REBALANCING_VOLUME ) ; return step ; }

Target:
private org.ovirt.engine.core.common.job.Step createStep ( org.ovirt.engine.core.compat.Guid taskGuid ) { org.ovirt.engine.core.common.job.Step step = new org.ovirt.engine.core.common.job.Step ( ) ; step.setStepType ( StepEnum.REBALANCING_VOLUME ) ; java.util.Calendar stepTime = java.util.Calendar.getInstance ( ) ; if ( taskGuid.equals ( org.ovirt.engine.core.bll.gluster.GlusterTasksSyncJobTest.TASK_GUIDS [ 2 ] ) ) { stepTime.set ( java.util.Calendar.HOUR , ( ( stepTime.get ( java.util.Calendar.HOUR ) ) - 1 ) ) ; } step.setStartTime ( stepTime.getTime ( ) ) ; return step ; }
Source:
public void testCompleteWhenUnsetIdAndName ( ) throws java.lang.Exception { org.ovirt.engine.core.bll.network.host.NicNameNicIdCompleter.NicNameAndNicIdAccessors withoutNameOrIdSet = org.mockito.Mockito.mock ( org.ovirt.engine.core.bll.network.host.NicNameNicIdCompleter.NicNameAndNicIdAccessors.class ) ; completer.complete ( withoutNameOrIdSet ) ; org.mockito.Mockito.verify ( withoutNameOrIdSet , org.mockito.Mockito.never ( ) ) . setName ( org.mockito.Matchers.anyString ( ) ) ; org.mockito.Mockito.verify ( withoutNameOrIdSet , org.mockito.Mockito.never ( ) ) . setId ( org.mockito.Matchers.any ( org.ovirt.engine.core.compat.Guid.class ) ) ; }

Target:
public void testCompleteWhenUnsetIdAndName ( ) throws java.lang.Exception { org.ovirt.engine.core.bll.network.host.NicNameNicIdCompleter.NicNameAndNicIdAccessors withoutNameOrIdSet = org.mockito.Mockito.mock ( org.ovirt.engine.core.bll.network.host.NicNameNicIdCompleter.NicNameAndNicIdAccessors.class ) ; completer.complete ( withoutNameOrIdSet ) ; org.mockito.Mockito.verify ( withoutNameOrIdSet , org.mockito.Mockito.never ( ) ) . setName ( org.mockito.ArgumentMatchers.anyString ( ) ) ; org.mockito.Mockito.verify ( withoutNameOrIdSet , org.mockito.Mockito.never ( ) ) . setId ( org.mockito.ArgumentMatchers.any ( org.ovirt.engine.core.compat.Guid.class ) ) ; }
Source:
public synchronized void _timer_Elapsed ( ) { if ( ThereAreTasksToPoll ( ) ) { PollAndUpdateAsyncTasks ( ) ; if ( ( ThereAreTasksToPoll ( ) ) && ( logChangedMap ) ) { org.ovirt.engine.core.bll.AsyncTaskManager.log.infoFormat ( "Finished polling Tasks, will poll again in {0} seconds." , org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.AsyncTaskPollingRate ) ) ; logChangedMap = false ; } if ( ( _tasks.size ( ) ) > 0 ) { CleanZombieTasks ( ) ; } } }

Target:
public synchronized void _timer_Elapsed ( ) { if ( ThereAreTasksToPoll ( ) ) { PollAndUpdateAsyncTasks ( ) ; if ( ( ThereAreTasksToPoll ( ) ) && ( logChangedMap ) ) { org.ovirt.engine.core.bll.AsyncTaskManager.log.infoFormat ( "Finished polling Tasks, will poll again in {0} seconds." , org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.AsyncTaskPollingRate ) ) ; logChangedMap = false ; } if ( ( _tasks.size ( ) ) > 0 ) { cleanZombieTasks ( ) ; } } }
Source:
public void validateSucceedsWithStartActionType ( ) { org.ovirt.engine.core.common.action.gluster.GlusterServiceParameters params = new org.ovirt.engine.core.common.action.gluster.GlusterServiceParameters ( ) ; params.setActionType ( GlusterConstants.MANAGE_GLUSTER_SERVICE_ACTION_TYPE_START ) ; cmd = org.mockito.Mockito.spy ( new org.ovirt.engine.core.bll.gluster.ManageGlusterServiceCommand ( params , null ) ) ; prepareMocks ( cmd ) ; org.junit.Assert.assertFalse ( cmd.validate ( ) ) ; }

Target:
public void validateFailsOnNull ( ) { cmd.getParameters ( ) . setServiceType ( ServiceType.NFS ) ; cmd.getParameters ( ) . setActionType ( GlusterConstants.MANAGE_GLUSTER_SERVICE_ACTION_TYPE_START ) ; prepareMocks ( cmd ) ; org.junit.Assert.assertFalse ( cmd.validate ( ) ) ; }
Source:
public org.ovirt.engine.api.model.CdRom get ( ) { for ( org.ovirt.engine.api.model.CdRom cdRom : collection.list ( ) . getCdRoms ( ) ) { if ( cdRom.getId ( ) . equals ( cdRomId ) ) { return cdRom ; } } throw new javax.ws.rs.WebApplicationException ( javax.ws.rs.core.Response.status ( Response.Status.NOT_FOUND ) . build ( ) ) ; }

Target:
public org.ovirt.engine.api.model.Cdrom get ( ) { for ( org.ovirt.engine.api.model.Cdrom cdRom : collection.list ( ) . getCdroms ( ) ) { if ( cdRom.getId ( ) . equals ( cdRomId ) ) { return cdRom ; } } throw new javax.ws.rs.WebApplicationException ( javax.ws.rs.core.Response.status ( Response.Status.NOT_FOUND ) . build ( ) ) ; }
Source:
public final boolean IsUpdateValid ( java.lang.Object source , java.lang.Object destination ) { if ( ( source.getClass ( ) ) != ( destination.getClass ( ) ) ) { return false ; } for ( java.lang.String fieldName : org.ovirt.engine.core.utils.ObjectIdentityChecker.GetChangedFields ( source , destination ) ) { if ( ! ( IsFieldUpdatable ( fieldName ) ) ) { return false ; } } return true ; }

Target:
public final boolean isUpdateValid ( java.lang.Object source , java.lang.Object destination ) { if ( ( source.getClass ( ) ) != ( destination.getClass ( ) ) ) { return false ; } for ( java.lang.String fieldName : org.ovirt.engine.core.utils.ObjectIdentityChecker.getChangedFields ( source , destination ) ) { if ( ! ( isFieldUpdatable ( fieldName ) ) ) { return false ; } } return true ; }
Source:
public void invalidQosInconsistentValues ( ) { org.ovirt.engine.core.common.businessentities.network.HostNetworkQos qos = new org.ovirt.engine.core.common.businessentities.network.HostNetworkQos ( ) ; qos.setOutAverageLinkshare ( 10 ) ; qos.setOutAverageUpperlimit ( org.ovirt.engine.core.bll.network.host.SetupNetworksHelperTest.LOW_BANDWIDTH ) ; qos.setOutAverageRealtime ( org.ovirt.engine.core.bll.network.host.SetupNetworksHelperTest.HIGH_BANDWIDTH ) ; org.ovirt.engine.core.bll.network.host.SetupNetworksHelper helper = qosValuesTest ( qos ) ; validateAndExpectViolation ( helper , EngineMessage.ACTION_TYPE_FAILED_HOST_NETWORK_QOS_SETUP_NETWORKS_INCONSISTENT_VALUES , org.ovirt.engine.core.bll.network.host.SetupNetworksHelperTest.MANAGEMENT_NETWORK_NAME ) ; }

Target:
public void setUp ( ) throws java.lang.Exception { effectiveHostNetworkQos = new org.ovirt.engine.core.vdsbroker.EffectiveHostNetworkQos ( qosDao ) ; injectorRule.bind ( org.ovirt.engine.core.dao.network.NetworkDao.class , networkDao ) ; injectorRule.bind ( org.ovirt.engine.core.dao.network.NetworkAttachmentDao.class , networkAttachmentDao ) ; injectorRule.bind ( org.ovirt.engine.core.dao.network.InterfaceDao.class , interfaceDao ) ; injectorRule.bind ( org.ovirt.engine.core.dao.gluster.GlusterBrickDao.class , brickDao ) ; injectorRule.bind ( org.ovirt.engine.core.vdsbroker.EffectiveHostNetworkQos.class , effectiveHostNetworkQos ) ; injectorRule.bind ( org.ovirt.engine.core.vdsbroker.NetworkImplementationDetailsUtils.class , new org.ovirt.engine.core.vdsbroker.NetworkImplementationDetailsUtils ( effectiveHostNetworkQos , networkAttachmentDao , calculateBaseNic ) ) ; injectorRule.bind ( org.ovirt.engine.core.vdsbroker.CalculateBaseNic.class , calculateBaseNic ) ; }
Source:
protected void initHeader ( org.ovirt.engine.ui.webadmin.ApplicationConstants constants ) { table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , constants.aliasTemplate ( ) ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , constants.disksTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , constants.provisionedSizeTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , constants.actualSizeTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , constants.creationDateTemplate ( ) , "170px" ) ; }

Target:
protected void initHeader ( ) { table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , org.ovirt.engine.ui.webadmin.section.main.view.tab.storage.SubTabStorageTemplateView.constants.aliasTemplate ( ) ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , org.ovirt.engine.ui.webadmin.section.main.view.tab.storage.SubTabStorageTemplateView.constants.disksTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , org.ovirt.engine.ui.webadmin.section.main.view.tab.storage.SubTabStorageTemplateView.constants.provisionedSizeTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , org.ovirt.engine.ui.webadmin.section.main.view.tab.storage.SubTabStorageTemplateView.constants.actualSizeTemplate ( ) , "110px" ) ; table.addColumn ( new org.ovirt.engine.ui.common.widget.table.column.EmptyColumn ( ) , org.ovirt.engine.ui.webadmin.section.main.view.tab.storage.SubTabStorageTemplateView.constants.creationDateTemplate ( ) , "170px" ) ; }
Source:
public void getHostArchitecture ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid id ) { aQuery.converterCallback = new org.ovirt.engine.ui.frontend.IAsyncConverter < org.ovirt.engine.core.common.businessentities.ArchitectureType > ( ) { @ java.lang.Override public org.ovirt.engine.core.common.businessentities.ArchitectureType Convert ( java.lang.Object source , org.ovirt.engine.ui.frontend.AsyncQuery _asyncQuery ) { return ( ( org.ovirt.engine.core.common.businessentities.ArchitectureType ) ( source ) ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetHostArchitecture , new org.ovirt.engine.core.common.queries.IdQueryParameters ( id ) , aQuery ) ; }

Target:
private void getIrsImageList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid storagePoolId , boolean forceRefresh , org.ovirt.engine.core.common.businessentities.storage.ImageFileType imageFileType , org.ovirt.engine.ui.frontend.IAsyncConverter converterCallBack ) { aQuery.converterCallback = converterCallBack ; org.ovirt.engine.core.common.queries.GetImagesListByStoragePoolIdParameters parameters = new org.ovirt.engine.core.common.queries.GetImagesListByStoragePoolIdParameters ( storagePoolId , imageFileType ) ; parameters.setForceRefresh ( forceRefresh ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetImagesListByStoragePoolId , parameters , aQuery ) ; }
Source:
public static void getClusterNetworkList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { if ( ( aQuery.converterCallback ) == null ) { 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.network.Network > ( ) ; } return source ; } } ; } org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetAllNetworksByClusterId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( clusterId ) , aQuery ) ; }

Target:
public static void getDomainList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , boolean filterInternalDomain ) { 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 < java.lang.String > ( ( ( java.util.ArrayList < java.lang.String > ) ( source ) ) ) : new java.util.ArrayList < java.lang.String > ( ) ; } } ; org.ovirt.engine.core.common.queries.GetDomainListParameters tempVar = new org.ovirt.engine.core.common.queries.GetDomainListParameters ( ) ; tempVar.setFilterInternalDomain ( filterInternalDomain ) ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetDomainList , tempVar , aQuery ) ; }
Source:
public void OnSuccess ( java.lang.Object target , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.models.clusters.ClusterGuideModel clusterGuideModel = ( ( org.ovirt.engine.ui.uicommonweb.models.clusters.ClusterGuideModel ) ( target ) ) ; java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VDS > hosts = ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VDS > ) ( returnValue ) ) ; clusterGuideModel.allHosts = hosts ; clusterGuideModel.UpdateOptionsNonLocalFS ( ) ; }

Target:
public void onSuccess ( java.lang.Object target , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.models.clusters.ClusterGuideModel clusterGuideModel = ( ( org.ovirt.engine.ui.uicommonweb.models.clusters.ClusterGuideModel ) ( target ) ) ; java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VDS > hosts = ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VDS > ) ( returnValue ) ) ; clusterGuideModel.allHosts = hosts ; clusterGuideModel.updateOptionsNonLocalFS ( ) ; }
Source:
private static void getVlanParentInterface ( org.ovirt.engine.core.compat.Guid vdsID , org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface iface , 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 ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetVlanParent , new org.ovirt.engine.core.common.queries.InterfaceAndIdQueryParameters ( vdsID , iface ) , aQuery ) ; }

Target:
public void getProviderCertificateChain ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.common.businessentities.Provider provider ) { 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 ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetProviderCertificateChain , new org.ovirt.engine.core.common.queries.ProviderQueryParameters ( provider ) , aQuery ) ; }
Source:
public void testUpdate ( ) { existing_bookmark.setName ( existing_bookmark.getName ( ) . toUpperCase ( ) ) ; dao.update ( existing_bookmark ) ; org.ovirt.engine.core.common.businessentities.Bookmark result = dao.get ( existing_bookmark.getId ( ) ) ; org.junit.Assert.assertNotNull ( result ) ; org.junit.Assert.assertEquals ( existing_bookmark.getName ( ) , result.getName ( ) ) ; }

Target:
public void testUpdate ( ) { existing_bookmark.setName ( existing_bookmark.getName ( ) . toUpperCase ( ) ) ; dao.update ( existing_bookmark ) ; org.ovirt.engine.core.common.businessentities.Bookmark result = dao.get ( existing_bookmark.getId ( ) ) ; org.junit.jupiter.api.Assertions.assertNotNull ( result ) ; org.junit.jupiter.api.Assertions.assertEquals ( existing_bookmark.getName ( ) , result.getName ( ) ) ; }
Source:
public void testGetIscsiIfacesByHostIdAndStorageTargetId ( ) { java.util.List < org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface > interfaces = dao.getIscsiIfacesByHostIdAndStorageTargetId ( org.ovirt.engine.core.dao.network.InterfaceDaoTest.VDS_ID , org.ovirt.engine.core.dao.network.InterfaceDaoTest.TARGET_ID ) ; org.junit.Assert.assertNotNull ( interfaces ) ; org.junit.Assert.assertFalse ( interfaces.isEmpty ( ) ) ; for ( org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface nic : interfaces ) { org.junit.Assert.assertEquals ( org.ovirt.engine.core.dao.network.InterfaceDaoTest.VDS_ID , nic.getVdsId ( ) ) ; } }

Target:
public void testGetIscsiIfacesByHostIdAndStorageTargetId ( ) { java.util.List < org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface > interfaces = dao.getIscsiIfacesByHostIdAndStorageTargetId ( org.ovirt.engine.core.dao.network.InterfaceDaoImplTest.VDS_ID , org.ovirt.engine.core.dao.network.InterfaceDaoImplTest.TARGET_ID ) ; org.junit.Assert.assertNotNull ( interfaces ) ; org.junit.Assert.assertFalse ( interfaces.isEmpty ( ) ) ; for ( org.ovirt.engine.core.common.businessentities.network.VdsNetworkInterface nic : interfaces ) { org.junit.Assert.assertEquals ( org.ovirt.engine.core.dao.network.InterfaceDaoImplTest.VDS_ID , nic.getVdsId ( ) ) ; } }
Source:
protected void postConnect ( org.ovirt.vdsm.jsonrpc.client.utils.OneTimeCallback callback ) throws org.ovirt.vdsm.jsonrpc.client.ClientConnectionException { try { int interestedOps = java.nio.channels.SelectionKey.OP_READ ; reactor.wakeup ( ) ; key = this . channel.register ( selector , interestedOps , this ) ; } catch ( java.nio.channels.ClosedChannelException e ) { throw new org.ovirt.vdsm.jsonrpc.client.ClientConnectionException ( e ) ; } }

Target:
public java.nio.channels.SelectionKey call ( ) throws java.nio.channels.ClosedChannelException { return channel.register ( selector , java.nio.channels.SelectionKey.OP_READ , client ) ; }
Source:
private org.ovirt.engine.ui.frontend.server.dashboard.Dashboard getDashboardFromCache ( ) throws org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataException { org.ovirt.engine.ui.frontend.server.dashboard.Dashboard dashboard ; org.ovirt.engine.ui.frontend.server.dashboard.Inventory inventory ; synchronized ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.UTILIZATION_LOCK ) { dashboard = org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.dashboardCache.get ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.UTILIZATION_KEY ) ; if ( dashboard == null ) { dashboard = populateUtilizationCache ( ) ; } inventory = org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.inventoryCache.get ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.INVENTORY_KEY ) ; if ( inventory == null ) { inventory = populateInventoryCache ( ) ; } } dashboard.setInventory ( inventory ) ; return dashboard ; }

Target:
private org.ovirt.engine.ui.frontend.server.dashboard.Dashboard getDashboardFromCache ( ) throws org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataException { org.ovirt.engine.ui.frontend.server.dashboard.Dashboard dashboard ; org.ovirt.engine.ui.frontend.server.dashboard.Inventory inventory ; synchronized ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.UTILIZATION_LOCK ) { dashboard = dashboardCache.get ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.UTILIZATION_KEY ) ; if ( dashboard == null ) { dashboard = populateUtilizationCache ( ) ; } inventory = inventoryCache.get ( org.ovirt.engine.ui.frontend.server.dashboard.DashboardDataServlet.INVENTORY_KEY ) ; if ( inventory == null ) { inventory = populateInventoryCache ( ) ; } } dashboard.setInventory ( inventory ) ; return dashboard ; }
Source:
public void getVMsWithVNumaNodesByClusterId ( org.ovirt.engine.ui.frontend.AsyncQuery asyncQuery , org.ovirt.engine.core.compat.Guid clusterId ) { asyncQuery.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.VM > ( ) ; } return source ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllVmsWithNumaByClusterId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( clusterId ) , asyncQuery ) ; }

Target:
public void getVMsWithVNumaNodesByClusterId ( org.ovirt.engine.ui.frontend.AsyncQuery < java.util.List < org.ovirt.engine.core.common.businessentities.VM > > asyncQuery , org.ovirt.engine.core.compat.Guid clusterId ) { asyncQuery.converterCallback = new org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.ListConverter < > ( ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetAllVmsWithNumaByClusterId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( clusterId ) , asyncQuery ) ; }
Source:
private void doTestBadRemove ( boolean valid , boolean success , java.lang.String detail ) { setUpGetDomainExpectations ( StorageType.NFS , true ) ; setUpGetConnectionExpectations ( ) ; setUriInfo ( setUpActionExpectations ( ActionType.DetachStorageDomainFromPool , org.ovirt.engine.core.common.action.DetachStorageDomainFromPoolParameters.class , new java.lang.String [ ] { "StorageDomainId" , "StoragePoolId" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendAttachedStorageDomainResourceTest.STORAGE_DOMAIN_ID , org.ovirt.engine.api.restapi.resource.BackendAttachedStorageDomainResourceTest.DATA_CENTER_ID } , valid , success ) ) ; try { resource.remove ( ) ; org.junit.jupiter.api.Assertions.fail ( "expected WebApplicationException" ) ; } catch ( javax.ws.rs.WebApplicationException wae ) { verifyFault ( wae , detail ) ; } }

Target:
private void doTestBadRemove ( boolean valid , boolean success , java.lang.String detail ) { setUpGetDomainExpectations ( StorageType.NFS , true ) ; setUpGetConnectionExpectations ( ) ; setUriInfo ( setUpActionExpectations ( ActionType.DetachStorageDomainFromPool , org.ovirt.engine.core.common.action.DetachStorageDomainFromPoolParameters.class , new java.lang.String [ ] { "StorageDomainId" , "StoragePoolId" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendAttachedStorageDomainResourceTest.STORAGE_DOMAIN_ID , org.ovirt.engine.api.restapi.resource.BackendAttachedStorageDomainResourceTest.DATA_CENTER_ID } , valid , success ) ) ; verifyFault ( org.junit.jupiter.api.Assertions.assertThrows ( javax.ws.rs.WebApplicationException.class , resource :: remove ) , detail ) ; }
Source:
private java.util.List < org.ovirt.engine.core.common.businessentities.UserSession > searchSessions ( ) { return genericSearch ( org.ovirt.engine.core.bll.SearchQuery.getDbFacade ( ) . getEngineSessionDao ( ) , false ) . stream ( ) . peek ( this :: injectSessionInfo ) . map ( UserSession :: new ) . collect ( java.util.stream.Collectors.toList ( ) ) ; }

Target:
private java.util.List < org.ovirt.engine.core.common.businessentities.StorageDomain > searchStorageDomain ( ) { return genericSearch ( storageDomainDao , true ) ; }
Source:
public org.ovirt.engine.ui.common.uicommon.model.SearchableDetailModelProvider < org.ovirt.engine.core.common.businessentities.VmTemplate , org.ovirt.engine.ui.uicommonweb.models.storage.StorageListModel , org.ovirt.engine.ui.uicommonweb.models.storage.StorageRegisterTemplateListModel > getStorageRegisterTemplateListProvider ( com.google.gwt.event.shared.EventBus eventBus , com.google.inject.Provider < org.ovirt.engine.ui.common.presenter.popup.DefaultConfirmationPopupPresenterWidget > defaultConfirmPopupProvider ) { return new org.ovirt.engine.ui.common.uicommon.model.SearchableDetailTabModelProvider < org.ovirt.engine.core.common.businessentities.VmTemplate , org.ovirt.engine.ui.uicommonweb.models.storage.StorageListModel , org.ovirt.engine.ui.uicommonweb.models.storage.StorageRegisterTemplateListModel > ( eventBus , defaultConfirmPopupProvider , org.ovirt.engine.ui.uicommonweb.models.storage.StorageListModel.class , org.ovirt.engine.ui.uicommonweb.models.storage.StorageRegisterTemplateListModel.class ) ; }

Target:
public org.ovirt.engine.ui.common.presenter.AbstractModelBoundPopupPresenterWidget < ? extends org.ovirt.engine.ui.uicommonweb.models.Model , ? > getModelPopup ( org.ovirt.engine.ui.uicommonweb.models.storage.StorageRegisterTemplateListModel source , org.ovirt.engine.ui.uicommonweb.UICommand lastExecutedCommand , org.ovirt.engine.ui.uicommonweb.models.Model windowModel ) { if ( lastExecutedCommand == ( getModel ( ) . getImportCommand ( ) ) ) { return registerEntityPopupProvider.get ( ) ; } else { return super . getModelPopup ( source , lastExecutedCommand , windowModel ) ; } }
Source:
public java.lang.String toString ( ) { java.lang.StringBuilder builder = new java.lang.StringBuilder ( ) ; builder.append ( "NetworkClusterId [clusterId=" ) . append ( getClusterId ( ) ) . append ( ", networkId=" ) . append ( getNetworkId ( ) ) . append ( "]" ) ; return builder.toString ( ) ; }

Target:
public java.lang.String toString ( ) { java.lang.StringBuilder builder = new java.lang.StringBuilder ( ) ; builder.append ( "{clusterId=" ) . append ( getClusterId ( ) ) . append ( ", networkId=" ) . append ( getNetworkId ( ) ) . append ( "}" ) ; return builder.toString ( ) ; }
Source:
private boolean isTemplateInDestStorageDomain ( org.ovirt.engine.core.compat.Guid imageId , org.ovirt.engine.core.compat.Guid sourceDomainId ) { org.ovirt.engine.core.compat.Guid templateId = getDiskImageByImageId ( imageId ) . getImageTemplateId ( ) ; if ( ! ( Guid.Empty.equals ( templateId ) ) ) { org.ovirt.engine.core.common.businessentities.storage.DiskImage templateImage = getDiskImageDao ( ) . get ( templateId ) ; if ( ! ( templateImage.getStorageIds ( ) . contains ( sourceDomainId ) ) ) { return failCanDoAction ( EngineMessage.ACTION_TYPE_FAILED_TEMPLATE_NOT_FOUND_ON_DESTINATION_DOMAIN ) ; } } return true ; }

Target:
private boolean isTemplateInDestStorageDomain ( org.ovirt.engine.core.compat.Guid imageId , org.ovirt.engine.core.compat.Guid sourceDomainId ) { org.ovirt.engine.core.compat.Guid templateId = getDiskImageByImageId ( imageId ) . getImageTemplateId ( ) ; if ( ! ( Guid.Empty.equals ( templateId ) ) ) { org.ovirt.engine.core.common.businessentities.storage.DiskImage templateImage = org.ovirt.engine.core.bll.storage.lsm.LiveMigrateVmDisksCommand.getDiskImageDao ( ) . get ( templateId ) ; if ( ! ( templateImage.getStorageIds ( ) . contains ( sourceDomainId ) ) ) { return failCanDoAction ( EngineMessage.ACTION_TYPE_FAILED_TEMPLATE_NOT_FOUND_ON_DESTINATION_DOMAIN ) ; } } return true ; }
Source:
protected void executeQueryCommand ( ) { org.ovirt.engine.core.common.businessentities.VM vm = null ; org.ovirt.engine.core.common.businessentities.VmPool vmpool = vmPoolDao.getByName ( org.ovirt.engine.core.bll.GetVmDataByPoolNameQuery.getParameters ( ) . getName ( ) ) ; if ( vmpool != null ) { org.ovirt.engine.core.common.queries.VdcQueryReturnValue getVmRet = org.ovirt.engine.core.bll.GetVmDataByPoolNameQuery.getBackend ( ) . runInternalQuery ( VdcQueryType.GetVmDataByPoolId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( vmpool.getVmPoolId ( ) ) ) ; if ( getVmRet != null ) { vm = getVmRet.getReturnValue ( ) ; } } org.ovirt.engine.core.bll.GetVmDataByPoolNameQuery.getQueryReturnValue ( ) . setReturnValue ( vm ) ; }

Target:
protected void executeQueryCommand ( ) { org.ovirt.engine.core.common.businessentities.VM vm = null ; org.ovirt.engine.core.common.businessentities.VmPool vmpool = vmPoolDao.getByName ( org.ovirt.engine.core.bll.GetVmDataByPoolNameQuery.getParameters ( ) . getName ( ) ) ; if ( vmpool != null ) { org.ovirt.engine.core.common.queries.VdcQueryReturnValue getVmRet = backend.runInternalQuery ( VdcQueryType.GetVmDataByPoolId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( vmpool.getVmPoolId ( ) ) ) ; if ( getVmRet != null ) { vm = getVmRet.getReturnValue ( ) ; } } org.ovirt.engine.core.bll.GetVmDataByPoolNameQuery.getQueryReturnValue ( ) . setReturnValue ( vm ) ; }
Source:
private void doTestBadUpdate ( boolean canDo , boolean success , java.lang.String detail ) throws java.lang.Exception { setUpGetEntityExpectations ( 1 ) ; setUriInfo ( setUpActionExpectations ( VdcActionType.UpdateVds , org.ovirt.engine.core.common.action.UpdateVdsActionParameters.class , new java.lang.String [ ] { "RootPassword" } , new java.lang.Object [ ] { "" } , canDo , success ) ) ; try { resource.update ( org.ovirt.engine.api.restapi.resource.BackendHostsResourceTest.getModel ( 0 ) ) ; fail ( "expected WebApplicationException" ) ; } catch ( javax.ws.rs.WebApplicationException wae ) { verifyFault ( wae , detail ) ; } }

Target:
private void doTestBadUpdate ( boolean canDo , boolean success , java.lang.String detail ) throws java.lang.Exception { setUpGetEntityWithNoCertificateInfoExpectations ( 1 ) ; setUriInfo ( setUpActionExpectations ( VdcActionType.UpdateVds , org.ovirt.engine.core.common.action.UpdateVdsActionParameters.class , new java.lang.String [ ] { "RootPassword" } , new java.lang.Object [ ] { "" } , canDo , success ) ) ; try { resource.update ( org.ovirt.engine.api.restapi.resource.BackendHostsResourceTest.getModel ( 0 ) ) ; fail ( "expected WebApplicationException" ) ; } catch ( javax.ws.rs.WebApplicationException wae ) { verifyFault ( wae , detail ) ; } }
Source:
public static void GetVmSnapshotList ( 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 ? ( ( java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Snapshot > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Snapshot > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetAllVmSnapshotsByVmId , new org.ovirt.engine.core.common.queries.GetAllVmSnapshotsByVmIdParameters ( id ) , aQuery ) ; }

Target:
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 ) ; }
Source:
public static void RunAction ( final org.ovirt.engine.core.common.action.VdcActionType actionType , final org.ovirt.engine.core.common.action.VdcActionParametersBase parameters , final org.ovirt.engine.ui.uicompat.IFrontendActionAsyncCallback callback , final java.lang.Object state ) { org.ovirt.engine.ui.frontend.Frontend.runActionImpl ( actionType , parameters , ( callback != null ? callback : org.ovirt.engine.ui.frontend.Frontend.NULLABLE_ASYNC_CALLBACK ) , state , true ) ; }

Target:
public static void RunAction ( final org.ovirt.engine.core.common.action.VdcActionType actionType , final org.ovirt.engine.core.common.action.VdcActionParametersBase parameters , final org.ovirt.engine.ui.uicompat.IFrontendActionAsyncCallback callback , final java.lang.Object state , final boolean showErrorDialog ) { final org.ovirt.engine.ui.frontend.gwtservices.GenericApiGWTServiceAsync service = GenericApiGWTServiceAsync.Util.getInstance ( ) ; org.ovirt.engine.ui.frontend.Frontend.runActionImpl ( actionType , parameters , ( callback != null ? callback : org.ovirt.engine.ui.frontend.Frontend.NULLABLE_ASYNC_CALLBACK ) , state , showErrorDialog , service ) ; }
Source:
private void reportMTUDifferences ( java.util.List < org.ovirt.engine.core.common.businessentities.network.Network > ifaceNetworks ) { java.util.List < java.lang.String > mtuDiffNetworks = new java.util.ArrayList < java.lang.String > ( ) ; for ( org.ovirt.engine.core.common.businessentities.network.Network net : ifaceNetworks ) { mtuDiffNetworks.add ( java.lang.String.format ( "%s(%s)" , net.getName ( ) , ( ( net.getMtu ( ) ) == 0 ? "default" : java.lang.String.valueOf ( net.getMtu ( ) ) ) ) ) ; } addViolation ( VdcBllMessages.NETWORK_MTU_DIFFERENCES , java.lang.String.format ( "[%s]" , org.apache.commons.lang.StringUtils.join ( mtuDiffNetworks , ", " ) ) ) ; }

Target:
private void reportMTUDifferences ( java.util.List < org.ovirt.engine.core.common.businessentities.network.Network > ifaceNetworks ) { java.util.List < java.lang.String > mtuDiffNetworks = new java.util.ArrayList < > ( ) ; for ( org.ovirt.engine.core.common.businessentities.network.Network net : ifaceNetworks ) { mtuDiffNetworks.add ( java.lang.String.format ( "%s(%s)" , net.getName ( ) , ( ( net.getMtu ( ) ) == 0 ? "default" : java.lang.String.valueOf ( net.getMtu ( ) ) ) ) ) ; } addViolation ( EngineMessage.NETWORK_MTU_DIFFERENCES , java.lang.String.format ( "[%s]" , org.apache.commons.lang.StringUtils.join ( mtuDiffNetworks , ", " ) ) ) ; }
Source:
protected void alertIfFencingDisabled ( ) { if ( ! ( getVdsGroup ( ) . getFencingPolicy ( ) . isFencingEnabled ( ) ) ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableBase alb = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableBase ( ) ; alb.setVdsGroupId ( getVdsGroup ( ) . getId ( ) ) ; alb.setRepeatable ( true ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.log ( alb , AuditLogType.FENCING_DISABLED_IN_CLUSTER_POLICY ) ; } }

Target:
protected void alertIfFencingDisabled ( ) { if ( ! ( getVdsGroup ( ) . getFencingPolicy ( ) . isFencingEnabled ( ) ) ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableBase alb = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableBase ( ) ; alb.setVdsGroupId ( getVdsGroup ( ) . getId ( ) ) ; alb.setRepeatable ( true ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.log ( alb , AuditLogType.FENCE_DISABLED_IN_CLUSTER_POLICY ) ; } }
Source:
public boolean isSmtpEncryptionNone ( ) { return org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION_NONE.equals ( getProperty ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION , true ) ) ; }

Target:
public boolean isSmtpEncryptionOptionValid ( ) { return ( ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION_NONE.equals ( getProperty ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION , true ) ) ) || ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION_SSL.equals ( getProperty ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION , true ) ) ) ) || ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION_TLS.equals ( getProperty ( org.ovirt.engine.core.notifier.utils.NotificationProperties.MAIL_SMTP_ENCRYPTION , true ) ) ) ; }
Source:
private org.ovirt.engine.core.bll.ValidationResult nicActuallyExistsOrReferencesNewBond ( org.ovirt.engine.core.common.businessentities.network.NetworkAttachment attachment ) { boolean nicActuallyExistsOrReferencesNewBond = isNicActuallyExistsOrReferencesNewBond ( attachment.getNicName ( ) , attachment.getNicId ( ) ) ; if ( nicActuallyExistsOrReferencesNewBond ) { return org.ovirt.engine.core.bll.ValidationResult.VALID ; } return new org.ovirt.engine.core.bll.ValidationResult ( org.ovirt.engine.core.common.errors.EngineMessage.HOST_NETWORK_INTERFACE_NOT_EXIST ) ; }

Target:
private org.ovirt.engine.core.bll.ValidationResult nicActuallyExistsOrReferencesNewBond ( org.ovirt.engine.core.common.businessentities.network.NetworkAttachment attachment ) { java.lang.String nicName = attachment.getNicName ( ) ; org.ovirt.engine.core.compat.Guid nicId = attachment.getNicId ( ) ; boolean nicActuallyExistsOrReferencesNewBond = isNicActuallyExistsOrReferencesNewBond ( nicName , nicId ) ; return org.ovirt.engine.core.bll.ValidationResult.failWith ( EngineMessage.HOST_NETWORK_INTERFACE_HAVING_ID_OR_NAME_DOES_NOT_EXIST , org.ovirt.engine.core.utils.ReplacementUtils.createSetVariableString ( org.ovirt.engine.core.bll.network.host.HostSetupNetworksValidator.VAR_NIC_ID , nicId ) , org.ovirt.engine.core.utils.ReplacementUtils.createSetVariableString ( org.ovirt.engine.core.bll.network.host.HostSetupNetworksValidator.VAR_NIC_NAME , nicName ) ) . when ( ( ! nicActuallyExistsOrReferencesNewBond ) ) ; }
Source:
public void tAggregateRow_7_AGGIN_error ( java.lang.Exception exception , java.lang.String errorComponent , final java.util.Map < java.lang.String , java.lang.Object > globalMap ) throws ovirt_engine_dwh.aggregationtodaily_3_6.AggregationToDaily.TalendException { end_Hash.put ( "tAggregateRow_7_AGGIN" , java.lang.System.currentTimeMillis ( ) ) ; ( ( java.util.Map ) ( threadLocal.get ( ) ) ) . put ( "status" , "failure" ) ; tJDBCInput_13_onSubJobError ( exception , errorComponent , globalMap ) ; }

Target:
public void talendLogs_LOGS_error ( java.lang.Exception exception , java.lang.String errorComponent , final java.util.Map < java.lang.String , java.lang.Object > globalMap ) throws ovirt_engine_dwh.aggregationtodaily_3_6.AggregationToDaily.TalendException { talendLogs_CONSOLE_error ( exception , errorComponent , globalMap ) ; }
Source:
private void setSelectedProtocol ( org.ovirt.engine.ui.uicommonweb.models.ConsoleProtocol selectedProtocol ) { model.getModel ( ) . setSelectedProtocol ( selectedProtocol ) ; }

Target:
private void setSelectedRdpImpl ( ) { org.ovirt.engine.ui.uicommonweb.models.vms.RdpConsoleModel rdpModel = model.getVmConsoles ( ) . getConsoleModel ( org.ovirt.engine.ui.uicommonweb.models.vms.RdpConsoleModel.class ) ; if ( rdpAutoImplRadioButton.asRadioButton ( ) . getValue ( ) ) { rdpModel.setRdpImplementation ( RdpConsoleModel.ClientConsoleMode.Auto ) ; } else if ( rdpNativeImplRadioButton.asRadioButton ( ) . getValue ( ) ) { rdpModel.setRdpImplementation ( RdpConsoleModel.ClientConsoleMode.Native ) ; } else if ( rdpPluginImplRadioButton.asRadioButton ( ) . getValue ( ) ) { rdpModel.setRdpImplementation ( RdpConsoleModel.ClientConsoleMode.Plugin ) ; } }
Source:
public java.lang.String renderNullSafe ( org.ovirt.engine.core.common.businessentities.Quota quota ) { return quota.getQuotaName ( ) ; }

Target:
void initEditors ( ) { volumeTypeListEditor = new org.ovirt.engine.ui.common.widget.editor.ListModelListBoxEditor ( new org.ovirt.engine.ui.common.widget.renderer.EnumRenderer < org.ovirt.engine.core.common.businessentities.VolumeType > ( ) ) ; storageListEditor = new org.ovirt.engine.ui.common.widget.editor.ListModelListBoxEditor ( new org.ovirt.engine.ui.common.widget.renderer.StorageDomainFreeSpaceRenderer ( ) ) ; sourceStorageListEditor = new org.ovirt.engine.ui.common.widget.editor.ListModelListBoxEditor ( new org.ovirt.engine.ui.common.widget.renderer.StorageDomainFreeSpaceRenderer ( ) ) ; diskProfileListEditor = new org.ovirt.engine.ui.common.widget.editor.ListModelListBoxEditor ( new org.ovirt.engine.ui.common.widget.renderer.NameRenderer < org.ovirt.engine.core.common.businessentities.profiles.DiskProfile > ( ) ) ; quotaListEditor = new org.ovirt.engine.ui.common.widget.editor.ListModelListBoxEditor ( new org.ovirt.engine.ui.common.widget.renderer.NameRenderer < org.ovirt.engine.core.common.businessentities.Quota > ( ) ) ; }
Source:
private void updateConsoleAddressPartiallyOverridden ( org.ovirt.engine.core.common.businessentities.VDSGroup cluster ) { org.ovirt.engine.ui.frontend.AsyncQuery query = 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 ) { boolean isConsistent = ( ( org.ovirt.engine.core.common.queries.VdcQueryReturnValue ) ( returnValue ) ) . getReturnValue ( ) ; setConsoleAddressPartiallyOverridden ( ( ! isConsistent ) ) ; } } ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.IsDisplayAddressConsistentInCluster , new org.ovirt.engine.core.common.queries.IdQueryParameters ( cluster.getId ( ) ) , query ) ; }

Target:
private void updateConsoleAddressPartiallyOverridden ( org.ovirt.engine.core.common.businessentities.Cluster cluster ) { org.ovirt.engine.ui.frontend.AsyncQuery query = 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 ) { boolean isConsistent = ( ( org.ovirt.engine.core.common.queries.VdcQueryReturnValue ) ( returnValue ) ) . getReturnValue ( ) ; setConsoleAddressPartiallyOverridden ( ( ! isConsistent ) ) ; } } ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.IsDisplayAddressConsistentInCluster , new org.ovirt.engine.core.common.queries.IdQueryParameters ( cluster.getId ( ) ) , query ) ; }
Source:
private org.ovirt.engine.core.bll.network.macpool.MacsStorage createMacsStorage ( java.util.Collection < org.apache.commons.lang.math.LongRange > rangesBoundaries ) { org.ovirt.engine.core.bll.network.macpool.MacsStorage macsStorage = new org.ovirt.engine.core.bll.network.macpool.MacsStorage ( allowDuplicates ) ; for ( org.apache.commons.lang.math.LongRange range : rangesBoundaries ) { macsStorage.addRange ( range.getMinimumLong ( ) , range.getMaximumLong ( ) ) ; } if ( macsStorage.availableMacExist ( ) ) { return macsStorage ; } else { throw new org.ovirt.engine.core.common.errors.EngineException ( org.ovirt.engine.core.common.errors.EngineError.MAC_POOL_INITIALIZATION_FAILED ) ; } }

Target:
private org.ovirt.engine.core.bll.network.macpool.MacsStorage createMacsStorage ( java.util.Collection < org.apache.commons.lang.math.LongRange > rangesBoundaries ) { org.ovirt.engine.core.bll.network.macpool.MacsStorage macsStorage = new org.ovirt.engine.core.bll.network.macpool.MacsStorage ( allowDuplicates ) ; for ( org.apache.commons.lang.math.LongRange range : rangesBoundaries ) { org.ovirt.engine.core.bll.network.macpool.MacPoolUsingRanges.log.debug ( "Adding range to pool {}." , range , this ) ; macsStorage.addRange ( range.getMinimumLong ( ) , range.getMaximumLong ( ) ) ; } if ( macsStorage.availableMacExist ( ) ) { return macsStorage ; } else { throw new org.ovirt.engine.core.common.errors.EngineException ( org.ovirt.engine.core.common.errors.EngineError.MAC_POOL_INITIALIZATION_FAILED ) ; } }