org.eclipse.xtext.xbase.typesystem.override.OverrideTester Java Examples

The following examples show how to use org.eclipse.xtext.xbase.typesystem.override.OverrideTester. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: SuperMemberImplementorTest.java    From xtext-xtend with Eclipse Public License 2.0 5 votes vote down vote up
protected void checkOverrideMethodCode(String operationName, String overrideCode) {
	StringBuilderBasedAppendable appendable = new StringBuilderBasedAppendable();
	LightweightTypeReference contextType = getContextType();
	IResolvedOperation resolvedOperation = new BottomResolvedOperation((JvmOperation) findExecutable(implementedInterface, operationName), contextType, new OverrideTester());
	implementor.appendOverrideFunction(xtendClass, resolvedOperation, appendable);
	String code = appendable.toString();
	if (!equalsIgnoreWhitespace(overrideCode, code))
		assertEquals(overrideCode, code);
}
 
Example #2
Source File: Bug621ResolvedFeatures.java    From sarl with Apache License 2.0 5 votes vote down vote up
private OverrideTester _getOverrideTester(AbstractResolvedOperation op) {
	try {
		Method meth = AbstractResolvedOperation.class.getDeclaredMethod("getOverrideTester");
		meth.setAccessible(true);
		return (OverrideTester) meth.invoke(op);
	} catch (Throwable exception) {
		throw new Error(exception);
	}
}
 
Example #3
Source File: Bug621ResolvedFeatures.java    From sarl with Apache License 2.0 4 votes vote down vote up
public Bug621ResolvedFeatures(LightweightTypeReference type, OverrideTester overrideTester, JavaVersion targetVersion) {
	super(type, overrideTester, targetVersion);
	this.targetVersion = targetVersion;
}
 
Example #4
Source File: Bug621ResolvedFeatures.java    From sarl with Apache License 2.0 4 votes vote down vote up
public Bug621ResolvedFeatures(LightweightTypeReference type, OverrideTester overrideTester) {
	super(type, overrideTester);
}