auphong2707/dl4se-code-review-dataset huggingface dataset:
Source:
protected boolean isVmNameValidLength ( org.ovirt.engine.core.common.businessentities.VM vm ) { java.lang.String vmName = vm.getName ( ) ; int maxVmNameLengthWindows = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.MaxVmNameLengthWindows ) ; int maxVmNameLengthNonWindows = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.MaxVmNameLengthNonWindows ) ; int maxLength = ( vm.getVmOs ( ) . isWindows ( ) ) ? maxVmNameLengthWindows : maxVmNameLengthNonWindows ; boolean nameLengthValid = ( vmName.length ( ) ) <= maxLength ; return nameLengthValid ; }

Target:
protected boolean isVmNameValidLength ( org.ovirt.engine.core.common.businessentities.VM vm ) { java.lang.String vmName = vm.getName ( ) ; int maxVmNameLengthWindows = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.MaxVmNameLengthWindows ) ; int maxVmNameLengthNonWindows = org.ovirt.engine.core.common.config.Config.< java.lang.Integer > GetValue ( ConfigValues.MaxVmNameLengthNonWindows ) ; int maxLength = ( osRepository.isWindows ( vm.getVmOsId ( ) ) ) ? maxVmNameLengthWindows : maxVmNameLengthNonWindows ; boolean nameLengthValid = ( vmName.length ( ) ) <= maxLength ; return nameLengthValid ; }
Source:
public static void GetClusterGlusterServices ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters parameters = new org.ovirt.engine.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters ( clusterId , null , null , false ) ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetGlusterVolumeAdvancedDetails , parameters , aQuery ) ; }

Target:
public static void getClusterGlusterServices ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters parameters = new org.ovirt.engine.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters ( clusterId , null , null , false ) ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetGlusterVolumeAdvancedDetails , parameters , aQuery ) ; }
Source:
public void testUpdate ( ) throws java.lang.Exception { setUpEntityQueryExpectations ( getVm ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , VMStatus.Down ) ) ; setUpEntityQueryExpectations ( getVm ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO , org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , VMStatus.Down ) ) ; setUriInfo ( setUpActionExpectations ( ActionType.UpdateVm , org.ovirt.engine.core.common.action.VmManagementParametersBase.class , new java.lang.String [ ] { "VmStaticData.IsoPath" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO } , true , true ) ) ; org.ovirt.engine.api.model.Cdrom cdrom = getCdrom ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO ) ; cdrom = resource.update ( cdrom ) ; assertTrue ( cdrom.isSetFile ( ) ) ; }

Target:
public void testUpdate ( ) throws java.lang.Exception { setUpEntityQueryExpectations ( getVm ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , VMStatus.Down ) ) ; setUpEntityQueryExpectations ( getVm ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO , org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.A_ISO , VMStatus.Down ) ) ; setUriInfo ( setUpActionExpectations ( ActionType.UpdateVm , org.ovirt.engine.core.common.action.VmManagementParametersBase.class , new java.lang.String [ ] { "VmStaticData.IsoPath" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO } , true , true ) ) ; org.ovirt.engine.api.model.Cdrom cdrom = getCdrom ( org.ovirt.engine.api.restapi.resource.BackendVmCdromResourceTest.B_ISO ) ; cdrom = resource.update ( cdrom ) ; org.junit.Assert.assertTrue ( cdrom.isSetFile ( ) ) ; }
Source:
protected void updateQuota ( org.ovirt.engine.core.common.businessentities.DiskImage diskImage ) { if ( isQuotaValidationNeeded ( ) ) { org.ovirt.engine.core.common.businessentities.DiskImage oldDisk = ( ( org.ovirt.engine.core.common.businessentities.DiskImage ) ( getOldDisk ( ) ) ) ; if ( ! ( java.util.Objects.equals ( oldDisk.getQuotaId ( ) , diskImage.getQuotaId ( ) ) ) ) { org.ovirt.engine.core.bll.UpdateVmDiskCommand.getImageStorageDomainMapDao ( ) . updateQuotaForImageAndSnapshots ( diskImage.getId ( ) , diskImage.getStorageIds ( ) . get ( 0 ) , diskImage.getQuotaId ( ) ) ; } } }

Target:
protected void updateQuota ( org.ovirt.engine.core.common.businessentities.DiskImage diskImage ) { if ( isDiskImage ( ) ) { org.ovirt.engine.core.common.businessentities.DiskImage oldDisk = ( ( org.ovirt.engine.core.common.businessentities.DiskImage ) ( getOldDisk ( ) ) ) ; if ( ! ( java.util.Objects.equals ( oldDisk.getQuotaId ( ) , diskImage.getQuotaId ( ) ) ) ) { org.ovirt.engine.core.bll.UpdateVmDiskCommand.getImageStorageDomainMapDao ( ) . updateQuotaForImageAndSnapshots ( diskImage.getId ( ) , diskImage.getStorageIds ( ) . get ( 0 ) , diskImage.getQuotaId ( ) ) ; } } }
Source:
private static void initClusterSeverities ( ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_ADD_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_ADD_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_UPDATE_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_UPDATE_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_REMOVE_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_REMOVE_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; }

