org.jetbrains.jet.lang.descriptors.impl
Class ClassDescriptorImpl

java.lang.Object
  extended by org.jetbrains.jet.lang.descriptors.annotations.AnnotatedImpl
      extended by org.jetbrains.jet.lang.descriptors.impl.DeclarationDescriptorImpl
          extended by org.jetbrains.jet.lang.descriptors.impl.DeclarationDescriptorNonRootImpl
              extended by org.jetbrains.jet.lang.descriptors.impl.ClassDescriptorImpl
All Implemented Interfaces:
Annotated, ClassDescriptor, ClassifierDescriptor, ClassOrNamespaceDescriptor, DeclarationDescriptor, DeclarationDescriptorNonRoot, DeclarationDescriptorWithVisibility, MemberDescriptor, Named

public class ClassDescriptorImpl
extends DeclarationDescriptorNonRootImpl
implements ClassDescriptor


Constructor Summary
ClassDescriptorImpl(DeclarationDescriptor containingDeclaration, ClassKind kind, java.util.List<AnnotationDescriptor> annotations, Modality modality, Name name)
           
ClassDescriptorImpl(DeclarationDescriptor containingDeclaration, java.util.List<AnnotationDescriptor> annotations, Modality modality, Name name)
           
 
Method Summary
<R,D> R
accept(DeclarationDescriptorVisitor<R,D> visitor, D data)
           
 ClassDescriptor getClassObjectDescriptor()
           
 JetType getClassObjectType()
           
 java.util.Collection<ConstructorDescriptor> getConstructors()
           
 JetType getDefaultType()
           
 ClassKind getKind()
           
 JetScope getMemberScope(java.util.List<TypeProjection> typeArguments)
           
 Modality getModality()
           
 ReceiverParameterDescriptor getThisAsReceiverParameter()
           
 TypeConstructor getTypeConstructor()
           
 JetScope getUnsubstitutedInnerClassesScope()
           
 ConstructorDescriptor getUnsubstitutedPrimaryConstructor()
           
 Visibility getVisibility()
           
 ClassDescriptorImpl initialize(boolean sealed, java.util.List<? extends TypeParameterDescriptor> typeParameters, java.util.Collection<JetType> supertypes, JetScope memberDeclarations, java.util.Set<ConstructorDescriptor> constructors, ConstructorDescriptor primaryConstructor, boolean isInner)
           
 boolean isInner()
           
 void setClassObjectDescriptor(ClassDescriptor classObjectDescriptor)
           
 void setPrimaryConstructor(ConstructorDescriptor primaryConstructor)
           
 ClassDescriptor substitute(TypeSubstitutor substitutor)
           
 
Methods inherited from class org.jetbrains.jet.lang.descriptors.impl.DeclarationDescriptorNonRootImpl
getContainingDeclaration
 
Methods inherited from class org.jetbrains.jet.lang.descriptors.impl.DeclarationDescriptorImpl
acceptVoid, getName, getOriginal, toString
 
Methods inherited from class org.jetbrains.jet.lang.descriptors.annotations.AnnotatedImpl
getAnnotations
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.jetbrains.jet.lang.descriptors.ClassDescriptor
getContainingDeclaration
 
Methods inherited from interface org.jetbrains.jet.lang.descriptors.DeclarationDescriptor
acceptVoid, getOriginal
 
Methods inherited from interface org.jetbrains.jet.lang.descriptors.annotations.Annotated
getAnnotations
 
Methods inherited from interface org.jetbrains.jet.lang.descriptors.Named
getName
 

Constructor Detail

ClassDescriptorImpl

public ClassDescriptorImpl(@NotNull
                           DeclarationDescriptor containingDeclaration,
                           @NotNull
                           java.util.List<AnnotationDescriptor> annotations,
                           @NotNull
                           Modality modality,
                           @NotNull
                           Name name)

ClassDescriptorImpl

public ClassDescriptorImpl(@NotNull
                           DeclarationDescriptor containingDeclaration,
                           @NotNull
                           ClassKind kind,
                           @NotNull
                           java.util.List<AnnotationDescriptor> annotations,
                           @NotNull
                           Modality modality,
                           @NotNull
                           Name name)
Method Detail

initialize

public final ClassDescriptorImpl initialize(boolean sealed,
                                            @NotNull
                                            java.util.List<? extends TypeParameterDescriptor> typeParameters,
                                            @NotNull
                                            java.util.Collection<JetType> supertypes,
                                            @NotNull
                                            JetScope memberDeclarations,
                                            @NotNull
                                            java.util.Set<ConstructorDescriptor> constructors,
                                            @Nullable
                                            ConstructorDescriptor primaryConstructor,
                                            boolean isInner)

setPrimaryConstructor

public void setPrimaryConstructor(@NotNull
                                  ConstructorDescriptor primaryConstructor)

setClassObjectDescriptor

public void setClassObjectDescriptor(@NotNull
                                     ClassDescriptor classObjectDescriptor)

getTypeConstructor

@NotNull
public TypeConstructor getTypeConstructor()
Specified by:
getTypeConstructor in interface ClassifierDescriptor

getMemberScope

@NotNull
public JetScope getMemberScope(java.util.List<TypeProjection> typeArguments)
Specified by:
getMemberScope in interface ClassDescriptor

getDefaultType

@NotNull
public JetType getDefaultType()
Specified by:
getDefaultType in interface ClassDescriptor
Specified by:
getDefaultType in interface ClassifierDescriptor
Returns:
type A<T> for the class A<T>

getConstructors

@NotNull
public java.util.Collection<ConstructorDescriptor> getConstructors()
Specified by:
getConstructors in interface ClassDescriptor

substitute

@NotNull
public ClassDescriptor substitute(@NotNull
                                          TypeSubstitutor substitutor)
Specified by:
substitute in interface ClassDescriptor
Specified by:
substitute in interface DeclarationDescriptor

getClassObjectType

public JetType getClassObjectType()
Specified by:
getClassObjectType in interface ClassDescriptor
Specified by:
getClassObjectType in interface ClassifierDescriptor

getClassObjectDescriptor

public ClassDescriptor getClassObjectDescriptor()
Specified by:
getClassObjectDescriptor in interface ClassDescriptor

getKind

@NotNull
public ClassKind getKind()
Specified by:
getKind in interface ClassDescriptor

accept

public <R,D> R accept(DeclarationDescriptorVisitor<R,D> visitor,
                      D data)
Specified by:
accept in interface DeclarationDescriptor

getUnsubstitutedPrimaryConstructor

public ConstructorDescriptor getUnsubstitutedPrimaryConstructor()
Specified by:
getUnsubstitutedPrimaryConstructor in interface ClassDescriptor

getModality

@NotNull
public Modality getModality()
Specified by:
getModality in interface ClassDescriptor
Specified by:
getModality in interface MemberDescriptor

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)

getThisAsReceiverParameter

@NotNull
public ReceiverParameterDescriptor getThisAsReceiverParameter()
Specified by:
getThisAsReceiverParameter in interface ClassDescriptor

getUnsubstitutedInnerClassesScope

@NotNull
public JetScope getUnsubstitutedInnerClassesScope()
Specified by:
getUnsubstitutedInnerClassesScope in interface ClassDescriptor