id stringlengths 11 116 | type stringclasses 1
value | granularity stringclasses 4
values | content stringlengths 16 477k | metadata dict |
|---|---|---|---|---|
fn_clm_external_services_upload_file_6443311555561730543 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/file_system
// Implementation of FileSystem for FileStorageInterface
/// Saves the provided file data to the file system under the specified file key.
async fn upload_file(
&self,
file_key: &st... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 24,
"total_crates": null
} |
fn_clm_external_services_retrieve_file_6443311555561730543 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/file_system
// Implementation of FileSystem for FileStorageInterface
/// Retrieves the file content associated with the specified file key from the file system.
async fn retrieve_file(&self, file_key: &str) ->... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 24,
"total_crates": null
} |
fn_clm_external_services_delete_file_6443311555561730543 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/file_system
// Implementation of FileSystem for FileStorageInterface
/// Deletes the file associated with the specified file key from the file system.
async fn delete_file(&self, file_key: &str) -> CustomResul... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 21,
"total_crates": null
} |
fn_clm_external_services_get_file_path_6443311555561730543 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/file_system
/// Constructs the file path for a given file key within the file system.
/// The file path is generated based on the workspace path and the provided file key.
fn get_file_path(file_key: impl AsRe... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 16,
"total_crates": null
} |
fn_clm_external_services_new_-2000283242844065826 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/aws_s3
// Inherent implementation for AwsFileStorageClient
/// Creates a new AWS S3 file storage client.
pub(super) async fn new(config: &AwsFileStorageConfig) -> Self {
let region_provider = RegionPro... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14479,
"total_crates": null
} |
fn_clm_external_services_validate_-2000283242844065826 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/aws_s3
// Inherent implementation for AwsFileStorageConfig
/// Validates the AWS S3 file storage configuration.
pub(super) fn validate(&self) -> Result<(), InvalidFileStorageConfig> {
use common_utils:... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 231,
"total_crates": null
} |
fn_clm_external_services_upload_file_-2000283242844065826 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/aws_s3
// Implementation of AwsFileStorageClient for FileStorageInterface
/// Uploads a file to AWS S3.
async fn upload_file(
&self,
file_key: &str,
file: Vec<u8>,
) -> CustomResult... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 24,
"total_crates": null
} |
fn_clm_external_services_retrieve_file_-2000283242844065826 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/aws_s3
// Implementation of AwsFileStorageClient for FileStorageInterface
/// Retrieves a file from AWS S3.
async fn retrieve_file(&self, file_key: &str) -> CustomResult<Vec<u8>, FileStorageError> {
Ok... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 24,
"total_crates": null
} |
fn_clm_external_services_delete_file_-2000283242844065826 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/file_storage/aws_s3
// Implementation of AwsFileStorageClient for FileStorageInterface
/// Deletes a file from AWS S3.
async fn delete_file(&self, file_key: &str) -> CustomResult<(), FileStorageError> {
self.delete... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 21,
"total_crates": null
} |
fn_clm_external_services_validate_-2311798538485878475 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/managers/secrets_management
// Inherent implementation for SecretsManagementConfig
/// Verifies that the client configuration is usable
pub fn validate(&self) -> Result<(), &'static str> {
match self {
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 223,
"total_crates": null
} |
fn_clm_external_services_get_secret_management_client_-2311798538485878475 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/managers/secrets_management
// Inherent implementation for SecretsManagementConfig
/// Retrieves the appropriate secret management client based on the configuration.
pub async fn get_secret_management_client(
&self... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 35,
"total_crates": null
} |
fn_clm_external_services_validate_-5772774202332400350 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/managers/encryption_management
// Inherent implementation for EncryptionManagementConfig
/// Verifies that the client configuration is usable
pub fn validate(&self) -> Result<(), &'static str> {
match self {
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 221,
"total_crates": null
} |
fn_clm_external_services_get_encryption_management_client_-5772774202332400350 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/managers/encryption_management
// Inherent implementation for EncryptionManagementConfig
/// Retrieves the appropriate encryption client based on the configuration.
pub async fn get_encryption_management_client(
&s... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 27,
"total_crates": null
} |
fn_clm_external_services_decrypt_-1086686959092261861 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/no_encryption/core
// Inherent implementation for NoEncryption
/// Decryption functionality
pub fn decrypt(&self, data: impl AsRef<[u8]>) -> Vec<u8> {
data.as_ref().into()
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 52,
"total_crates": null
} |
fn_clm_external_services_encrypt_-1086686959092261861 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/no_encryption/core
// Inherent implementation for NoEncryption
/// Encryption functionality
pub fn encrypt(&self, data: impl AsRef<[u8]>) -> Vec<u8> {
data.as_ref().into()
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 49,
"total_crates": null
} |
fn_clm_external_services_get_secret_-6912714844158479302 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/no_encryption/implementers
// Implementation of NoEncryption for SecretManagementInterface
async fn get_secret(
&self,
input: Secret<String>,
) -> CustomResult<Secret<String>, SecretsManagementError> {
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 104,
"total_crates": null
} |
fn_clm_external_services_decrypt_-6912714844158479302 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/no_encryption/implementers
// Implementation of NoEncryption for EncryptionManagementInterface
async fn decrypt(&self, input: &[u8]) -> CustomResult<Vec<u8>, EncryptionError> {
Ok(self.decrypt(input))
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 40,
"total_crates": null
} |
fn_clm_external_services_encrypt_-6912714844158479302 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/no_encryption/implementers
// Implementation of NoEncryption for EncryptionManagementInterface
async fn encrypt(&self, input: &[u8]) -> CustomResult<Vec<u8>, EncryptionError> {
Ok(self.encrypt(input))
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 37,
"total_crates": null
} |
fn_clm_external_services_new_5428978503985758258 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/core
// Inherent implementation for AwsKmsClient
/// Constructs a new AWS KMS client.
pub async fn new(config: &AwsKmsConfig) -> Self {
let region_provider = RegionProviderChain::first_try(Region::new(confi... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14479,
"total_crates": null
} |
fn_clm_external_services_validate_5428978503985758258 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/core
// Inherent implementation for AwsKmsConfig
/// Verifies that the [`AwsKmsClient`] configuration is usable.
pub fn validate(&self) -> Result<(), &'static str> {
use common_utils::{ext_traits::ConfigExt... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 227,
"total_crates": null
} |
fn_clm_external_services_decrypt_5428978503985758258 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/core
// Inherent implementation for AwsKmsClient
/// Decrypts the provided base64-encoded encrypted data using the AWS KMS SDK. We assume that
/// the SDK has the values required to interact with the AWS KMS APIs (`... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 86,
"total_crates": null
} |
fn_clm_external_services_encrypt_5428978503985758258 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/core
// Inherent implementation for AwsKmsClient
/// Encrypts the provided String data using the AWS KMS SDK. We assume that
/// the SDK has the values required to interact with the AWS KMS APIs (`AWS_ACCESS_KEY_ID`... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 79,
"total_crates": null
} |
fn_clm_external_services_check_aws_kms_encryption_5428978503985758258 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/core
async fn check_aws_kms_encryption() {
std::env::set_var("AWS_SECRET_ACCESS_KEY", "YOUR SECRET ACCESS KEY");
std::env::set_var("AWS_ACCESS_KEY_ID", "YOUR AWS ACCESS KEY ID");
use super::*;... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 16,
"total_crates": null
} |
fn_clm_external_services_get_secret_3292068361999423685 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/implementers
// Implementation of AwsKmsClient for SecretManagementInterface
async fn get_secret(
&self,
input: Secret<String>,
) -> CustomResult<Secret<String>, SecretsManagementError> {
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 100,
"total_crates": null
} |
fn_clm_external_services_decrypt_3292068361999423685 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/implementers
// Implementation of AwsKmsClient for EncryptionManagementInterface
async fn decrypt(&self, input: &[u8]) -> CustomResult<Vec<u8>, EncryptionError> {
self.decrypt(input)
.await
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 46,
"total_crates": null
} |
fn_clm_external_services_encrypt_3292068361999423685 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/aws_kms/implementers
// Implementation of AwsKmsClient for EncryptionManagementInterface
async fn encrypt(&self, input: &[u8]) -> CustomResult<Vec<u8>, EncryptionError> {
self.encrypt(input)
.await
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 43,
"total_crates": null
} |
fn_clm_external_services_new_327877765888171431 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/superposition/types
// Inherent implementation for ConfigContext
/// Create a new empty context
pub fn new() -> Self {
Self::default()
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14465,
"total_crates": null
} |
fn_clm_external_services_default_327877765888171431 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/superposition/types
// Implementation of SuperpositionClientConfig for Default
fn default() -> Self {
Self {
enabled: false,
endpoint: String::new(),
token: Secret::new(String::new... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7713,
"total_crates": null
} |
fn_clm_external_services_try_from_327877765888171431 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/superposition/types
// Implementation of JsonValue for TryFrom<open_feature::StructValue>
fn try_from(sv: open_feature::StructValue) -> Result<Self, Self::Error> {
let capacity = sv.fields.len();
sv.fields
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 2675,
"total_crates": null
} |
fn_clm_external_services_into_inner_327877765888171431 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/superposition/types
// Inherent implementation for JsonValue
/// Consume the wrapper and return the inner JSON value
pub(super) fn into_inner(self) -> serde_json::Value {
self.0
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 2061,
"total_crates": null
} |
fn_clm_external_services_validate_327877765888171431 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/superposition/types
// Inherent implementation for SuperpositionClientConfig
/// Validate the Superposition configuration
pub fn validate(&self) -> Result<(), SuperpositionError> {
if !self.enabled {
re... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 265,
"total_crates": null
} |
fn_clm_external_services_perform_health_check_-1467357567945343445 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/health_check_client
// Implementation of None for HealthCheckClient
/// Perform health check for all services involved
pub async fn perform_health_check(
&self,
config: &GrpcClientSettings,
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 57,
"total_crates": null
} |
fn_clm_external_services_build_connections_-1467357567945343445 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/health_check_client
// Implementation of None for HealthCheckClient
/// Build connections to all gRPC services
pub async fn build_connections(
config: &GrpcClientSettings,
client: Client,
) ... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 34,
"total_crates": null
} |
fn_clm_external_services_get_response_from_grpc_service_-1467357567945343445 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/health_check_client
// Implementation of None for HealthCheckClient
async fn get_response_from_grpc_service(
&self,
service: String,
client: Option<&HealthClient<Client>>,
) -> HealthC... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 31,
"total_crates": null
} |
fn_clm_external_services_build_unified_connector_service_grpc_headers_4861670135421457472 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/unified_connector_service
/// Build the gRPC Headers for Unified Connector Service Request
pub fn build_unified_connector_service_grpc_headers(
meta: ConnectorAuthMetadata,
grpc_headers: GrpcHeadersUcs,... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 111,
"total_crates": null
} |
fn_clm_external_services_payment_authorize_4861670135421457472 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/unified_connector_service
// Implementation of None for UnifiedConnectorServiceClient
/// Performs Payment Authorize
pub async fn payment_authorize(
&self,
payment_authorize_request: payments_gr... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 43,
"total_crates": null
} |
fn_clm_external_services_payment_get_4861670135421457472 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/unified_connector_service
// Implementation of None for UnifiedConnectorServiceClient
/// Performs Payment Sync/Get
pub async fn payment_get(
&self,
payment_get_request: payments_grpc::PaymentSe... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 37,
"total_crates": null
} |
fn_clm_external_services_payment_setup_mandate_4861670135421457472 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/unified_connector_service
// Implementation of None for UnifiedConnectorServiceClient
/// Performs Payment Setup Mandate
pub async fn payment_setup_mandate(
&self,
payment_register_request: paym... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 37,
"total_crates": null
} |
fn_clm_external_services_payment_repeat_4861670135421457472 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/unified_connector_service
// Implementation of None for UnifiedConnectorServiceClient
/// Performs Payment repeat (MIT - Merchant Initiated Transaction).
pub async fn payment_repeat(
&self,
paym... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 37,
"total_crates": null
} |
fn_clm_external_services_get_dynamic_routing_connection_434055429132977546 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing
// Inherent implementation for DynamicRoutingClientConfig
/// establish connection with the server
pub fn get_dynamic_routing_connection(
self,
client: Client,
) -> Result<Op... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 35,
"total_crates": null
} |
fn_clm_external_services_add_recovery_headers_4046408955831391427 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/revenue_recovery
// Implementation of tonic::Request<T> for AddRecoveryHeaders
fn add_recovery_headers(&mut self, headers: GrpcRecoveryHeaders) {
headers.request_id.map(|request_id| {
request_... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 25,
"total_crates": null
} |
fn_clm_external_services_create_revenue_recovery_grpc_request_4046408955831391427 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/revenue_recovery
/// Creates a tonic::Request with recovery headers added.
pub(crate) fn create_revenue_recovery_grpc_request<T: Debug>(
message: T,
recovery_headers: GrpcRecoveryHeaders,
) -> tonic::Re... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 17,
"total_crates": null
} |
fn_clm_external_services_foreign_try_from_-657950532223310013 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/elimination_based_client
// Implementation of EliminationBucketConfig for ForeignTryFrom<EliminationConfig>
fn foreign_try_from(config: EliminationConfig) -> Result<Self, Self::Error> {
Ok... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 440,
"total_crates": null
} |
fn_clm_external_services_perform_elimination_routing_-657950532223310013 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/elimination_based_client
// Implementation of EliminationAnalyserClient<Client> for EliminationBasedRouting
async fn perform_elimination_routing(
&self,
id: String,
params:... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 38,
"total_crates": null
} |
fn_clm_external_services_update_elimination_bucket_config_-657950532223310013 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/elimination_based_client
// Implementation of EliminationAnalyserClient<Client> for EliminationBasedRouting
async fn update_elimination_bucket_config(
&self,
id: String,
pa... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 35,
"total_crates": null
} |
fn_clm_external_services_invalidate_elimination_bucket_-657950532223310013 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/elimination_based_client
// Implementation of EliminationAnalyserClient<Client> for EliminationBasedRouting
async fn invalidate_elimination_bucket(
&self,
id: String,
heade... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 25,
"total_crates": null
} |
fn_clm_external_services_foreign_try_from_-8573382143543490697 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/success_rate_client
// Implementation of CalGlobalSuccessRateConfig for ForeignTryFrom<SuccessBasedRoutingConfigBody>
fn foreign_try_from(config: SuccessBasedRoutingConfigBody) -> Result<Self, Sel... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 440,
"total_crates": null
} |
fn_clm_external_services_update_success_rate_-8573382143543490697 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/success_rate_client
// Implementation of SuccessRateCalculatorClient<Client> for SuccessBasedDynamicRouting
async fn update_success_rate(
&self,
id: String,
success_rate_ba... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 47,
"total_crates": null
} |
fn_clm_external_services_calculate_entity_and_global_success_rate_-8573382143543490697 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/success_rate_client
// Implementation of SuccessRateCalculatorClient<Client> for SuccessBasedDynamicRouting
async fn calculate_entity_and_global_success_rate(
&self,
id: String,
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 43,
"total_crates": null
} |
fn_clm_external_services_calculate_success_rate_-8573382143543490697 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/success_rate_client
// Implementation of SuccessRateCalculatorClient<Client> for SuccessBasedDynamicRouting
async fn calculate_success_rate(
&self,
id: String,
success_rate... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 35,
"total_crates": null
} |
fn_clm_external_services_invalidate_success_rate_routing_keys_-8573382143543490697 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/success_rate_client
// Implementation of SuccessRateCalculatorClient<Client> for SuccessBasedDynamicRouting
async fn invalidate_success_rate_routing_keys(
&self,
id: String,
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 25,
"total_crates": null
} |
fn_clm_external_services_foreign_try_from_-4224376731579693474 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/contract_routing_client
// Implementation of CalContractScoreConfig for ForeignTryFrom<ContractBasedRoutingConfigBody>
fn foreign_try_from(config: ContractBasedRoutingConfigBody) -> Result<Self, S... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 438,
"total_crates": null
} |
fn_clm_external_services_foreign_from_-4224376731579693474 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/contract_routing_client
// Implementation of ProtoLabelInfo for ForeignFrom<LabelInformation>
fn foreign_from(config: LabelInformation) -> Self {
Self {
label: format!(
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 214,
"total_crates": null
} |
fn_clm_external_services_calculate_contract_score_-4224376731579693474 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/contract_routing_client
// Implementation of ContractScoreCalculatorClient<Client> for ContractBasedDynamicRouting
async fn calculate_contract_score(
&self,
id: String,
con... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 40,
"total_crates": null
} |
fn_clm_external_services_update_contracts_-4224376731579693474 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/contract_routing_client
// Implementation of ContractScoreCalculatorClient<Client> for ContractBasedDynamicRouting
async fn update_contracts(
&self,
id: String,
label_info:... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 36,
"total_crates": null
} |
fn_clm_external_services_invalidate_contracts_-4224376731579693474 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/dynamic_routing/contract_routing_client
// Implementation of ContractScoreCalculatorClient<Client> for ContractBasedDynamicRouting
async fn invalidate_contracts(
&self,
id: String,
headers... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 25,
"total_crates": null
} |
fn_clm_external_services_validate_1182830238634037889 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/revenue_recovery/recovery_decider_client
// Inherent implementation for RecoveryDeciderClientConfig
/// Validate the configuration
pub fn validate(&self) -> Result<(), RecoveryDeciderError> {
use common... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 227,
"total_crates": null
} |
fn_clm_external_services_get_recovery_decider_connection_1182830238634037889 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/revenue_recovery/recovery_decider_client
// Inherent implementation for RecoveryDeciderClientConfig
/// create a connection
pub fn get_recovery_decider_connection(
&self,
hyper_client: Client,
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 29,
"total_crates": null
} |
fn_clm_external_services_decide_on_retry_1182830238634037889 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/grpc_client/revenue_recovery/recovery_decider_client
// Implementation of DeciderClient<Client> for RecoveryDeciderClientInterface
async fn decide_on_retry(
&mut self,
request_payload: DeciderRequest,
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 23,
"total_crates": null
} |
fn_clm_external_services_validate_-3799855670246986663 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/ses
// Implementation of None for SESConfig
/// Validation for the SES client specific configs
pub fn validate(&self) -> Result<(), &'static str> {
use common_utils::{ext_traits::ConfigExt, fp_utils::when};
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 227,
"total_crates": null
} |
fn_clm_external_services_create_client_-3799855670246986663 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/ses
// Inherent implementation for AwsSes
/// A helper function to create ses client
pub async fn create_client(
conf: &EmailSettings,
ses_config: &SESConfig,
proxy_url: Option<impl AsRef<str>... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 105,
"total_crates": null
} |
fn_clm_external_services_create_-3799855670246986663 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/ses
// Inherent implementation for AwsSes
/// Constructs a new AwsSes client
pub async fn create(
conf: &EmailSettings,
ses_config: &SESConfig,
proxy_url: Option<impl AsRef<str>>,
) -> Sel... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 78,
"total_crates": null
} |
fn_clm_external_services_send_email_-3799855670246986663 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/ses
// Implementation of AwsSes for EmailClient
async fn send_email(
&self,
recipient: pii::Email,
subject: String,
body: Self::RichText,
proxy_url: Option<&String>,
) -> Ema... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 68,
"total_crates": null
} |
fn_clm_external_services_convert_to_rich_text_-3799855670246986663 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/ses
// Implementation of AwsSes for EmailClient
fn convert_to_rich_text(
&self,
intermediate_string: IntermediateString,
) -> CustomResult<Self::RichText, EmailError> {
let email_body = Body... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 29,
"total_crates": null
} |
fn_clm_external_services_create_-4883370010201602958 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/no_email
// Inherent implementation for NoEmailClient
/// Constructs a new client when email is disabled
pub async fn create() -> Self {
Self {}
}
| {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 66,
"total_crates": null
} |
fn_clm_external_services_send_email_-4883370010201602958 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/no_email
// Implementation of NoEmailClient for EmailClient
async fn send_email(
&self,
_recipient: pii::Email,
_subject: String,
_body: Self::RichText,
_proxy_url: Option<&Strin... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14,
"total_crates": null
} |
fn_clm_external_services_convert_to_rich_text_-4883370010201602958 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/no_email
// Implementation of NoEmailClient for EmailClient
fn convert_to_rich_text(
&self,
intermediate_string: IntermediateString,
) -> CustomResult<Self::RichText, EmailError> {
Ok(interm... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 13,
"total_crates": null
} |
fn_clm_external_services_validate_-2456641570340612897 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/smtp
// Implementation of None for SmtpServerConfig
/// Validation for the SMTP server client specific configs
pub fn validate(&self) -> Result<(), &'static str> {
use common_utils::{ext_traits::ConfigExt, fp... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 243,
"total_crates": null
} |
fn_clm_external_services_create_client_-2456641570340612897 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/smtp
// Inherent implementation for SmtpServer
/// A helper function to create SMTP server client
pub fn create_client(&self) -> Result<SmtpTransport, SmtpError> {
let host = self.smtp_config.host.clone();
... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 101,
"total_crates": null
} |
fn_clm_external_services_create_-2456641570340612897 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/smtp
// Inherent implementation for SmtpServer
/// Constructs a new SMTP client
pub async fn create(conf: &EmailSettings, smtp_config: SmtpServerConfig) -> Self {
Self {
sender: conf.sender_email.... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 70,
"total_crates": null
} |
fn_clm_external_services_send_email_-2456641570340612897 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/smtp
// Implementation of SmtpServer for EmailClient
async fn send_email(
&self,
recipient: pii::Email,
subject: String,
body: Self::RichText,
_proxy_url: Option<&String>,
) ... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 50,
"total_crates": null
} |
fn_clm_external_services_to_mail_box_-2456641570340612897 | clm | function | // Repository: hyperswitch
// Crate: external_services
// Module: crates/external_services/src/email/smtp
// Inherent implementation for SmtpServer
/// helper function to convert email id into Mailbox
fn to_mail_box(email: String) -> EmailResult<Mailbox> {
Ok(Mailbox::new(
None,
email... | {
"crate": "external_services",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 22,
"total_crates": null
} |
fn_clm_euclid_macros_knowledge_6180411282091019233 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/lib
pub fn knowledge(ts: TokenStream) -> TokenStream {
match inner::knowledge_inner(ts.into()) {
Ok(ts) => ts.into(),
Err(e) => e.into_compile_error().into(),
}
}
| {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 20,
"total_crates": null
} |
fn_clm_euclid_macros_enum_nums_6180411282091019233 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/lib
pub fn enum_nums(ts: TokenStream) -> TokenStream {
inner::enum_nums_inner(ts)
}
| {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 12,
"total_crates": null
} |
fn_clm_euclid_macros_error_7679541349067252623 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/enum_nums
fn error() -> TokenStream2 {
syn::Error::new(
Span::call_site(),
"'EnumNums' can only be derived on enums with unit variants".to_string(),
)
.to_compile_error()
}
| {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 95,
"total_crates": null
} |
fn_clm_euclid_macros_enum_nums_inner_7679541349067252623 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/enum_nums
pub(crate) fn enum_nums_inner(ts: TokenStream) -> TokenStream {
let derive_input = syn::parse_macro_input!(ts as syn::DeriveInput);
let enum_obj = match derive_input.data {
syn::Data::Enum(e) => e,
... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 33,
"total_crates": null
} |
fn_clm_euclid_macros_to_string_3249742868210120849 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/knowledge
// Inherent implementation for ValueType
fn to_string(&self, key: &str) -> String {
match self {
Self::Any => format!("{key}(any)"),
Self::EnumVariant(s) => format!("{key}({s})"),
... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14744,
"total_crates": null
} |
fn_clm_euclid_macros_new_3249742868210120849 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/knowledge
// Implementation of None for GenContext
fn new() -> Self {
Self {
next_idx: 1,
next_node_idx: 1,
idx2atom: FxHashMap::default(),
atom2idx: FxHashMap::default()... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14461,
"total_crates": null
} |
fn_clm_euclid_macros_parse_3249742868210120849 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/knowledge
// Implementation of Program for Parse
fn parse(input: syn::parse::ParseStream<'_>) -> syn::Result<Self> {
let mut rules: Vec<Rc<Rule>> = Vec::new();
while !input.is_empty() {
rules.push(... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 454,
"total_crates": null
} |
fn_clm_euclid_macros_cycle_dfs_3249742868210120849 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/knowledge
// Implementation of None for GenContext
fn cycle_dfs(
&self,
node_id: usize,
explored: &mut FxHashSet<usize>,
visited: &mut FxHashSet<usize>,
order: &mut Vec<usize>,
) -> ... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 54,
"total_crates": null
} |
fn_clm_euclid_macros_detect_graph_cycles_3249742868210120849 | clm | function | // Repository: hyperswitch
// Crate: euclid_macros
// Module: crates/euclid_macros/src/inner/knowledge
// Implementation of None for GenContext
fn detect_graph_cycles(&self) -> Result<(), String> {
let start_nodes = self.edges.keys().copied().collect::<Vec<usize>>();
let mut total_visited = FxHashSet:... | {
"crate": "euclid_macros",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 49,
"total_crates": null
} |
fn_clm_masking_zeroize_2360117845480941133 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/tests/basic
// Implementation of AccountNumber for ZeroizableSecret
fn zeroize(&mut self) {
self.0.zeroize();
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 25,
"total_crates": null
} |
fn_clm_masking_basic_2360117845480941133 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/tests/basic
fn basic() -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
#[cfg_attr(feature = "serde", derive(Serialize))]
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct AccountNumb... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14,
"total_crates": null
} |
fn_clm_masking_without_serialize_2360117845480941133 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/tests/basic
fn without_serialize() -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
#[cfg_attr(feature = "serde", derive(Serialize))]
#[derive(Clone, Debug, PartialEq, Eq)]
pub struct... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 12,
"total_crates": null
} |
fn_clm_masking_for_string_2360117845480941133 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/tests/basic
fn for_string() -> Result<(), Box<dyn std::error::Error + Send + Sync>> {
#[cfg_attr(all(feature = "alloc", feature = "serde"), derive(Serialize))]
#[derive(Clone, Debug, PartialEq, Eq... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 10,
"total_crates": null
} |
fn_clm_masking_fmt_5830369588327829564 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strategy
// Implementation of WithoutType for Strategy<T>
fn fmt(_: &T, fmt: &mut fmt::Formatter<'_>) -> fmt::Result {
fmt.write_str("*** ***")
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 40,
"total_crates": null
} |
fn_clm_masking_expose_-5098255901369738420 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/abs
// Implementation of Secret<S, I> for ExposeInterface<S>
fn expose(self) -> S {
self.inner_secret
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 887,
"total_crates": null
} |
fn_clm_masking_switch_strategy_-5098255901369738420 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/abs
// Implementation of Secret<S, FromStrategy> for SwitchStrategy<FromStrategy, ToStrategy>
fn switch_strategy(self) -> Self::Output {
Secret::new(self.inner_secret)
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 70,
"total_crates": null
} |
fn_clm_masking_expose_option_-5098255901369738420 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/abs
// Implementation of Option<Secret<S, I>> for ExposeOptionInterface<Option<S>>
fn expose_option(self) -> Option<S> {
self.map(ExposeInterface::expose)
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 52,
"total_crates": null
} |
fn_clm_masking_clone_-2729277852852699987 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strong_secret
// Implementation of StrongSecret<Secret, MaskingStrategy> for Clone
fn clone(&self) -> Self {
Self {
inner_secret: self.inner_secret.clone(),
masking_str... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 27325,
"total_crates": null
} |
fn_clm_masking_new_-2729277852852699987 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strong_secret
// Inherent implementation for StrongSecret<Secret, MaskingStrategy>
/// Take ownership of a secret value
pub fn new(secret: Secret) -> Self {
Self {
inner_secret: ... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": true,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 14463,
"total_crates": null
} |
fn_clm_masking_default_-2729277852852699987 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strong_secret
// Implementation of StrongSecret<Secret, MaskingStrategy> for Default
fn default() -> Self {
Secret::default().into()
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 7707,
"total_crates": null
} |
fn_clm_masking_from_-2729277852852699987 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strong_secret
// Implementation of StrongSecret<Secret, MaskingStrategy> for From<Secret>
fn from(secret: Secret) -> Self {
Self::new(secret)
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 2602,
"total_crates": null
} |
fn_clm_masking_eq_-2729277852852699987 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/strong_secret
// Implementation of StrongSecret<Secret, MaskingStrategy> for PartialEq
fn eq(&self, other: &Self) -> bool {
StrongEq::strong_eq(self.peek(), other.peek())
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 1664,
"total_crates": null
} |
fn_clm_masking_clone_3894462210123451612 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/serde
// Implementation of PIISerializer for Clone
fn clone(&self) -> Self {
Self {
inner: JsonValueSerializer,
}
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 27323,
"total_crates": null
} |
fn_clm_masking_deserialize_3894462210123451612 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/serde
// Implementation of StrongSecret<T, I> for Deserialize<'de>
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>
where
D: serde::Deserializer<'de>,
{
T::deserial... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 138,
"total_crates": null
} |
fn_clm_masking_serialize_3894462210123451612 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/serde
// Implementation of None for Serialize
fn serialize<S>(&self, serializer: S) -> Result<S::Ok, S::Error>
where
S: Serializer,
{
erased_serde::serialize(self, serializer)
... | {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 85,
"total_crates": null
} |
fn_clm_masking_masked_serialize_3894462210123451612 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/serde
// Implementation of T for ErasedMaskSerialize
fn masked_serialize(&self) -> Result<Value, serde_json::Error> {
masked_serialize(self)
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 79,
"total_crates": null
} |
fn_clm_masking_serialize_str_3894462210123451612 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/serde
// Implementation of PIISerializer for Serializer
fn serialize_str(self, value: &str) -> Result<Self::Ok, Self::Error> {
Ok(Value::String(value.to_owned()))
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 30,
"total_crates": null
} |
fn_clm_masking_from_-1768448059029681441 | clm | function | // Repository: hyperswitch
// Crate: masking
// Purpose: PII protection and data masking
// Module: crates/masking/src/maskable
// Implementation of Maskable<String> for From<&str>
fn from(value: &str) -> Self {
Self::new_normal(value.to_string())
}
| {
"crate": "masking",
"file": null,
"file_size": null,
"is_async": false,
"is_pub": false,
"num_enums": null,
"num_structs": null,
"num_tables": null,
"score": 2604,
"total_crates": null
} |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.