Target:
private static void initClusterSeverities ( ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_ADD_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_ADD_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_UPDATE_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_UPDATE_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_REMOVE_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_REMOVE_VDS_GROUP_FAILED , AuditLogSeverity.ERROR ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.SYSTEM_UPDATE_VDS_GROUP , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.SYSTEM_UPDATE_VDS_GROUP_FAILED , AuditLogSeverity.NORMAL ) ; org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogDirector.mSeverities.put ( AuditLogType.USER_UPDATE_VM_CLUSTER_DEFAULT_HOST_CLEARED , AuditLogSeverity.NORMAL ) ; }
Source:
public void testList ( ) throws java.lang.Exception { setUriInfo ( setUpBasicUriExpectations ( ) ) ; setUpEntityQueryExpectations ( VdcQueryType.GetVmByVmId , org.ovirt.engine.core.common.queries.IdQueryParameters.class , new java.lang.String [ ] { "Id" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendVmApplicationsResourceTest.VM_ID } , getVm ( ) ) ; verifyApplications ( resource.list ( ) ) ; }

Target:
public void testList ( ) throws java.lang.Exception { setUriInfo ( setUpBasicUriExpectations ( ) ) ; setUpEntityQueryExpectations ( QueryType.GetVmByVmId , org.ovirt.engine.core.common.queries.IdQueryParameters.class , new java.lang.String [ ] { "Id" } , new java.lang.Object [ ] { org.ovirt.engine.api.restapi.resource.BackendVmApplicationsResourceTest.VM_ID } , getVm ( ) ) ; verifyApplications ( resource.list ( ) ) ; }
Source:
protected void runningFailed ( ) { org.ovirt.engine.core.bll.Backend.getInstance ( ) . getResourceManager ( ) . RemoveAsyncRunningCommand ( org.ovirt.engine.core.bll.RunVmCommandBase.getVmId ( ) ) ; _isRerun = false ; org.ovirt.engine.core.bll.RunVmCommandBase.setSucceeded ( false ) ; org.ovirt.engine.core.bll.RunVmCommandBase.log ( ) ; processVmPoolOnStopVm ( ) ; org.ovirt.engine.core.bll.job.ExecutionHandler.setAsyncJob ( org.ovirt.engine.core.bll.RunVmCommandBase.getExecutionContext ( ) , false ) ; org.ovirt.engine.core.bll.job.ExecutionHandler.endJob ( org.ovirt.engine.core.bll.RunVmCommandBase.getExecutionContext ( ) , false ) ; }

Target:
protected void runningFailed ( ) { try { org.ovirt.engine.core.bll.Backend.getInstance ( ) . getResourceManager ( ) . RemoveAsyncRunningCommand ( org.ovirt.engine.core.bll.RunVmCommandBase.getVmId ( ) ) ; _isRerun = false ; org.ovirt.engine.core.bll.RunVmCommandBase.setSucceeded ( false ) ; org.ovirt.engine.core.bll.RunVmCommandBase.log ( ) ; processVmPoolOnStopVm ( ) ; org.ovirt.engine.core.bll.job.ExecutionHandler.setAsyncJob ( org.ovirt.engine.core.bll.RunVmCommandBase.getExecutionContext ( ) , false ) ; org.ovirt.engine.core.bll.job.ExecutionHandler.endJob ( org.ovirt.engine.core.bll.RunVmCommandBase.getExecutionContext ( ) , false ) ; } finally { org.ovirt.engine.core.bll.RunVmCommandBase.freeLock ( ) ; } }
Source:
public void getGlusterHooks ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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 ? source : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterHookEntity > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterHooks , new org.ovirt.engine.core.common.queries.gluster.GlusterParameters ( clusterId ) , aQuery ) ; }

Target:
public java.lang.Object Convert ( java.lang.Object returnValue , org.ovirt.engine.ui.frontend.AsyncQuery asyncQuery ) { return returnValue == null ? new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepNonEligibilityReason > ( ) : ( ( java.util.List < org.ovirt.engine.core.common.businessentities.gluster.GlusterGeoRepNonEligibilityReason > ) ( returnValue ) ) ; }
Source:
public static void getGlusterBricksForServer ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid serverId ) { 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 ? source : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterVolumeBricksByServerId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( serverId ) , aQuery ) ; }

Target:
public static void getGlusterSwiftServerServices ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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 ? source : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterServerService > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterServerServicesByClusterId , new org.ovirt.engine.core.common.queries.gluster.GlusterServiceQueryParameters ( clusterId , org.ovirt.engine.core.common.businessentities.gluster.ServiceType.GLUSTER_SWIFT ) , aQuery ) ; }
Source:
public void getGlusterHostsNewlyAdded ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId , boolean isFingerprintRequired ) { 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.GetAddedGlusterServers , new org.ovirt.engine.core.common.queries.gluster.AddedGlusterServersParameters ( clusterId , isFingerprintRequired ) , aQuery ) ; }

