congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
JvmGenericType.getDeclaredConstructors
Code IndexAdd Tabnine to your IDE (free)

How to use
getDeclaredConstructors
method
in
org.eclipse.xtext.common.types.JvmGenericType

Best Java code snippets using org.eclipse.xtext.common.types.JvmGenericType.getDeclaredConstructors (Showing top 11 results out of 315)

origin: org.eclipse.xtext/org.eclipse.xtext.common.types

  @Override
  public Iterator<JvmConstructor> iterator() {
    return castedType.getDeclaredConstructors().iterator();
  }
};
origin: org.eclipse.xtext.common/types

  public Iterator<JvmConstructor> iterator() {
    return castedType.getDeclaredConstructors().iterator();
  }
};
origin: org.eclipse.xtext/org.eclipse.xtext.xbase

protected List<IEObjectDescription> createConstructorDescriptions(QualifiedName name, JvmGenericType type, boolean superType) {
  Iterable<JvmConstructor> constructors = type.getDeclaredConstructors();
  List<IEObjectDescription> result = Lists.newArrayListWithCapacity(3);
  for(JvmConstructor constructor: constructors) {
    addToList(createDescription(name, constructor, superType), result);
  }
  return result;
}
origin: org.eclipse.xtext/org.eclipse.xtext.xbase

protected List<IResolvedConstructor> computeDeclaredConstructors() {
  JvmType rawType = getRawType();
  if (!(rawType instanceof JvmGenericType)) {
    return Collections.emptyList();
  }
  List<IResolvedConstructor> result = Lists.newArrayList();
  for(JvmConstructor constructor: ((JvmGenericType)rawType).getDeclaredConstructors()) {
    result.add(new ResolvedConstructor(constructor, getType()));
  }
  return Collections.unmodifiableList(result);
}

origin: org.eclipse.emf.parsley/org.eclipse.emf.parsley.dsl

public boolean containsConstructorAcceptingPluginParameter(final EObject context, final JvmTypeReference typeRef) {
 final JvmType type = typeRef.getType();
 if ((type instanceof JvmGenericType)) {
  final Function1<JvmConstructor, Boolean> _function = new Function1<JvmConstructor, Boolean>() {
   @Override
   public Boolean apply(final JvmConstructor it) {
    return Boolean.valueOf(((it.getParameters().size() == 1) && 
     EmfParsleyDslGuiceModuleHelper.this._emfParsleyDslTypeSystem.isConformant(context, AbstractUIPlugin.class, IterableExtensions.<JvmFormalParameter>head(it.getParameters()).getParameterType())));
   }
  };
  return IterableExtensions.<JvmConstructor>exists(((JvmGenericType)type).getDeclaredConstructors(), _function);
 }
 return false;
}

origin: org.eclipse.xtext/org.eclipse.xtext.xbase

Iterable<JvmConstructor> declaredConstructors = type.getDeclaredConstructors();
if (Iterables.size(declaredConstructors) == 1 && jvmTypeExtensions.isSingleSyntheticDefaultConstructor(declaredConstructors.iterator().next())) {
  finalFields.removeAll(initializedFields);
origin: org.eclipse.xtext/org.eclipse.xtext.xbase

protected void addFeatureDescriptions(IEObjectDescription typeDescription, List<IEObjectDescription> result) {
  EObject proxy = getResolvedProxy(typeDescription);
  if (!proxy.eIsProxy() && proxy instanceof JvmGenericType) {
    JvmGenericType type = (JvmGenericType) proxy;
    if (!type.isInterface()) {
      for(JvmConstructor constructor: type.getDeclaredConstructors()) {
        boolean visible = visibilityHelper.isVisible(constructor);
        ConstructorDescription constructorDescription = createConstructorDescription(typeDescription, constructor, visible);
        result.add(constructorDescription);
      }
    } else if (!strict) {
      result.add(new SimpleIdentifiableElementDescription(typeDescription));
    }
  } else if (proxy instanceof JvmType) {
    if (!strict)
      result.add(new SimpleIdentifiableElementDescription(typeDescription));
  }
}
origin: org.eclipse.xtend/org.eclipse.xtend.core

JvmType superType = inferredType.getExtendedClass().getType();
if(superType instanceof JvmGenericType) {
  Iterable<JvmConstructor> superConstructors = ((JvmGenericType) superType).getDeclaredConstructors();
  for(JvmConstructor superConstructor: superConstructors) {
    if(superConstructor.getParameters().isEmpty()) 
origin: org.eclipse.xtext/org.eclipse.xtext.xbase

protected void completeJvmGenericType(JvmGenericType element) {
  // if no super type add Object
  ensureSuperTypeObject(element);
  addAnnotations(element);
  if (!element.isInterface()) {
    // if no constructors have been added, add a default constructor
    if (isEmpty(element.getDeclaredConstructors())) {
      JvmConstructor constructor = TypesFactory.eINSTANCE.createJvmConstructor();
      constructor.setSimpleName(element.getSimpleName());
      constructor.setVisibility(JvmVisibility.PUBLIC);
      typeExtensions.setSynthetic(constructor, true);
      EObject primarySourceElement = associations.getPrimarySourceElement(element);
      if (primarySourceElement != null) {
        associator.associate(primarySourceElement, constructor);
      }
      element.getMembers().add(constructor);
    }
  }
}
origin: io.sarl.lang/io.sarl.lang

if (supertype instanceof JvmGenericType) {
  final JvmGenericType jvmSuperElement = (JvmGenericType) supertype;
  for (final JvmConstructor superConstructor : jvmSuperElement.getDeclaredConstructors()) {
    final ActionParameterTypes sig = this.sarlActionSignatures.createParameterTypesFromJvmModel(
        superConstructor.isVarArgs(), superConstructor.getParameters());
origin: io.sarl.lang/io.sarl.lang

for (final JvmConstructor cons : parentType.getDeclaredConstructors()) {
  final ActionParameterTypes sig = sarlSignatureProvider.createParameterTypesFromJvmModel(
      cons.isVarArgs(), cons.getParameters());
org.eclipse.xtext.common.typesJvmGenericTypegetDeclaredConstructors

Javadoc

Popular methods of JvmGenericType

  • getMembers
  • isInterface
    Returns the value of the 'Interface' attribute. If the meaning of the 'Interface' attribute isn't cl
  • getSuperTypes
  • getTypeParameters
  • setAbstract
  • setInterface
    Sets the value of the ' org.eclipse.xtext.common.types.JvmGenericType#isInterface' attribute.
  • setPackageName
  • setSimpleName
  • setVisibility
  • getAllFeatures
  • getSimpleName
  • isAbstract
  • getSimpleName,
  • isAbstract,
  • setFinal,
  • setStatic,
  • setStrictFloatingPoint,
  • getDeclaredFields,
  • getDeclaredOperations,
  • getIdentifier,
  • isFinal

Popular in Java

  • Parsing JSON documents to java classes using gson
  • onRequestPermissionsResult (Fragment)
  • getSharedPreferences (Context)
  • getApplicationContext (Context)
  • Font (java.awt)
    The Font class represents fonts, which are used to render text in a visible way. A font provides the
  • InetAddress (java.net)
    An Internet Protocol (IP) address. This can be either an IPv4 address or an IPv6 address, and in pra
  • URLEncoder (java.net)
    This class is used to encode a string using the format required by application/x-www-form-urlencoded
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • ReentrantLock (java.util.concurrent.locks)
    A reentrant mutual exclusion Lock with the same basic behavior and semantics as the implicit monitor
  • Reference (javax.naming)
  • Top Vim plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now