org.jetbrains.kotlin.descriptors
Interface ValueParameterDescriptor

All Superinterfaces:
Annotated, CallableDescriptor, DeclarationDescriptor, DeclarationDescriptorNonRoot, DeclarationDescriptorWithSource, DeclarationDescriptorWithVisibility, Named, ParameterDescriptor, VariableDescriptor
All Known Implementing Classes:
ValueParameterDescriptorImpl

public interface ValueParameterDescriptor
extends VariableDescriptor, ParameterDescriptor


Method Summary
 void addOverriddenDescriptor(ValueParameterDescriptor overridden)
           
 ValueParameterDescriptor copy(DeclarationDescriptor newOwner, Name newName)
           
 boolean declaresDefaultValue()
          The back-end should relies on this property when generating function signatures
 int getIndex()
          Returns the 0-based index of the value parameter in the parameter list of its containing function.
 ValueParameterDescriptor getOriginal()
           
 java.util.Set<? extends ValueParameterDescriptor> getOverriddenDescriptors()
          Parameter p1 overrides p2 iff a) their respective owners (function declarations) f1 override f2 b) p1 and p2 have the same indices in the owners' parameter lists
 JetType getVarargElementType()
           
 boolean hasDefaultValue()
          The front-end relies on this property when resolving function calls
 
Methods inherited from interface org.jetbrains.kotlin.descriptors.VariableDescriptor
getCompileTimeInitializer, getContainingDeclaration, getType, isVar, substitute
 
Methods inherited from interface org.jetbrains.kotlin.descriptors.ParameterDescriptor
getContainingDeclaration, getType
 
Methods inherited from interface org.jetbrains.kotlin.descriptors.CallableDescriptor
getDispatchReceiverParameter, getExtensionReceiverParameter, getReturnType, getTypeParameters, getValueParameters, hasStableParameterNames, hasSynthesizedParameterNames
 
Methods inherited from interface org.jetbrains.kotlin.descriptors.DeclarationDescriptorWithVisibility
getVisibility
 
Methods inherited from interface org.jetbrains.kotlin.descriptors.DeclarationDescriptorWithSource
getSource
 

Method Detail

getIndex

int getIndex()
Returns the 0-based index of the value parameter in the parameter list of its containing function.

Returns:
the parameter index

hasDefaultValue

boolean hasDefaultValue()
The front-end relies on this property when resolving function calls

Returns:
true iff the parameter has a default value, i.e. declares it or inherits by overriding a parameter in an overridden function.

declaresDefaultValue

boolean declaresDefaultValue()
The back-end should relies on this property when generating function signatures

Returns:
true iff the parameter declares a default value, i.e. explicitly specifies it in the function header

getVarargElementType

@Nullable
JetType getVarargElementType()

getOriginal

@NotNull
ValueParameterDescriptor getOriginal()
Specified by:
getOriginal in interface CallableDescriptor
Specified by:
getOriginal in interface DeclarationDescriptor
Specified by:
getOriginal in interface ParameterDescriptor
Returns:
The descriptor that corresponds to the original declaration of this element. A descriptor can be obtained from its original by substituting type arguments (of the declaring class or of the element itself). returns this object if the current descriptor is original itself

copy

@NotNull
ValueParameterDescriptor copy(@NotNull
                                      DeclarationDescriptor newOwner,
                                      @NotNull
                                      Name newName)

getOverriddenDescriptors

@NotNull
java.util.Set<? extends ValueParameterDescriptor> getOverriddenDescriptors()
Parameter p1 overrides p2 iff a) their respective owners (function declarations) f1 override f2 b) p1 and p2 have the same indices in the owners' parameter lists

Specified by:
getOverriddenDescriptors in interface CallableDescriptor

addOverriddenDescriptor

void addOverriddenDescriptor(@NotNull
                             ValueParameterDescriptor overridden)