Target:
public void getClusterGlusterServices ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters parameters = new org.ovirt.engine.core.common.queries.gluster.GlusterVolumeAdvancedDetailsParameters ( clusterId , null , null , false ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterVolumeAdvancedDetails , parameters , aQuery ) ; }
Source:
public static void initDiskHotpluggableInterfacesMap ( ) { org.ovirt.engine.ui.frontend.AsyncQuery callback = new org.ovirt.engine.ui.frontend.AsyncQuery ( ) ; callback.asyncCallback = new org.ovirt.engine.ui.frontend.INewAsyncCallback ( ) { @ java.lang.Override public void onSuccess ( java.lang.Object model , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.diskHotpluggableInterfacesMap = ( ( org.ovirt.engine.core.common.queries.VdcQueryReturnValue ) ( returnValue ) ) . getReturnValue ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.OsRepository , new org.ovirt.engine.core.common.queries.OsQueryParameters ( org.ovirt.engine.core.common.queries.OsQueryParameters.OsRepositoryVerb.GetDiskHotpluggableInterfacesMap ) , callback ) ; }

Target:
public void initBalloonSupportMap ( ) { org.ovirt.engine.ui.frontend.AsyncQuery callback = new org.ovirt.engine.ui.frontend.AsyncQuery ( ) ; callback.asyncCallback = new org.ovirt.engine.ui.frontend.INewAsyncCallback ( ) { @ java.lang.Override public void onSuccess ( java.lang.Object model , java.lang.Object returnValue ) { balloonSupportMap = ( ( java.util.Map < java.lang.Integer , java.util.Map < org.ovirt.engine.core.compat.Version , java.lang.Boolean > > ) ( ( ( org.ovirt.engine.core.common.queries.VdcQueryReturnValue ) ( returnValue ) ) . getReturnValue ( ) ) ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.OsRepository , new org.ovirt.engine.core.common.queries.OsQueryParameters ( org.ovirt.engine.core.common.queries.OsQueryParameters.OsRepositoryVerb.GetBalloonSupportMap ) , callback ) ; }
Source:
public org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc snapshot ( java.lang.String vmId , java.util.Map < java.lang.String , java.lang.String > [ ] snapParams ) { try { java.util.Map < java.lang.String , java.lang.Object > xmlRpcReturnValue = vdsServer.snapshot ( vmId , snapParams ) ; org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc wrapper = new org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc ( xmlRpcReturnValue ) ; return wrapper ; } catch ( java.lang.reflect.UndeclaredThrowableException ute ) { throw new org.ovirt.engine.core.vdsbroker.xmlrpc.XmlRpcRunTimeException ( ute ) ; } }

Target:
public org.ovirt.engine.core.vdsbroker.vdsbroker.AlignmentScanReturnForXmlRpc getDiskAlignment ( java.lang.String vmId , java.util.Map < java.lang.String , java.lang.String > driveSpecs ) { try { java.util.Map < java.lang.String , java.lang.Object > xmlRpcReturnValue = vdsServer.getDiskAlignment ( vmId , driveSpecs ) ; org.ovirt.engine.core.vdsbroker.vdsbroker.AlignmentScanReturnForXmlRpc wrapper = new org.ovirt.engine.core.vdsbroker.vdsbroker.AlignmentScanReturnForXmlRpc ( xmlRpcReturnValue ) ; return wrapper ; } catch ( java.lang.reflect.UndeclaredThrowableException ute ) { throw new org.ovirt.engine.core.vdsbroker.xmlrpc.XmlRpcRunTimeException ( ute ) ; } }
Source:
public void getGlusterHooks ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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 ? source : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterHookEntity > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterHooks , new org.ovirt.engine.core.common.queries.gluster.GlusterParameters ( clusterId ) , aQuery ) ; }

Target:
public void getGlusterBricksForServer ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid serverId ) { 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 ? source : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.gluster.GlusterBrickEntity > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterVolumeBricksByServerId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( serverId ) , aQuery ) ; }
Source:
public static void GetClusterNetworkList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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 getStorageDomainById ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid storageDomainId ) { 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 ? ( ( org.ovirt.engine.core.common.businessentities.StorageDomain ) ( source ) ) : null ; } } ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetStorageDomainById , new org.ovirt.engine.core.common.queries.IdQueryParameters ( storageDomainId ) , aQuery ) ; }
Source:
public void Search ( ) { if ( ( getEntity ( ) ) != null ) { setSearchString ( org.ovirt.engine.core.compat.StringFormat.format ( "clusters: network.name=%1$s" , getEntity ( ) . getname ( ) ) ) ; super . Search ( ) ; } }

Target:
public void ExecuteCommand ( org.ovirt.engine.ui.uicommonweb.UICommand command ) { super . ExecuteCommand ( command ) ; if ( command == ( getManageCommand ( ) ) ) { Manage ( ) ; } else if ( org.ovirt.engine.core.compat.StringHelper.stringsEqual ( command.getName ( ) , "OnManage" ) ) { OnManage ( ) ; } else if ( org.ovirt.engine.core.compat.StringHelper.stringsEqual ( command.getName ( ) , "Cancel" ) ) { Cancel ( ) ; } }
Source:
public static java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VmOsType > getLinuxOsTypes ( ) { if ( ( org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.linuxOsTypes ) != null ) { return org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.linuxOsTypes ; } org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.linuxOsTypes = new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.VmOsType > ( java.util.Arrays.asList ( new org.ovirt.engine.core.common.businessentities.VmOsType [ ] { org.ovirt.engine.core.common.businessentities.VmOsType.OtherLinux , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL3 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL3x64 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL4 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL4x64 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL5 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL5x64 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL6 , org.ovirt.engine.core.common.businessentities.VmOsType.RHEL6x64 } ) ) ; return org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.linuxOsTypes ; }

