from __future__ import annotations

from enum import Enum


class BucketOperationType(Enum):
    CloseBucket = 'close_bucket'
    OpenBucket = 'open_bucket'
    Ping = 'ping'


class ClusterOperationType(Enum):
    Close = 'close'
    Connect = 'connect'
    Diagnostics = 'diagnostics'
    GetConnectionInfo = 'get_connection_info'
    GetClusterLabels = 'get_cluster_labels'
    GetDefaultTimeouts = 'get_default_timeouts'
    Ping = 'ping'
    UpdateCredentials = 'update_credentials'
    WaitUntilReady = 'wait_until_ready'


class CollectionOperationType(Enum):
    KeyValueRangeScan = 'kv_range_scan'


class DatastructureOperationType(Enum):
    ListAppend = 'list_append'
    ListClear = 'list_clear'
    ListGetAll = 'list_get_all'
    ListGetAt = 'list_get_at'
    ListIndexOf = 'list_index_of'
    ListPrepend = 'list_prepend'
    ListRemoveAt = 'list_remove_at'
    ListSetAt = 'list_set_at'
    ListSize = 'list_size'
    MapAdd = 'map_add'
    MapClear = 'map_clear'
    MapExists = 'map_exists'
    MapGet = 'map_get'
    MapGetAll = 'map_get_all'
    MapItems = 'map_items'
    MapKeys = 'map_keys'
    MapRemove = 'map_remove'
    MapSize = 'map_size'
    MapValues = 'map_values'
    QueueClear = 'queue_clear'
    QueuePop = 'queue_pop'
    QueuePush = 'queue_push'
    QueueSize = 'queue_size'
    SetAdd = 'set_add'
    SetClear = 'set_clear'
    SetContains = 'set_contains'
    SetRemove = 'set_remove'
    SetSize = 'set_size'
    SetValues = 'set_values'

# For mgmt operations that do not have a C++ core request


class MgmtOperationType(Enum):
    QueryIndexWatchIndexes = 'query_index_watch_indexes'
    ViewIndexPublish = 'view_index_publish'

# TODO:  needed?  All scope operations are covered by StreamingOperationType.
# class ScopeOperationType(Enum):
#     AnalyicsQuery = 'analytics_query'
#     Query = 'query'
#     SearchQuery = 'search_query'

# ====================================================================================================
# AUTOGENERATED SECTION START - DO NOT EDIT MANUALLY
# Generated-On: 2026-02-21 16:18:40
# Content-Hash: 49e56774357fa1058b6773f6ff98302d
# ====================================================================================================
# ==========================================================================================
# Key-Value Operations
# ==========================================================================================


class KeyValueOperationType(Enum):
    Append = 'append'
    AppendWithLegacyDurability = 'append_with_legacy_durability'
    Decrement = 'decrement'
    DecrementWithLegacyDurability = 'decrement_with_legacy_durability'
    Exists = 'exists'
    Get = 'get'
    GetAllReplicas = 'get_all_replicas'
    GetAndLock = 'get_and_lock'
    GetAndTouch = 'get_and_touch'
    GetAnyReplica = 'get_any_replica'
    GetProjected = 'get_projected'
    Increment = 'increment'
    IncrementWithLegacyDurability = 'increment_with_legacy_durability'
    Insert = 'insert'
    InsertWithLegacyDurability = 'insert_with_legacy_durability'
    LookupIn = 'lookup_in'
    LookupInAllReplicas = 'lookup_in_all_replicas'
    LookupInAnyReplica = 'lookup_in_any_replica'
    MutateIn = 'mutate_in'
    MutateInWithLegacyDurability = 'mutate_in_with_legacy_durability'
    Prepend = 'prepend'
    PrependWithLegacyDurability = 'prepend_with_legacy_durability'
    Remove = 'remove'
    RemoveWithLegacyDurability = 'remove_with_legacy_durability'
    Replace = 'replace'
    ReplaceWithLegacyDurability = 'replace_with_legacy_durability'
    Touch = 'touch'
    Unlock = 'unlock'
    Upsert = 'upsert'
    UpsertWithLegacyDurability = 'upsert_with_legacy_durability'

