本文整理了Java中org.eclipse.xtext.xbase.XAbstractFeatureCall.getActualReceiver()
方法的一些代码示例,展示了XAbstractFeatureCall.getActualReceiver()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XAbstractFeatureCall.getActualReceiver()
方法的具体详情如下:
包路径:org.eclipse.xtext.xbase.XAbstractFeatureCall
类名称:XAbstractFeatureCall
方法名:getActualReceiver
[英]Returns the actual receiver of the feature call. The decision will be made according to the linking of the feature. May not be used during linking itself.
Static features, constructor calls (this, super), references to local variables or parameters will return null
.
[中]返回功能调用的实际接收者。将根据功能的链接做出决定。在链接过程中不能使用。
静态特性、构造函数调用(this、super)、对局部变量或参数的引用将返回[$0$]。
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
protected XExpression getActualReceiver(final XAbstractFeatureCall expr) {
return expr.getActualReceiver();
}
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
protected XExpression getActualReceiver(XAbstractFeatureCall featureCall) {
return featureCall.getActualReceiver();
}
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
protected XExpression getReceiver() {
return getFeatureCall().getActualReceiver();
}
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
protected LightweightTypeReference getReceiverType(XAbstractFeatureCall featureCall, IResolvedTypes resolvedTypes, ITypeReferenceOwner owner) {
XExpression receiver = featureCall.getActualReceiver();
if (receiver == null) {
// static feature call
JvmOperation operation = (JvmOperation) featureCall.getFeature();
JvmDeclaredType declaringType = operation.getDeclaringType();
return owner.newParameterizedTypeReference(declaringType);
}
return resolvedTypes.getActualType(receiver);
}
}
代码示例来源:origin: org.eclipse.xtend/org.eclipse.xtend.core
EObject _eContainer_1 = referrer.eContainer();
final XAbstractFeatureCall containingFeature = ((XAbstractFeatureCall) _eContainer_1);
if (((Objects.equal(containingFeature.getActualReceiver(), referrer) && (containingFeature.getFeature() instanceof JvmMember)) && (!this.isVisible(((JvmMember) containingFeature.getFeature()), localType)))) {
references.clear();
throw new XtendGenerator.StopCollecting();
代码示例来源:origin: io.sarl.lang/io.sarl.lang
return true;
final XExpression receiver = call.getActualReceiver();
if (receiver == null) {
return false;
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
if (featureCall.getActualReceiver() != null && !internalCanCompileToJavaExpression(featureCall.getActualReceiver(), appendable)) {
return false;
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
if (_exists) {
boolean _xifexpression = false;
XExpression _actualReceiver = expression.getActualReceiver();
boolean _tripleEquals = (_actualReceiver == null);
if (_tripleEquals) {
_xifexpression = true;
} else {
_xifexpression = this.isConstant(expression.getActualReceiver());
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
protected void checkIsValidConstructorArgument(XExpression argument, JvmType containerType) {
TreeIterator<EObject> iterator = EcoreUtil2.eAll(argument);
while(iterator.hasNext()) {
EObject partOfArgumentExpression = iterator.next();
if (partOfArgumentExpression instanceof XFeatureCall || partOfArgumentExpression instanceof XMemberFeatureCall) {
XAbstractFeatureCall featureCall = (XAbstractFeatureCall) partOfArgumentExpression;
XExpression actualReceiver = featureCall.getActualReceiver();
if(actualReceiver instanceof XFeatureCall && ((XFeatureCall)actualReceiver).getFeature() == containerType) {
JvmIdentifiableElement feature = featureCall.getFeature();
if (feature != null && !feature.eIsProxy()) {
if (feature instanceof JvmField) {
if (!((JvmField) feature).isStatic())
error("Cannot refer to an instance field " + feature.getSimpleName() + " while explicitly invoking a constructor",
partOfArgumentExpression, null, INVALID_CONSTRUCTOR_ARGUMENT);
} else if (feature instanceof JvmOperation) {
if (!((JvmOperation) feature).isStatic())
error("Cannot refer to an instance method while explicitly invoking a constructor",
partOfArgumentExpression, null, INVALID_CONSTRUCTOR_ARGUMENT);
}
}
}
} else if(isLocalClassSemantics(partOfArgumentExpression)) {
iterator.prune();
}
}
}
代码示例来源:origin: io.sarl.lang/io.sarl.lang
return !isLocalExpression(expression.getActualReceiver(), context, true);
} else if (sideEffectForExternalElements && isExternalFeature(feature)) {
return true;
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
EObject proxyOrResolved = (EObject) context.eGet(reference, false);
if (proxyOrResolved != null && !proxyOrResolved.eIsProxy()) {
XExpression receiver = ((XAbstractFeatureCall) context).getActualReceiver();
if (receiver == null && context instanceof XMemberFeatureCall) {
receiver = ((XMemberFeatureCall) context).getMemberCallTarget();
代码示例来源:origin: org.eclipse.xtext/org.eclipse.xtext.xbase
boolean _isFinal = ((JvmField)feature).isFinal();
if (_isFinal) {
XExpression _actualReceiver = it.getActualReceiver();
boolean _tripleNotEquals = (_actualReceiver != null);
if (_tripleNotEquals) {
final EvaluationResult receiver = this.doEvaluate(it.getActualReceiver(), context);
boolean _isNotAConstant = receiver.isNotAConstant();
if (_isNotAConstant) {
内容来源于网络,如有侵权,请联系作者删除!