org.jetbrains.kotlin.builtins
Class KotlinBuiltIns
java.lang.Object
org.jetbrains.kotlin.builtins.KotlinBuiltIns
public abstract class KotlinBuiltIns
- extends java.lang.Object
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BUILT_INS_PACKAGE_NAME
public static final Name BUILT_INS_PACKAGE_NAME
BUILT_INS_PACKAGE_FQ_NAME
public static final FqName BUILT_INS_PACKAGE_FQ_NAME
COLLECTIONS_PACKAGE_FQ_NAME
public static final FqName COLLECTIONS_PACKAGE_FQ_NAME
RANGES_PACKAGE_FQ_NAME
public static final FqName RANGES_PACKAGE_FQ_NAME
BUILT_INS_PACKAGE_FQ_NAMES
public static final java.util.Set<FqName> BUILT_INS_PACKAGE_FQ_NAMES
builtInsModule
protected final ModuleDescriptorImpl builtInsModule
FQ_NAMES
public static final KotlinBuiltIns.FqNames FQ_NAMES
KotlinBuiltIns
protected KotlinBuiltIns()
getAdditionalSupertypesProvider
@NotNull
protected AdditionalSupertypes getAdditionalSupertypesProvider()
getBuiltInsModule
@NotNull
public ModuleDescriptorImpl getBuiltInsModule()
getBuiltInsPackageFragments
@NotNull
public java.util.Set<BuiltInsPackageFragment> getBuiltInsPackageFragments()
getBuiltInsPackageFragment
@NotNull
public PackageFragmentDescriptor getBuiltInsPackageFragment()
isBuiltInPackageFragment
public boolean isBuiltInPackageFragment(@Nullable
PackageFragmentDescriptor packageFragment)
getBuiltInsPackageScope
@NotNull
public MemberScope getBuiltInsPackageScope()
getBuiltInClassByName
@NotNull
public ClassDescriptor getBuiltInClassByName(@NotNull
Name simpleName)
getBuiltInClassByNameNullable
@Nullable
public ClassDescriptor getBuiltInClassByNameNullable(@NotNull
Name simpleName)
getBuiltInClassByFqNameNullable
@Nullable
public ClassDescriptor getBuiltInClassByFqNameNullable(@NotNull
FqName fqName)
getAny
@NotNull
public ClassDescriptor getAny()
getNothing
@NotNull
public ClassDescriptor getNothing()
getPrimitiveClassDescriptor
@NotNull
public ClassDescriptor getPrimitiveClassDescriptor(@NotNull
PrimitiveType type)
getByte
@NotNull
public ClassDescriptor getByte()
getShort
@NotNull
public ClassDescriptor getShort()
getInt
@NotNull
public ClassDescriptor getInt()
getLong
@NotNull
public ClassDescriptor getLong()
getFloat
@NotNull
public ClassDescriptor getFloat()
getDouble
@NotNull
public ClassDescriptor getDouble()
getChar
@NotNull
public ClassDescriptor getChar()
getBoolean
@NotNull
public ClassDescriptor getBoolean()
getIntegralRanges
@NotNull
public java.util.Set<DeclarationDescriptor> getIntegralRanges()
getArray
@NotNull
public ClassDescriptor getArray()
getPrimitiveArrayClassDescriptor
@NotNull
public ClassDescriptor getPrimitiveArrayClassDescriptor(@NotNull
PrimitiveType type)
getNumber
@NotNull
public ClassDescriptor getNumber()
getUnit
@NotNull
public ClassDescriptor getUnit()
getFunctionName
@NotNull
public static java.lang.String getFunctionName(int parameterCount)
getFunction
@NotNull
public ClassDescriptor getFunction(int parameterCount)
getThrowable
@NotNull
public ClassDescriptor getThrowable()
getCloneable
@NotNull
public ClassDescriptor getCloneable()
getDeprecatedAnnotation
@NotNull
public ClassDescriptor getDeprecatedAnnotation()
getDeprecationLevelEnumEntry
@Nullable
public ClassDescriptor getDeprecationLevelEnumEntry(@NotNull
java.lang.String level)
getTargetAnnotation
@NotNull
public ClassDescriptor getTargetAnnotation()
getRetentionAnnotation
@NotNull
public ClassDescriptor getRetentionAnnotation()
getRepeatableAnnotation
@NotNull
public ClassDescriptor getRepeatableAnnotation()
getMustBeDocumentedAnnotation
@NotNull
public ClassDescriptor getMustBeDocumentedAnnotation()
getAnnotationTargetEnumEntry
@Nullable
public ClassDescriptor getAnnotationTargetEnumEntry(@NotNull
KotlinTarget target)
getAnnotationRetentionEnumEntry
@Nullable
public ClassDescriptor getAnnotationRetentionEnumEntry(@NotNull
KotlinRetention retention)
getString
@NotNull
public ClassDescriptor getString()
getCharSequence
@NotNull
public ClassDescriptor getCharSequence()
getComparable
@NotNull
public ClassDescriptor getComparable()
getEnum
@NotNull
public ClassDescriptor getEnum()
getAnnotation
@NotNull
public ClassDescriptor getAnnotation()
getIterator
@NotNull
public ClassDescriptor getIterator()
getIterable
@NotNull
public ClassDescriptor getIterable()
getMutableIterable
@NotNull
public ClassDescriptor getMutableIterable()
getMutableIterator
@NotNull
public ClassDescriptor getMutableIterator()
getCollection
@NotNull
public ClassDescriptor getCollection()
getMutableCollection
@NotNull
public ClassDescriptor getMutableCollection()
getList
@NotNull
public ClassDescriptor getList()
getMutableList
@NotNull
public ClassDescriptor getMutableList()
getSet
@NotNull
public ClassDescriptor getSet()
getMutableSet
@NotNull
public ClassDescriptor getMutableSet()
getMap
@NotNull
public ClassDescriptor getMap()
getMutableMap
@NotNull
public ClassDescriptor getMutableMap()
getMapEntry
@NotNull
public ClassDescriptor getMapEntry()
getMutableMapEntry
@NotNull
public ClassDescriptor getMutableMapEntry()
getListIterator
@NotNull
public ClassDescriptor getListIterator()
getMutableListIterator
@NotNull
public ClassDescriptor getMutableListIterator()
getNothingType
@NotNull
public KotlinType getNothingType()
getNullableNothingType
@NotNull
public KotlinType getNullableNothingType()
getAnyType
@NotNull
public KotlinType getAnyType()
getNullableAnyType
@NotNull
public KotlinType getNullableAnyType()
getDefaultBound
@NotNull
public KotlinType getDefaultBound()
getPrimitiveKotlinType
@NotNull
public KotlinType getPrimitiveKotlinType(@NotNull
PrimitiveType type)
getByteType
@NotNull
public KotlinType getByteType()
getShortType
@NotNull
public KotlinType getShortType()
getIntType
@NotNull
public KotlinType getIntType()
getLongType
@NotNull
public KotlinType getLongType()
getFloatType
@NotNull
public KotlinType getFloatType()
getDoubleType
@NotNull
public KotlinType getDoubleType()
getCharType
@NotNull
public KotlinType getCharType()
getBooleanType
@NotNull
public KotlinType getBooleanType()
getUnitType
@NotNull
public KotlinType getUnitType()
getStringType
@NotNull
public KotlinType getStringType()
getArrayElementType
@NotNull
public KotlinType getArrayElementType(@NotNull
KotlinType arrayType)
getPrimitiveArrayKotlinType
@NotNull
public KotlinType getPrimitiveArrayKotlinType(@NotNull
PrimitiveType primitiveType)
getPrimitiveArrayKotlinTypeByPrimitiveKotlinType
@Nullable
public KotlinType getPrimitiveArrayKotlinTypeByPrimitiveKotlinType(@NotNull
KotlinType kotlinType)
- Returns:
null
if not primitive
isPrimitiveArray
public static boolean isPrimitiveArray(@NotNull
FqNameUnsafe arrayFqName)
getPrimitiveTypeByFqName
@Nullable
public static PrimitiveType getPrimitiveTypeByFqName(@NotNull
FqNameUnsafe primitiveClassFqName)
getPrimitiveTypeByArrayClassFqName
@Nullable
public static PrimitiveType getPrimitiveTypeByArrayClassFqName(@NotNull
FqNameUnsafe primitiveArrayClassFqName)
getArrayType
@NotNull
public KotlinType getArrayType(@NotNull
Variance projectionType,
@NotNull
KotlinType argument)
getEnumType
@NotNull
public KotlinType getEnumType(@NotNull
KotlinType argument)
getAnnotationType
@NotNull
public KotlinType getAnnotationType()
isArray
public static boolean isArray(@NotNull
KotlinType type)
isArrayOrPrimitiveArray
public static boolean isArrayOrPrimitiveArray(@NotNull
ClassDescriptor descriptor)
isPrimitiveArray
public static boolean isPrimitiveArray(@NotNull
KotlinType type)
isPrimitiveType
public static boolean isPrimitiveType(@NotNull
KotlinType type)
isPrimitiveClass
public static boolean isPrimitiveClass(@NotNull
ClassDescriptor descriptor)
isSpecialClassWithNoSupertypes
public static boolean isSpecialClassWithNoSupertypes(@NotNull
ClassDescriptor descriptor)
isAny
public static boolean isAny(@NotNull
ClassDescriptor descriptor)
isAny
public static boolean isAny(@NotNull
KotlinType type)
isBoolean
public static boolean isBoolean(@NotNull
KotlinType type)
isBooleanOrNullableBoolean
public static boolean isBooleanOrNullableBoolean(@NotNull
KotlinType type)
isBoolean
public static boolean isBoolean(@NotNull
ClassDescriptor classDescriptor)
isChar
public static boolean isChar(@NotNull
KotlinType type)
isInt
public static boolean isInt(@NotNull
KotlinType type)
isByte
public static boolean isByte(@NotNull
KotlinType type)
isLong
public static boolean isLong(@NotNull
KotlinType type)
isShort
public static boolean isShort(@NotNull
KotlinType type)
isFloat
public static boolean isFloat(@NotNull
KotlinType type)
isDouble
public static boolean isDouble(@NotNull
KotlinType type)
isNothing
public static boolean isNothing(@NotNull
KotlinType type)
isNullableNothing
public static boolean isNullableNothing(@NotNull
KotlinType type)
isNothingOrNullableNothing
public static boolean isNothingOrNullableNothing(@NotNull
KotlinType type)
isAnyOrNullableAny
public static boolean isAnyOrNullableAny(@NotNull
KotlinType type)
isNullableAny
public static boolean isNullableAny(@NotNull
KotlinType type)
isDefaultBound
public static boolean isDefaultBound(@NotNull
KotlinType type)
isUnit
public static boolean isUnit(@NotNull
KotlinType type)
isUnitOrNullableUnit
public static boolean isUnitOrNullableUnit(@NotNull
KotlinType type)
isBooleanOrSubtype
public boolean isBooleanOrSubtype(@NotNull
KotlinType type)
isMemberOfAny
public boolean isMemberOfAny(@NotNull
DeclarationDescriptor descriptor)
isString
public static boolean isString(@Nullable
KotlinType type)
isCharSequenceOrNullableCharSequence
public static boolean isCharSequenceOrNullableCharSequence(@Nullable
KotlinType type)
isStringOrNullableString
public static boolean isStringOrNullableString(@Nullable
KotlinType type)
isCollectionOrNullableCollection
public static boolean isCollectionOrNullableCollection(@NotNull
KotlinType type)
isListOrNullableList
public static boolean isListOrNullableList(@NotNull
KotlinType type)
isSetOrNullableSet
public static boolean isSetOrNullableSet(@NotNull
KotlinType type)
isIterableOrNullableIterable
public static boolean isIterableOrNullableIterable(@NotNull
KotlinType type)
isKClass
public static boolean isKClass(@NotNull
ClassDescriptor descriptor)
isNonPrimitiveArray
public static boolean isNonPrimitiveArray(@NotNull
ClassDescriptor descriptor)
isCloneable
public static boolean isCloneable(@NotNull
ClassDescriptor descriptor)
isDeprecated
public static boolean isDeprecated(@NotNull
DeclarationDescriptor declarationDescriptor)
isSuppressAnnotation
public static boolean isSuppressAnnotation(@NotNull
AnnotationDescriptor annotationDescriptor)