# ==========================================================================================
# Key-Value Multi Operations
# ==========================================================================================


class KeyValueMultiOperationType(Enum):
    AppendMulti = 'append_multi'
    AppendWithLegacyDurabilityMulti = 'append_with_legacy_durability_multi'
    DecrementMulti = 'decrement_multi'
    DecrementWithLegacyDurabilityMulti = 'decrement_with_legacy_durability_multi'
    ExistsMulti = 'exists_multi'
    GetMulti = 'get_multi'
    GetAllReplicasMulti = 'get_all_replicas_multi'
    GetAndLockMulti = 'get_and_lock_multi'
    GetAndTouchMulti = 'get_and_touch_multi'
    GetAnyReplicaMulti = 'get_any_replica_multi'
    IncrementMulti = 'increment_multi'
    IncrementWithLegacyDurabilityMulti = 'increment_with_legacy_durability_multi'
    InsertMulti = 'insert_multi'
    InsertWithLegacyDurabilityMulti = 'insert_with_legacy_durability_multi'
    PrependMulti = 'prepend_multi'
    PrependWithLegacyDurabilityMulti = 'prepend_with_legacy_durability_multi'
    RemoveMulti = 'remove_multi'
    RemoveWithLegacyDurabilityMulti = 'remove_with_legacy_durability_multi'
    ReplaceMulti = 'replace_multi'
    ReplaceWithLegacyDurabilityMulti = 'replace_with_legacy_durability_multi'
    TouchMulti = 'touch_multi'
    UnlockMulti = 'unlock_multi'
    UpsertMulti = 'upsert_multi'
    UpsertWithLegacyDurabilityMulti = 'upsert_with_legacy_durability_multi'

# ==========================================================================================
# Streaming Operations
# ==========================================================================================


class StreamingOperationType(Enum):
    AnalyticsQuery = 'analytics_query'
    Query = 'query'
    SearchQuery = 'search_query'
    ViewQuery = 'view_query'


# ==========================================================================================
# Analytics Management Operations
# ==========================================================================================
class AnalyticsMgmtOperationType(Enum):
    AnalyticsDatasetCreate = 'analytics_dataset_create'
    AnalyticsDatasetDrop = 'analytics_dataset_drop'
    AnalyticsDatasetGetAll = 'analytics_dataset_get_all'
    AnalyticsDataverseCreate = 'analytics_dataverse_create'
    AnalyticsDataverseDrop = 'analytics_dataverse_drop'
    AnalyticsGetPendingMutations = 'analytics_get_pending_mutations'
    AnalyticsIndexCreate = 'analytics_index_create'
    AnalyticsIndexDrop = 'analytics_index_drop'
    AnalyticsIndexGetAll = 'analytics_index_get_all'
    AnalyticsLinkConnect = 'analytics_link_connect'
    AnalyticsLinkCreateCouchbaseRemoteLink = 'analytics_link_create_couchbase_remote_link'
    AnalyticsLinkCreateS3ExternalLink = 'analytics_link_create_s3_external_link'
    AnalyticsLinkCreateAzureBlobExternalLink = 'analytics_link_create_azure_blob_external_link'
    AnalyticsLinkDisconnect = 'analytics_link_disconnect'
    AnalyticsLinkDrop = 'analytics_link_drop'
    AnalyticsLinkGetAll = 'analytics_link_get_all'
    AnalyticsLinkReplaceCouchbaseRemoteLink = 'analytics_link_replace_couchbase_remote_link'
    AnalyticsLinkReplaceS3ExternalLink = 'analytics_link_replace_s3_external_link'
    AnalyticsLinkReplaceAzureBlobExternalLink = 'analytics_link_replace_azure_blob_external_link'


# ==========================================================================================
# Bucket Management Operations
# ==========================================================================================
class BucketMgmtOperationType(Enum):
    BucketCreate = 'bucket_create'
    BucketDrop = 'bucket_drop'
    BucketFlush = 'bucket_flush'
    BucketGet = 'bucket_get'
    BucketGetAll = 'bucket_get_all'
    BucketUpdate = 'bucket_update'
    BucketDescribe = 'bucket_describe'


