All Implemented Interfaces:
IAnnotatable, IJavaElement, IMember, IParent, ISourceManipulation, ISourceReference, IType, org.eclipse.core.runtime.IAdaptable

public class AssistSourceType extends ResolvedSourceType
  • Constructor Details

    • AssistSourceType

      public AssistSourceType(JavaElement parent, String name, Map bindingCache, Map infoCache)
  • Method Details

    • getElementInfo

      public Object getElementInfo(org.eclipse.core.runtime.IProgressMonitor monitor) throws JavaModelException
      Description copied from class: JavaElement
      Returns the info for this handle. If this element is not already open, it and all of its parents are opened. Does not return null. NOTE: BinaryType infos are NOT rooted under JavaElementInfo.
      Overrides:
      getElementInfo in class JavaElement
      Throws:
      JavaModelException - if the element is not present or not accessible
    • getFullyQualifiedParameterizedName

      public String getFullyQualifiedParameterizedName() throws JavaModelException
      Description copied from interface: IType
      Returns this type's fully qualified name using a '.' enclosing type separator followed by its type parameters between angle brackets if it is a generic type. For example, "p.X<T>", "java.util.Map<java.lang.String, p.X>"
      Specified by:
      getFullyQualifiedParameterizedName in interface IType
      Overrides:
      getFullyQualifiedParameterizedName in class ResolvedSourceType
      Returns:
      the fully qualified parameterized representation of this type
      Throws:
      JavaModelException - if this element does not exist or if an exception occurs while accessing its corresponding resource.
    • getKey

      public String getKey()
      Description copied from interface: IType
      Returns the binding key for this type only if the given type is resolved. A binding key is a key that uniquely identifies this type. It allows access to generic info for parameterized types.

      If the given type is not resolved, the returned key is simply the java element's key.

      Specified by:
      getKey in interface IType
      Overrides:
      getKey in class ResolvedSourceType
      Returns:
      the binding key for this type
      See Also:
      IBinding.getKey(), BindingKey, IType.isResolved()
    • isResolved

      public boolean isResolved()
      Description copied from interface: IType
      Returns whether this type represents a resolved type. If a type is resolved, its key contains resolved information.
      Specified by:
      isResolved in interface IType
      Overrides:
      isResolved in class ResolvedSourceType
      Returns:
      whether this type represents a resolved type.
    • toStringInfo

      protected void toStringInfo(int tab, StringBuffer buffer, Object info, boolean showResolvedInfo)
      Description copied from class: JavaElement
      Debugging purposes
      Overrides:
      toStringInfo in class ResolvedSourceType
      showResolvedInfo - TODO
    • getAnnotation

      public IAnnotation getAnnotation(String annotationName)
      Description copied from interface: IAnnotatable
      Returns the annotation with the given name declared on this element. This is a handle-only method. The annotation may or may not exist.
      Specified by:
      getAnnotation in interface IAnnotatable
      Overrides:
      getAnnotation in class SourceRefElement
      Parameters:
      annotationName - the given simple name
      Returns:
      the annotation with the given name declared on this element
    • getField

      public IField getField(String fieldName)
      Description copied from interface: IType
      Returns the field with the specified name in this type (for example, "bar"). This is a handle-only method. The field may or may not exist.
      Specified by:
      getField in interface IType
      Overrides:
      getField in class SourceType
      Parameters:
      fieldName - the given name
      Returns:
      the field with the specified name in this type
      See Also:
      IType.getField(java.lang.String)
    • getInitializer

      public IInitializer getInitializer(int count)
      Description copied from interface: IType
      Returns the initializer with the specified position relative to the order they are defined in the source. Numbering starts at 1 (thus the first occurrence is occurrence 1, not occurrence 0). This is a handle-only method. The initializer may or may not be present.
      Specified by:
      getInitializer in interface IType
      Overrides:
      getInitializer in class SourceType
      Parameters:
      count - the specified position
      Returns:
      the initializer with the specified position relative to the order they are defined in the source
      See Also:
      IType
    • getMethod

      public IMethod getMethod(String selector, String[] parameterTypeSignatures)
      Description copied from interface: IType
      Returns the method with the specified name and parameter types in this type (for example, "foo", {"I", "QString;"}). To get the handle for a constructor, the name specified must be the simple name of the enclosing type. This is a handle-only method. The method may or may not be present.

      The type signatures may be either unresolved (for source types) or resolved (for binary types), and either basic (for basic types) or rich (for parameterized types). See Signature for details. Note that the parameter type signatures for binary methods are expected to be dot-based.

      Specified by:
      getMethod in interface IType
      Overrides:
      getMethod in class SourceType
      Parameters:
      selector - the given name
      parameterTypeSignatures - the given parameter types
      Returns:
      the method with the specified name and parameter types in this type
      See Also:
      IType.getMethod(java.lang.String, java.lang.String[])
    • getType

      public IType getType(String typeName)
      Description copied from interface: IType
      Returns the member type declared in this type with the given simple name. This is a handle-only method. The type may or may not exist.
      Specified by:
      getType in interface IType
      Overrides:
      getType in class SourceType
      Parameters:
      typeName - the given simple name
      Returns:
      the member type declared in this type with the given simple name
      See Also:
      IType
    • getType

      public IType getType(String typeName, int count)
      Description copied from interface: IMember
      Returns the local or anonymous type declared in this source member with the given simple name and/or with the specified position relative to the order they are defined in the source. The name is empty if it is an anonymous type. Numbering starts at 1 (thus the first occurrence is occurrence 1, not occurrence 0). This is a handle-only method. The type may or may not exist. Throws a RuntimeException if this member is not a source member.
      Specified by:
      getType in interface IMember
      Overrides:
      getType in class Member
      Parameters:
      typeName - the given simple name
      count - the specified position
      Returns:
      the type with the given name and/or with the specified position relative to the order they are defined in the source
      See Also:
      IMember
    • getTypeParameter

      public ITypeParameter getTypeParameter(String typeParameterName)
      Description copied from interface: IType
      Returns the type parameter declared in this type with the given name. This is a handle-only method. The type parameter may or may not exist.
      Specified by:
      getTypeParameter in interface IType
      Overrides:
      getTypeParameter in class SourceType
      Parameters:
      typeParameterName - the given simple name
      Returns:
      the type parameter declared in this type with the given name