Target:
public void onSuccess ( java.lang.Object model , java.lang.Object returnValue ) { org.ovirt.engine.ui.uicommonweb.dataprovider.AsyncDataProvider.windowsOsIds = ( ( java.util.ArrayList < java.lang.Integer > ) ( ( ( org.ovirt.engine.core.common.queries.VdcQueryReturnValue ) ( returnValue ) ) . getReturnValue ( ) ) ) ; }
Source:
private org.ovirt.engine.core.common.businessentities.HostDevice fetchHostDevice ( java.lang.String deviceName ) { return hostDeviceDao.getHostDeviceByHostIdAndDeviceName ( org.ovirt.engine.core.bll.hostdev.AbstractVmHostDevicesCommand.getVm ( ) . getDedicatedVmForVds ( ) , deviceName ) ; }

Target:
private java.util.Collection < org.ovirt.engine.core.common.businessentities.HostDevice > getDeviceAtomicGroup ( org.ovirt.engine.core.common.businessentities.HostDevice hostDevice ) { if ( ! ( hasIommu ( hostDevice ) ) ) { return java.util.Collections.singleton ( hostDevice ) ; } return hostDeviceDao.getHostDevicesByHostIdAndIommuGroup ( org.ovirt.engine.core.bll.hostdev.AbstractVmHostDevicesCommand.getVm ( ) . getDedicatedVmForVdsList ( ) . get ( 0 ) , hostDevice.getIommuGroup ( ) ) ; }
Source:
public org.ovirt.engine.ui.common.presenter.AbstractModelBoundPopupPresenterWidget < ? extends org.ovirt.engine.ui.uicommonweb.models.ConfirmationModel , ? > getConfirmModelPopup ( org.ovirt.engine.ui.uicommonweb.models.storage.StorageDataCenterListModel source , org.ovirt.engine.ui.uicommonweb.UICommand lastExecutedCommand ) { if ( lastExecutedCommand == ( getModel ( ) . getDetachCommand ( ) ) ) { return removeConfirmPopupProvider.get ( ) ; } else { return super . getConfirmModelPopup ( source , lastExecutedCommand ) ; } }

Target:
public org.ovirt.engine.ui.common.presenter.AbstractModelBoundPopupPresenterWidget < ? extends org.ovirt.engine.ui.uicommonweb.models.ConfirmationModel , ? > getConfirmModelPopup ( org.ovirt.engine.ui.uicommonweb.models.storage.StorageDataCenterListModel source , org.ovirt.engine.ui.uicommonweb.UICommand lastExecutedCommand ) { if ( ( lastExecutedCommand == ( getModel ( ) . getDetachCommand ( ) ) ) || ( lastExecutedCommand.getName ( ) . equals ( "OnAttach" ) ) ) { return removeConfirmPopupProvider.get ( ) ; } else { return super . getConfirmModelPopup ( source , lastExecutedCommand ) ; } }
Source:
public void getHostPublicKey ( 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.lang.String ) ( source ) ) : "" ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetServerSSHPublicKey , new org.ovirt.engine.core.common.queries.VdcQueryParametersBase ( ) , aQuery ) ; }

Target:
public void getHostPublicKey ( 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.lang.String ) ( source ) ) : "" ; } } ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetServerSSHPublicKey , new org.ovirt.engine.core.common.queries.VdcQueryParametersBase ( ) , aQuery ) ; }
Source:
private boolean validateNics ( java.util.List < org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface > interfaces , org.ovirt.engine.core.compat.Version clusterCompatibilityVersion ) { for ( org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface iface : interfaces ) { org.ovirt.engine.core.bll.validator.VmNicValidator nicValidator = new org.ovirt.engine.core.bll.validator.VmNicValidator ( iface , clusterCompatibilityVersion ) ; if ( ( ! ( validate ( nicValidator.networkNameValid ( ) ) ) ) || ( ! ( validate ( nicValidator.linkedCorrectly ( ) ) ) ) ) { return false ; } } return true ; }

Target:
private boolean validateNics ( java.util.List < org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface > interfaces , org.ovirt.engine.core.compat.Version clusterCompatibilityVersion ) { for ( org.ovirt.engine.core.common.businessentities.network.VmNetworkInterface iface : interfaces ) { org.ovirt.engine.core.bll.validator.VmNicValidator nicValidator = new org.ovirt.engine.core.bll.validator.VmNicValidator ( iface , clusterCompatibilityVersion ) ; if ( ( ! ( validate ( nicValidator.emptyNetworkValid ( ) ) ) ) || ( ! ( validate ( nicValidator.linkedCorrectly ( ) ) ) ) ) { return false ; } } return true ; }
Source:
public boolean IsTemplate ( ) { java.lang.String id1 = "1" ; java.lang.String id2 = "2" ; org.ovirt.engine.core.compat.backendcompat.XmlNode node = _document.SelectSingleNode ( "//*/Content/TemplateId" ) ; if ( ! ( org.apache.commons.lang.StringUtils.isBlank ( node.innerText ) ) ) { id1 = node.innerText ; } org.ovirt.engine.core.compat.backendcompat.XmlNodeList list = _document.SelectNodes ( "//*/Content/Section" ) ; for ( org.ovirt.engine.core.compat.backendcompat.XmlNode section : list ) { java.lang.String value = section.attributes.get ( "xsi:type" ) . getValue ( ) ; if ( org.apache.commons.lang.StringUtils.equals ( value , "ovf:OperatingSystemSection_Type" ) ) { id2 = section.attributes.get ( "ovf:id" ) . getValue ( ) ; } } return org.apache.commons.lang.StringUtils.equals ( id1 , id2 ) ; }

