當前位置: 首頁>>代碼示例>>Java>>正文


Java UnknownProperty類代碼示例

本文整理匯總了Java中jkind.results.UnknownProperty的典型用法代碼示例。如果您正苦於以下問題:Java UnknownProperty類的具體用法?Java UnknownProperty怎麽用?Java UnknownProperty使用的例子?那麽, 這裏精選的類代碼示例或許可以為您提供幫助。


UnknownProperty類屬於jkind.results包,在下文中一共展示了UnknownProperty類的6個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: addViewCounterexampleMenu

import jkind.results.UnknownProperty; //導入依賴的package包/類
private void addViewCounterexampleMenu(IMenuManager manager, PropertyResult result) {
	final Counterexample cex = getCounterexample(result);
	if (cex == null) {
		return;
	}

	boolean inductive = result.getProperty() instanceof UnknownProperty;
	
	String text = "View " + (inductive ? "Inductive " : "") + "Counterexample in ";
	manager.add(new Action(text + "spreadsheet") {
		@Override
		public void run() {
			viewCexSpreadsheet(cex, layout);
		}
	});
	
	manager.add(new Action(text + "Eclipse") {
		@Override
		public void run() {
			viewCexEclipse(cex,layout);
		}


	});
}
 
開發者ID:AFifarek,項目名稱:SpeAR,代碼行數:26,代碼來源:JKindMenuListener.java

示例2: addViewCounterexampleMenu

import jkind.results.UnknownProperty; //導入依賴的package包/類
private void addViewCounterexampleMenu(IMenuManager manager, PropertyResult result) {
	final Counterexample cex = getCounterexample(result);
	if (cex == null) {
		return;
	}

	boolean inductive = result.getProperty() instanceof UnknownProperty;
	String text = "View " + (inductive ? "Inductive " : "") + "Counterexample in ";
	manager.add(new Action(text + "Spreadsheet") {
		@Override
		public void run() {
			viewCexSpreadsheet(cex, layout);
		}
	});
	manager.add(new Action(text + "Eclipse") {
		@Override
		public void run() {
			viewCexEclipse(cex, layout);
		}
	});
}
 
開發者ID:agacek,項目名稱:jkind-xtext,代碼行數:22,代碼來源:JKindMenuListener.java

示例3: receiveCex

import jkind.results.UnknownProperty; //導入依賴的package包/類
public void receiveCex(final ComponentImplementation compImpl, Property property, EObject agreeProperty, final Counterexample cex, final Map<String, EObject> refMap, final Mode mode) {		
	// Launch the simulation
	final SimulationService simulationService = Objects.requireNonNull((SimulationService)PlatformUI.getWorkbench().getActiveWorkbenchWindow().getService(SimulationService.class), "Unable to retrieve simulation service");
	final SimulationLaunchShortcut launchShortcut = new SimulationLaunchShortcut();
	try {
		final boolean isInductiveCex = property instanceof UnknownProperty;
		final ILaunch launch = launchShortcut.launch(compImpl, isInductiveCex ? mode.inductiveEngineTypeId : mode.engineTypeId, ILaunchManager.RUN_MODE);
		
		// Get the simulation engine
		final SimulationEngine simulationEngine = getSimulationEngine(launch);
		if(simulationEngine instanceof AGREESimulationEngine) {
			final AGREESimulationEngine agreeSimulationEngine = (AGREESimulationEngine)simulationEngine;
			final SimulationUIService simulationUIService = Objects.requireNonNull((SimulationUIService)PlatformUI.getWorkbench().getActiveWorkbenchWindow().getService(SimulationUIService.class), "Unable to retrieve simulation UI service");
			final Map<String, Object> signalNameToSimStateElementMap = buildAgreeNameToSimulationStateElementMap(agreeSimulationEngine);
			simulateCounterexample(cex, 0, signalNameToSimStateElementMap, agreeSimulationEngine, simulationService, simulationUIService);
		}			
	} catch (final Exception e) {
		simulationService.getExceptionHandler().handleException(e);			
	}		
}
 
開發者ID:smaccm,項目名稱:smaccm,代碼行數:21,代碼來源:CounterexampleLoaderHelper.java

示例4: renameKind2Prop

import jkind.results.UnknownProperty; //導入依賴的package包/類
private Property renameKind2Prop(Property property){
    if(property instanceof InvalidProperty){
        InvalidProperty renamedInvalid = (InvalidProperty)property;
        return new InvalidProperty(renamedInvalid.getName(), 
                renamedInvalid.getSource(), 
                rename(renamedInvalid.getCounterexample()), 
                renamedInvalid.getConflicts(), 
                renamedInvalid.getRuntime());
    }else if(property instanceof UnknownProperty){
        UnknownProperty renamedUnknown = (UnknownProperty)property;
        UnknownProperty newProp =  new UnknownProperty(renamedUnknown.getName(), 
                renamedUnknown.getTrueFor(), 
                rename(renamedUnknown.getInductiveCounterexample()), 
                renamedUnknown.getRuntime());
        return newProp;
    }
    if(!(property instanceof ValidProperty)){
        throw new AgreeException("Unexpected property type");
    }
    return property;
}
 
開發者ID:smaccm,項目名稱:smaccm,代碼行數:22,代碼來源:AgreeRenaming.java

示例5: getCounterexample

import jkind.results.UnknownProperty; //導入依賴的package包/類
private static Counterexample getCounterexample(PropertyResult result) {
	Property prop = result.getProperty();
	if (prop instanceof InvalidProperty) {
		return ((InvalidProperty) prop).getCounterexample();
	} else if (prop instanceof UnknownProperty) {
		return ((UnknownProperty) prop).getInductiveCounterexample();
	} else {
		return null;
	}
}
 
開發者ID:AFifarek,項目名稱:SpeAR,代碼行數:11,代碼來源:JKindMenuListener.java

示例6: getCounterexampleType

import jkind.results.UnknownProperty; //導入依賴的package包/類
private static String getCounterexampleType(AnalysisResult result) {
    if (result instanceof PropertyResult) {
        Property prop = ((PropertyResult) result).getProperty();
        if (prop instanceof UnknownProperty) {
            return "Inductive ";
        }
    }

    return " ";
}
 
開發者ID:smaccm,項目名稱:smaccm,代碼行數:11,代碼來源:TestCaseGeneratorMenuListener.java


注:本文中的jkind.results.UnknownProperty類示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。