Sha256: aa40baaec18178243545463991668e87ae3b30d0072980b9ddb44552d2237987
Contents?: true
Size: 601 Bytes
Versions: 14
Compression:
Stored size: 601 Bytes
Contents
module MeducationSDK module Helpers SDK_TO_SPI_MAPPINGS = {} def sdk_class_for(spi_type) sdk_type_for(spi_type).constantize end def sdk_type_for(spi_type) if SDK_TO_SPI_MAPPINGS.has_value?(spi_type) SDK_TO_SPI_MAPPINGS.key(spi_type) else "MeducationSDK::#{spi_type.gsub("::", "")}" end end def spi_type_for(sdk_type) sdk_type = sdk_type.gsub(/Mock$/, "") if SDK_TO_SPI_MAPPINGS.has_key?(sdk_type) SDK_TO_SPI_MAPPINGS[sdk_type] else sdk_type.gsub("MeducationSDK::", "") end end end end
Version data entries
14 entries across 14 versions & 1 rubygems