Target:
public boolean IsTemplate ( ) { java.lang.String id1 = "1" ; java.lang.String id2 = "2" ; org.ovirt.engine.core.utils.ovf.xml.XmlNode node = _document.SelectSingleNode ( "//*/Content/TemplateId" ) ; if ( ! ( org.apache.commons.lang.StringUtils.isBlank ( node.innerText ) ) ) { id1 = node.innerText ; } org.ovirt.engine.core.utils.ovf.xml.XmlNodeList list = _document.SelectNodes ( "//*/Content/Section" ) ; for ( org.ovirt.engine.core.utils.ovf.xml.XmlNode section : list ) { java.lang.String value = section.attributes.get ( "xsi:type" ) . getValue ( ) ; if ( org.apache.commons.lang.StringUtils.equals ( value , "ovf:OperatingSystemSection_Type" ) ) { id2 = section.attributes.get ( "ovf:id" ) . getValue ( ) ; } } return org.apache.commons.lang.StringUtils.equals ( id1 , id2 ) ; }
Source:
public javax.ws.rs.core.Response add ( org.ovirt.engine.api.model.Quota quota ) { validateParameters ( quota , "name" ) ; org.ovirt.engine.api.model.Quota entity = map ( quota ) ; entity.setStoragePoolId ( dataCenterId ) ; return performCreate ( ActionType.AddQuota , new org.ovirt.engine.core.common.action.QuotaCRUDParameters ( entity ) , new org.ovirt.engine.api.restapi.resource.QueryIdResolver < org.ovirt.engine.core.compat.Guid > ( org.ovirt.engine.core.common.queries.VdcQueryType.GetQuotaByQuotaId , org.ovirt.engine.core.common.queries.IdQueryParameters.class ) ) ; }

Target:
public javax.ws.rs.core.Response add ( org.ovirt.engine.api.model.Quota quota ) { validateParameters ( quota , "name" ) ; org.ovirt.engine.api.model.Quota entity = map ( quota ) ; entity.setStoragePoolId ( dataCenterId ) ; return performCreate ( ActionType.AddQuota , new org.ovirt.engine.core.common.action.QuotaCRUDParameters ( entity ) , new org.ovirt.engine.api.restapi.resource.QueryIdResolver < org.ovirt.engine.core.compat.Guid > ( org.ovirt.engine.core.common.queries.QueryType.GetQuotaByQuotaId , org.ovirt.engine.core.common.queries.IdQueryParameters.class ) ) ; }
Source:
private org.ovirt.engine.core.common.action.ActionReturnValue addNetwork ( org.ovirt.engine.core.compat.Guid dataCenterId , org.ovirt.engine.core.common.businessentities.network.Network network , boolean attachToAllClusters ) { org.ovirt.engine.core.common.action.AddNetworkStoragePoolParameters params = new org.ovirt.engine.core.common.action.AddNetworkStoragePoolParameters ( dataCenterId , network ) ; params.setVnicProfileRequired ( false ) ; if ( attachToAllClusters ) { params.setNetworkClusterList ( networkHelper.createNetworkClusters ( getAllClusterIdsInDataCenter ( dataCenterId ) ) ) ; } return runInternalAction ( ActionType.AddNetwork , params ) ; }

Target:
private org.ovirt.engine.core.common.action.ActionReturnValue addNetwork ( org.ovirt.engine.core.compat.Guid dataCenterId , org.ovirt.engine.core.common.businessentities.network.Network network , boolean attachToAllClusters ) { org.ovirt.engine.core.common.action.AddNetworkStoragePoolParameters params = new org.ovirt.engine.core.common.action.AddNetworkStoragePoolParameters ( dataCenterId , network ) ; params.setVnicProfilePublicUse ( org.ovirt.engine.core.bll.network.dc.InternalImportExternalNetworkCommand.getParameters ( ) . isPublicUse ( ) ) ; if ( attachToAllClusters ) { params.setNetworkClusterList ( networkHelper.createNetworkClusters ( getAllClusterIdsInDataCenter ( dataCenterId ) ) ) ; } return runInternalAction ( ActionType.AddNetwork , params ) ; }
Source:
protected boolean canDoAction ( ) { org.ovirt.engine.core.bll.validator.FenceValidator fenceValidator = new org.ovirt.engine.core.bll.validator.FenceValidator ( ) ; java.util.List < java.lang.String > messages = org.ovirt.engine.core.bll.pm.VdsNotRespondingTreatmentCommand.getReturnValue ( ) . getCanDoActionMessages ( ) ; boolean canDo = ( ( fenceValidator.isHostExists ( org.ovirt.engine.core.bll.pm.VdsNotRespondingTreatmentCommand.getVds ( ) , messages ) ) && ( fenceValidator.isStartupTimeoutPassed ( messages ) ) ) && ( org.ovirt.engine.core.bll.pm.VdsNotRespondingTreatmentCommand.isQuietTimeFromLastActionPassed ( ) ) ; if ( ! canDo ) { handleError ( ) ; } org.ovirt.engine.core.bll.pm.VdsNotRespondingTreatmentCommand.getReturnValue ( ) . setSucceeded ( canDo ) ; return canDo ; }

