Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,9 @@ class CodeWhispererFeatureConfigService {

fun getNewAutoTriggerUX(): Boolean = getFeatureValueForKey(NEW_AUTO_TRIGGER_UX).stringValue() == "TREATMENT"

@Suppress("UNUSED")
fun getInlineCompletion(): Boolean = getFeatureValueForKey(INLINE_COMPLETION).stringValue() == "TREATMENT"

// Get the feature value for the given key.
// In case of a misconfiguration, it will return a default feature value of Boolean false.
private fun getFeatureValueForKey(name: String): FeatureValue =
Expand All @@ -117,6 +120,7 @@ class CodeWhispererFeatureConfigService {
companion object {
fun getInstance(): CodeWhispererFeatureConfigService = service()
private const val TEST_FEATURE_NAME = "testFeature"
private const val INLINE_COMPLETION = "ProjectContextV2"
private const val DATA_COLLECTION_FEATURE = "IDEProjectContextDataCollection"
const val CUSTOMIZATION_ARN_OVERRIDE_NAME = "customizationArnOverride"
private const val NEW_AUTO_TRIGGER_UX = "newAutoTriggerUX"
Expand All @@ -141,6 +145,11 @@ class CodeWhispererFeatureConfigService {
"CONTROL",
FeatureValue.builder().stringValue("CONTROL").build()
),
INLINE_COMPLETION to FeatureContext(
INLINE_COMPLETION,
"CONTROL",
FeatureValue.builder().stringValue("CONTROL").build()
)
)
}
}
Expand Down
Loading