Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: reformat typed link template file #289

Merged
merged 1 commit into from
Feb 19, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,42 +1,45 @@
{{#operations}}{{#operation}}{{#isLinkable}}
package com.expediagroup.sdk.{{namespace}}.operations
{{#operations}}
{{#operation}}
{{#isLinkable}}
package com.expediagroup.sdk.{{namespace}}.operations

import com.expediagroup.sdk.{{namespace}}.models.Link
import com.fasterxml.jackson.annotation.JsonProperty
import javax.validation.Valid
import com.expediagroup.sdk.{{namespace}}.models.Link
import com.fasterxml.jackson.annotation.JsonProperty
import javax.validation.Valid

data class {{classname}}Link(
// The request method used to access the link.
@JsonProperty("method")
@field:Valid
override val method: kotlin.String? = null,
// The URL for the link. This can be absolute or relative.
@JsonProperty("href")
@field:Valid
override val href: kotlin.String? = null,
// If the link expires, this will be the UTC date the link will expire, in ISO 8601 format.
@JsonProperty("expires")
@field:Valid
override val expires: kotlin.String? = null
) : Link(method, href, expires) {
companion object {
@JvmStatic
fun builder() = Builder()
}
data class {{classname}}Link(
// The request method used to access the link.
@JsonProperty("method")
@field:Valid
override val method: kotlin.String? = null,
// The URL for the link. This can be absolute or relative.
@JsonProperty("href")
@field:Valid
override val href: kotlin.String? = null,
// If the link expires, this will be the UTC date the link will expire, in ISO 8601 format.
@JsonProperty("expires")
@field:Valid
override val expires: kotlin.String? = null
) : Link(method, href, expires) {
companion object {
@JvmStatic
fun builder() = Builder()
}

class Builder(
private var method: kotlin.String? = null,
private var href: kotlin.String? = null,
private var expires: kotlin.String? = null
) {
fun build(): {{classname}}Link {
return {{classname}}Link(
method = method,
href = href,
expires = expires
)
class Builder(
private var method: kotlin.String? = null,
private var href: kotlin.String? = null,
private var expires: kotlin.String? = null
) {
fun build(): {{classname}}Link {
return {{classname}}Link(
method = method,
href = href,
expires = expires
)
}
}
}
}
}

{{/isLinkable}}{{/operation}}{{/operations}}
{{/isLinkable}}
{{/operation}}
{{/operations}}