739 739 | pub(crate) crate_: ::std::option::Option<bool>,
|
740 740 | pub(crate) super_: ::std::option::Option<bool>,
|
741 741 | pub(crate) build_value: ::std::option::Option<::std::string::String>,
|
742 742 | pub(crate) default_value: ::std::option::Option<::std::string::String>,
|
743 743 | pub(crate) send: ::std::option::Option<::std::string::String>,
|
744 744 | }
|
745 745 | impl Builder {
|
746 746 | #[allow(missing_docs)] // documentation missing in model
|
747 747 | pub(crate) fn set_as(mut self, input: Option<impl ::std::convert::Into<i32>>) -> Self {
|
748 748 | self.r#as = input.map(|v| v.into());
|
749 749 | self
|
750 750 | }
|
751 751 | #[allow(missing_docs)] // documentation missing in model
|
752 752 | pub(crate) fn set_async(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
753 753 | self.r#async = input.map(|v| v.into());
|
754 754 | self
|
755 755 | }
|
756 756 | #[allow(missing_docs)] // documentation missing in model
|
757 757 | pub(crate) fn set_enum(
|
758 758 | mut self,
|
759 759 | input: Option<
|
760 760 | impl ::std::convert::Into<
|
761 761 | crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
|
762 762 | >,
|
763 763 | >,
|
764 764 | ) -> Self {
|
765 765 | self.r#enum = input.map(|v| v.into());
|
766 766 | self
|
767 767 | }
|
768 768 | #[allow(missing_docs)] // documentation missing in model
|
769 - | pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
769 + | pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
770 770 | self.self_ = input.map(|v| v.into());
|
771 771 | self
|
772 772 | }
|
773 773 | #[allow(missing_docs)] // documentation missing in model
|
774 - | pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
774 + | pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
775 775 | self.crate_ = input.map(|v| v.into());
|
776 776 | self
|
777 777 | }
|
778 778 | #[allow(missing_docs)] // documentation missing in model
|
779 - | pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
779 + | pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
780 780 | self.super_ = input.map(|v| v.into());
|
781 781 | self
|
782 782 | }
|
783 783 | #[allow(missing_docs)] // documentation missing in model
|
784 - | pub(crate) fn set_build(
|
784 + | pub(crate) fn set_build_value(
|
785 785 | mut self,
|
786 786 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
787 787 | ) -> Self {
|
788 788 | self.build_value = input.map(|v| v.into());
|
789 789 | self
|
790 790 | }
|
791 791 | #[allow(missing_docs)] // documentation missing in model
|
792 - | pub(crate) fn set_default(
|
792 + | pub(crate) fn set_default_value(
|
793 793 | mut self,
|
794 794 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
795 795 | ) -> Self {
|
796 796 | self.default_value = input.map(|v| v.into());
|
797 797 | self
|
798 798 | }
|
799 799 | #[allow(missing_docs)] // documentation missing in model
|
800 800 | pub(crate) fn set_send(
|
801 801 | mut self,
|
802 802 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
803 803 | ) -> Self {
|
804 804 | self.send = input.map(|v| v.into());
|
805 805 | self
|
806 806 | }
|
807 807 | /// Consumes the builder and constructs a [`RpcEchoInput`](crate::input::RpcEchoInput).
|
808 808 | ///
|
809 809 | /// The builder fails to construct a [`RpcEchoInput`](crate::input::RpcEchoInput) if a [`ConstraintViolation`] occurs.
|
810 810 | ///
|
811 811 | pub fn build(self) -> Result<crate::input::RpcEchoInput, ConstraintViolation> {
|
812 812 | self.build_enforcing_all_constraints()
|
813 813 | }
|
814 814 | fn build_enforcing_all_constraints(
|
815 815 | self,
|
816 816 | ) -> Result<crate::input::RpcEchoInput, ConstraintViolation> {
|
817 817 | Ok(crate::input::RpcEchoInput {
|
818 818 | r#as: self.r#as,
|
819 819 | r#async: self.r#async,
|
820 820 | r#enum: self
|
821 821 | .r#enum
|
822 822 | .map(|v| match v {
|
1004 1004 | pub(crate) crate_: ::std::option::Option<bool>,
|
1005 1005 | pub(crate) super_: ::std::option::Option<bool>,
|
1006 1006 | pub(crate) build_value: ::std::option::Option<::std::string::String>,
|
1007 1007 | pub(crate) default_value: ::std::option::Option<::std::string::String>,
|
1008 1008 | pub(crate) send: ::std::option::Option<::std::string::String>,
|
1009 1009 | }
|
1010 1010 | impl Builder {
|
1011 1011 | #[allow(missing_docs)] // documentation missing in model
|
1012 1012 | pub(crate) fn set_as(mut self, input: Option<impl ::std::convert::Into<i32>>) -> Self {
|
1013 1013 | self.r#as = input.map(|v| v.into());
|
1014 1014 | self
|
1015 1015 | }
|
1016 1016 | #[allow(missing_docs)] // documentation missing in model
|
1017 1017 | pub(crate) fn set_async(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1018 1018 | self.r#async = input.map(|v| v.into());
|
1019 1019 | self
|
1020 1020 | }
|
1021 1021 | #[allow(missing_docs)] // documentation missing in model
|
1022 1022 | pub(crate) fn set_enum(
|
1023 1023 | mut self,
|
1024 1024 | input: Option<
|
1025 1025 | impl ::std::convert::Into<
|
1026 1026 | crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
|
1027 1027 | >,
|
1028 1028 | >,
|
1029 1029 | ) -> Self {
|
1030 1030 | self.r#enum = input.map(|v| v.into());
|
1031 1031 | self
|
1032 1032 | }
|
1033 1033 | #[allow(missing_docs)] // documentation missing in model
|
1034 - | pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1034 + | pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1035 1035 | self.self_ = input.map(|v| v.into());
|
1036 1036 | self
|
1037 1037 | }
|
1038 1038 | #[allow(missing_docs)] // documentation missing in model
|
1039 - | pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1039 + | pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1040 1040 | self.crate_ = input.map(|v| v.into());
|
1041 1041 | self
|
1042 1042 | }
|
1043 1043 | #[allow(missing_docs)] // documentation missing in model
|
1044 - | pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1044 + | pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1045 1045 | self.super_ = input.map(|v| v.into());
|
1046 1046 | self
|
1047 1047 | }
|
1048 1048 | #[allow(missing_docs)] // documentation missing in model
|
1049 - | pub(crate) fn set_build(
|
1049 + | pub(crate) fn set_build_value(
|
1050 1050 | mut self,
|
1051 1051 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1052 1052 | ) -> Self {
|
1053 1053 | self.build_value = input.map(|v| v.into());
|
1054 1054 | self
|
1055 1055 | }
|
1056 1056 | #[allow(missing_docs)] // documentation missing in model
|
1057 - | pub(crate) fn set_default(
|
1057 + | pub(crate) fn set_default_value(
|
1058 1058 | mut self,
|
1059 1059 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1060 1060 | ) -> Self {
|
1061 1061 | self.default_value = input.map(|v| v.into());
|
1062 1062 | self
|
1063 1063 | }
|
1064 1064 | #[allow(missing_docs)] // documentation missing in model
|
1065 1065 | pub(crate) fn set_send(
|
1066 1066 | mut self,
|
1067 1067 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1068 1068 | ) -> Self {
|
1069 1069 | self.send = input.map(|v| v.into());
|
1070 1070 | self
|
1071 1071 | }
|
1072 1072 | /// Consumes the builder and constructs a [`MatchInput`](crate::input::MatchInput).
|
1073 1073 | ///
|
1074 1074 | /// The builder fails to construct a [`MatchInput`](crate::input::MatchInput) if a [`ConstraintViolation`] occurs.
|
1075 1075 | ///
|
1076 1076 | pub fn build(self) -> Result<crate::input::MatchInput, ConstraintViolation> {
|
1077 1077 | self.build_enforcing_all_constraints()
|
1078 1078 | }
|
1079 1079 | fn build_enforcing_all_constraints(
|
1080 1080 | self,
|
1081 1081 | ) -> Result<crate::input::MatchInput, ConstraintViolation> {
|
1082 1082 | Ok(crate::input::MatchInput {
|
1083 1083 | r#as: self.r#as,
|
1084 1084 | r#async: self.r#async,
|
1085 1085 | r#enum: self
|
1086 1086 | .r#enum
|
1087 1087 | .map(|v| match v {
|
1522 1522 | pub(crate) crate_: ::std::option::Option<bool>,
|
1523 1523 | pub(crate) super_: ::std::option::Option<bool>,
|
1524 1524 | pub(crate) build_value: ::std::option::Option<::std::string::String>,
|
1525 1525 | pub(crate) default_value: ::std::option::Option<::std::string::String>,
|
1526 1526 | pub(crate) send: ::std::option::Option<::std::string::String>,
|
1527 1527 | }
|
1528 1528 | impl Builder {
|
1529 1529 | #[allow(missing_docs)] // documentation missing in model
|
1530 1530 | pub(crate) fn set_as(mut self, input: Option<impl ::std::convert::Into<i32>>) -> Self {
|
1531 1531 | self.r#as = input.map(|v| v.into());
|
1532 1532 | self
|
1533 1533 | }
|
1534 1534 | #[allow(missing_docs)] // documentation missing in model
|
1535 1535 | pub(crate) fn set_async(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1536 1536 | self.r#async = input.map(|v| v.into());
|
1537 1537 | self
|
1538 1538 | }
|
1539 1539 | #[allow(missing_docs)] // documentation missing in model
|
1540 1540 | pub(crate) fn set_enum(
|
1541 1541 | mut self,
|
1542 1542 | input: Option<
|
1543 1543 | impl ::std::convert::Into<
|
1544 1544 | crate::constrained::MaybeConstrained<crate::model::UnknownVariantCollidingEnum>,
|
1545 1545 | >,
|
1546 1546 | >,
|
1547 1547 | ) -> Self {
|
1548 1548 | self.r#enum = input.map(|v| v.into());
|
1549 1549 | self
|
1550 1550 | }
|
1551 1551 | #[allow(missing_docs)] // documentation missing in model
|
1552 - | pub(crate) fn set_self(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1552 + | pub(crate) fn set_self_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1553 1553 | self.self_ = input.map(|v| v.into());
|
1554 1554 | self
|
1555 1555 | }
|
1556 1556 | #[allow(missing_docs)] // documentation missing in model
|
1557 - | pub(crate) fn set_crate(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1557 + | pub(crate) fn set_crate_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1558 1558 | self.crate_ = input.map(|v| v.into());
|
1559 1559 | self
|
1560 1560 | }
|
1561 1561 | #[allow(missing_docs)] // documentation missing in model
|
1562 - | pub(crate) fn set_super(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1562 + | pub(crate) fn set_super_(mut self, input: Option<impl ::std::convert::Into<bool>>) -> Self {
|
1563 1563 | self.super_ = input.map(|v| v.into());
|
1564 1564 | self
|
1565 1565 | }
|
1566 1566 | #[allow(missing_docs)] // documentation missing in model
|
1567 - | pub(crate) fn set_build(
|
1567 + | pub(crate) fn set_build_value(
|
1568 1568 | mut self,
|
1569 1569 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1570 1570 | ) -> Self {
|
1571 1571 | self.build_value = input.map(|v| v.into());
|
1572 1572 | self
|
1573 1573 | }
|
1574 1574 | #[allow(missing_docs)] // documentation missing in model
|
1575 - | pub(crate) fn set_default(
|
1575 + | pub(crate) fn set_default_value(
|
1576 1576 | mut self,
|
1577 1577 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1578 1578 | ) -> Self {
|
1579 1579 | self.default_value = input.map(|v| v.into());
|
1580 1580 | self
|
1581 1581 | }
|
1582 1582 | #[allow(missing_docs)] // documentation missing in model
|
1583 1583 | pub(crate) fn set_send(
|
1584 1584 | mut self,
|
1585 1585 | input: Option<impl ::std::convert::Into<::std::string::String>>,
|
1586 1586 | ) -> Self {
|
1587 1587 | self.send = input.map(|v| v.into());
|
1588 1588 | self
|
1589 1589 | }
|
1590 1590 | /// Consumes the builder and constructs a [`ReservedWordsAsMembersInput`](crate::input::ReservedWordsAsMembersInput).
|
1591 1591 | ///
|
1592 1592 | /// The builder fails to construct a [`ReservedWordsAsMembersInput`](crate::input::ReservedWordsAsMembersInput) if a [`ConstraintViolation`] occurs.
|
1593 1593 | ///
|
1594 1594 | pub fn build(
|
1595 1595 | self,
|
1596 1596 | ) -> Result<crate::input::ReservedWordsAsMembersInput, ConstraintViolation> {
|
1597 1597 | self.build_enforcing_all_constraints()
|
1598 1598 | }
|
1599 1599 | fn build_enforcing_all_constraints(
|
1600 1600 | self,
|
1601 1601 | ) -> Result<crate::input::ReservedWordsAsMembersInput, ConstraintViolation> {
|
1602 1602 | Ok(crate::input::ReservedWordsAsMembersInput {
|
1603 1603 | r#as: self.r#as,
|
1604 1604 | r#async: self.r#async,
|
1605 1605 | r#enum: self
|