Skip to content

Commit

Permalink
✨ Add EmailAddressAsStringSerializer type (#691)
Browse files Browse the repository at this point in the history
  • Loading branch information
LVMVRQUXL committed Aug 27, 2024
1 parent d186481 commit b02097e
Show file tree
Hide file tree
Showing 3 changed files with 42 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
public final class org/kotools/types/kotlinx/serialization/EmailAddressAsStringSerializer {
public fun <init> ()V
}

public final class org/kotools/types/kotlinx/serialization/KotoolsTypesSerializers {
public static final field INSTANCE Lorg/kotools/types/kotlinx/serialization/KotoolsTypesSerializers;
public final fun getAll ()Lkotlinx/serialization/modules/SerializersModule;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
package org.kotools.types.kotlinx.serialization

import kotools.types.experimental.ExperimentalKotoolsTypesApi
import org.kotools.types.EmailAddress
import org.kotools.types.internal.ExperimentalSince
import org.kotools.types.internal.KotoolsTypesVersion

/**
* Class responsible for serializing the [EmailAddress] type as [String].
*
* @constructor Creates an instance of [EmailAddressAsStringSerializer].
*
* <br>
* <details>
* <summary>
* <b>Calling from Kotlin</b>
* </summary>
*
* Here's an example of calling this constructor from Kotlin code:
*
* SAMPLE: [org.kotools.types.kotlinx.serialization.EmailAddressAsStringSerializerCommonSample.primaryConstructor]
* </details>
*/
@ExperimentalKotoolsTypesApi
@ExperimentalSince(KotoolsTypesVersion.Unreleased)
public class EmailAddressAsStringSerializer
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
package org.kotools.types.kotlinx.serialization

import kotools.types.experimental.ExperimentalKotoolsTypesApi
import kotlin.test.Test

@OptIn(ExperimentalKotoolsTypesApi::class)
internal class EmailAddressAsStringSerializerCommonSample {
@Test
fun primaryConstructor() {
EmailAddressAsStringSerializer()
}
}

0 comments on commit b02097e

Please sign in to comment.