# ==========================================================================================
# Cluster Management Operations
# ==========================================================================================
class ClusterMgmtOperationType(Enum):
    ClusterDescribe = 'cluster_describe'
    ClusterDeveloperPreviewEnable = 'cluster_developer_preview_enable'


# ==========================================================================================
# Collection Management Operations
# ==========================================================================================
class CollectionMgmtOperationType(Enum):
    CollectionCreate = 'collection_create'
    CollectionsManifestGet = 'collections_manifest_get'
    CollectionDrop = 'collection_drop'
    CollectionUpdate = 'collection_update'
    ScopeCreate = 'scope_create'
    ScopeDrop = 'scope_drop'
    ScopeGetAll = 'scope_get_all'


# ==========================================================================================
# EventingFunction Management Operations
# ==========================================================================================
class EventingFunctionMgmtOperationType(Enum):
    EventingDeployFunction = 'eventing_deploy_function'
    EventingDropFunction = 'eventing_drop_function'
    EventingGetAllFunctions = 'eventing_get_all_functions'
    EventingGetFunction = 'eventing_get_function'
    EventingGetStatus = 'eventing_get_status'
    EventingPauseFunction = 'eventing_pause_function'
    EventingResumeFunction = 'eventing_resume_function'
    EventingUndeployFunction = 'eventing_undeploy_function'
    EventingUpsertFunction = 'eventing_upsert_function'


# ==========================================================================================
# QueryIndex Management Operations
# ==========================================================================================
class QueryIndexMgmtOperationType(Enum):
    QueryIndexBuild = 'query_index_build'
    QueryIndexBuildDeferred = 'query_index_build_deferred'
    QueryIndexCreate = 'query_index_create'
    QueryIndexDrop = 'query_index_drop'
    QueryIndexGetAll = 'query_index_get_all'
    QueryIndexGetAllDeferred = 'query_index_get_all_deferred'


# ==========================================================================================
# SearchIndex Management Operations
# ==========================================================================================
class SearchIndexMgmtOperationType(Enum):
    SearchGetStats = 'search_get_stats'
    SearchIndexAnalyzeDocument = 'search_index_analyze_document'
    SearchIndexControlIngest = 'search_index_control_ingest'
    SearchIndexControlPlanFreeze = 'search_index_control_plan_freeze'
    SearchIndexControlQuery = 'search_index_control_query'
    SearchIndexDrop = 'search_index_drop'
    SearchIndexGet = 'search_index_get'
    SearchIndexGetAll = 'search_index_get_all'
    SearchIndexGetDocumentsCount = 'search_index_get_documents_count'
    SearchIndexGetStats = 'search_index_get_stats'
    SearchIndexUpsert = 'search_index_upsert'


# ==========================================================================================
# User Management Operations
# ==========================================================================================
class UserMgmtOperationType(Enum):
    ChangePassword = 'change_password'
    GroupDrop = 'group_drop'
    GroupGet = 'group_get'
    GroupGetAll = 'group_get_all'
    GroupUpsert = 'group_upsert'
    RoleGetAll = 'role_get_all'
    UserDrop = 'user_drop'
    UserGet = 'user_get'
    UserGetAll = 'user_get_all'
    UserUpsert = 'user_upsert'


# ==========================================================================================
# ViewIndex Management Operations
# ==========================================================================================
class ViewIndexMgmtOperationType(Enum):
    ViewIndexDrop = 'view_index_drop'
    ViewIndexGet = 'view_index_get'
    ViewIndexGetAll = 'view_index_get_all'
    ViewIndexUpsert = 'view_index_upsert'

# ====================================================================================================
# AUTOGENERATED SECTION END - DO NOT EDIT MANUALLY
# Generated-On: 2026-02-21 16:18:40
# Content-Hash: 49e56774357fa1058b6773f6ff98302d
# ====================================================================================================