Target:
protected boolean canDoAction ( ) { org.ovirt.engine.core.bll.validator.HostValidator validator = new org.ovirt.engine.core.bll.validator.HostValidator ( org.ovirt.engine.core.bll.pm.VdsNotRespondingTreatmentCommand.getVds ( ) ) ; return validate ( validator.hostExists ( ) ) ; }
Source:
public void getExternalProviderComputeResourceList ( 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 ) { if ( source == null ) { return new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.ExternalComputeResource > ( ) ; } return source ; } } ; org.ovirt.engine.core.common.queries.ProviderQueryParameters params = new org.ovirt.engine.core.common.queries.ProviderQueryParameters ( ) ; params.setProvider ( provider ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetComputeResourceFromExternalProvider , params , aQuery ) ; }

Target:
public void getVnicProfilesByDcId ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid dcId ) { 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.VnicProfileView > ( ) ; } return source ; } } ; } org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetVnicProfilesByDataCenterId , new org.ovirt.engine.core.common.queries.IdQueryParameters ( dcId ) , aQuery ) ; }
Source:
public void testExtractVariableDeclarationsForStaticMsgs ( ) { org.ovirt.engine.core.common.action.VdcActionParametersBase parameterMock = org.mockito.Mockito.mock ( org.ovirt.engine.core.common.action.VdcActionParametersBase.class ) ; org.ovirt.engine.core.bll.CommandBase < org.ovirt.engine.core.common.action.VdcActionParametersBase > command = new org.ovirt.engine.core.bll.CommandBaseTest.CommandBaseDummy ( parameterMock ) ; java.util.List < java.lang.String > msgs = java.util.Arrays.asList ( "ACTION_TYPE_FAILED_TEMPLATE_IS_USED_FOR_CREATE_VM" , "IRS_FAILED_RETRIEVING_SNAPSHOT_INFO" ) ; junit.framework.Assert.assertTrue ( "extractVariableDeclarations didn't return the same static messages" , org.apache.commons.collections.CollectionUtils.isEqualCollection ( msgs , command.extractVariableDeclarations ( msgs ) ) ) ; }

Target:
public void testExtractVariableDeclarationsForStaticMsgs ( ) { org.ovirt.engine.core.common.action.VdcActionParametersBase parameterMock = org.mockito.Mockito.mock ( org.ovirt.engine.core.common.action.VdcActionParametersBase.class ) ; org.ovirt.engine.core.bll.CommandBase < org.ovirt.engine.core.common.action.VdcActionParametersBase > command = new org.ovirt.engine.core.bll.CommandBaseTest.CommandBaseDummy ( parameterMock ) ; java.util.List < java.lang.String > msgs = java.util.Arrays.asList ( "ACTION_TYPE_FAILED_TEMPLATE_IS_USED_FOR_CREATE_VM" , "IRS_FAILED_RETRIEVING_SNAPSHOT_INFO" ) ; org.junit.Assert.assertTrue ( "extractVariableDeclarations didn't return the same static messages" , org.apache.commons.collections.CollectionUtils.isEqualCollection ( msgs , command.extractVariableDeclarations ( msgs ) ) ) ; }
Source:
public static void GetNetworkList ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid dataCenterId ) { 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.Network > ) ( source ) ) : new java.util.ArrayList < org.ovirt.engine.core.common.businessentities.Network > ( ) ; } } ; org.ovirt.engine.ui.frontend.Frontend.RunQuery ( VdcQueryType.GetAllNetworks , new org.ovirt.engine.core.common.queries.GetAllNetworkQueryParamenters ( dataCenterId ) , 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.RunQuery ( VdcQueryType.GetAllServerCpuList , new org.ovirt.engine.core.common.queries.GetAllServerCpuListParameters ( version ) , aQuery ) ; }
Source:
protected boolean canRunVm ( org.ovirt.engine.core.common.businessentities.VM vm ) { return getVmRunHandler ( ) . canRunVm ( vm , org.ovirt.engine.core.bll.RunVmCommand.getReturnValue ( ) . getCanDoActionMessages ( ) , org.ovirt.engine.core.bll.RunVmCommand.getParameters ( ) , org.ovirt.engine.core.bll.RunVmCommand.getVdsSelector ( ) , org.ovirt.engine.core.bll.RunVmCommand.getSnapshotsValidator ( ) , getVmPropertiesUtils ( ) ) ; }

Target:
protected org.ovirt.engine.core.bll.validator.VmValidator getVmValidator ( org.ovirt.engine.core.common.businessentities.VM vm ) { return new org.ovirt.engine.core.bll.validator.VmValidator ( vm ) ; }
Source:
public void testGetNowPlusYearHttpDate ( ) { java.util.Calendar calendar = org.mockito.Mockito.spy ( java.util.Calendar.getInstance ( java.util.TimeZone.getTimeZone ( org.ovirt.engine.core.utils.servlet.CachingFilterTest.GMT ) , java.util.Locale.US ) ) ; calendar.clear ( ) ; calendar.set ( 2000 , 0 , 1 , 15 , 0 ) ; java.lang.String result = testFilter.getNowPlusYearHttpDate ( calendar ) ; org.junit.Assert.assertNotNull ( result ) ; org.junit.Assert.assertTrue ( result.contains ( "01 Jan 2001 15:00:00" ) ) ; org.mockito.Mockito.verify ( calendar ) . add ( java.util.Calendar.YEAR , 1 ) ; }

