All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonMain.aws.sdk.kotlin.hll.dynamodbmapper.model.Index.kt Maven / Gradle / Ivy

There is a newer version: 1.3.73-beta
Show newest version
/*
 * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * SPDX-License-Identifier: Apache-2.0
 */
package aws.sdk.kotlin.hll.dynamodbmapper.model

import aws.sdk.kotlin.hll.dynamodbmapper.operations.IndexOperations
import aws.smithy.kotlin.runtime.ExperimentalApi

/**
 * Represents a secondary index on a table in DynamoDB and an associated item schema. Operations on this index will
 * invoke low-level operations and map items to objects.
 * @param T The type of objects which will be read from this index
 */
@ExperimentalApi
public interface Index :
    IndexSpec,
    IndexOperations,
    ItemSource {

    /**
     * Represents a secondary index whose primary key is a single partition key
     * @param T The type of objects which will be read from this index
     * @param PK The type of the partition key property, either [String], [Number], or [ByteArray]
     */
    @ExperimentalApi
    public interface PartitionKey :
        Index,
        PersistenceSpec.PartitionKey

    /**
     * Represents a secondary index whose primary key is a composite of a partition key and a sort key
     * @param T The type of objects which will be read from this index
     * @param PK The type of the partition key property, either [String], [Number], or [ByteArray]
     * @param SK The type of the sort key property, either [String], [Number], or [ByteArray]
     */
    @ExperimentalApi
    public interface CompositeKey :
        Index,
        PersistenceSpec.CompositeKey
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy