org.jetbrains.kotlin.descriptors.impl
Class MutableClassDescriptor
java.lang.Object
org.jetbrains.kotlin.descriptors.impl.AbstractClassDescriptor
org.jetbrains.kotlin.descriptors.impl.ClassDescriptorBase
org.jetbrains.kotlin.descriptors.impl.MutableClassDescriptor
- All Implemented Interfaces:
- Annotated, ClassDescriptor, ClassDescriptorWithResolutionScopes, ClassifierDescriptor, ClassOrPackageFragmentDescriptor, DeclarationDescriptor, DeclarationDescriptorNonRoot, DeclarationDescriptorWithSource, DeclarationDescriptorWithVisibility, MemberDescriptor, Named
public class MutableClassDescriptor
- extends ClassDescriptorBase
- implements ClassDescriptorWithResolutionScopes
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
MutableClassDescriptor
public MutableClassDescriptor(@NotNull
DeclarationDescriptor containingDeclaration,
@NotNull
JetScope outerScope,
@NotNull
ClassKind kind,
boolean isInner,
@NotNull
Name name,
@NotNull
SourceElement source)
getCompanionObjectDescriptor
@Nullable
public MutableClassDescriptor getCompanionObjectDescriptor()
- Specified by:
getCompanionObjectDescriptor
in interface ClassDescriptor
- Specified by:
getCompanionObjectDescriptor
in interface ClassDescriptorWithResolutionScopes
- Returns:
- nested object declared as 'companion' if one is present.
setCompanionObjectDescriptor
public void setCompanionObjectDescriptor(@NotNull
MutableClassDescriptor classObjectDescriptor)
getAnnotations
@NotNull
public Annotations getAnnotations()
- Specified by:
getAnnotations
in interface Annotated
addAnnotations
public void addAnnotations(@NotNull
java.lang.Iterable<AnnotationDescriptor> annotationsToAdd)
setModality
public void setModality(@NotNull
Modality modality)
getModality
@NotNull
public Modality getModality()
- Specified by:
getModality
in interface ClassDescriptor
- Specified by:
getModality
in interface MemberDescriptor
getKind
@NotNull
public ClassKind getKind()
- Specified by:
getKind
in interface ClassDescriptor
setVisibility
public void setVisibility(@NotNull
Visibility visibility)
getVisibility
@NotNull
public Visibility getVisibility()
- Specified by:
getVisibility
in interface ClassDescriptor
- Specified by:
getVisibility
in interface DeclarationDescriptorWithVisibility
- Specified by:
getVisibility
in interface MemberDescriptor
isInner
public boolean isInner()
- Specified by:
isInner
in interface ClassDescriptor
- Returns:
true
if this class contains a reference to its outer class (as opposed to static nested class)
isCompanionObject
public boolean isCompanionObject()
- Specified by:
isCompanionObject
in interface ClassDescriptor
getTypeConstructor
@NotNull
public TypeConstructor getTypeConstructor()
- Specified by:
getTypeConstructor
in interface ClassifierDescriptor
getSupertypes
@NotNull
public java.util.Collection<JetType> getSupertypes()
setSupertypes
public void setSupertypes(@NotNull
java.util.Collection<JetType> supertypes)
addSupertype
public void addSupertype(@NotNull
JetType supertype)
setPrimaryConstructor
public void setPrimaryConstructor(@NotNull
ConstructorDescriptor constructorDescriptor)
addConstructorParametersToInitializersScope
public void addConstructorParametersToInitializersScope(@NotNull
java.util.Collection<? extends VariableDescriptor> variables)
getConstructors
@NotNull
public java.util.Set<ConstructorDescriptor> getConstructors()
- Specified by:
getConstructors
in interface ClassDescriptor
getUnsubstitutedPrimaryConstructor
@Nullable
public ConstructorDescriptor getUnsubstitutedPrimaryConstructor()
- Specified by:
getUnsubstitutedPrimaryConstructor
in interface ClassDescriptor
getFunctions
@NotNull
public java.util.Set<SimpleFunctionDescriptor> getFunctions()
getProperties
@NotNull
public java.util.Set<PropertyDescriptor> getProperties()
getDeclaredCallableMembers
@NotNull
public java.util.Set<CallableMemberDescriptor> getDeclaredCallableMembers()
- Specified by:
getDeclaredCallableMembers
in interface ClassDescriptorWithResolutionScopes
getAllCallableMembers
@NotNull
public java.util.Set<CallableMemberDescriptor> getAllCallableMembers()
setTypeParameterDescriptors
public void setTypeParameterDescriptors(@NotNull
java.util.List<TypeParameterDescriptor> typeParameters)
createTypeConstructor
public void createTypeConstructor()
getScopeForClassHeaderResolution
@NotNull
public JetScope getScopeForClassHeaderResolution()
- Specified by:
getScopeForClassHeaderResolution
in interface ClassDescriptorWithResolutionScopes
getScopeForMemberDeclarationResolution
@NotNull
public JetScope getScopeForMemberDeclarationResolution()
- Specified by:
getScopeForMemberDeclarationResolution
in interface ClassDescriptorWithResolutionScopes
getScopeForInitializerResolution
@NotNull
public JetScope getScopeForInitializerResolution()
- Specified by:
getScopeForInitializerResolution
in interface ClassDescriptorWithResolutionScopes
getScopeForSecondaryConstructorHeaderResolution
@NotNull
public JetScope getScopeForSecondaryConstructorHeaderResolution()
- Specified by:
getScopeForSecondaryConstructorHeaderResolution
in interface ClassDescriptorWithResolutionScopes
setScopeForMemberLookup
public void setScopeForMemberLookup(@NotNull
JetScope scopeForMemberLookup)
getScopeForMemberLookup
@NotNull
public JetScope getScopeForMemberLookup()
- Specified by:
getScopeForMemberLookup
in interface ClassDescriptorWithResolutionScopes
- Specified by:
getScopeForMemberLookup
in class AbstractClassDescriptor
getStaticScope
@NotNull
public JetScope getStaticScope()
- Specified by:
getStaticScope
in interface ClassDescriptor
lockScopes
public void lockScopes()
toString
public java.lang.String toString()
- Overrides:
toString
in class java.lang.Object