Target:
public void testGetNowPlusYearHttpDate ( ) { java.util.Calendar calendar = org.mockito.Mockito.spy ( java.util.Calendar.getInstance ( java.util.TimeZone.getTimeZone ( org.ovirt.engine.core.utils.servlet.CachingFilterTest.GMT ) , java.util.Locale.US ) ) ; calendar.clear ( ) ; calendar.set ( 2000 , 0 , 1 , 15 , 0 ) ; java.lang.String result = testFilter.getNowPlusYearHttpDate ( calendar ) ; org.junit.jupiter.api.Assertions.assertNotNull ( result ) ; org.junit.jupiter.api.Assertions.assertTrue ( result.contains ( "01 Jan 2001 15:00:00" ) ) ; org.mockito.Mockito.verify ( calendar ) . add ( java.util.Calendar.YEAR , 1 ) ; }
Source:
protected java.util.List < java.lang.String > listFiles ( ) { org.ovirt.engine.core.common.queries.GetImagesListParameters queryParams = new org.ovirt.engine.core.common.queries.GetImagesListParameters ( asGuid ( storageDomainId ) , org.ovirt.engine.core.common.businessentities.ImageType.ISO ) ; queryParams.setForceRefresh ( true ) ; java.util.List < org.ovirt.engine.core.common.businessentities.RepoFileMetaData > files = getBackendCollection ( org.ovirt.engine.core.common.businessentities.RepoFileMetaData.class , VdcQueryType.GetImagesList , queryParams ) ; java.util.List < java.lang.String > fileNames = new java.util.LinkedList < java.lang.String > ( ) ; for ( org.ovirt.engine.core.common.businessentities.RepoFileMetaData file : files ) { fileNames.add ( file.getRepoFileName ( ) ) ; } return fileNames ; }

Target:
protected java.util.List < java.lang.String > listFiles ( ) { org.ovirt.engine.core.common.queries.GetImagesListParameters queryParams = new org.ovirt.engine.core.common.queries.GetImagesListParameters ( asGuid ( storageDomainId ) , org.ovirt.engine.core.common.businessentities.ImageFileType.ISO ) ; queryParams.setForceRefresh ( true ) ; java.util.List < org.ovirt.engine.core.common.businessentities.RepoFileMetaData > files = getBackendCollection ( org.ovirt.engine.core.common.businessentities.RepoFileMetaData.class , VdcQueryType.GetImagesList , queryParams ) ; java.util.List < java.lang.String > fileNames = new java.util.LinkedList < java.lang.String > ( ) ; for ( org.ovirt.engine.core.common.businessentities.RepoFileMetaData file : files ) { fileNames.add ( file.getRepoFileName ( ) ) ; } return fileNames ; }
Source:
public org.ovirt.engine.core.vdsbroker.vdsbroker.StatusOnlyReturnForXmlRpc glusterVolumeGeoRepConfigReset ( java.lang.String volumeName , java.lang.String slaveHost , java.lang.String slaveVolumeName , java.lang.String configKey ) { org.ovirt.vdsm.jsonrpc.client.JsonRpcRequest request = new org.ovirt.vdsm.jsonrpc.client.RequestBuilder ( "GlusterVolume.geoRepConfigReset" ) . withParameter ( "volumeName" , volumeName ) . withParameter ( "remoteHost" , slaveHost ) . withParameter ( "remoteVolumeName" , slaveVolumeName ) . withParameter ( "optionName" , configKey ) . 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.StatusOnlyReturnForXmlRpc glusterVolumeGeoRepConfigReset ( java.lang.String volumeName , java.lang.String slaveHost , java.lang.String slaveVolumeName , java.lang.String configKey , java.lang.String userName ) { org.ovirt.vdsm.jsonrpc.client.JsonRpcRequest request = new org.ovirt.vdsm.jsonrpc.client.RequestBuilder ( "GlusterVolume.geoRepConfigReset" ) . withParameter ( "volumeName" , volumeName ) . withParameter ( "remoteHost" , slaveHost ) . withParameter ( "remoteVolumeName" , slaveVolumeName ) . withParameter ( "optionName" , configKey ) . withOptionalParameter ( "remoteUserName" , userName ) . 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 ) ; }
Source:
public void setUsedSwap ( java.lang.Long value ) { if ( ( ( usedSwap ) == null ) && ( value == null ) ) { return ; } if ( ( ( usedSwap ) == null ) || ( ! ( usedSwap.equals ( value ) ) ) ) { usedSwap = value ; OnPropertyChanged ( new org.ovirt.engine.core.compat.PropertyChangedEventArgs ( "UsedSwap" ) ) ; } }

