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

Improve code generated documentation #2019

Merged
merged 8 commits into from
Nov 22, 2022
Merged
Changes from 2 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
Expand Up @@ -198,6 +198,9 @@ class ServerServiceGeneratorV2(
/// Constructs a [`$serviceName`] from the arguments provided to the builder.
///
/// Forgetting to register a handler for one or more operations will result in an error.
///
/// Check out [`$builderName::build_unchecked`] if you'd prefer the service to return status code 500 when an
/// unspecified route requested.
pub fn build(self) -> Result<$serviceName<#{SmithyHttpServer}::routing::Route<$builderBodyGenericTypeName>>, MissingOperationsError>
{
let router = {
Expand Down Expand Up @@ -434,6 +437,8 @@ class ServerServiceGeneratorV2(
private fun missingOperationsError(): Writable = writable {
rust(
"""
/// The error encountered when calling the [`$builderName::build`] method while one or more operations are not
hlbarber marked this conversation as resolved.
Show resolved Hide resolved
/// specified.
##[derive(Debug)]
pub struct MissingOperationsError {
operation_names2setter_methods: std::collections::HashMap<&'static str, &'static str>,
Expand Down