Target:
public void setUsedSwap ( java.lang.Long value ) { if ( ( ( usedSwap ) == null ) && ( value == null ) ) { return ; } if ( ( ( usedSwap ) == null ) || ( ! ( usedSwap.equals ( value ) ) ) ) { usedSwap = value ; OnPropertyChanged ( new org.ovirt.engine.ui.uicompat.PropertyChangedEventArgs ( "UsedSwap" ) ) ; } }
Source:
private void auditLog ( java.util.Map < java.lang.String , java.lang.String > customValues , org.ovirt.engine.core.common.AuditLogType auditLogType ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogable logable = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableImpl ( ) ; for ( java.util.Map.Entry < java.lang.String , java.lang.String > customValue : customValues.entrySet ( ) ) { logable.addCustomValue ( customValue.getKey ( ) , customValue.getValue ( ) ) ; } getAuditLogDirector ( ) . log ( logable , auditLogType ) ; }

Target:
private org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogable createDiskEvent ( java.lang.String diskAlias ) { org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogable logable = new org.ovirt.engine.core.dal.dbbroker.auditloghandling.AuditLogableImpl ( ) ; logable.addCustomValue ( "DiskAlias" , diskAlias ) ; return logable ; }
Source:
public void onFailure ( final java.util.List < org.ovirt.engine.ui.frontend.communication.VdcOperation < org.ovirt.engine.core.common.queries.VdcQueryType , org.ovirt.engine.core.common.queries.VdcQueryParametersBase > > operationList , final java.lang.Throwable caught ) { try { if ( ignoreFailure ( caught ) ) { return ; } org.ovirt.engine.ui.frontend.Frontend.logger.log ( java.util.logging.Level.SEVERE , ( "Failed to execute runMultipleQueries: " + caught ) , caught ) ; org.ovirt.engine.ui.uicompat.FrontendMultipleQueryAsyncResult f = new org.ovirt.engine.ui.uicompat.FrontendMultipleQueryAsyncResult ( queryTypeList , queryParamsList , null ) ; failureEventHandler ( caught ) ; callback.executed ( f ) ; } finally { org.ovirt.engine.ui.frontend.communication.AsyncOperationCompleteEvent.fire ( this , state ) ; raiseQueryCompleteEvent ( queryTypeList , state ) ; } }

Target:
public void onFailure ( final java.util.List < org.ovirt.engine.ui.frontend.communication.VdcOperation < org.ovirt.engine.core.common.queries.VdcQueryType , org.ovirt.engine.core.common.queries.VdcQueryParametersBase > > operationList , final java.lang.Throwable caught ) { try { if ( ignoreFailure ( caught ) ) { return ; } org.ovirt.engine.ui.frontend.Frontend.logger.log ( java.util.logging.Level.SEVERE , ( "Failed to execute runMultipleQueries: " + caught ) , caught ) ; org.ovirt.engine.ui.uicompat.FrontendMultipleQueryAsyncResult f = new org.ovirt.engine.ui.uicompat.FrontendMultipleQueryAsyncResult ( queryTypeList , queryParamsList , null ) ; failureEventHandler ( caught ) ; callback.executed ( f ) ; } finally { fireAsyncOperationCompleteEvent ( state ) ; } }
Source:
public void executed ( org.ovirt.engine.ui.uicompat.FrontendActionAsyncResult result ) { if ( isAddingNewVm ) { org.ovirt.engine.core.common.action.VmOperationParameterBase reorderParams = new org.ovirt.engine.core.common.action.VmOperationParameterBase ( vmId ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runAction ( VdcActionType.ReorderVmNics , reorderParams , new org.ovirt.engine.ui.uicompat.IFrontendActionAsyncCallback ( ) { public void executed ( org.ovirt.engine.ui.uicompat.FrontendActionAsyncResult result ) { callback.vnicCreated ( vmId ) ; } } ) ; } else { callback.vnicCreated ( vmId ) ; } }

Target:
public void executed ( org.ovirt.engine.ui.uicompat.FrontendActionAsyncResult result ) { if ( unitVmModel.getIsNew ( ) ) { org.ovirt.engine.core.common.action.VmOperationParameterBase reorderParams = new org.ovirt.engine.core.common.action.VmOperationParameterBase ( vmId ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runAction ( VdcActionType.ReorderVmNics , reorderParams , new org.ovirt.engine.ui.uicompat.IFrontendActionAsyncCallback ( ) { public void executed ( org.ovirt.engine.ui.uicompat.FrontendActionAsyncResult result ) { callback.vnicCreated ( vmId ) ; } } ) ; } else { callback.vnicCreated ( vmId ) ; } }
Source:
public static void getGlusterHookContent ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid hookId , org.ovirt.engine.core.compat.Guid serverId ) { 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 ? source : "" ; } } ; org.ovirt.engine.core.common.queries.gluster.GlusterHookContentQueryParameters parameters = new org.ovirt.engine.core.common.queries.gluster.GlusterHookContentQueryParameters ( hookId ) ; parameters.setGlusterServerId ( serverId ) ; org.ovirt.engine.ui.frontend.Frontend.getInstance ( ) . runQuery ( VdcQueryType.GetGlusterHookContent , parameters , aQuery ) ; }

Target:
public static void getIsGlusterVolumeSnapshotCliScheduleEnabled ( org.ovirt.engine.ui.frontend.AsyncQuery aQuery , org.ovirt.engine.core.compat.Guid clusterId ) { 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.GetGlusterVolumeSnapshotCliScheduleFlag , new org.ovirt.engine.core.common.queries.IdQueryParameters ( clusterId ) , aQuery ) ; }