1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129 6130 6131 6132 6133 6134 6135 6136 6137 6138 6139 6140 6141 6142 6143 6144 6145 6146 6147 6148 6149 6150 6151 6152 6153 6154 6155 6156 6157 6158 6159 6160 6161 6162 6163 6164 6165 6166 6167 6168 6169 6170 6171 6172 6173 6174 6175 6176 6177 6178 6179 6180 6181 6182 6183 6184 6185 6186 6187 6188 6189 6190 6191 6192 6193 6194 6195 6196 6197 6198 6199 6200 6201 6202 6203 6204 6205 6206 6207 6208 6209 6210 6211 6212 6213 6214 6215 6216 6217 6218 6219 6220 6221 6222 6223 6224 6225 6226 6227 6228 6229 6230 6231 6232 6233 6234 6235 6236 6237 6238 6239 6240 6241 6242 6243 6244 6245 6246 6247 6248 6249 6250 6251 6252 6253 6254 6255 6256 6257 6258 6259 6260 6261 6262 6263 6264 6265 6266 6267 6268 6269 6270 6271 6272 6273 6274 6275 6276 6277 6278 6279 6280 6281 6282 6283 6284 6285 6286 6287 6288 6289 6290 6291 6292 6293 6294 6295 6296 6297 6298 6299 6300 6301 6302 6303 6304 6305 6306 6307 6308 6309 6310 6311 6312 6313 6314 6315 6316 6317 6318 6319 6320 6321 6322 6323 6324 6325 6326 6327 6328 6329 6330 6331 6332 6333 6334 6335 6336 6337 6338 6339 6340 6341 6342 6343 6344 6345 6346 6347 6348 6349 6350 6351 6352 6353 6354 6355 6356 6357 6358 6359 6360 6361 6362 6363 6364 6365 6366 6367 6368 6369 6370 6371 6372 6373 6374 6375 6376 6377 6378 6379 6380 6381 6382 6383 6384 6385 6386 6387 6388 6389 6390 6391 6392 6393 6394 6395 6396 6397 6398 6399 6400 6401 6402 6403 6404 6405 6406 6407 6408 6409 6410 6411 6412 6413 6414 6415 6416 6417 6418 6419 6420 6421 6422 6423 6424 6425 6426 6427 6428 6429 6430 6431 6432 6433 6434 6435 6436 6437 6438 6439 6440 6441 6442 6443 6444 6445 6446 6447 6448 6449 6450 6451 6452 6453 6454 6455 6456 6457 6458 6459 6460 6461 6462 6463 6464 6465 6466 6467 6468 6469 6470 6471 6472 6473 6474 6475 6476 6477 6478 6479 6480 6481 6482 6483 6484 6485 6486 6487 6488 6489 6490 6491 6492 6493 6494 6495 6496 6497 6498 6499 6500 6501 6502 6503 6504 6505 6506 6507 6508 6509 6510 6511 6512 6513 6514 6515 6516 6517 6518 6519 6520 6521 6522 6523 6524 6525 6526 6527 6528 6529 6530 6531 6532 6533 6534 6535 6536 6537 6538 6539 6540 6541 6542 6543 6544 6545 6546 6547 6548 6549 6550 6551 6552 6553 6554 6555 6556 6557 6558 6559 6560 6561 6562 6563 6564 6565 6566 6567 6568 6569 6570 6571 6572 6573 6574 6575 6576 6577 6578 6579 6580 6581 6582 6583 6584 6585 6586 6587 6588 6589 6590 6591 6592 6593 6594 6595 6596 6597 6598 6599 6600 6601 6602 6603 6604 6605 6606 6607 6608 6609 6610 6611 6612 6613 6614 6615 6616 6617 6618 6619 6620 6621 6622 6623 6624 6625 6626 6627 6628 6629 6630 6631 6632 6633 6634 6635 6636 6637 6638 6639 6640 6641 6642 6643 6644 6645 6646 6647 6648 6649 6650 6651 6652 6653 6654 6655 6656 6657 6658 6659 6660 6661 6662 6663 6664 6665 6666 6667 6668 6669 6670 6671 6672 6673 6674 6675 6676 6677 6678 6679 6680 6681 6682 6683 6684 6685 6686 6687 6688 6689 6690 6691 6692 6693 6694 6695 6696 6697 6698 6699 6700 6701 6702 6703 6704 6705 6706 6707 6708 6709 6710 6711 6712 6713 6714 6715 6716 6717 6718 6719 6720 6721 6722 6723 6724 6725 6726 6727 6728 6729 6730 6731 6732 6733 6734 6735 6736 6737 6738 6739 6740 6741 6742 6743 6744 6745 6746 6747 6748 6749 6750 6751 6752 6753 6754 6755 6756 6757 6758 6759 6760 6761 6762 6763 6764 6765 6766 6767 6768 6769 6770 6771 6772 6773 6774 6775 6776 6777 6778 6779 6780 6781 6782 6783 6784 6785 6786 6787 6788 6789 6790 6791 6792 6793 6794 6795 6796 6797 6798 6799 6800 6801 6802 6803 6804 6805 6806 6807 6808 6809 6810 6811 6812 6813 6814 6815 6816 6817 6818 6819 6820 6821 6822 6823 6824 6825 6826 6827 6828 6829 6830 6831 6832 6833 6834 6835 6836 6837 6838 6839 6840 6841 6842 6843 6844 6845 6846 6847 6848 6849 6850 6851 6852 6853 6854 6855 6856 6857 6858 6859 6860 6861 6862 6863 6864 6865 6866 6867 6868 6869 6870 6871 6872 6873 6874 6875 6876 6877 6878 6879 6880 6881 6882 6883 6884 6885 6886 6887 6888 6889 6890 6891 6892 6893 6894 6895 6896 6897 6898 6899 6900 6901 6902 6903 6904 6905 6906 6907 6908 6909 6910 6911 6912 6913 6914 6915 6916 6917 6918 6919 6920 6921 6922 6923 6924 6925 6926 6927 6928 6929 6930 6931 6932 6933 6934 6935 6936 6937 6938 6939 6940 6941 6942 6943 6944 6945 6946 6947 6948 6949 6950 6951 6952 6953 6954 6955 6956 6957 6958 6959 6960 6961 6962 6963 6964 6965 6966 6967 6968 6969 6970 6971 6972 6973 6974 6975 6976 6977 6978 6979 6980 6981 6982 6983 6984 6985 6986 6987 6988 6989 6990 6991 6992 6993 6994 6995 6996 6997 6998 6999 7000 7001 7002 7003 7004 7005 7006 7007 7008 7009 7010 7011 7012 7013 7014 7015 7016 7017 7018 7019 7020 7021 7022 7023 7024 7025 7026 7027 7028 7029 7030 7031 7032 7033 7034 7035 7036 7037 7038 7039 7040 7041 7042 7043 7044 7045 7046 7047 7048 7049 7050 7051 7052 7053 7054 7055 7056 7057 7058 7059 7060 7061 7062 7063 7064 7065 7066 7067 7068 7069 7070 7071 7072 7073 7074 7075 7076 7077 7078 7079 7080 7081 7082 7083 7084 7085 7086 7087 7088 7089 7090 7091 7092 7093 7094 7095 7096 7097 7098 7099 7100 7101 7102 7103 7104 7105 7106 7107 7108 7109 7110 7111 7112 7113 7114 7115 7116 7117 7118 7119 7120 7121 7122 7123 7124 7125 7126 7127 7128 7129 7130 7131 7132 7133 7134 7135 7136 7137 7138 7139 7140 7141 7142 7143 7144 7145 7146 7147 7148 7149 7150 7151 7152 7153 7154 7155 7156 7157 7158 7159 7160 7161 7162 7163 7164 7165 7166 7167 7168 7169 7170 7171 7172 7173 7174 7175 7176 7177 7178 7179 7180 7181 7182 7183 7184 7185 7186 7187 7188 7189 7190 7191 7192 7193 7194 7195 7196 7197 7198 7199 7200 7201 7202 7203 7204 7205 7206 7207 7208 7209 7210 7211 7212 7213 7214 7215 7216 7217 7218 7219 7220 7221 7222 7223 7224 7225 7226 7227 7228 7229 7230 7231 7232 7233 7234 7235 7236 7237 7238 7239 7240 7241 7242 7243 7244 7245 7246 7247 7248 7249 7250 7251 7252 7253 7254 7255 7256 7257 7258 7259 7260 7261 7262 7263 7264 7265 7266 7267 7268 7269 7270 7271 7272 7273 7274 7275 7276 7277 7278 7279 7280 7281 7282 7283 7284 7285 7286 7287 7288 7289 7290 7291 7292 7293 7294 7295 7296 7297 7298 7299 7300 7301 7302 7303 7304 7305 7306 7307 7308 7309 7310 7311 7312 7313 7314 7315 7316 7317 7318 7319 7320 7321 7322 7323 7324 7325 7326 7327 7328 7329 7330 7331 7332 7333 7334 7335 7336 7337 7338 7339 7340 7341 7342 7343 7344 7345 7346 7347 7348 7349 7350 7351 7352 7353 7354 7355 7356 7357 7358 7359 7360 7361 7362 7363 7364 7365 7366 7367 7368 7369 7370 7371 7372 7373 7374 7375 7376 7377 7378 7379 7380 7381 7382 7383 7384 7385 7386 7387 7388 7389 7390 7391 7392 7393 7394 7395 7396 7397 7398 7399 7400 7401 7402 7403 7404 7405 7406 7407 7408 7409 7410 7411 7412 7413 7414 7415 7416 7417 7418 7419 7420 7421 7422 7423 7424 7425 7426 7427 7428 7429 7430 7431 7432 7433 7434 7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 7446 7447 7448 7449 7450 7451 7452 7453 7454 7455 7456 7457 7458 7459 7460 7461 7462 7463 7464 7465 7466 7467 7468 7469 7470 7471 7472 7473 7474 7475 7476 7477 7478 7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 7490 7491 7492 7493 7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 7505 7506 7507 7508 7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 7520 7521 7522 7523 7524 7525 7526 7527 7528 7529 7530 7531 7532 7533 7534 7535 7536 7537 7538 7539 7540 7541 7542 7543 7544 7545 7546 7547 7548 7549 7550 7551 7552 7553 7554 7555 7556 7557 7558 7559 7560 7561 7562 7563 7564 7565 7566 7567 7568 7569 7570 7571 7572 7573 7574 7575 7576 7577 7578 7579 7580 7581 7582 7583 7584 7585 7586 7587 7588 7589 7590 7591 7592 7593 7594 7595 7596 7597 7598 7599 7600 7601 7602 7603 7604 7605 7606 7607 7608 7609 7610 7611 7612 7613 7614 7615 7616 7617 7618 7619 7620 7621 7622 7623 7624 7625 7626 7627 7628 7629 7630 7631 7632 7633 7634 7635 7636 7637 7638 7639 7640 7641 7642 7643 7644 7645 7646 7647 7648 7649 7650 7651 7652 7653 7654 7655 7656 7657 7658 7659 7660 7661 7662 7663 7664 7665 7666 7667 7668 7669 7670 7671 7672 7673 7674 7675 7676 7677 7678 7679 7680 7681 7682 7683 7684 7685 7686 7687 7688 7689 7690 7691 7692 7693 7694 7695 7696 7697 7698 7699 7700 7701 7702 7703 7704 7705 7706 7707 7708 7709 7710 7711 7712 7713 7714 7715 7716 7717 7718 7719 7720 7721 7722 7723 7724 7725 7726 7727 7728 7729 7730 7731 7732 7733 7734 7735 7736 7737 7738 7739 7740 7741 7742 7743 7744 7745 7746 7747 7748 7749 7750 7751 7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774 7775 7776 7777 7778 7779 7780 7781 7782 7783 7784 7785 7786 7787 7788 7789 7790 7791 7792 7793 7794 7795 7796 7797 7798 7799 7800 7801 7802 7803 7804 7805 7806 7807 7808 7809 7810 7811 7812 7813 7814 7815 7816 7817 7818 7819 7820 7821 7822 7823 7824 7825 7826 7827 7828 7829 7830 7831 7832 7833 7834 7835 7836 7837 7838 7839 7840 7841 7842 7843 7844 7845 7846 7847 7848 7849 7850 7851 7852 7853 7854 7855 7856 7857 7858 7859 7860 7861 7862 7863 7864 7865 7866 7867 7868 7869 7870 7871 7872 7873 7874 7875 7876 7877 7878 7879 7880 7881 7882 7883 7884 7885 7886 7887 7888 7889 7890 7891 7892 7893 7894 7895 7896 7897 7898 7899 7900 7901 7902 7903 7904 7905 7906 7907 7908 7909 7910 7911 7912 7913 7914 7915 7916 7917 7918 7919 7920 7921 7922 7923 7924 7925 7926 7927 7928 7929 7930 7931 7932 7933 7934 7935 7936 7937 7938 7939 7940 7941 7942 7943 7944 7945 7946 7947 7948 7949 7950 7951 7952 7953 7954 7955 7956 7957 7958 7959 7960 7961 7962 7963 7964 7965 7966 7967 7968 7969 7970 7971 7972 7973 7974 7975 7976 7977 7978 7979 7980 7981 7982 7983 7984 7985 7986 7987 7988 7989 7990 7991 7992 7993 7994 7995 7996 7997 7998 7999 8000 8001 8002 8003 8004 8005 8006 8007 8008 8009 8010 8011 8012 8013 8014 8015 8016 8017 8018 8019 8020 8021 8022 8023 8024 8025 8026 8027 8028 8029 8030 8031 8032 8033 8034 8035 8036 8037 8038 8039 8040 8041 8042 8043 8044 8045 8046 8047 8048 8049 8050 8051 8052 8053 8054 8055 8056 8057 8058 8059 8060 8061 8062 8063 8064 8065 8066 8067 8068 8069 8070 8071 8072 8073 8074 8075 8076 8077 8078 8079 8080 8081 8082 8083 8084 8085 8086 8087 8088 8089 8090 8091 8092 8093 8094 8095 8096 8097 8098 8099 8100 8101 8102 8103 8104 8105 8106 8107 8108 8109 8110 8111 8112 8113 8114 8115 8116 8117 8118 8119 8120 8121 8122 8123 8124 8125 8126 8127 8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 8139 8140 8141 8142 8143 8144 8145 8146 8147 8148 8149 8150 8151 8152 8153 8154 8155 8156 8157 8158 8159 8160 8161 8162 8163 8164 8165 8166 8167 8168 8169 8170 8171 8172 8173 8174 8175 8176 8177 8178 8179 8180 8181 8182 8183 8184 8185 8186 8187 8188 8189 8190 8191 8192 8193 8194 8195 8196 8197 8198 8199 8200 8201 8202 8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266 8267 8268 8269 8270 8271 8272 8273 8274 8275 8276 8277 8278 8279 8280 8281 8282 8283 8284 8285 8286 8287 8288 8289 8290 8291 8292 8293 8294 8295 8296 8297 8298 8299 8300 8301 8302 8303 8304 8305 8306 8307 8308 8309 8310 8311 8312 8313 8314 8315 8316 8317 8318 8319 8320 8321 8322 8323 8324 8325 8326 8327 8328 8329 8330 8331 8332 8333 8334 8335 8336 8337 8338 8339 8340 8341 8342 8343 8344 8345 8346 8347 8348 8349 8350 8351 8352 8353 8354 8355 8356 8357 8358 8359 8360 8361 8362 8363 8364 8365 8366 8367 8368 8369 8370 8371 8372 8373 8374 8375 8376 8377 8378 8379 8380 8381 8382 8383 8384 8385 8386 8387 8388 8389 8390 8391 8392 8393 8394 8395 8396 8397 8398 8399 8400 8401 8402 8403 8404 8405 8406 8407 8408 8409 8410 8411 8412 8413 8414 8415 8416 8417 8418 8419 8420 8421 8422 8423 8424 8425 8426 8427 8428 8429 8430 8431 8432 8433 8434 8435 8436 8437 8438 8439 8440 8441 8442 8443 8444 8445 8446 8447 8448 8449 8450 8451 8452 8453 8454 8455 8456 8457 8458 8459 8460 8461 8462 8463 8464 8465 8466 8467 8468 8469 8470 8471 8472 8473 8474 8475 8476 8477 8478 8479 8480 8481 8482 8483 8484 8485 8486 8487 8488 8489 8490 8491 8492 8493 8494 8495 8496 8497 8498 8499 8500 8501 8502 8503 8504 8505 8506 8507 8508 8509 8510 8511 8512 8513 8514 8515 8516 8517 8518 8519 8520 8521 8522 8523 8524 8525 8526 8527 8528 8529 8530 8531 8532 8533 8534 8535 8536 8537 8538 8539 8540 8541 8542 8543 8544 8545 8546 8547 8548 8549 8550 8551 8552 8553 8554 8555 8556 8557 8558 8559 8560 8561 8562 8563 8564 8565 8566 8567 8568 8569 8570 8571 8572 8573 8574 8575 8576 8577 8578 8579 8580 8581 8582 8583 8584 8585 8586 8587 8588 8589 8590 8591 8592 8593 8594 8595 8596 8597 8598 8599 8600 8601 8602 8603 8604 8605 8606 8607 8608 8609 8610 8611 8612 8613 8614 8615 8616 8617 8618 8619 8620 8621 8622 8623 8624 8625 8626 8627 8628 8629 8630 8631 8632 8633 8634 8635 8636 8637 8638 8639 8640 8641 8642 8643 8644 8645 8646 8647 8648 8649 8650 8651 8652 8653 8654 8655 8656 8657 8658 8659 8660 8661 8662 8663 8664 8665 8666 8667 8668 8669 8670 8671 8672 8673 8674 8675 8676 8677 8678 8679 8680 8681 8682 8683 8684 8685 8686 8687 8688 8689 8690 8691 8692 8693 8694 8695 8696 8697 8698 8699 8700 8701 8702 8703 8704 8705 8706 8707 8708 8709 8710 8711 8712 8713 8714 8715 8716 8717 8718 8719 8720 8721 8722 8723 8724 8725 8726 8727 8728 8729 8730 8731 8732 8733 8734 8735 8736 8737 8738 8739 8740 8741 8742 8743 8744 8745 8746 8747 8748 8749 8750 8751 8752 8753 8754 8755 8756 8757 8758 8759 8760 8761 8762 8763 8764 8765 8766 8767 8768 8769 8770 8771 8772 8773 8774 8775 8776 8777 8778 8779 8780 8781 8782 8783 8784 8785 8786 8787 8788 8789 8790 8791 8792 8793 8794 8795 8796 8797 8798 8799 8800 8801 8802 8803 8804 8805 8806 8807 8808 8809 8810 8811 8812 8813 8814 8815 8816 8817 8818 8819 8820 8821 8822 8823 8824 8825 8826 8827 8828 8829 8830 8831 8832 8833 8834 8835 8836 8837 8838 8839 8840 8841 8842 8843 8844 8845 8846 8847 8848 8849 8850 8851 8852 8853 8854 8855 8856 8857 8858 8859 8860 8861 8862 8863 8864 8865 8866 8867 8868 8869 8870 8871 8872 8873 8874 8875 8876 8877 8878 8879 8880 8881 8882 8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934 8935 8936 8937 8938 8939 8940 8941 8942 8943 8944 8945 8946 8947 8948 8949 8950 8951 8952 8953 8954 8955 8956 8957 8958 8959 8960 8961 8962 8963 8964 8965 8966 8967 8968 8969 8970 8971 8972 8973 8974 8975 8976 8977 8978 8979 8980 8981 8982 8983 8984 8985 8986 8987 8988 8989 8990 8991 8992 8993 8994 8995 8996 8997 8998 8999 9000 9001 9002 9003 9004 9005 9006 9007 9008 9009 9010 9011 9012 9013 9014 9015 9016 9017 9018 9019 9020 9021 9022 9023 9024 9025 9026 9027 9028 9029 9030 9031 9032 9033 9034 9035 9036 9037 9038 9039 9040 9041 9042 9043 9044 9045 9046 9047 9048 9049 9050 9051 9052 9053 9054 9055 9056 9057 9058 9059 9060 9061 9062 9063 9064 9065 9066 9067 9068 9069 9070 9071 9072 9073 9074 9075 9076 9077 9078 9079 9080 9081 9082 9083 9084 9085 9086 9087 9088 9089 9090 9091 9092 9093 9094 9095 9096 9097 9098 9099 9100 9101 9102 9103 9104 9105 9106 9107 9108 9109 9110 9111 9112 9113 9114 9115 9116 9117 9118 9119 9120 9121 9122 9123 9124 9125 9126 9127 9128 9129 9130 9131 9132 9133 9134 9135 9136 9137 9138 9139 9140 9141 9142 9143 9144 9145 9146 9147 9148 9149 9150 9151 9152 9153 9154 9155 9156 9157 9158 9159 9160 9161 9162 9163 9164 9165 9166 9167 9168 9169 9170 9171 9172 9173 9174 9175 9176 9177 9178 9179 9180 9181 9182 9183 9184 9185 9186 9187 9188 9189 9190 9191 9192 9193 9194 9195 9196 9197 9198 9199 9200 9201 9202 9203 9204 9205 9206 9207 9208 9209 9210 9211 9212 9213 9214 9215 9216 9217 9218 9219 9220 9221 9222 9223 9224 9225 9226 9227 9228 9229 9230 9231 9232 9233 9234 9235 9236 9237 9238 9239 9240 9241 9242 9243 9244 9245 9246 9247 9248 9249 9250 9251 9252 9253 9254 9255 9256 9257 9258 9259 9260 9261 9262 9263 9264 9265 9266 9267 9268 9269 9270 9271 9272 9273 9274 9275 9276 9277 9278 9279 9280 9281 9282 9283 9284 9285 9286 9287 9288 9289 9290 9291 9292 9293 9294 9295 9296 9297 9298 9299 9300 9301 9302 9303 9304 9305 9306 9307 9308 9309 9310 9311 9312 9313 9314 9315 9316 9317 9318 9319 9320 9321 9322 9323 9324 9325 9326 9327 9328 9329 9330 9331 9332 9333 9334 9335 9336 9337 9338 9339 9340 9341 9342 9343 9344 9345 9346 9347 9348 9349 9350 9351 9352 9353 9354 9355 9356 9357 9358 9359 9360 9361 9362 9363 9364 9365 9366 9367 9368 9369 9370 9371 9372 9373 9374 9375 9376 9377 9378 9379 9380 9381 9382 9383 9384 9385 9386 9387 9388 9389 9390 9391 9392 9393 9394 9395 9396 9397 9398 9399 9400 9401 9402 9403 9404 9405 9406 9407 9408 9409 9410 9411 9412 9413 9414 9415 9416 9417 9418 9419 9420 9421 9422 9423 9424 9425 9426 9427 9428 9429 9430 9431 9432 9433 9434 9435 9436 9437 9438 9439 9440 9441 9442 9443 9444 9445 9446 9447 9448 9449 9450 9451 9452 9453 9454 9455 9456 9457 9458 9459 9460 9461 9462 9463 9464 9465 9466 9467 9468 9469 9470 9471 9472 9473 9474 9475 9476 9477 9478 9479 9480 9481 9482 9483 9484 9485 9486 9487 9488 9489 9490 9491 9492 9493 9494 9495 9496 9497 9498 9499 9500 9501 9502 9503 9504 9505 9506 9507 9508 9509 9510 9511 9512 9513 9514 9515 9516 9517 9518 9519 9520 9521 9522 9523 9524 9525 9526 9527 9528 9529 9530 9531 9532 9533 9534 9535 9536 9537 9538 9539 9540 9541 9542 9543 9544 9545 9546 9547 9548 9549 9550 9551 9552 9553 9554 9555 9556 9557 9558 9559 9560 9561 9562 9563 9564 9565 9566 9567 9568 9569 9570 9571 9572 9573 9574 9575 9576 9577 9578 9579 9580 9581 9582 9583 9584 9585 9586 9587 9588 9589 9590 9591 9592 9593 9594 9595 9596 9597 9598 9599 9600 9601 9602 9603 9604 9605 9606 9607 9608 9609 9610 9611 9612 9613 9614 9615 9616 9617 9618 9619 9620 9621 9622 9623 9624 9625 9626 9627 9628 9629 9630 9631 9632 9633 9634 9635 9636 9637 9638
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
/// <p>Represents the structure of actions and stages to be performed in the pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineDeclaration {
/// <p>The name of the pipeline.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The Amazon Resource Name (ARN) for AWS CodePipeline to use to either perform actions with no <code>actionRoleArn</code>, or to use to assume roles for actions with an <code>actionRoleArn</code>.</p>
#[doc(hidden)]
pub role_arn: std::option::Option<std::string::String>,
/// <p>Represents information about the S3 bucket where artifacts are stored for the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
#[doc(hidden)]
pub artifact_store: std::option::Option<crate::model::ArtifactStore>,
/// <p>A mapping of <code>artifactStore</code> objects and their corresponding AWS Regions. There must be an artifact store for the pipeline Region and for each cross-region action in the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
#[doc(hidden)]
pub artifact_stores: std::option::Option<
std::collections::HashMap<std::string::String, crate::model::ArtifactStore>,
>,
/// <p>The stage in which to perform the action.</p>
#[doc(hidden)]
pub stages: std::option::Option<std::vec::Vec<crate::model::StageDeclaration>>,
/// <p>The version number of the pipeline. A new pipeline always has a version number of 1. This number is incremented when a pipeline is updated.</p>
#[doc(hidden)]
pub version: std::option::Option<i32>,
}
impl PipelineDeclaration {
/// <p>The name of the pipeline.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The Amazon Resource Name (ARN) for AWS CodePipeline to use to either perform actions with no <code>actionRoleArn</code>, or to use to assume roles for actions with an <code>actionRoleArn</code>.</p>
pub fn role_arn(&self) -> std::option::Option<&str> {
self.role_arn.as_deref()
}
/// <p>Represents information about the S3 bucket where artifacts are stored for the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn artifact_store(&self) -> std::option::Option<&crate::model::ArtifactStore> {
self.artifact_store.as_ref()
}
/// <p>A mapping of <code>artifactStore</code> objects and their corresponding AWS Regions. There must be an artifact store for the pipeline Region and for each cross-region action in the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn artifact_stores(
&self,
) -> std::option::Option<
&std::collections::HashMap<std::string::String, crate::model::ArtifactStore>,
> {
self.artifact_stores.as_ref()
}
/// <p>The stage in which to perform the action.</p>
pub fn stages(&self) -> std::option::Option<&[crate::model::StageDeclaration]> {
self.stages.as_deref()
}
/// <p>The version number of the pipeline. A new pipeline always has a version number of 1. This number is incremented when a pipeline is updated.</p>
pub fn version(&self) -> std::option::Option<i32> {
self.version
}
}
/// See [`PipelineDeclaration`](crate::model::PipelineDeclaration).
pub mod pipeline_declaration {
/// A builder for [`PipelineDeclaration`](crate::model::PipelineDeclaration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) role_arn: std::option::Option<std::string::String>,
pub(crate) artifact_store: std::option::Option<crate::model::ArtifactStore>,
pub(crate) artifact_stores: std::option::Option<
std::collections::HashMap<std::string::String, crate::model::ArtifactStore>,
>,
pub(crate) stages: std::option::Option<std::vec::Vec<crate::model::StageDeclaration>>,
pub(crate) version: std::option::Option<i32>,
}
impl Builder {
/// <p>The name of the pipeline.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the pipeline.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The Amazon Resource Name (ARN) for AWS CodePipeline to use to either perform actions with no <code>actionRoleArn</code>, or to use to assume roles for actions with an <code>actionRoleArn</code>.</p>
pub fn role_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.role_arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) for AWS CodePipeline to use to either perform actions with no <code>actionRoleArn</code>, or to use to assume roles for actions with an <code>actionRoleArn</code>.</p>
pub fn set_role_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.role_arn = input;
self
}
/// <p>Represents information about the S3 bucket where artifacts are stored for the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn artifact_store(mut self, input: crate::model::ArtifactStore) -> Self {
self.artifact_store = Some(input);
self
}
/// <p>Represents information about the S3 bucket where artifacts are stored for the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn set_artifact_store(
mut self,
input: std::option::Option<crate::model::ArtifactStore>,
) -> Self {
self.artifact_store = input;
self
}
/// Adds a key-value pair to `artifact_stores`.
///
/// To override the contents of this collection use [`set_artifact_stores`](Self::set_artifact_stores).
///
/// <p>A mapping of <code>artifactStore</code> objects and their corresponding AWS Regions. There must be an artifact store for the pipeline Region and for each cross-region action in the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn artifact_stores(
mut self,
k: impl Into<std::string::String>,
v: crate::model::ArtifactStore,
) -> Self {
let mut hash_map = self.artifact_stores.unwrap_or_default();
hash_map.insert(k.into(), v);
self.artifact_stores = Some(hash_map);
self
}
/// <p>A mapping of <code>artifactStore</code> objects and their corresponding AWS Regions. There must be an artifact store for the pipeline Region and for each cross-region action in the pipeline.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
pub fn set_artifact_stores(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, crate::model::ArtifactStore>,
>,
) -> Self {
self.artifact_stores = input;
self
}
/// Appends an item to `stages`.
///
/// To override the contents of this collection use [`set_stages`](Self::set_stages).
///
/// <p>The stage in which to perform the action.</p>
pub fn stages(mut self, input: crate::model::StageDeclaration) -> Self {
let mut v = self.stages.unwrap_or_default();
v.push(input);
self.stages = Some(v);
self
}
/// <p>The stage in which to perform the action.</p>
pub fn set_stages(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::StageDeclaration>>,
) -> Self {
self.stages = input;
self
}
/// <p>The version number of the pipeline. A new pipeline always has a version number of 1. This number is incremented when a pipeline is updated.</p>
pub fn version(mut self, input: i32) -> Self {
self.version = Some(input);
self
}
/// <p>The version number of the pipeline. A new pipeline always has a version number of 1. This number is incremented when a pipeline is updated.</p>
pub fn set_version(mut self, input: std::option::Option<i32>) -> Self {
self.version = input;
self
}
/// Consumes the builder and constructs a [`PipelineDeclaration`](crate::model::PipelineDeclaration).
pub fn build(self) -> crate::model::PipelineDeclaration {
crate::model::PipelineDeclaration {
name: self.name,
role_arn: self.role_arn,
artifact_store: self.artifact_store,
artifact_stores: self.artifact_stores,
stages: self.stages,
version: self.version,
}
}
}
}
impl PipelineDeclaration {
/// Creates a new builder-style object to manufacture [`PipelineDeclaration`](crate::model::PipelineDeclaration).
pub fn builder() -> crate::model::pipeline_declaration::Builder {
crate::model::pipeline_declaration::Builder::default()
}
}
/// <p>Represents information about a stage and its definition.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct StageDeclaration {
/// <p>The name of the stage.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>Reserved for future use.</p>
#[doc(hidden)]
pub blockers: std::option::Option<std::vec::Vec<crate::model::BlockerDeclaration>>,
/// <p>The actions included in a stage.</p>
#[doc(hidden)]
pub actions: std::option::Option<std::vec::Vec<crate::model::ActionDeclaration>>,
}
impl StageDeclaration {
/// <p>The name of the stage.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>Reserved for future use.</p>
pub fn blockers(&self) -> std::option::Option<&[crate::model::BlockerDeclaration]> {
self.blockers.as_deref()
}
/// <p>The actions included in a stage.</p>
pub fn actions(&self) -> std::option::Option<&[crate::model::ActionDeclaration]> {
self.actions.as_deref()
}
}
/// See [`StageDeclaration`](crate::model::StageDeclaration).
pub mod stage_declaration {
/// A builder for [`StageDeclaration`](crate::model::StageDeclaration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) blockers: std::option::Option<std::vec::Vec<crate::model::BlockerDeclaration>>,
pub(crate) actions: std::option::Option<std::vec::Vec<crate::model::ActionDeclaration>>,
}
impl Builder {
/// <p>The name of the stage.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the stage.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// Appends an item to `blockers`.
///
/// To override the contents of this collection use [`set_blockers`](Self::set_blockers).
///
/// <p>Reserved for future use.</p>
pub fn blockers(mut self, input: crate::model::BlockerDeclaration) -> Self {
let mut v = self.blockers.unwrap_or_default();
v.push(input);
self.blockers = Some(v);
self
}
/// <p>Reserved for future use.</p>
pub fn set_blockers(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::BlockerDeclaration>>,
) -> Self {
self.blockers = input;
self
}
/// Appends an item to `actions`.
///
/// To override the contents of this collection use [`set_actions`](Self::set_actions).
///
/// <p>The actions included in a stage.</p>
pub fn actions(mut self, input: crate::model::ActionDeclaration) -> Self {
let mut v = self.actions.unwrap_or_default();
v.push(input);
self.actions = Some(v);
self
}
/// <p>The actions included in a stage.</p>
pub fn set_actions(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ActionDeclaration>>,
) -> Self {
self.actions = input;
self
}
/// Consumes the builder and constructs a [`StageDeclaration`](crate::model::StageDeclaration).
pub fn build(self) -> crate::model::StageDeclaration {
crate::model::StageDeclaration {
name: self.name,
blockers: self.blockers,
actions: self.actions,
}
}
}
}
impl StageDeclaration {
/// Creates a new builder-style object to manufacture [`StageDeclaration`](crate::model::StageDeclaration).
pub fn builder() -> crate::model::stage_declaration::Builder {
crate::model::stage_declaration::Builder::default()
}
}
/// <p>Represents information about an action declaration.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionDeclaration {
/// <p>The action declaration's name.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>Specifies the action type and the provider of the action.</p>
#[doc(hidden)]
pub action_type_id: std::option::Option<crate::model::ActionTypeId>,
/// <p>The order in which actions are run.</p>
#[doc(hidden)]
pub run_order: std::option::Option<i32>,
/// <p>The action's configuration. These are key-value pairs that specify input values for an action. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Action Structure Requirements in CodePipeline</a>. For the list of configuration properties for the AWS CloudFormation action type in CodePipeline, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-action-reference.html">Configuration Properties Reference</a> in the <i>AWS CloudFormation User Guide</i>. For template snippets with examples, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-parameter-override-functions.html">Using Parameter Override Functions with CodePipeline Pipelines</a> in the <i>AWS CloudFormation User Guide</i>.</p>
/// <p>The values can be represented in either JSON or YAML format. For example, the JSON configuration item format is as follows: </p>
/// <p> <i>JSON:</i> </p>
/// <p> <code>"Configuration" : { Key : Value },</code> </p>
#[doc(hidden)]
pub configuration:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
/// <p>The name or ID of the result of the action declaration, such as a test or build artifact.</p>
#[doc(hidden)]
pub output_artifacts: std::option::Option<std::vec::Vec<crate::model::OutputArtifact>>,
/// <p>The name or ID of the artifact consumed by the action, such as a test or build artifact.</p>
#[doc(hidden)]
pub input_artifacts: std::option::Option<std::vec::Vec<crate::model::InputArtifact>>,
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline.</p>
#[doc(hidden)]
pub role_arn: std::option::Option<std::string::String>,
/// <p>The action declaration's AWS Region, such as us-east-1.</p>
#[doc(hidden)]
pub region: std::option::Option<std::string::String>,
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
#[doc(hidden)]
pub namespace: std::option::Option<std::string::String>,
}
impl ActionDeclaration {
/// <p>The action declaration's name.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>Specifies the action type and the provider of the action.</p>
pub fn action_type_id(&self) -> std::option::Option<&crate::model::ActionTypeId> {
self.action_type_id.as_ref()
}
/// <p>The order in which actions are run.</p>
pub fn run_order(&self) -> std::option::Option<i32> {
self.run_order
}
/// <p>The action's configuration. These are key-value pairs that specify input values for an action. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Action Structure Requirements in CodePipeline</a>. For the list of configuration properties for the AWS CloudFormation action type in CodePipeline, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-action-reference.html">Configuration Properties Reference</a> in the <i>AWS CloudFormation User Guide</i>. For template snippets with examples, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-parameter-override-functions.html">Using Parameter Override Functions with CodePipeline Pipelines</a> in the <i>AWS CloudFormation User Guide</i>.</p>
/// <p>The values can be represented in either JSON or YAML format. For example, the JSON configuration item format is as follows: </p>
/// <p> <i>JSON:</i> </p>
/// <p> <code>"Configuration" : { Key : Value },</code> </p>
pub fn configuration(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.configuration.as_ref()
}
/// <p>The name or ID of the result of the action declaration, such as a test or build artifact.</p>
pub fn output_artifacts(&self) -> std::option::Option<&[crate::model::OutputArtifact]> {
self.output_artifacts.as_deref()
}
/// <p>The name or ID of the artifact consumed by the action, such as a test or build artifact.</p>
pub fn input_artifacts(&self) -> std::option::Option<&[crate::model::InputArtifact]> {
self.input_artifacts.as_deref()
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline.</p>
pub fn role_arn(&self) -> std::option::Option<&str> {
self.role_arn.as_deref()
}
/// <p>The action declaration's AWS Region, such as us-east-1.</p>
pub fn region(&self) -> std::option::Option<&str> {
self.region.as_deref()
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn namespace(&self) -> std::option::Option<&str> {
self.namespace.as_deref()
}
}
/// See [`ActionDeclaration`](crate::model::ActionDeclaration).
pub mod action_declaration {
/// A builder for [`ActionDeclaration`](crate::model::ActionDeclaration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) action_type_id: std::option::Option<crate::model::ActionTypeId>,
pub(crate) run_order: std::option::Option<i32>,
pub(crate) configuration: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
pub(crate) output_artifacts:
std::option::Option<std::vec::Vec<crate::model::OutputArtifact>>,
pub(crate) input_artifacts: std::option::Option<std::vec::Vec<crate::model::InputArtifact>>,
pub(crate) role_arn: std::option::Option<std::string::String>,
pub(crate) region: std::option::Option<std::string::String>,
pub(crate) namespace: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The action declaration's name.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The action declaration's name.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>Specifies the action type and the provider of the action.</p>
pub fn action_type_id(mut self, input: crate::model::ActionTypeId) -> Self {
self.action_type_id = Some(input);
self
}
/// <p>Specifies the action type and the provider of the action.</p>
pub fn set_action_type_id(
mut self,
input: std::option::Option<crate::model::ActionTypeId>,
) -> Self {
self.action_type_id = input;
self
}
/// <p>The order in which actions are run.</p>
pub fn run_order(mut self, input: i32) -> Self {
self.run_order = Some(input);
self
}
/// <p>The order in which actions are run.</p>
pub fn set_run_order(mut self, input: std::option::Option<i32>) -> Self {
self.run_order = input;
self
}
/// Adds a key-value pair to `configuration`.
///
/// To override the contents of this collection use [`set_configuration`](Self::set_configuration).
///
/// <p>The action's configuration. These are key-value pairs that specify input values for an action. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Action Structure Requirements in CodePipeline</a>. For the list of configuration properties for the AWS CloudFormation action type in CodePipeline, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-action-reference.html">Configuration Properties Reference</a> in the <i>AWS CloudFormation User Guide</i>. For template snippets with examples, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-parameter-override-functions.html">Using Parameter Override Functions with CodePipeline Pipelines</a> in the <i>AWS CloudFormation User Guide</i>.</p>
/// <p>The values can be represented in either JSON or YAML format. For example, the JSON configuration item format is as follows: </p>
/// <p> <i>JSON:</i> </p>
/// <p> <code>"Configuration" : { Key : Value },</code> </p>
pub fn configuration(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.configuration.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.configuration = Some(hash_map);
self
}
/// <p>The action's configuration. These are key-value pairs that specify input values for an action. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Action Structure Requirements in CodePipeline</a>. For the list of configuration properties for the AWS CloudFormation action type in CodePipeline, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-action-reference.html">Configuration Properties Reference</a> in the <i>AWS CloudFormation User Guide</i>. For template snippets with examples, see <a href="https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/continuous-delivery-codepipeline-parameter-override-functions.html">Using Parameter Override Functions with CodePipeline Pipelines</a> in the <i>AWS CloudFormation User Guide</i>.</p>
/// <p>The values can be represented in either JSON or YAML format. For example, the JSON configuration item format is as follows: </p>
/// <p> <i>JSON:</i> </p>
/// <p> <code>"Configuration" : { Key : Value },</code> </p>
pub fn set_configuration(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.configuration = input;
self
}
/// Appends an item to `output_artifacts`.
///
/// To override the contents of this collection use [`set_output_artifacts`](Self::set_output_artifacts).
///
/// <p>The name or ID of the result of the action declaration, such as a test or build artifact.</p>
pub fn output_artifacts(mut self, input: crate::model::OutputArtifact) -> Self {
let mut v = self.output_artifacts.unwrap_or_default();
v.push(input);
self.output_artifacts = Some(v);
self
}
/// <p>The name or ID of the result of the action declaration, such as a test or build artifact.</p>
pub fn set_output_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::OutputArtifact>>,
) -> Self {
self.output_artifacts = input;
self
}
/// Appends an item to `input_artifacts`.
///
/// To override the contents of this collection use [`set_input_artifacts`](Self::set_input_artifacts).
///
/// <p>The name or ID of the artifact consumed by the action, such as a test or build artifact.</p>
pub fn input_artifacts(mut self, input: crate::model::InputArtifact) -> Self {
let mut v = self.input_artifacts.unwrap_or_default();
v.push(input);
self.input_artifacts = Some(v);
self
}
/// <p>The name or ID of the artifact consumed by the action, such as a test or build artifact.</p>
pub fn set_input_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::InputArtifact>>,
) -> Self {
self.input_artifacts = input;
self
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline.</p>
pub fn role_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.role_arn = Some(input.into());
self
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline.</p>
pub fn set_role_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.role_arn = input;
self
}
/// <p>The action declaration's AWS Region, such as us-east-1.</p>
pub fn region(mut self, input: impl Into<std::string::String>) -> Self {
self.region = Some(input.into());
self
}
/// <p>The action declaration's AWS Region, such as us-east-1.</p>
pub fn set_region(mut self, input: std::option::Option<std::string::String>) -> Self {
self.region = input;
self
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn namespace(mut self, input: impl Into<std::string::String>) -> Self {
self.namespace = Some(input.into());
self
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn set_namespace(mut self, input: std::option::Option<std::string::String>) -> Self {
self.namespace = input;
self
}
/// Consumes the builder and constructs a [`ActionDeclaration`](crate::model::ActionDeclaration).
pub fn build(self) -> crate::model::ActionDeclaration {
crate::model::ActionDeclaration {
name: self.name,
action_type_id: self.action_type_id,
run_order: self.run_order,
configuration: self.configuration,
output_artifacts: self.output_artifacts,
input_artifacts: self.input_artifacts,
role_arn: self.role_arn,
region: self.region,
namespace: self.namespace,
}
}
}
}
impl ActionDeclaration {
/// Creates a new builder-style object to manufacture [`ActionDeclaration`](crate::model::ActionDeclaration).
pub fn builder() -> crate::model::action_declaration::Builder {
crate::model::action_declaration::Builder::default()
}
}
/// <p>Represents information about an artifact to be worked on, such as a test or build artifact.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct InputArtifact {
/// <p>The name of the artifact to be worked on (for example, "My App").</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
}
impl InputArtifact {
/// <p>The name of the artifact to be worked on (for example, "My App").</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
}
/// See [`InputArtifact`](crate::model::InputArtifact).
pub mod input_artifact {
/// A builder for [`InputArtifact`](crate::model::InputArtifact).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the artifact to be worked on (for example, "My App").</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the artifact to be worked on (for example, "My App").</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// Consumes the builder and constructs a [`InputArtifact`](crate::model::InputArtifact).
pub fn build(self) -> crate::model::InputArtifact {
crate::model::InputArtifact { name: self.name }
}
}
}
impl InputArtifact {
/// Creates a new builder-style object to manufacture [`InputArtifact`](crate::model::InputArtifact).
pub fn builder() -> crate::model::input_artifact::Builder {
crate::model::input_artifact::Builder::default()
}
}
/// <p>Represents information about the output of an action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct OutputArtifact {
/// <p>The name of the output of an artifact, such as "My App".</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
/// <p>Output artifact names must be unique within a pipeline.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
}
impl OutputArtifact {
/// <p>The name of the output of an artifact, such as "My App".</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
/// <p>Output artifact names must be unique within a pipeline.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
}
/// See [`OutputArtifact`](crate::model::OutputArtifact).
pub mod output_artifact {
/// A builder for [`OutputArtifact`](crate::model::OutputArtifact).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the output of an artifact, such as "My App".</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
/// <p>Output artifact names must be unique within a pipeline.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the output of an artifact, such as "My App".</p>
/// <p>The input artifact of an action must exactly match the output artifact declared in a preceding action, but the input artifact does not have to be the next action in strict sequence from the action that provided the output artifact. Actions in parallel can declare different output artifacts, which are in turn consumed by different following actions.</p>
/// <p>Output artifact names must be unique within a pipeline.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// Consumes the builder and constructs a [`OutputArtifact`](crate::model::OutputArtifact).
pub fn build(self) -> crate::model::OutputArtifact {
crate::model::OutputArtifact { name: self.name }
}
}
}
impl OutputArtifact {
/// Creates a new builder-style object to manufacture [`OutputArtifact`](crate::model::OutputArtifact).
pub fn builder() -> crate::model::output_artifact::Builder {
crate::model::output_artifact::Builder::default()
}
}
/// <p>Represents information about an action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeId {
/// <p>A category defines what kind of action can be taken in the stage, and constrains the provider type for the action. Valid categories are limited to one of the following values. </p>
/// <ul>
/// <li> <p>Source</p> </li>
/// <li> <p>Build</p> </li>
/// <li> <p>Test</p> </li>
/// <li> <p>Deploy</p> </li>
/// <li> <p>Invoke</p> </li>
/// <li> <p>Approval</p> </li>
/// </ul>
#[doc(hidden)]
pub category: std::option::Option<crate::model::ActionCategory>,
/// <p>The creator of the action being called. There are three valid values for the <code>Owner</code> field in the action category section within your pipeline structure: <code>AWS</code>, <code>ThirdParty</code>, and <code>Custom</code>. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
#[doc(hidden)]
pub owner: std::option::Option<crate::model::ActionOwner>,
/// <p>The provider of the service being called by the action. Valid providers are determined by the action category. For example, an action in the Deploy category type might have a provider of AWS CodeDeploy, which would be specified as CodeDeploy. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
#[doc(hidden)]
pub provider: std::option::Option<std::string::String>,
/// <p>A string that describes the action version.</p>
#[doc(hidden)]
pub version: std::option::Option<std::string::String>,
}
impl ActionTypeId {
/// <p>A category defines what kind of action can be taken in the stage, and constrains the provider type for the action. Valid categories are limited to one of the following values. </p>
/// <ul>
/// <li> <p>Source</p> </li>
/// <li> <p>Build</p> </li>
/// <li> <p>Test</p> </li>
/// <li> <p>Deploy</p> </li>
/// <li> <p>Invoke</p> </li>
/// <li> <p>Approval</p> </li>
/// </ul>
pub fn category(&self) -> std::option::Option<&crate::model::ActionCategory> {
self.category.as_ref()
}
/// <p>The creator of the action being called. There are three valid values for the <code>Owner</code> field in the action category section within your pipeline structure: <code>AWS</code>, <code>ThirdParty</code>, and <code>Custom</code>. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn owner(&self) -> std::option::Option<&crate::model::ActionOwner> {
self.owner.as_ref()
}
/// <p>The provider of the service being called by the action. Valid providers are determined by the action category. For example, an action in the Deploy category type might have a provider of AWS CodeDeploy, which would be specified as CodeDeploy. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn provider(&self) -> std::option::Option<&str> {
self.provider.as_deref()
}
/// <p>A string that describes the action version.</p>
pub fn version(&self) -> std::option::Option<&str> {
self.version.as_deref()
}
}
/// See [`ActionTypeId`](crate::model::ActionTypeId).
pub mod action_type_id {
/// A builder for [`ActionTypeId`](crate::model::ActionTypeId).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) category: std::option::Option<crate::model::ActionCategory>,
pub(crate) owner: std::option::Option<crate::model::ActionOwner>,
pub(crate) provider: std::option::Option<std::string::String>,
pub(crate) version: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>A category defines what kind of action can be taken in the stage, and constrains the provider type for the action. Valid categories are limited to one of the following values. </p>
/// <ul>
/// <li> <p>Source</p> </li>
/// <li> <p>Build</p> </li>
/// <li> <p>Test</p> </li>
/// <li> <p>Deploy</p> </li>
/// <li> <p>Invoke</p> </li>
/// <li> <p>Approval</p> </li>
/// </ul>
pub fn category(mut self, input: crate::model::ActionCategory) -> Self {
self.category = Some(input);
self
}
/// <p>A category defines what kind of action can be taken in the stage, and constrains the provider type for the action. Valid categories are limited to one of the following values. </p>
/// <ul>
/// <li> <p>Source</p> </li>
/// <li> <p>Build</p> </li>
/// <li> <p>Test</p> </li>
/// <li> <p>Deploy</p> </li>
/// <li> <p>Invoke</p> </li>
/// <li> <p>Approval</p> </li>
/// </ul>
pub fn set_category(
mut self,
input: std::option::Option<crate::model::ActionCategory>,
) -> Self {
self.category = input;
self
}
/// <p>The creator of the action being called. There are three valid values for the <code>Owner</code> field in the action category section within your pipeline structure: <code>AWS</code>, <code>ThirdParty</code>, and <code>Custom</code>. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn owner(mut self, input: crate::model::ActionOwner) -> Self {
self.owner = Some(input);
self
}
/// <p>The creator of the action being called. There are three valid values for the <code>Owner</code> field in the action category section within your pipeline structure: <code>AWS</code>, <code>ThirdParty</code>, and <code>Custom</code>. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn set_owner(mut self, input: std::option::Option<crate::model::ActionOwner>) -> Self {
self.owner = input;
self
}
/// <p>The provider of the service being called by the action. Valid providers are determined by the action category. For example, an action in the Deploy category type might have a provider of AWS CodeDeploy, which would be specified as CodeDeploy. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn provider(mut self, input: impl Into<std::string::String>) -> Self {
self.provider = Some(input.into());
self
}
/// <p>The provider of the service being called by the action. Valid providers are determined by the action category. For example, an action in the Deploy category type might have a provider of AWS CodeDeploy, which would be specified as CodeDeploy. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#actions-valid-providers">Valid Action Types and Providers in CodePipeline</a>.</p>
pub fn set_provider(mut self, input: std::option::Option<std::string::String>) -> Self {
self.provider = input;
self
}
/// <p>A string that describes the action version.</p>
pub fn version(mut self, input: impl Into<std::string::String>) -> Self {
self.version = Some(input.into());
self
}
/// <p>A string that describes the action version.</p>
pub fn set_version(mut self, input: std::option::Option<std::string::String>) -> Self {
self.version = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeId`](crate::model::ActionTypeId).
pub fn build(self) -> crate::model::ActionTypeId {
crate::model::ActionTypeId {
category: self.category,
owner: self.owner,
provider: self.provider,
version: self.version,
}
}
}
}
impl ActionTypeId {
/// Creates a new builder-style object to manufacture [`ActionTypeId`](crate::model::ActionTypeId).
pub fn builder() -> crate::model::action_type_id::Builder {
crate::model::action_type_id::Builder::default()
}
}
/// When writing a match expression against `ActionOwner`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let actionowner = unimplemented!();
/// match actionowner {
/// ActionOwner::Aws => { /* ... */ },
/// ActionOwner::Custom => { /* ... */ },
/// ActionOwner::ThirdParty => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `actionowner` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ActionOwner::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ActionOwner::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ActionOwner::NewFeature` is defined.
/// Specifically, when `actionowner` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ActionOwner::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ActionOwner {
#[allow(missing_docs)] // documentation missing in model
Aws,
#[allow(missing_docs)] // documentation missing in model
Custom,
#[allow(missing_docs)] // documentation missing in model
ThirdParty,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ActionOwner {
fn from(s: &str) -> Self {
match s {
"AWS" => ActionOwner::Aws,
"Custom" => ActionOwner::Custom,
"ThirdParty" => ActionOwner::ThirdParty,
other => ActionOwner::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for ActionOwner {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ActionOwner::from(s))
}
}
impl ActionOwner {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ActionOwner::Aws => "AWS",
ActionOwner::Custom => "Custom",
ActionOwner::ThirdParty => "ThirdParty",
ActionOwner::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["AWS", "Custom", "ThirdParty"]
}
}
impl AsRef<str> for ActionOwner {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// When writing a match expression against `ActionCategory`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let actioncategory = unimplemented!();
/// match actioncategory {
/// ActionCategory::Approval => { /* ... */ },
/// ActionCategory::Build => { /* ... */ },
/// ActionCategory::Deploy => { /* ... */ },
/// ActionCategory::Invoke => { /* ... */ },
/// ActionCategory::Source => { /* ... */ },
/// ActionCategory::Test => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `actioncategory` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ActionCategory::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ActionCategory::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ActionCategory::NewFeature` is defined.
/// Specifically, when `actioncategory` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ActionCategory::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ActionCategory {
#[allow(missing_docs)] // documentation missing in model
Approval,
#[allow(missing_docs)] // documentation missing in model
Build,
#[allow(missing_docs)] // documentation missing in model
Deploy,
#[allow(missing_docs)] // documentation missing in model
Invoke,
#[allow(missing_docs)] // documentation missing in model
Source,
#[allow(missing_docs)] // documentation missing in model
Test,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ActionCategory {
fn from(s: &str) -> Self {
match s {
"Approval" => ActionCategory::Approval,
"Build" => ActionCategory::Build,
"Deploy" => ActionCategory::Deploy,
"Invoke" => ActionCategory::Invoke,
"Source" => ActionCategory::Source,
"Test" => ActionCategory::Test,
other => ActionCategory::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for ActionCategory {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ActionCategory::from(s))
}
}
impl ActionCategory {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ActionCategory::Approval => "Approval",
ActionCategory::Build => "Build",
ActionCategory::Deploy => "Deploy",
ActionCategory::Invoke => "Invoke",
ActionCategory::Source => "Source",
ActionCategory::Test => "Test",
ActionCategory::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Approval", "Build", "Deploy", "Invoke", "Source", "Test"]
}
}
impl AsRef<str> for ActionCategory {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Reserved for future use.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct BlockerDeclaration {
/// <p>Reserved for future use.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>Reserved for future use.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::BlockerType>,
}
impl BlockerDeclaration {
/// <p>Reserved for future use.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>Reserved for future use.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::BlockerType> {
self.r#type.as_ref()
}
}
/// See [`BlockerDeclaration`](crate::model::BlockerDeclaration).
pub mod blocker_declaration {
/// A builder for [`BlockerDeclaration`](crate::model::BlockerDeclaration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::BlockerType>,
}
impl Builder {
/// <p>Reserved for future use.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>Reserved for future use.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>Reserved for future use.</p>
pub fn r#type(mut self, input: crate::model::BlockerType) -> Self {
self.r#type = Some(input);
self
}
/// <p>Reserved for future use.</p>
pub fn set_type(mut self, input: std::option::Option<crate::model::BlockerType>) -> Self {
self.r#type = input;
self
}
/// Consumes the builder and constructs a [`BlockerDeclaration`](crate::model::BlockerDeclaration).
pub fn build(self) -> crate::model::BlockerDeclaration {
crate::model::BlockerDeclaration {
name: self.name,
r#type: self.r#type,
}
}
}
}
impl BlockerDeclaration {
/// Creates a new builder-style object to manufacture [`BlockerDeclaration`](crate::model::BlockerDeclaration).
pub fn builder() -> crate::model::blocker_declaration::Builder {
crate::model::blocker_declaration::Builder::default()
}
}
/// When writing a match expression against `BlockerType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let blockertype = unimplemented!();
/// match blockertype {
/// BlockerType::Schedule => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `blockertype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `BlockerType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `BlockerType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `BlockerType::NewFeature` is defined.
/// Specifically, when `blockertype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `BlockerType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum BlockerType {
#[allow(missing_docs)] // documentation missing in model
Schedule,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for BlockerType {
fn from(s: &str) -> Self {
match s {
"Schedule" => BlockerType::Schedule,
other => BlockerType::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for BlockerType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(BlockerType::from(s))
}
}
impl BlockerType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
BlockerType::Schedule => "Schedule",
BlockerType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Schedule"]
}
}
impl AsRef<str> for BlockerType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The S3 bucket where artifacts for the pipeline are stored.</p> <note>
/// <p>You must include either <code>artifactStore</code> or <code>artifactStores</code> in your pipeline, but you cannot use both. If you create a cross-region action in your pipeline, you must use <code>artifactStores</code>.</p>
/// </note>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ArtifactStore {
/// <p>The type of the artifact store, such as S3.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::ArtifactStoreType>,
/// <p>The S3 bucket used for storing the artifacts for a pipeline. You can specify the name of an S3 bucket but not a folder in the bucket. A folder to contain the pipeline artifacts is created for you based on the name of the pipeline. You can use any S3 bucket in the same AWS Region as the pipeline to store your pipeline artifacts.</p>
#[doc(hidden)]
pub location: std::option::Option<std::string::String>,
/// <p>The encryption key used to encrypt the data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. If this is undefined, the default key for Amazon S3 is used.</p>
#[doc(hidden)]
pub encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl ArtifactStore {
/// <p>The type of the artifact store, such as S3.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::ArtifactStoreType> {
self.r#type.as_ref()
}
/// <p>The S3 bucket used for storing the artifacts for a pipeline. You can specify the name of an S3 bucket but not a folder in the bucket. A folder to contain the pipeline artifacts is created for you based on the name of the pipeline. You can use any S3 bucket in the same AWS Region as the pipeline to store your pipeline artifacts.</p>
pub fn location(&self) -> std::option::Option<&str> {
self.location.as_deref()
}
/// <p>The encryption key used to encrypt the data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. If this is undefined, the default key for Amazon S3 is used.</p>
pub fn encryption_key(&self) -> std::option::Option<&crate::model::EncryptionKey> {
self.encryption_key.as_ref()
}
}
/// See [`ArtifactStore`](crate::model::ArtifactStore).
pub mod artifact_store {
/// A builder for [`ArtifactStore`](crate::model::ArtifactStore).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::ArtifactStoreType>,
pub(crate) location: std::option::Option<std::string::String>,
pub(crate) encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl Builder {
/// <p>The type of the artifact store, such as S3.</p>
pub fn r#type(mut self, input: crate::model::ArtifactStoreType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of the artifact store, such as S3.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::ArtifactStoreType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The S3 bucket used for storing the artifacts for a pipeline. You can specify the name of an S3 bucket but not a folder in the bucket. A folder to contain the pipeline artifacts is created for you based on the name of the pipeline. You can use any S3 bucket in the same AWS Region as the pipeline to store your pipeline artifacts.</p>
pub fn location(mut self, input: impl Into<std::string::String>) -> Self {
self.location = Some(input.into());
self
}
/// <p>The S3 bucket used for storing the artifacts for a pipeline. You can specify the name of an S3 bucket but not a folder in the bucket. A folder to contain the pipeline artifacts is created for you based on the name of the pipeline. You can use any S3 bucket in the same AWS Region as the pipeline to store your pipeline artifacts.</p>
pub fn set_location(mut self, input: std::option::Option<std::string::String>) -> Self {
self.location = input;
self
}
/// <p>The encryption key used to encrypt the data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. If this is undefined, the default key for Amazon S3 is used.</p>
pub fn encryption_key(mut self, input: crate::model::EncryptionKey) -> Self {
self.encryption_key = Some(input);
self
}
/// <p>The encryption key used to encrypt the data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. If this is undefined, the default key for Amazon S3 is used.</p>
pub fn set_encryption_key(
mut self,
input: std::option::Option<crate::model::EncryptionKey>,
) -> Self {
self.encryption_key = input;
self
}
/// Consumes the builder and constructs a [`ArtifactStore`](crate::model::ArtifactStore).
pub fn build(self) -> crate::model::ArtifactStore {
crate::model::ArtifactStore {
r#type: self.r#type,
location: self.location,
encryption_key: self.encryption_key,
}
}
}
}
impl ArtifactStore {
/// Creates a new builder-style object to manufacture [`ArtifactStore`](crate::model::ArtifactStore).
pub fn builder() -> crate::model::artifact_store::Builder {
crate::model::artifact_store::Builder::default()
}
}
/// <p>Represents information about the key used to encrypt data in the artifact store, such as an AWS Key Management Service (AWS KMS) key.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct EncryptionKey {
/// <p>The ID used to identify the key. For an AWS KMS key, you can use the key ID, the key ARN, or the alias ARN.</p> <note>
/// <p>Aliases are recognized only in the account that created the customer master key (CMK). For cross-account actions, you can only use the key ID or key ARN to identify the key.</p>
/// </note>
#[doc(hidden)]
pub id: std::option::Option<std::string::String>,
/// <p>The type of encryption key, such as an AWS Key Management Service (AWS KMS) key. When creating or updating a pipeline, the value must be set to 'KMS'.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::EncryptionKeyType>,
}
impl EncryptionKey {
/// <p>The ID used to identify the key. For an AWS KMS key, you can use the key ID, the key ARN, or the alias ARN.</p> <note>
/// <p>Aliases are recognized only in the account that created the customer master key (CMK). For cross-account actions, you can only use the key ID or key ARN to identify the key.</p>
/// </note>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The type of encryption key, such as an AWS Key Management Service (AWS KMS) key. When creating or updating a pipeline, the value must be set to 'KMS'.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::EncryptionKeyType> {
self.r#type.as_ref()
}
}
/// See [`EncryptionKey`](crate::model::EncryptionKey).
pub mod encryption_key {
/// A builder for [`EncryptionKey`](crate::model::EncryptionKey).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::EncryptionKeyType>,
}
impl Builder {
/// <p>The ID used to identify the key. For an AWS KMS key, you can use the key ID, the key ARN, or the alias ARN.</p> <note>
/// <p>Aliases are recognized only in the account that created the customer master key (CMK). For cross-account actions, you can only use the key ID or key ARN to identify the key.</p>
/// </note>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The ID used to identify the key. For an AWS KMS key, you can use the key ID, the key ARN, or the alias ARN.</p> <note>
/// <p>Aliases are recognized only in the account that created the customer master key (CMK). For cross-account actions, you can only use the key ID or key ARN to identify the key.</p>
/// </note>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The type of encryption key, such as an AWS Key Management Service (AWS KMS) key. When creating or updating a pipeline, the value must be set to 'KMS'.</p>
pub fn r#type(mut self, input: crate::model::EncryptionKeyType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of encryption key, such as an AWS Key Management Service (AWS KMS) key. When creating or updating a pipeline, the value must be set to 'KMS'.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::EncryptionKeyType>,
) -> Self {
self.r#type = input;
self
}
/// Consumes the builder and constructs a [`EncryptionKey`](crate::model::EncryptionKey).
pub fn build(self) -> crate::model::EncryptionKey {
crate::model::EncryptionKey {
id: self.id,
r#type: self.r#type,
}
}
}
}
impl EncryptionKey {
/// Creates a new builder-style object to manufacture [`EncryptionKey`](crate::model::EncryptionKey).
pub fn builder() -> crate::model::encryption_key::Builder {
crate::model::encryption_key::Builder::default()
}
}
/// When writing a match expression against `EncryptionKeyType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let encryptionkeytype = unimplemented!();
/// match encryptionkeytype {
/// EncryptionKeyType::Kms => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `encryptionkeytype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `EncryptionKeyType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `EncryptionKeyType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `EncryptionKeyType::NewFeature` is defined.
/// Specifically, when `encryptionkeytype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `EncryptionKeyType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum EncryptionKeyType {
#[allow(missing_docs)] // documentation missing in model
Kms,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for EncryptionKeyType {
fn from(s: &str) -> Self {
match s {
"KMS" => EncryptionKeyType::Kms,
other => {
EncryptionKeyType::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for EncryptionKeyType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(EncryptionKeyType::from(s))
}
}
impl EncryptionKeyType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
EncryptionKeyType::Kms => "KMS",
EncryptionKeyType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["KMS"]
}
}
impl AsRef<str> for EncryptionKeyType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// When writing a match expression against `ArtifactStoreType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let artifactstoretype = unimplemented!();
/// match artifactstoretype {
/// ArtifactStoreType::S3 => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `artifactstoretype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ArtifactStoreType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ArtifactStoreType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ArtifactStoreType::NewFeature` is defined.
/// Specifically, when `artifactstoretype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ArtifactStoreType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ArtifactStoreType {
#[allow(missing_docs)] // documentation missing in model
S3,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ArtifactStoreType {
fn from(s: &str) -> Self {
match s {
"S3" => ArtifactStoreType::S3,
other => {
ArtifactStoreType::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for ArtifactStoreType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ArtifactStoreType::from(s))
}
}
impl ArtifactStoreType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ArtifactStoreType::S3 => "S3",
ArtifactStoreType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["S3"]
}
}
impl AsRef<str> for ArtifactStoreType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The parameters for the action type definition that are provided when the action type is created or updated.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeDeclaration {
/// <p>The description for the action type to be updated.</p>
#[doc(hidden)]
pub description: std::option::Option<std::string::String>,
/// <p>Information about the executor for an action type that was created with any supported integration model.</p>
#[doc(hidden)]
pub executor: std::option::Option<crate::model::ActionTypeExecutor>,
/// <p>The action category, owner, provider, and version of the action type to be updated.</p>
#[doc(hidden)]
pub id: std::option::Option<crate::model::ActionTypeIdentifier>,
/// <p>Details for the artifacts, such as application files, to be worked on by the action. For example, the minimum and maximum number of input artifacts allowed.</p>
#[doc(hidden)]
pub input_artifact_details: std::option::Option<crate::model::ActionTypeArtifactDetails>,
/// <p>Details for the output artifacts, such as a built application, that are the result of the action. For example, the minimum and maximum number of output artifacts allowed.</p>
#[doc(hidden)]
pub output_artifact_details: std::option::Option<crate::model::ActionTypeArtifactDetails>,
/// <p>Details identifying the accounts with permissions to use the action type.</p>
#[doc(hidden)]
pub permissions: std::option::Option<crate::model::ActionTypePermissions>,
/// <p>The properties of the action type to be updated.</p>
#[doc(hidden)]
pub properties: std::option::Option<std::vec::Vec<crate::model::ActionTypeProperty>>,
/// <p>The links associated with the action type to be updated.</p>
#[doc(hidden)]
pub urls: std::option::Option<crate::model::ActionTypeUrls>,
}
impl ActionTypeDeclaration {
/// <p>The description for the action type to be updated.</p>
pub fn description(&self) -> std::option::Option<&str> {
self.description.as_deref()
}
/// <p>Information about the executor for an action type that was created with any supported integration model.</p>
pub fn executor(&self) -> std::option::Option<&crate::model::ActionTypeExecutor> {
self.executor.as_ref()
}
/// <p>The action category, owner, provider, and version of the action type to be updated.</p>
pub fn id(&self) -> std::option::Option<&crate::model::ActionTypeIdentifier> {
self.id.as_ref()
}
/// <p>Details for the artifacts, such as application files, to be worked on by the action. For example, the minimum and maximum number of input artifacts allowed.</p>
pub fn input_artifact_details(
&self,
) -> std::option::Option<&crate::model::ActionTypeArtifactDetails> {
self.input_artifact_details.as_ref()
}
/// <p>Details for the output artifacts, such as a built application, that are the result of the action. For example, the minimum and maximum number of output artifacts allowed.</p>
pub fn output_artifact_details(
&self,
) -> std::option::Option<&crate::model::ActionTypeArtifactDetails> {
self.output_artifact_details.as_ref()
}
/// <p>Details identifying the accounts with permissions to use the action type.</p>
pub fn permissions(&self) -> std::option::Option<&crate::model::ActionTypePermissions> {
self.permissions.as_ref()
}
/// <p>The properties of the action type to be updated.</p>
pub fn properties(&self) -> std::option::Option<&[crate::model::ActionTypeProperty]> {
self.properties.as_deref()
}
/// <p>The links associated with the action type to be updated.</p>
pub fn urls(&self) -> std::option::Option<&crate::model::ActionTypeUrls> {
self.urls.as_ref()
}
}
/// See [`ActionTypeDeclaration`](crate::model::ActionTypeDeclaration).
pub mod action_type_declaration {
/// A builder for [`ActionTypeDeclaration`](crate::model::ActionTypeDeclaration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) description: std::option::Option<std::string::String>,
pub(crate) executor: std::option::Option<crate::model::ActionTypeExecutor>,
pub(crate) id: std::option::Option<crate::model::ActionTypeIdentifier>,
pub(crate) input_artifact_details:
std::option::Option<crate::model::ActionTypeArtifactDetails>,
pub(crate) output_artifact_details:
std::option::Option<crate::model::ActionTypeArtifactDetails>,
pub(crate) permissions: std::option::Option<crate::model::ActionTypePermissions>,
pub(crate) properties: std::option::Option<std::vec::Vec<crate::model::ActionTypeProperty>>,
pub(crate) urls: std::option::Option<crate::model::ActionTypeUrls>,
}
impl Builder {
/// <p>The description for the action type to be updated.</p>
pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
self.description = Some(input.into());
self
}
/// <p>The description for the action type to be updated.</p>
pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
self.description = input;
self
}
/// <p>Information about the executor for an action type that was created with any supported integration model.</p>
pub fn executor(mut self, input: crate::model::ActionTypeExecutor) -> Self {
self.executor = Some(input);
self
}
/// <p>Information about the executor for an action type that was created with any supported integration model.</p>
pub fn set_executor(
mut self,
input: std::option::Option<crate::model::ActionTypeExecutor>,
) -> Self {
self.executor = input;
self
}
/// <p>The action category, owner, provider, and version of the action type to be updated.</p>
pub fn id(mut self, input: crate::model::ActionTypeIdentifier) -> Self {
self.id = Some(input);
self
}
/// <p>The action category, owner, provider, and version of the action type to be updated.</p>
pub fn set_id(
mut self,
input: std::option::Option<crate::model::ActionTypeIdentifier>,
) -> Self {
self.id = input;
self
}
/// <p>Details for the artifacts, such as application files, to be worked on by the action. For example, the minimum and maximum number of input artifacts allowed.</p>
pub fn input_artifact_details(
mut self,
input: crate::model::ActionTypeArtifactDetails,
) -> Self {
self.input_artifact_details = Some(input);
self
}
/// <p>Details for the artifacts, such as application files, to be worked on by the action. For example, the minimum and maximum number of input artifacts allowed.</p>
pub fn set_input_artifact_details(
mut self,
input: std::option::Option<crate::model::ActionTypeArtifactDetails>,
) -> Self {
self.input_artifact_details = input;
self
}
/// <p>Details for the output artifacts, such as a built application, that are the result of the action. For example, the minimum and maximum number of output artifacts allowed.</p>
pub fn output_artifact_details(
mut self,
input: crate::model::ActionTypeArtifactDetails,
) -> Self {
self.output_artifact_details = Some(input);
self
}
/// <p>Details for the output artifacts, such as a built application, that are the result of the action. For example, the minimum and maximum number of output artifacts allowed.</p>
pub fn set_output_artifact_details(
mut self,
input: std::option::Option<crate::model::ActionTypeArtifactDetails>,
) -> Self {
self.output_artifact_details = input;
self
}
/// <p>Details identifying the accounts with permissions to use the action type.</p>
pub fn permissions(mut self, input: crate::model::ActionTypePermissions) -> Self {
self.permissions = Some(input);
self
}
/// <p>Details identifying the accounts with permissions to use the action type.</p>
pub fn set_permissions(
mut self,
input: std::option::Option<crate::model::ActionTypePermissions>,
) -> Self {
self.permissions = input;
self
}
/// Appends an item to `properties`.
///
/// To override the contents of this collection use [`set_properties`](Self::set_properties).
///
/// <p>The properties of the action type to be updated.</p>
pub fn properties(mut self, input: crate::model::ActionTypeProperty) -> Self {
let mut v = self.properties.unwrap_or_default();
v.push(input);
self.properties = Some(v);
self
}
/// <p>The properties of the action type to be updated.</p>
pub fn set_properties(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ActionTypeProperty>>,
) -> Self {
self.properties = input;
self
}
/// <p>The links associated with the action type to be updated.</p>
pub fn urls(mut self, input: crate::model::ActionTypeUrls) -> Self {
self.urls = Some(input);
self
}
/// <p>The links associated with the action type to be updated.</p>
pub fn set_urls(
mut self,
input: std::option::Option<crate::model::ActionTypeUrls>,
) -> Self {
self.urls = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeDeclaration`](crate::model::ActionTypeDeclaration).
pub fn build(self) -> crate::model::ActionTypeDeclaration {
crate::model::ActionTypeDeclaration {
description: self.description,
executor: self.executor,
id: self.id,
input_artifact_details: self.input_artifact_details,
output_artifact_details: self.output_artifact_details,
permissions: self.permissions,
properties: self.properties,
urls: self.urls,
}
}
}
}
impl ActionTypeDeclaration {
/// Creates a new builder-style object to manufacture [`ActionTypeDeclaration`](crate::model::ActionTypeDeclaration).
pub fn builder() -> crate::model::action_type_declaration::Builder {
crate::model::action_type_declaration::Builder::default()
}
}
/// <p>Returns information about URLs for web pages that display to customers as links on the pipeline view, such as an external configuration page for the action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeUrls {
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can configure the external action.</p>
#[doc(hidden)]
pub configuration_url: std::option::Option<std::string::String>,
/// <p>The URL returned to the CodePipeline console that provides a deep link to the resources of the external system, such as a status page. This link is provided as part of the action display in the pipeline.</p>
#[doc(hidden)]
pub entity_url_template: std::option::Option<std::string::String>,
/// <p>The link to an execution page for the action type in progress. For example, for a CodeDeploy action, this link is shown on the pipeline view page in the CodePipeline console, and it links to a CodeDeploy status page.</p>
#[doc(hidden)]
pub execution_url_template: std::option::Option<std::string::String>,
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
#[doc(hidden)]
pub revision_url_template: std::option::Option<std::string::String>,
}
impl ActionTypeUrls {
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can configure the external action.</p>
pub fn configuration_url(&self) -> std::option::Option<&str> {
self.configuration_url.as_deref()
}
/// <p>The URL returned to the CodePipeline console that provides a deep link to the resources of the external system, such as a status page. This link is provided as part of the action display in the pipeline.</p>
pub fn entity_url_template(&self) -> std::option::Option<&str> {
self.entity_url_template.as_deref()
}
/// <p>The link to an execution page for the action type in progress. For example, for a CodeDeploy action, this link is shown on the pipeline view page in the CodePipeline console, and it links to a CodeDeploy status page.</p>
pub fn execution_url_template(&self) -> std::option::Option<&str> {
self.execution_url_template.as_deref()
}
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn revision_url_template(&self) -> std::option::Option<&str> {
self.revision_url_template.as_deref()
}
}
/// See [`ActionTypeUrls`](crate::model::ActionTypeUrls).
pub mod action_type_urls {
/// A builder for [`ActionTypeUrls`](crate::model::ActionTypeUrls).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) configuration_url: std::option::Option<std::string::String>,
pub(crate) entity_url_template: std::option::Option<std::string::String>,
pub(crate) execution_url_template: std::option::Option<std::string::String>,
pub(crate) revision_url_template: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can configure the external action.</p>
pub fn configuration_url(mut self, input: impl Into<std::string::String>) -> Self {
self.configuration_url = Some(input.into());
self
}
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can configure the external action.</p>
pub fn set_configuration_url(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.configuration_url = input;
self
}
/// <p>The URL returned to the CodePipeline console that provides a deep link to the resources of the external system, such as a status page. This link is provided as part of the action display in the pipeline.</p>
pub fn entity_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.entity_url_template = Some(input.into());
self
}
/// <p>The URL returned to the CodePipeline console that provides a deep link to the resources of the external system, such as a status page. This link is provided as part of the action display in the pipeline.</p>
pub fn set_entity_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.entity_url_template = input;
self
}
/// <p>The link to an execution page for the action type in progress. For example, for a CodeDeploy action, this link is shown on the pipeline view page in the CodePipeline console, and it links to a CodeDeploy status page.</p>
pub fn execution_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.execution_url_template = Some(input.into());
self
}
/// <p>The link to an execution page for the action type in progress. For example, for a CodeDeploy action, this link is shown on the pipeline view page in the CodePipeline console, and it links to a CodeDeploy status page.</p>
pub fn set_execution_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.execution_url_template = input;
self
}
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn revision_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_url_template = Some(input.into());
self
}
/// <p>The URL returned to the CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn set_revision_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_url_template = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeUrls`](crate::model::ActionTypeUrls).
pub fn build(self) -> crate::model::ActionTypeUrls {
crate::model::ActionTypeUrls {
configuration_url: self.configuration_url,
entity_url_template: self.entity_url_template,
execution_url_template: self.execution_url_template,
revision_url_template: self.revision_url_template,
}
}
}
}
impl ActionTypeUrls {
/// Creates a new builder-style object to manufacture [`ActionTypeUrls`](crate::model::ActionTypeUrls).
pub fn builder() -> crate::model::action_type_urls::Builder {
crate::model::action_type_urls::Builder::default()
}
}
/// <p>Represents information about each property specified in the action configuration, such as the description and key name that display for the customer using the action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeProperty {
/// <p>The property name that is displayed to users.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>Whether the configuration property is an optional value.</p>
#[doc(hidden)]
pub optional: bool,
/// <p>Whether the configuration property is a key.</p>
#[doc(hidden)]
pub key: bool,
/// <p>Whether to omit the field value entered by the customer in the log. If <code>true</code>, the value is not saved in CloudTrail logs for the action execution.</p>
#[doc(hidden)]
pub no_echo: bool,
/// <p>Indicates that the property is used with polling. An action type can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
#[doc(hidden)]
pub queryable: bool,
/// <p>The description of the property that is displayed to users.</p>
#[doc(hidden)]
pub description: std::option::Option<std::string::String>,
}
impl ActionTypeProperty {
/// <p>The property name that is displayed to users.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>Whether the configuration property is an optional value.</p>
pub fn optional(&self) -> bool {
self.optional
}
/// <p>Whether the configuration property is a key.</p>
pub fn key(&self) -> bool {
self.key
}
/// <p>Whether to omit the field value entered by the customer in the log. If <code>true</code>, the value is not saved in CloudTrail logs for the action execution.</p>
pub fn no_echo(&self) -> bool {
self.no_echo
}
/// <p>Indicates that the property is used with polling. An action type can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
pub fn queryable(&self) -> bool {
self.queryable
}
/// <p>The description of the property that is displayed to users.</p>
pub fn description(&self) -> std::option::Option<&str> {
self.description.as_deref()
}
}
/// See [`ActionTypeProperty`](crate::model::ActionTypeProperty).
pub mod action_type_property {
/// A builder for [`ActionTypeProperty`](crate::model::ActionTypeProperty).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) optional: std::option::Option<bool>,
pub(crate) key: std::option::Option<bool>,
pub(crate) no_echo: std::option::Option<bool>,
pub(crate) queryable: std::option::Option<bool>,
pub(crate) description: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The property name that is displayed to users.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The property name that is displayed to users.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>Whether the configuration property is an optional value.</p>
pub fn optional(mut self, input: bool) -> Self {
self.optional = Some(input);
self
}
/// <p>Whether the configuration property is an optional value.</p>
pub fn set_optional(mut self, input: std::option::Option<bool>) -> Self {
self.optional = input;
self
}
/// <p>Whether the configuration property is a key.</p>
pub fn key(mut self, input: bool) -> Self {
self.key = Some(input);
self
}
/// <p>Whether the configuration property is a key.</p>
pub fn set_key(mut self, input: std::option::Option<bool>) -> Self {
self.key = input;
self
}
/// <p>Whether to omit the field value entered by the customer in the log. If <code>true</code>, the value is not saved in CloudTrail logs for the action execution.</p>
pub fn no_echo(mut self, input: bool) -> Self {
self.no_echo = Some(input);
self
}
/// <p>Whether to omit the field value entered by the customer in the log. If <code>true</code>, the value is not saved in CloudTrail logs for the action execution.</p>
pub fn set_no_echo(mut self, input: std::option::Option<bool>) -> Self {
self.no_echo = input;
self
}
/// <p>Indicates that the property is used with polling. An action type can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
pub fn queryable(mut self, input: bool) -> Self {
self.queryable = Some(input);
self
}
/// <p>Indicates that the property is used with polling. An action type can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
pub fn set_queryable(mut self, input: std::option::Option<bool>) -> Self {
self.queryable = input;
self
}
/// <p>The description of the property that is displayed to users.</p>
pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
self.description = Some(input.into());
self
}
/// <p>The description of the property that is displayed to users.</p>
pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
self.description = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeProperty`](crate::model::ActionTypeProperty).
pub fn build(self) -> crate::model::ActionTypeProperty {
crate::model::ActionTypeProperty {
name: self.name,
optional: self.optional.unwrap_or_default(),
key: self.key.unwrap_or_default(),
no_echo: self.no_echo.unwrap_or_default(),
queryable: self.queryable.unwrap_or_default(),
description: self.description,
}
}
}
}
impl ActionTypeProperty {
/// Creates a new builder-style object to manufacture [`ActionTypeProperty`](crate::model::ActionTypeProperty).
pub fn builder() -> crate::model::action_type_property::Builder {
crate::model::action_type_property::Builder::default()
}
}
/// <p>Details identifying the users with permissions to use the action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypePermissions {
/// <p>A list of AWS account IDs with access to use the action type in their pipelines.</p>
#[doc(hidden)]
pub allowed_accounts: std::option::Option<std::vec::Vec<std::string::String>>,
}
impl ActionTypePermissions {
/// <p>A list of AWS account IDs with access to use the action type in their pipelines.</p>
pub fn allowed_accounts(&self) -> std::option::Option<&[std::string::String]> {
self.allowed_accounts.as_deref()
}
}
/// See [`ActionTypePermissions`](crate::model::ActionTypePermissions).
pub mod action_type_permissions {
/// A builder for [`ActionTypePermissions`](crate::model::ActionTypePermissions).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) allowed_accounts: std::option::Option<std::vec::Vec<std::string::String>>,
}
impl Builder {
/// Appends an item to `allowed_accounts`.
///
/// To override the contents of this collection use [`set_allowed_accounts`](Self::set_allowed_accounts).
///
/// <p>A list of AWS account IDs with access to use the action type in their pipelines.</p>
pub fn allowed_accounts(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.allowed_accounts.unwrap_or_default();
v.push(input.into());
self.allowed_accounts = Some(v);
self
}
/// <p>A list of AWS account IDs with access to use the action type in their pipelines.</p>
pub fn set_allowed_accounts(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.allowed_accounts = input;
self
}
/// Consumes the builder and constructs a [`ActionTypePermissions`](crate::model::ActionTypePermissions).
pub fn build(self) -> crate::model::ActionTypePermissions {
crate::model::ActionTypePermissions {
allowed_accounts: self.allowed_accounts,
}
}
}
}
impl ActionTypePermissions {
/// Creates a new builder-style object to manufacture [`ActionTypePermissions`](crate::model::ActionTypePermissions).
pub fn builder() -> crate::model::action_type_permissions::Builder {
crate::model::action_type_permissions::Builder::default()
}
}
/// <p>Information about parameters for artifacts associated with the action type, such as the minimum and maximum artifacts allowed.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeArtifactDetails {
/// <p>The minimum number of artifacts that can be used with the action type. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
#[doc(hidden)]
pub minimum_count: i32,
/// <p>The maximum number of artifacts that can be used with the actiontype. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
#[doc(hidden)]
pub maximum_count: i32,
}
impl ActionTypeArtifactDetails {
/// <p>The minimum number of artifacts that can be used with the action type. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn minimum_count(&self) -> i32 {
self.minimum_count
}
/// <p>The maximum number of artifacts that can be used with the actiontype. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn maximum_count(&self) -> i32 {
self.maximum_count
}
}
/// See [`ActionTypeArtifactDetails`](crate::model::ActionTypeArtifactDetails).
pub mod action_type_artifact_details {
/// A builder for [`ActionTypeArtifactDetails`](crate::model::ActionTypeArtifactDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) minimum_count: std::option::Option<i32>,
pub(crate) maximum_count: std::option::Option<i32>,
}
impl Builder {
/// <p>The minimum number of artifacts that can be used with the action type. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn minimum_count(mut self, input: i32) -> Self {
self.minimum_count = Some(input);
self
}
/// <p>The minimum number of artifacts that can be used with the action type. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn set_minimum_count(mut self, input: std::option::Option<i32>) -> Self {
self.minimum_count = input;
self
}
/// <p>The maximum number of artifacts that can be used with the actiontype. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn maximum_count(mut self, input: i32) -> Self {
self.maximum_count = Some(input);
self
}
/// <p>The maximum number of artifacts that can be used with the actiontype. For example, you should specify a minimum and maximum of zero input artifacts for an action type with a category of <code>source</code>.</p>
pub fn set_maximum_count(mut self, input: std::option::Option<i32>) -> Self {
self.maximum_count = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeArtifactDetails`](crate::model::ActionTypeArtifactDetails).
pub fn build(self) -> crate::model::ActionTypeArtifactDetails {
crate::model::ActionTypeArtifactDetails {
minimum_count: self.minimum_count.unwrap_or_default(),
maximum_count: self.maximum_count.unwrap_or_default(),
}
}
}
}
impl ActionTypeArtifactDetails {
/// Creates a new builder-style object to manufacture [`ActionTypeArtifactDetails`](crate::model::ActionTypeArtifactDetails).
pub fn builder() -> crate::model::action_type_artifact_details::Builder {
crate::model::action_type_artifact_details::Builder::default()
}
}
/// <p>Specifies the category, owner, provider, and version of the action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeIdentifier {
/// <p>Defines what kind of action can be taken in the stage, one of the following:</p>
/// <ul>
/// <li> <p> <code>Source</code> </p> </li>
/// <li> <p> <code>Build</code> </p> </li>
/// <li> <p> <code>Test</code> </p> </li>
/// <li> <p> <code>Deploy</code> </p> </li>
/// <li> <p> <code>Approval</code> </p> </li>
/// <li> <p> <code>Invoke</code> </p> </li>
/// </ul>
#[doc(hidden)]
pub category: std::option::Option<crate::model::ActionCategory>,
/// <p>The creator of the action type being called: <code>AWS</code> or <code>ThirdParty</code>.</p>
#[doc(hidden)]
pub owner: std::option::Option<std::string::String>,
/// <p>The provider of the action type being called. The provider name is supplied when the action type is created.</p>
#[doc(hidden)]
pub provider: std::option::Option<std::string::String>,
/// <p>A string that describes the action type version.</p>
#[doc(hidden)]
pub version: std::option::Option<std::string::String>,
}
impl ActionTypeIdentifier {
/// <p>Defines what kind of action can be taken in the stage, one of the following:</p>
/// <ul>
/// <li> <p> <code>Source</code> </p> </li>
/// <li> <p> <code>Build</code> </p> </li>
/// <li> <p> <code>Test</code> </p> </li>
/// <li> <p> <code>Deploy</code> </p> </li>
/// <li> <p> <code>Approval</code> </p> </li>
/// <li> <p> <code>Invoke</code> </p> </li>
/// </ul>
pub fn category(&self) -> std::option::Option<&crate::model::ActionCategory> {
self.category.as_ref()
}
/// <p>The creator of the action type being called: <code>AWS</code> or <code>ThirdParty</code>.</p>
pub fn owner(&self) -> std::option::Option<&str> {
self.owner.as_deref()
}
/// <p>The provider of the action type being called. The provider name is supplied when the action type is created.</p>
pub fn provider(&self) -> std::option::Option<&str> {
self.provider.as_deref()
}
/// <p>A string that describes the action type version.</p>
pub fn version(&self) -> std::option::Option<&str> {
self.version.as_deref()
}
}
/// See [`ActionTypeIdentifier`](crate::model::ActionTypeIdentifier).
pub mod action_type_identifier {
/// A builder for [`ActionTypeIdentifier`](crate::model::ActionTypeIdentifier).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) category: std::option::Option<crate::model::ActionCategory>,
pub(crate) owner: std::option::Option<std::string::String>,
pub(crate) provider: std::option::Option<std::string::String>,
pub(crate) version: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>Defines what kind of action can be taken in the stage, one of the following:</p>
/// <ul>
/// <li> <p> <code>Source</code> </p> </li>
/// <li> <p> <code>Build</code> </p> </li>
/// <li> <p> <code>Test</code> </p> </li>
/// <li> <p> <code>Deploy</code> </p> </li>
/// <li> <p> <code>Approval</code> </p> </li>
/// <li> <p> <code>Invoke</code> </p> </li>
/// </ul>
pub fn category(mut self, input: crate::model::ActionCategory) -> Self {
self.category = Some(input);
self
}
/// <p>Defines what kind of action can be taken in the stage, one of the following:</p>
/// <ul>
/// <li> <p> <code>Source</code> </p> </li>
/// <li> <p> <code>Build</code> </p> </li>
/// <li> <p> <code>Test</code> </p> </li>
/// <li> <p> <code>Deploy</code> </p> </li>
/// <li> <p> <code>Approval</code> </p> </li>
/// <li> <p> <code>Invoke</code> </p> </li>
/// </ul>
pub fn set_category(
mut self,
input: std::option::Option<crate::model::ActionCategory>,
) -> Self {
self.category = input;
self
}
/// <p>The creator of the action type being called: <code>AWS</code> or <code>ThirdParty</code>.</p>
pub fn owner(mut self, input: impl Into<std::string::String>) -> Self {
self.owner = Some(input.into());
self
}
/// <p>The creator of the action type being called: <code>AWS</code> or <code>ThirdParty</code>.</p>
pub fn set_owner(mut self, input: std::option::Option<std::string::String>) -> Self {
self.owner = input;
self
}
/// <p>The provider of the action type being called. The provider name is supplied when the action type is created.</p>
pub fn provider(mut self, input: impl Into<std::string::String>) -> Self {
self.provider = Some(input.into());
self
}
/// <p>The provider of the action type being called. The provider name is supplied when the action type is created.</p>
pub fn set_provider(mut self, input: std::option::Option<std::string::String>) -> Self {
self.provider = input;
self
}
/// <p>A string that describes the action type version.</p>
pub fn version(mut self, input: impl Into<std::string::String>) -> Self {
self.version = Some(input.into());
self
}
/// <p>A string that describes the action type version.</p>
pub fn set_version(mut self, input: std::option::Option<std::string::String>) -> Self {
self.version = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeIdentifier`](crate::model::ActionTypeIdentifier).
pub fn build(self) -> crate::model::ActionTypeIdentifier {
crate::model::ActionTypeIdentifier {
category: self.category,
owner: self.owner,
provider: self.provider,
version: self.version,
}
}
}
}
impl ActionTypeIdentifier {
/// Creates a new builder-style object to manufacture [`ActionTypeIdentifier`](crate::model::ActionTypeIdentifier).
pub fn builder() -> crate::model::action_type_identifier::Builder {
crate::model::action_type_identifier::Builder::default()
}
}
/// <p>The action engine, or executor, for an action type created for a provider, where the action is to be used by customers of the provider. The action engine is associated with the model used to create and update the action, such as the Lambda integration model.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeExecutor {
/// <p>The action configuration properties for the action type. These properties are specified in the action definition when the action type is created.</p>
#[doc(hidden)]
pub configuration: std::option::Option<crate::model::ExecutorConfiguration>,
/// <p>The integration model used to create and update the action type, <code>Lambda</code> or <code>JobWorker</code>. </p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::ExecutorType>,
/// <p>The policy statement that specifies the permissions in the CodePipeline customer’s account that are needed to successfully run an action.</p>
/// <p>To grant permission to another account, specify the account ID as the Principal, a domain-style identifier defined by the service, for example <code>codepipeline.amazonaws.com</code>.</p> <note>
/// <p>The size of the passed JSON policy document cannot exceed 2048 characters.</p>
/// </note>
#[doc(hidden)]
pub policy_statements_template: std::option::Option<std::string::String>,
/// <p>The timeout in seconds for the job. An action execution can have multiple jobs. This is the timeout for a single job, not the entire action execution.</p>
#[doc(hidden)]
pub job_timeout: std::option::Option<i32>,
}
impl ActionTypeExecutor {
/// <p>The action configuration properties for the action type. These properties are specified in the action definition when the action type is created.</p>
pub fn configuration(&self) -> std::option::Option<&crate::model::ExecutorConfiguration> {
self.configuration.as_ref()
}
/// <p>The integration model used to create and update the action type, <code>Lambda</code> or <code>JobWorker</code>. </p>
pub fn r#type(&self) -> std::option::Option<&crate::model::ExecutorType> {
self.r#type.as_ref()
}
/// <p>The policy statement that specifies the permissions in the CodePipeline customer’s account that are needed to successfully run an action.</p>
/// <p>To grant permission to another account, specify the account ID as the Principal, a domain-style identifier defined by the service, for example <code>codepipeline.amazonaws.com</code>.</p> <note>
/// <p>The size of the passed JSON policy document cannot exceed 2048 characters.</p>
/// </note>
pub fn policy_statements_template(&self) -> std::option::Option<&str> {
self.policy_statements_template.as_deref()
}
/// <p>The timeout in seconds for the job. An action execution can have multiple jobs. This is the timeout for a single job, not the entire action execution.</p>
pub fn job_timeout(&self) -> std::option::Option<i32> {
self.job_timeout
}
}
/// See [`ActionTypeExecutor`](crate::model::ActionTypeExecutor).
pub mod action_type_executor {
/// A builder for [`ActionTypeExecutor`](crate::model::ActionTypeExecutor).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) configuration: std::option::Option<crate::model::ExecutorConfiguration>,
pub(crate) r#type: std::option::Option<crate::model::ExecutorType>,
pub(crate) policy_statements_template: std::option::Option<std::string::String>,
pub(crate) job_timeout: std::option::Option<i32>,
}
impl Builder {
/// <p>The action configuration properties for the action type. These properties are specified in the action definition when the action type is created.</p>
pub fn configuration(mut self, input: crate::model::ExecutorConfiguration) -> Self {
self.configuration = Some(input);
self
}
/// <p>The action configuration properties for the action type. These properties are specified in the action definition when the action type is created.</p>
pub fn set_configuration(
mut self,
input: std::option::Option<crate::model::ExecutorConfiguration>,
) -> Self {
self.configuration = input;
self
}
/// <p>The integration model used to create and update the action type, <code>Lambda</code> or <code>JobWorker</code>. </p>
pub fn r#type(mut self, input: crate::model::ExecutorType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The integration model used to create and update the action type, <code>Lambda</code> or <code>JobWorker</code>. </p>
pub fn set_type(mut self, input: std::option::Option<crate::model::ExecutorType>) -> Self {
self.r#type = input;
self
}
/// <p>The policy statement that specifies the permissions in the CodePipeline customer’s account that are needed to successfully run an action.</p>
/// <p>To grant permission to another account, specify the account ID as the Principal, a domain-style identifier defined by the service, for example <code>codepipeline.amazonaws.com</code>.</p> <note>
/// <p>The size of the passed JSON policy document cannot exceed 2048 characters.</p>
/// </note>
pub fn policy_statements_template(mut self, input: impl Into<std::string::String>) -> Self {
self.policy_statements_template = Some(input.into());
self
}
/// <p>The policy statement that specifies the permissions in the CodePipeline customer’s account that are needed to successfully run an action.</p>
/// <p>To grant permission to another account, specify the account ID as the Principal, a domain-style identifier defined by the service, for example <code>codepipeline.amazonaws.com</code>.</p> <note>
/// <p>The size of the passed JSON policy document cannot exceed 2048 characters.</p>
/// </note>
pub fn set_policy_statements_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.policy_statements_template = input;
self
}
/// <p>The timeout in seconds for the job. An action execution can have multiple jobs. This is the timeout for a single job, not the entire action execution.</p>
pub fn job_timeout(mut self, input: i32) -> Self {
self.job_timeout = Some(input);
self
}
/// <p>The timeout in seconds for the job. An action execution can have multiple jobs. This is the timeout for a single job, not the entire action execution.</p>
pub fn set_job_timeout(mut self, input: std::option::Option<i32>) -> Self {
self.job_timeout = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeExecutor`](crate::model::ActionTypeExecutor).
pub fn build(self) -> crate::model::ActionTypeExecutor {
crate::model::ActionTypeExecutor {
configuration: self.configuration,
r#type: self.r#type,
policy_statements_template: self.policy_statements_template,
job_timeout: self.job_timeout,
}
}
}
}
impl ActionTypeExecutor {
/// Creates a new builder-style object to manufacture [`ActionTypeExecutor`](crate::model::ActionTypeExecutor).
pub fn builder() -> crate::model::action_type_executor::Builder {
crate::model::action_type_executor::Builder::default()
}
}
/// When writing a match expression against `ExecutorType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let executortype = unimplemented!();
/// match executortype {
/// ExecutorType::JobWorker => { /* ... */ },
/// ExecutorType::Lambda => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `executortype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ExecutorType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ExecutorType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ExecutorType::NewFeature` is defined.
/// Specifically, when `executortype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ExecutorType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ExecutorType {
#[allow(missing_docs)] // documentation missing in model
JobWorker,
#[allow(missing_docs)] // documentation missing in model
Lambda,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ExecutorType {
fn from(s: &str) -> Self {
match s {
"JobWorker" => ExecutorType::JobWorker,
"Lambda" => ExecutorType::Lambda,
other => ExecutorType::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for ExecutorType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ExecutorType::from(s))
}
}
impl ExecutorType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ExecutorType::JobWorker => "JobWorker",
ExecutorType::Lambda => "Lambda",
ExecutorType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["JobWorker", "Lambda"]
}
}
impl AsRef<str> for ExecutorType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The action engine, or executor, related to the supported integration model used to create and update the action type. The available executor types are <code>Lambda</code> and <code>JobWorker</code>.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ExecutorConfiguration {
/// <p>Details about the <code>Lambda</code> executor of the action type.</p>
#[doc(hidden)]
pub lambda_executor_configuration:
std::option::Option<crate::model::LambdaExecutorConfiguration>,
/// <p>Details about the <code>JobWorker</code> executor of the action type.</p>
#[doc(hidden)]
pub job_worker_executor_configuration:
std::option::Option<crate::model::JobWorkerExecutorConfiguration>,
}
impl ExecutorConfiguration {
/// <p>Details about the <code>Lambda</code> executor of the action type.</p>
pub fn lambda_executor_configuration(
&self,
) -> std::option::Option<&crate::model::LambdaExecutorConfiguration> {
self.lambda_executor_configuration.as_ref()
}
/// <p>Details about the <code>JobWorker</code> executor of the action type.</p>
pub fn job_worker_executor_configuration(
&self,
) -> std::option::Option<&crate::model::JobWorkerExecutorConfiguration> {
self.job_worker_executor_configuration.as_ref()
}
}
/// See [`ExecutorConfiguration`](crate::model::ExecutorConfiguration).
pub mod executor_configuration {
/// A builder for [`ExecutorConfiguration`](crate::model::ExecutorConfiguration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) lambda_executor_configuration:
std::option::Option<crate::model::LambdaExecutorConfiguration>,
pub(crate) job_worker_executor_configuration:
std::option::Option<crate::model::JobWorkerExecutorConfiguration>,
}
impl Builder {
/// <p>Details about the <code>Lambda</code> executor of the action type.</p>
pub fn lambda_executor_configuration(
mut self,
input: crate::model::LambdaExecutorConfiguration,
) -> Self {
self.lambda_executor_configuration = Some(input);
self
}
/// <p>Details about the <code>Lambda</code> executor of the action type.</p>
pub fn set_lambda_executor_configuration(
mut self,
input: std::option::Option<crate::model::LambdaExecutorConfiguration>,
) -> Self {
self.lambda_executor_configuration = input;
self
}
/// <p>Details about the <code>JobWorker</code> executor of the action type.</p>
pub fn job_worker_executor_configuration(
mut self,
input: crate::model::JobWorkerExecutorConfiguration,
) -> Self {
self.job_worker_executor_configuration = Some(input);
self
}
/// <p>Details about the <code>JobWorker</code> executor of the action type.</p>
pub fn set_job_worker_executor_configuration(
mut self,
input: std::option::Option<crate::model::JobWorkerExecutorConfiguration>,
) -> Self {
self.job_worker_executor_configuration = input;
self
}
/// Consumes the builder and constructs a [`ExecutorConfiguration`](crate::model::ExecutorConfiguration).
pub fn build(self) -> crate::model::ExecutorConfiguration {
crate::model::ExecutorConfiguration {
lambda_executor_configuration: self.lambda_executor_configuration,
job_worker_executor_configuration: self.job_worker_executor_configuration,
}
}
}
}
impl ExecutorConfiguration {
/// Creates a new builder-style object to manufacture [`ExecutorConfiguration`](crate::model::ExecutorConfiguration).
pub fn builder() -> crate::model::executor_configuration::Builder {
crate::model::executor_configuration::Builder::default()
}
}
/// <p>Details about the polling configuration for the <code>JobWorker</code> action engine, or executor.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct JobWorkerExecutorConfiguration {
/// <p>The accounts in which the job worker is configured and might poll for jobs as part of the action execution.</p>
#[doc(hidden)]
pub polling_accounts: std::option::Option<std::vec::Vec<std::string::String>>,
/// <p>The service Principals in which the job worker is configured and might poll for jobs as part of the action execution.</p>
#[doc(hidden)]
pub polling_service_principals: std::option::Option<std::vec::Vec<std::string::String>>,
}
impl JobWorkerExecutorConfiguration {
/// <p>The accounts in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn polling_accounts(&self) -> std::option::Option<&[std::string::String]> {
self.polling_accounts.as_deref()
}
/// <p>The service Principals in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn polling_service_principals(&self) -> std::option::Option<&[std::string::String]> {
self.polling_service_principals.as_deref()
}
}
/// See [`JobWorkerExecutorConfiguration`](crate::model::JobWorkerExecutorConfiguration).
pub mod job_worker_executor_configuration {
/// A builder for [`JobWorkerExecutorConfiguration`](crate::model::JobWorkerExecutorConfiguration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) polling_accounts: std::option::Option<std::vec::Vec<std::string::String>>,
pub(crate) polling_service_principals:
std::option::Option<std::vec::Vec<std::string::String>>,
}
impl Builder {
/// Appends an item to `polling_accounts`.
///
/// To override the contents of this collection use [`set_polling_accounts`](Self::set_polling_accounts).
///
/// <p>The accounts in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn polling_accounts(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.polling_accounts.unwrap_or_default();
v.push(input.into());
self.polling_accounts = Some(v);
self
}
/// <p>The accounts in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn set_polling_accounts(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.polling_accounts = input;
self
}
/// Appends an item to `polling_service_principals`.
///
/// To override the contents of this collection use [`set_polling_service_principals`](Self::set_polling_service_principals).
///
/// <p>The service Principals in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn polling_service_principals(mut self, input: impl Into<std::string::String>) -> Self {
let mut v = self.polling_service_principals.unwrap_or_default();
v.push(input.into());
self.polling_service_principals = Some(v);
self
}
/// <p>The service Principals in which the job worker is configured and might poll for jobs as part of the action execution.</p>
pub fn set_polling_service_principals(
mut self,
input: std::option::Option<std::vec::Vec<std::string::String>>,
) -> Self {
self.polling_service_principals = input;
self
}
/// Consumes the builder and constructs a [`JobWorkerExecutorConfiguration`](crate::model::JobWorkerExecutorConfiguration).
pub fn build(self) -> crate::model::JobWorkerExecutorConfiguration {
crate::model::JobWorkerExecutorConfiguration {
polling_accounts: self.polling_accounts,
polling_service_principals: self.polling_service_principals,
}
}
}
}
impl JobWorkerExecutorConfiguration {
/// Creates a new builder-style object to manufacture [`JobWorkerExecutorConfiguration`](crate::model::JobWorkerExecutorConfiguration).
pub fn builder() -> crate::model::job_worker_executor_configuration::Builder {
crate::model::job_worker_executor_configuration::Builder::default()
}
}
/// <p>Details about the configuration for the <code>Lambda</code> action engine, or executor.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct LambdaExecutorConfiguration {
/// <p>The ARN of the Lambda function used by the action engine.</p>
#[doc(hidden)]
pub lambda_function_arn: std::option::Option<std::string::String>,
}
impl LambdaExecutorConfiguration {
/// <p>The ARN of the Lambda function used by the action engine.</p>
pub fn lambda_function_arn(&self) -> std::option::Option<&str> {
self.lambda_function_arn.as_deref()
}
}
/// See [`LambdaExecutorConfiguration`](crate::model::LambdaExecutorConfiguration).
pub mod lambda_executor_configuration {
/// A builder for [`LambdaExecutorConfiguration`](crate::model::LambdaExecutorConfiguration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) lambda_function_arn: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The ARN of the Lambda function used by the action engine.</p>
pub fn lambda_function_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.lambda_function_arn = Some(input.into());
self
}
/// <p>The ARN of the Lambda function used by the action engine.</p>
pub fn set_lambda_function_arn(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.lambda_function_arn = input;
self
}
/// Consumes the builder and constructs a [`LambdaExecutorConfiguration`](crate::model::LambdaExecutorConfiguration).
pub fn build(self) -> crate::model::LambdaExecutorConfiguration {
crate::model::LambdaExecutorConfiguration {
lambda_function_arn: self.lambda_function_arn,
}
}
}
}
impl LambdaExecutorConfiguration {
/// Creates a new builder-style object to manufacture [`LambdaExecutorConfiguration`](crate::model::LambdaExecutorConfiguration).
pub fn builder() -> crate::model::lambda_executor_configuration::Builder {
crate::model::lambda_executor_configuration::Builder::default()
}
}
/// <p>A tag is a key-value pair that is used to manage the resource.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Tag {
/// <p>The tag's key.</p>
#[doc(hidden)]
pub key: std::option::Option<std::string::String>,
/// <p>The tag's value.</p>
#[doc(hidden)]
pub value: std::option::Option<std::string::String>,
}
impl Tag {
/// <p>The tag's key.</p>
pub fn key(&self) -> std::option::Option<&str> {
self.key.as_deref()
}
/// <p>The tag's value.</p>
pub fn value(&self) -> std::option::Option<&str> {
self.value.as_deref()
}
}
/// See [`Tag`](crate::model::Tag).
pub mod tag {
/// A builder for [`Tag`](crate::model::Tag).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) key: std::option::Option<std::string::String>,
pub(crate) value: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The tag's key.</p>
pub fn key(mut self, input: impl Into<std::string::String>) -> Self {
self.key = Some(input.into());
self
}
/// <p>The tag's key.</p>
pub fn set_key(mut self, input: std::option::Option<std::string::String>) -> Self {
self.key = input;
self
}
/// <p>The tag's value.</p>
pub fn value(mut self, input: impl Into<std::string::String>) -> Self {
self.value = Some(input.into());
self
}
/// <p>The tag's value.</p>
pub fn set_value(mut self, input: std::option::Option<std::string::String>) -> Self {
self.value = input;
self
}
/// Consumes the builder and constructs a [`Tag`](crate::model::Tag).
pub fn build(self) -> crate::model::Tag {
crate::model::Tag {
key: self.key,
value: self.value,
}
}
}
}
impl Tag {
/// Creates a new builder-style object to manufacture [`Tag`](crate::model::Tag).
pub fn builder() -> crate::model::tag::Builder {
crate::model::tag::Builder::default()
}
}
/// When writing a match expression against `StageRetryMode`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let stageretrymode = unimplemented!();
/// match stageretrymode {
/// StageRetryMode::FailedActions => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `stageretrymode` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `StageRetryMode::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `StageRetryMode::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `StageRetryMode::NewFeature` is defined.
/// Specifically, when `stageretrymode` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `StageRetryMode::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum StageRetryMode {
#[allow(missing_docs)] // documentation missing in model
FailedActions,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for StageRetryMode {
fn from(s: &str) -> Self {
match s {
"FAILED_ACTIONS" => StageRetryMode::FailedActions,
other => StageRetryMode::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for StageRetryMode {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(StageRetryMode::from(s))
}
}
impl StageRetryMode {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
StageRetryMode::FailedActions => "FAILED_ACTIONS",
StageRetryMode::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["FAILED_ACTIONS"]
}
}
impl AsRef<str> for StageRetryMode {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The detail returned for each webhook after listing webhooks, such as the webhook URL, the webhook name, and the webhook ARN.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ListWebhookItem {
/// <p>The detail returned for each webhook, such as the webhook authentication type and filter rules.</p>
#[doc(hidden)]
pub definition: std::option::Option<crate::model::WebhookDefinition>,
/// <p>A unique URL generated by CodePipeline. When a POST request is made to this URL, the defined pipeline is started as long as the body of the post request satisfies the defined authentication and filtering conditions. Deleting and re-creating a webhook makes the old URL invalid and generates a new one.</p>
#[doc(hidden)]
pub url: std::option::Option<std::string::String>,
/// <p>The text of the error message about the webhook.</p>
#[doc(hidden)]
pub error_message: std::option::Option<std::string::String>,
/// <p>The number code of the error.</p>
#[doc(hidden)]
pub error_code: std::option::Option<std::string::String>,
/// <p>The date and time a webhook was last successfully triggered, in timestamp format.</p>
#[doc(hidden)]
pub last_triggered: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The Amazon Resource Name (ARN) of the webhook.</p>
#[doc(hidden)]
pub arn: std::option::Option<std::string::String>,
/// <p>Specifies the tags applied to the webhook.</p>
#[doc(hidden)]
pub tags: std::option::Option<std::vec::Vec<crate::model::Tag>>,
}
impl ListWebhookItem {
/// <p>The detail returned for each webhook, such as the webhook authentication type and filter rules.</p>
pub fn definition(&self) -> std::option::Option<&crate::model::WebhookDefinition> {
self.definition.as_ref()
}
/// <p>A unique URL generated by CodePipeline. When a POST request is made to this URL, the defined pipeline is started as long as the body of the post request satisfies the defined authentication and filtering conditions. Deleting and re-creating a webhook makes the old URL invalid and generates a new one.</p>
pub fn url(&self) -> std::option::Option<&str> {
self.url.as_deref()
}
/// <p>The text of the error message about the webhook.</p>
pub fn error_message(&self) -> std::option::Option<&str> {
self.error_message.as_deref()
}
/// <p>The number code of the error.</p>
pub fn error_code(&self) -> std::option::Option<&str> {
self.error_code.as_deref()
}
/// <p>The date and time a webhook was last successfully triggered, in timestamp format.</p>
pub fn last_triggered(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_triggered.as_ref()
}
/// <p>The Amazon Resource Name (ARN) of the webhook.</p>
pub fn arn(&self) -> std::option::Option<&str> {
self.arn.as_deref()
}
/// <p>Specifies the tags applied to the webhook.</p>
pub fn tags(&self) -> std::option::Option<&[crate::model::Tag]> {
self.tags.as_deref()
}
}
/// See [`ListWebhookItem`](crate::model::ListWebhookItem).
pub mod list_webhook_item {
/// A builder for [`ListWebhookItem`](crate::model::ListWebhookItem).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) definition: std::option::Option<crate::model::WebhookDefinition>,
pub(crate) url: std::option::Option<std::string::String>,
pub(crate) error_message: std::option::Option<std::string::String>,
pub(crate) error_code: std::option::Option<std::string::String>,
pub(crate) last_triggered: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) arn: std::option::Option<std::string::String>,
pub(crate) tags: std::option::Option<std::vec::Vec<crate::model::Tag>>,
}
impl Builder {
/// <p>The detail returned for each webhook, such as the webhook authentication type and filter rules.</p>
pub fn definition(mut self, input: crate::model::WebhookDefinition) -> Self {
self.definition = Some(input);
self
}
/// <p>The detail returned for each webhook, such as the webhook authentication type and filter rules.</p>
pub fn set_definition(
mut self,
input: std::option::Option<crate::model::WebhookDefinition>,
) -> Self {
self.definition = input;
self
}
/// <p>A unique URL generated by CodePipeline. When a POST request is made to this URL, the defined pipeline is started as long as the body of the post request satisfies the defined authentication and filtering conditions. Deleting and re-creating a webhook makes the old URL invalid and generates a new one.</p>
pub fn url(mut self, input: impl Into<std::string::String>) -> Self {
self.url = Some(input.into());
self
}
/// <p>A unique URL generated by CodePipeline. When a POST request is made to this URL, the defined pipeline is started as long as the body of the post request satisfies the defined authentication and filtering conditions. Deleting and re-creating a webhook makes the old URL invalid and generates a new one.</p>
pub fn set_url(mut self, input: std::option::Option<std::string::String>) -> Self {
self.url = input;
self
}
/// <p>The text of the error message about the webhook.</p>
pub fn error_message(mut self, input: impl Into<std::string::String>) -> Self {
self.error_message = Some(input.into());
self
}
/// <p>The text of the error message about the webhook.</p>
pub fn set_error_message(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.error_message = input;
self
}
/// <p>The number code of the error.</p>
pub fn error_code(mut self, input: impl Into<std::string::String>) -> Self {
self.error_code = Some(input.into());
self
}
/// <p>The number code of the error.</p>
pub fn set_error_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.error_code = input;
self
}
/// <p>The date and time a webhook was last successfully triggered, in timestamp format.</p>
pub fn last_triggered(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_triggered = Some(input);
self
}
/// <p>The date and time a webhook was last successfully triggered, in timestamp format.</p>
pub fn set_last_triggered(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_triggered = input;
self
}
/// <p>The Amazon Resource Name (ARN) of the webhook.</p>
pub fn arn(mut self, input: impl Into<std::string::String>) -> Self {
self.arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the webhook.</p>
pub fn set_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.arn = input;
self
}
/// Appends an item to `tags`.
///
/// To override the contents of this collection use [`set_tags`](Self::set_tags).
///
/// <p>Specifies the tags applied to the webhook.</p>
pub fn tags(mut self, input: crate::model::Tag) -> Self {
let mut v = self.tags.unwrap_or_default();
v.push(input);
self.tags = Some(v);
self
}
/// <p>Specifies the tags applied to the webhook.</p>
pub fn set_tags(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Tag>>,
) -> Self {
self.tags = input;
self
}
/// Consumes the builder and constructs a [`ListWebhookItem`](crate::model::ListWebhookItem).
pub fn build(self) -> crate::model::ListWebhookItem {
crate::model::ListWebhookItem {
definition: self.definition,
url: self.url,
error_message: self.error_message,
error_code: self.error_code,
last_triggered: self.last_triggered,
arn: self.arn,
tags: self.tags,
}
}
}
}
impl ListWebhookItem {
/// Creates a new builder-style object to manufacture [`ListWebhookItem`](crate::model::ListWebhookItem).
pub fn builder() -> crate::model::list_webhook_item::Builder {
crate::model::list_webhook_item::Builder::default()
}
}
/// <p>Represents information about a webhook and its definition.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct WebhookDefinition {
/// <p>The name of the webhook.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The name of the pipeline you want to connect to the webhook.</p>
#[doc(hidden)]
pub target_pipeline: std::option::Option<std::string::String>,
/// <p>The name of the action in a pipeline you want to connect to the webhook. The action must be from the source (first) stage of the pipeline.</p>
#[doc(hidden)]
pub target_action: std::option::Option<std::string::String>,
/// <p>A list of rules applied to the body/payload sent in the POST request to a webhook URL. All defined rules must pass for the request to be accepted and the pipeline started.</p>
#[doc(hidden)]
pub filters: std::option::Option<std::vec::Vec<crate::model::WebhookFilterRule>>,
/// <p>Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.</p>
/// <ul>
/// <li> <p>For information about the authentication scheme implemented by GITHUB_HMAC, see <a href="https://developer.github.com/webhooks/securing/">Securing your webhooks</a> on the GitHub Developer website.</p> </li>
/// <li> <p> IP rejects webhooks trigger requests unless they originate from an IP address in the IP range whitelisted in the authentication configuration.</p> </li>
/// <li> <p> UNAUTHENTICATED accepts all webhook trigger requests regardless of origin.</p> </li>
/// </ul>
#[doc(hidden)]
pub authentication: std::option::Option<crate::model::WebhookAuthenticationType>,
/// <p>Properties that configure the authentication applied to incoming webhook trigger requests. The required properties depend on the authentication type. For GITHUB_HMAC, only the <code>SecretToken </code>property must be set. For IP, only the <code>AllowedIPRange </code>property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.</p>
#[doc(hidden)]
pub authentication_configuration: std::option::Option<crate::model::WebhookAuthConfiguration>,
}
impl WebhookDefinition {
/// <p>The name of the webhook.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The name of the pipeline you want to connect to the webhook.</p>
pub fn target_pipeline(&self) -> std::option::Option<&str> {
self.target_pipeline.as_deref()
}
/// <p>The name of the action in a pipeline you want to connect to the webhook. The action must be from the source (first) stage of the pipeline.</p>
pub fn target_action(&self) -> std::option::Option<&str> {
self.target_action.as_deref()
}
/// <p>A list of rules applied to the body/payload sent in the POST request to a webhook URL. All defined rules must pass for the request to be accepted and the pipeline started.</p>
pub fn filters(&self) -> std::option::Option<&[crate::model::WebhookFilterRule]> {
self.filters.as_deref()
}
/// <p>Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.</p>
/// <ul>
/// <li> <p>For information about the authentication scheme implemented by GITHUB_HMAC, see <a href="https://developer.github.com/webhooks/securing/">Securing your webhooks</a> on the GitHub Developer website.</p> </li>
/// <li> <p> IP rejects webhooks trigger requests unless they originate from an IP address in the IP range whitelisted in the authentication configuration.</p> </li>
/// <li> <p> UNAUTHENTICATED accepts all webhook trigger requests regardless of origin.</p> </li>
/// </ul>
pub fn authentication(&self) -> std::option::Option<&crate::model::WebhookAuthenticationType> {
self.authentication.as_ref()
}
/// <p>Properties that configure the authentication applied to incoming webhook trigger requests. The required properties depend on the authentication type. For GITHUB_HMAC, only the <code>SecretToken </code>property must be set. For IP, only the <code>AllowedIPRange </code>property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.</p>
pub fn authentication_configuration(
&self,
) -> std::option::Option<&crate::model::WebhookAuthConfiguration> {
self.authentication_configuration.as_ref()
}
}
/// See [`WebhookDefinition`](crate::model::WebhookDefinition).
pub mod webhook_definition {
/// A builder for [`WebhookDefinition`](crate::model::WebhookDefinition).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) target_pipeline: std::option::Option<std::string::String>,
pub(crate) target_action: std::option::Option<std::string::String>,
pub(crate) filters: std::option::Option<std::vec::Vec<crate::model::WebhookFilterRule>>,
pub(crate) authentication: std::option::Option<crate::model::WebhookAuthenticationType>,
pub(crate) authentication_configuration:
std::option::Option<crate::model::WebhookAuthConfiguration>,
}
impl Builder {
/// <p>The name of the webhook.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the webhook.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The name of the pipeline you want to connect to the webhook.</p>
pub fn target_pipeline(mut self, input: impl Into<std::string::String>) -> Self {
self.target_pipeline = Some(input.into());
self
}
/// <p>The name of the pipeline you want to connect to the webhook.</p>
pub fn set_target_pipeline(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.target_pipeline = input;
self
}
/// <p>The name of the action in a pipeline you want to connect to the webhook. The action must be from the source (first) stage of the pipeline.</p>
pub fn target_action(mut self, input: impl Into<std::string::String>) -> Self {
self.target_action = Some(input.into());
self
}
/// <p>The name of the action in a pipeline you want to connect to the webhook. The action must be from the source (first) stage of the pipeline.</p>
pub fn set_target_action(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.target_action = input;
self
}
/// Appends an item to `filters`.
///
/// To override the contents of this collection use [`set_filters`](Self::set_filters).
///
/// <p>A list of rules applied to the body/payload sent in the POST request to a webhook URL. All defined rules must pass for the request to be accepted and the pipeline started.</p>
pub fn filters(mut self, input: crate::model::WebhookFilterRule) -> Self {
let mut v = self.filters.unwrap_or_default();
v.push(input);
self.filters = Some(v);
self
}
/// <p>A list of rules applied to the body/payload sent in the POST request to a webhook URL. All defined rules must pass for the request to be accepted and the pipeline started.</p>
pub fn set_filters(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::WebhookFilterRule>>,
) -> Self {
self.filters = input;
self
}
/// <p>Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.</p>
/// <ul>
/// <li> <p>For information about the authentication scheme implemented by GITHUB_HMAC, see <a href="https://developer.github.com/webhooks/securing/">Securing your webhooks</a> on the GitHub Developer website.</p> </li>
/// <li> <p> IP rejects webhooks trigger requests unless they originate from an IP address in the IP range whitelisted in the authentication configuration.</p> </li>
/// <li> <p> UNAUTHENTICATED accepts all webhook trigger requests regardless of origin.</p> </li>
/// </ul>
pub fn authentication(mut self, input: crate::model::WebhookAuthenticationType) -> Self {
self.authentication = Some(input);
self
}
/// <p>Supported options are GITHUB_HMAC, IP, and UNAUTHENTICATED.</p>
/// <ul>
/// <li> <p>For information about the authentication scheme implemented by GITHUB_HMAC, see <a href="https://developer.github.com/webhooks/securing/">Securing your webhooks</a> on the GitHub Developer website.</p> </li>
/// <li> <p> IP rejects webhooks trigger requests unless they originate from an IP address in the IP range whitelisted in the authentication configuration.</p> </li>
/// <li> <p> UNAUTHENTICATED accepts all webhook trigger requests regardless of origin.</p> </li>
/// </ul>
pub fn set_authentication(
mut self,
input: std::option::Option<crate::model::WebhookAuthenticationType>,
) -> Self {
self.authentication = input;
self
}
/// <p>Properties that configure the authentication applied to incoming webhook trigger requests. The required properties depend on the authentication type. For GITHUB_HMAC, only the <code>SecretToken </code>property must be set. For IP, only the <code>AllowedIPRange </code>property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.</p>
pub fn authentication_configuration(
mut self,
input: crate::model::WebhookAuthConfiguration,
) -> Self {
self.authentication_configuration = Some(input);
self
}
/// <p>Properties that configure the authentication applied to incoming webhook trigger requests. The required properties depend on the authentication type. For GITHUB_HMAC, only the <code>SecretToken </code>property must be set. For IP, only the <code>AllowedIPRange </code>property must be set to a valid CIDR range. For UNAUTHENTICATED, no properties can be set.</p>
pub fn set_authentication_configuration(
mut self,
input: std::option::Option<crate::model::WebhookAuthConfiguration>,
) -> Self {
self.authentication_configuration = input;
self
}
/// Consumes the builder and constructs a [`WebhookDefinition`](crate::model::WebhookDefinition).
pub fn build(self) -> crate::model::WebhookDefinition {
crate::model::WebhookDefinition {
name: self.name,
target_pipeline: self.target_pipeline,
target_action: self.target_action,
filters: self.filters,
authentication: self.authentication,
authentication_configuration: self.authentication_configuration,
}
}
}
}
impl WebhookDefinition {
/// Creates a new builder-style object to manufacture [`WebhookDefinition`](crate::model::WebhookDefinition).
pub fn builder() -> crate::model::webhook_definition::Builder {
crate::model::webhook_definition::Builder::default()
}
}
/// <p>The authentication applied to incoming webhook trigger requests.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct WebhookAuthConfiguration {
/// <p>The property used to configure acceptance of webhooks in an IP address range. For IP, only the <code>AllowedIPRange</code> property must be set. This property must be set to a valid CIDR range.</p>
#[doc(hidden)]
pub allowed_ip_range: std::option::Option<std::string::String>,
/// <p>The property used to configure GitHub authentication. For GITHUB_HMAC, only the <code>SecretToken</code> property must be set.</p>
#[doc(hidden)]
pub secret_token: std::option::Option<std::string::String>,
}
impl WebhookAuthConfiguration {
/// <p>The property used to configure acceptance of webhooks in an IP address range. For IP, only the <code>AllowedIPRange</code> property must be set. This property must be set to a valid CIDR range.</p>
pub fn allowed_ip_range(&self) -> std::option::Option<&str> {
self.allowed_ip_range.as_deref()
}
/// <p>The property used to configure GitHub authentication. For GITHUB_HMAC, only the <code>SecretToken</code> property must be set.</p>
pub fn secret_token(&self) -> std::option::Option<&str> {
self.secret_token.as_deref()
}
}
/// See [`WebhookAuthConfiguration`](crate::model::WebhookAuthConfiguration).
pub mod webhook_auth_configuration {
/// A builder for [`WebhookAuthConfiguration`](crate::model::WebhookAuthConfiguration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) allowed_ip_range: std::option::Option<std::string::String>,
pub(crate) secret_token: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The property used to configure acceptance of webhooks in an IP address range. For IP, only the <code>AllowedIPRange</code> property must be set. This property must be set to a valid CIDR range.</p>
pub fn allowed_ip_range(mut self, input: impl Into<std::string::String>) -> Self {
self.allowed_ip_range = Some(input.into());
self
}
/// <p>The property used to configure acceptance of webhooks in an IP address range. For IP, only the <code>AllowedIPRange</code> property must be set. This property must be set to a valid CIDR range.</p>
pub fn set_allowed_ip_range(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.allowed_ip_range = input;
self
}
/// <p>The property used to configure GitHub authentication. For GITHUB_HMAC, only the <code>SecretToken</code> property must be set.</p>
pub fn secret_token(mut self, input: impl Into<std::string::String>) -> Self {
self.secret_token = Some(input.into());
self
}
/// <p>The property used to configure GitHub authentication. For GITHUB_HMAC, only the <code>SecretToken</code> property must be set.</p>
pub fn set_secret_token(mut self, input: std::option::Option<std::string::String>) -> Self {
self.secret_token = input;
self
}
/// Consumes the builder and constructs a [`WebhookAuthConfiguration`](crate::model::WebhookAuthConfiguration).
pub fn build(self) -> crate::model::WebhookAuthConfiguration {
crate::model::WebhookAuthConfiguration {
allowed_ip_range: self.allowed_ip_range,
secret_token: self.secret_token,
}
}
}
}
impl WebhookAuthConfiguration {
/// Creates a new builder-style object to manufacture [`WebhookAuthConfiguration`](crate::model::WebhookAuthConfiguration).
pub fn builder() -> crate::model::webhook_auth_configuration::Builder {
crate::model::webhook_auth_configuration::Builder::default()
}
}
/// When writing a match expression against `WebhookAuthenticationType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let webhookauthenticationtype = unimplemented!();
/// match webhookauthenticationtype {
/// WebhookAuthenticationType::GithubHmac => { /* ... */ },
/// WebhookAuthenticationType::Ip => { /* ... */ },
/// WebhookAuthenticationType::Unauthenticated => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `webhookauthenticationtype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `WebhookAuthenticationType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `WebhookAuthenticationType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `WebhookAuthenticationType::NewFeature` is defined.
/// Specifically, when `webhookauthenticationtype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `WebhookAuthenticationType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum WebhookAuthenticationType {
#[allow(missing_docs)] // documentation missing in model
GithubHmac,
#[allow(missing_docs)] // documentation missing in model
Ip,
#[allow(missing_docs)] // documentation missing in model
Unauthenticated,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for WebhookAuthenticationType {
fn from(s: &str) -> Self {
match s {
"GITHUB_HMAC" => WebhookAuthenticationType::GithubHmac,
"IP" => WebhookAuthenticationType::Ip,
"UNAUTHENTICATED" => WebhookAuthenticationType::Unauthenticated,
other => WebhookAuthenticationType::Unknown(crate::types::UnknownVariantValue(
other.to_owned(),
)),
}
}
}
impl std::str::FromStr for WebhookAuthenticationType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(WebhookAuthenticationType::from(s))
}
}
impl WebhookAuthenticationType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
WebhookAuthenticationType::GithubHmac => "GITHUB_HMAC",
WebhookAuthenticationType::Ip => "IP",
WebhookAuthenticationType::Unauthenticated => "UNAUTHENTICATED",
WebhookAuthenticationType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["GITHUB_HMAC", "IP", "UNAUTHENTICATED"]
}
}
impl AsRef<str> for WebhookAuthenticationType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>The event criteria that specify when a webhook notification is sent to your URL.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct WebhookFilterRule {
/// <p>A JsonPath expression that is applied to the body/payload of the webhook. The value selected by the JsonPath expression must match the value specified in the <code>MatchEquals</code> field. Otherwise, the request is ignored. For more information, see <a href="https://github.com/json-path/JsonPath">Java JsonPath implementation</a> in GitHub.</p>
#[doc(hidden)]
pub json_path: std::option::Option<std::string::String>,
/// <p>The value selected by the <code>JsonPath</code> expression must match what is supplied in the <code>MatchEquals</code> field. Otherwise, the request is ignored. Properties from the target action configuration can be included as placeholders in this value by surrounding the action configuration key with curly brackets. For example, if the value supplied here is "refs/heads/{Branch}" and the target action has an action configuration property called "Branch" with a value of "master", the <code>MatchEquals</code> value is evaluated as "refs/heads/master". For a list of action configuration properties for built-in action types, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Pipeline Structure Reference Action Requirements</a>.</p>
#[doc(hidden)]
pub match_equals: std::option::Option<std::string::String>,
}
impl WebhookFilterRule {
/// <p>A JsonPath expression that is applied to the body/payload of the webhook. The value selected by the JsonPath expression must match the value specified in the <code>MatchEquals</code> field. Otherwise, the request is ignored. For more information, see <a href="https://github.com/json-path/JsonPath">Java JsonPath implementation</a> in GitHub.</p>
pub fn json_path(&self) -> std::option::Option<&str> {
self.json_path.as_deref()
}
/// <p>The value selected by the <code>JsonPath</code> expression must match what is supplied in the <code>MatchEquals</code> field. Otherwise, the request is ignored. Properties from the target action configuration can be included as placeholders in this value by surrounding the action configuration key with curly brackets. For example, if the value supplied here is "refs/heads/{Branch}" and the target action has an action configuration property called "Branch" with a value of "master", the <code>MatchEquals</code> value is evaluated as "refs/heads/master". For a list of action configuration properties for built-in action types, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Pipeline Structure Reference Action Requirements</a>.</p>
pub fn match_equals(&self) -> std::option::Option<&str> {
self.match_equals.as_deref()
}
}
/// See [`WebhookFilterRule`](crate::model::WebhookFilterRule).
pub mod webhook_filter_rule {
/// A builder for [`WebhookFilterRule`](crate::model::WebhookFilterRule).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) json_path: std::option::Option<std::string::String>,
pub(crate) match_equals: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>A JsonPath expression that is applied to the body/payload of the webhook. The value selected by the JsonPath expression must match the value specified in the <code>MatchEquals</code> field. Otherwise, the request is ignored. For more information, see <a href="https://github.com/json-path/JsonPath">Java JsonPath implementation</a> in GitHub.</p>
pub fn json_path(mut self, input: impl Into<std::string::String>) -> Self {
self.json_path = Some(input.into());
self
}
/// <p>A JsonPath expression that is applied to the body/payload of the webhook. The value selected by the JsonPath expression must match the value specified in the <code>MatchEquals</code> field. Otherwise, the request is ignored. For more information, see <a href="https://github.com/json-path/JsonPath">Java JsonPath implementation</a> in GitHub.</p>
pub fn set_json_path(mut self, input: std::option::Option<std::string::String>) -> Self {
self.json_path = input;
self
}
/// <p>The value selected by the <code>JsonPath</code> expression must match what is supplied in the <code>MatchEquals</code> field. Otherwise, the request is ignored. Properties from the target action configuration can be included as placeholders in this value by surrounding the action configuration key with curly brackets. For example, if the value supplied here is "refs/heads/{Branch}" and the target action has an action configuration property called "Branch" with a value of "master", the <code>MatchEquals</code> value is evaluated as "refs/heads/master". For a list of action configuration properties for built-in action types, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Pipeline Structure Reference Action Requirements</a>.</p>
pub fn match_equals(mut self, input: impl Into<std::string::String>) -> Self {
self.match_equals = Some(input.into());
self
}
/// <p>The value selected by the <code>JsonPath</code> expression must match what is supplied in the <code>MatchEquals</code> field. Otherwise, the request is ignored. Properties from the target action configuration can be included as placeholders in this value by surrounding the action configuration key with curly brackets. For example, if the value supplied here is "refs/heads/{Branch}" and the target action has an action configuration property called "Branch" with a value of "master", the <code>MatchEquals</code> value is evaluated as "refs/heads/master". For a list of action configuration properties for built-in action types, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/reference-pipeline-structure.html#action-requirements">Pipeline Structure Reference Action Requirements</a>.</p>
pub fn set_match_equals(mut self, input: std::option::Option<std::string::String>) -> Self {
self.match_equals = input;
self
}
/// Consumes the builder and constructs a [`WebhookFilterRule`](crate::model::WebhookFilterRule).
pub fn build(self) -> crate::model::WebhookFilterRule {
crate::model::WebhookFilterRule {
json_path: self.json_path,
match_equals: self.match_equals,
}
}
}
}
impl WebhookFilterRule {
/// Creates a new builder-style object to manufacture [`WebhookFilterRule`](crate::model::WebhookFilterRule).
pub fn builder() -> crate::model::webhook_filter_rule::Builder {
crate::model::webhook_filter_rule::Builder::default()
}
}
/// <p>The details of the actions taken and results produced on an artifact as it passes through stages in the pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ExecutionDetails {
/// <p>The summary of the current status of the actions.</p>
#[doc(hidden)]
pub summary: std::option::Option<std::string::String>,
/// <p>The system-generated unique ID of this action used to identify this job worker in any external systems, such as AWS CodeDeploy.</p>
#[doc(hidden)]
pub external_execution_id: std::option::Option<std::string::String>,
/// <p>The percentage of work completed on the action, represented on a scale of 0 to 100 percent.</p>
#[doc(hidden)]
pub percent_complete: std::option::Option<i32>,
}
impl ExecutionDetails {
/// <p>The summary of the current status of the actions.</p>
pub fn summary(&self) -> std::option::Option<&str> {
self.summary.as_deref()
}
/// <p>The system-generated unique ID of this action used to identify this job worker in any external systems, such as AWS CodeDeploy.</p>
pub fn external_execution_id(&self) -> std::option::Option<&str> {
self.external_execution_id.as_deref()
}
/// <p>The percentage of work completed on the action, represented on a scale of 0 to 100 percent.</p>
pub fn percent_complete(&self) -> std::option::Option<i32> {
self.percent_complete
}
}
/// See [`ExecutionDetails`](crate::model::ExecutionDetails).
pub mod execution_details {
/// A builder for [`ExecutionDetails`](crate::model::ExecutionDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) summary: std::option::Option<std::string::String>,
pub(crate) external_execution_id: std::option::Option<std::string::String>,
pub(crate) percent_complete: std::option::Option<i32>,
}
impl Builder {
/// <p>The summary of the current status of the actions.</p>
pub fn summary(mut self, input: impl Into<std::string::String>) -> Self {
self.summary = Some(input.into());
self
}
/// <p>The summary of the current status of the actions.</p>
pub fn set_summary(mut self, input: std::option::Option<std::string::String>) -> Self {
self.summary = input;
self
}
/// <p>The system-generated unique ID of this action used to identify this job worker in any external systems, such as AWS CodeDeploy.</p>
pub fn external_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_id = Some(input.into());
self
}
/// <p>The system-generated unique ID of this action used to identify this job worker in any external systems, such as AWS CodeDeploy.</p>
pub fn set_external_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_id = input;
self
}
/// <p>The percentage of work completed on the action, represented on a scale of 0 to 100 percent.</p>
pub fn percent_complete(mut self, input: i32) -> Self {
self.percent_complete = Some(input);
self
}
/// <p>The percentage of work completed on the action, represented on a scale of 0 to 100 percent.</p>
pub fn set_percent_complete(mut self, input: std::option::Option<i32>) -> Self {
self.percent_complete = input;
self
}
/// Consumes the builder and constructs a [`ExecutionDetails`](crate::model::ExecutionDetails).
pub fn build(self) -> crate::model::ExecutionDetails {
crate::model::ExecutionDetails {
summary: self.summary,
external_execution_id: self.external_execution_id,
percent_complete: self.percent_complete,
}
}
}
}
impl ExecutionDetails {
/// Creates a new builder-style object to manufacture [`ExecutionDetails`](crate::model::ExecutionDetails).
pub fn builder() -> crate::model::execution_details::Builder {
crate::model::execution_details::Builder::default()
}
}
/// <p>Represents information about a current revision.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct CurrentRevision {
/// <p>The revision ID of the current version of an artifact.</p>
#[doc(hidden)]
pub revision: std::option::Option<std::string::String>,
/// <p>The change identifier for the current revision.</p>
#[doc(hidden)]
pub change_identifier: std::option::Option<std::string::String>,
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
#[doc(hidden)]
pub created: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The summary of the most recent revision of the artifact.</p>
#[doc(hidden)]
pub revision_summary: std::option::Option<std::string::String>,
}
impl CurrentRevision {
/// <p>The revision ID of the current version of an artifact.</p>
pub fn revision(&self) -> std::option::Option<&str> {
self.revision.as_deref()
}
/// <p>The change identifier for the current revision.</p>
pub fn change_identifier(&self) -> std::option::Option<&str> {
self.change_identifier.as_deref()
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn created(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created.as_ref()
}
/// <p>The summary of the most recent revision of the artifact.</p>
pub fn revision_summary(&self) -> std::option::Option<&str> {
self.revision_summary.as_deref()
}
}
/// See [`CurrentRevision`](crate::model::CurrentRevision).
pub mod current_revision {
/// A builder for [`CurrentRevision`](crate::model::CurrentRevision).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) revision: std::option::Option<std::string::String>,
pub(crate) change_identifier: std::option::Option<std::string::String>,
pub(crate) created: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) revision_summary: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The revision ID of the current version of an artifact.</p>
pub fn revision(mut self, input: impl Into<std::string::String>) -> Self {
self.revision = Some(input.into());
self
}
/// <p>The revision ID of the current version of an artifact.</p>
pub fn set_revision(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision = input;
self
}
/// <p>The change identifier for the current revision.</p>
pub fn change_identifier(mut self, input: impl Into<std::string::String>) -> Self {
self.change_identifier = Some(input.into());
self
}
/// <p>The change identifier for the current revision.</p>
pub fn set_change_identifier(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.change_identifier = input;
self
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn created(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created = Some(input);
self
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn set_created(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created = input;
self
}
/// <p>The summary of the most recent revision of the artifact.</p>
pub fn revision_summary(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_summary = Some(input.into());
self
}
/// <p>The summary of the most recent revision of the artifact.</p>
pub fn set_revision_summary(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_summary = input;
self
}
/// Consumes the builder and constructs a [`CurrentRevision`](crate::model::CurrentRevision).
pub fn build(self) -> crate::model::CurrentRevision {
crate::model::CurrentRevision {
revision: self.revision,
change_identifier: self.change_identifier,
created: self.created,
revision_summary: self.revision_summary,
}
}
}
}
impl CurrentRevision {
/// Creates a new builder-style object to manufacture [`CurrentRevision`](crate::model::CurrentRevision).
pub fn builder() -> crate::model::current_revision::Builder {
crate::model::current_revision::Builder::default()
}
}
/// <p>Represents information about failure details.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct FailureDetails {
/// <p>The type of the failure.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::FailureType>,
/// <p>The message about the failure.</p>
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
/// <p>The external ID of the run of the action that failed.</p>
#[doc(hidden)]
pub external_execution_id: std::option::Option<std::string::String>,
}
impl FailureDetails {
/// <p>The type of the failure.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::FailureType> {
self.r#type.as_ref()
}
/// <p>The message about the failure.</p>
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
/// <p>The external ID of the run of the action that failed.</p>
pub fn external_execution_id(&self) -> std::option::Option<&str> {
self.external_execution_id.as_deref()
}
}
/// See [`FailureDetails`](crate::model::FailureDetails).
pub mod failure_details {
/// A builder for [`FailureDetails`](crate::model::FailureDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::FailureType>,
pub(crate) message: std::option::Option<std::string::String>,
pub(crate) external_execution_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The type of the failure.</p>
pub fn r#type(mut self, input: crate::model::FailureType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of the failure.</p>
pub fn set_type(mut self, input: std::option::Option<crate::model::FailureType>) -> Self {
self.r#type = input;
self
}
/// <p>The message about the failure.</p>
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
/// <p>The message about the failure.</p>
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
/// <p>The external ID of the run of the action that failed.</p>
pub fn external_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_id = Some(input.into());
self
}
/// <p>The external ID of the run of the action that failed.</p>
pub fn set_external_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_id = input;
self
}
/// Consumes the builder and constructs a [`FailureDetails`](crate::model::FailureDetails).
pub fn build(self) -> crate::model::FailureDetails {
crate::model::FailureDetails {
r#type: self.r#type,
message: self.message,
external_execution_id: self.external_execution_id,
}
}
}
}
impl FailureDetails {
/// Creates a new builder-style object to manufacture [`FailureDetails`](crate::model::FailureDetails).
pub fn builder() -> crate::model::failure_details::Builder {
crate::model::failure_details::Builder::default()
}
}
/// When writing a match expression against `FailureType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let failuretype = unimplemented!();
/// match failuretype {
/// FailureType::ConfigurationError => { /* ... */ },
/// FailureType::JobFailed => { /* ... */ },
/// FailureType::PermissionError => { /* ... */ },
/// FailureType::RevisionOutOfSync => { /* ... */ },
/// FailureType::RevisionUnavailable => { /* ... */ },
/// FailureType::SystemUnavailable => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `failuretype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `FailureType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `FailureType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `FailureType::NewFeature` is defined.
/// Specifically, when `failuretype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `FailureType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum FailureType {
#[allow(missing_docs)] // documentation missing in model
ConfigurationError,
#[allow(missing_docs)] // documentation missing in model
JobFailed,
#[allow(missing_docs)] // documentation missing in model
PermissionError,
#[allow(missing_docs)] // documentation missing in model
RevisionOutOfSync,
#[allow(missing_docs)] // documentation missing in model
RevisionUnavailable,
#[allow(missing_docs)] // documentation missing in model
SystemUnavailable,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for FailureType {
fn from(s: &str) -> Self {
match s {
"ConfigurationError" => FailureType::ConfigurationError,
"JobFailed" => FailureType::JobFailed,
"PermissionError" => FailureType::PermissionError,
"RevisionOutOfSync" => FailureType::RevisionOutOfSync,
"RevisionUnavailable" => FailureType::RevisionUnavailable,
"SystemUnavailable" => FailureType::SystemUnavailable,
other => FailureType::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for FailureType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(FailureType::from(s))
}
}
impl FailureType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
FailureType::ConfigurationError => "ConfigurationError",
FailureType::JobFailed => "JobFailed",
FailureType::PermissionError => "PermissionError",
FailureType::RevisionOutOfSync => "RevisionOutOfSync",
FailureType::RevisionUnavailable => "RevisionUnavailable",
FailureType::SystemUnavailable => "SystemUnavailable",
FailureType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&[
"ConfigurationError",
"JobFailed",
"PermissionError",
"RevisionOutOfSync",
"RevisionUnavailable",
"SystemUnavailable",
]
}
}
impl AsRef<str> for FailureType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Represents information about the result of an approval request.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ApprovalResult {
/// <p>The summary of the current status of the approval request.</p>
#[doc(hidden)]
pub summary: std::option::Option<std::string::String>,
/// <p>The response submitted by a reviewer assigned to an approval action request.</p>
#[doc(hidden)]
pub status: std::option::Option<crate::model::ApprovalStatus>,
}
impl ApprovalResult {
/// <p>The summary of the current status of the approval request.</p>
pub fn summary(&self) -> std::option::Option<&str> {
self.summary.as_deref()
}
/// <p>The response submitted by a reviewer assigned to an approval action request.</p>
pub fn status(&self) -> std::option::Option<&crate::model::ApprovalStatus> {
self.status.as_ref()
}
}
/// See [`ApprovalResult`](crate::model::ApprovalResult).
pub mod approval_result {
/// A builder for [`ApprovalResult`](crate::model::ApprovalResult).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) summary: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::ApprovalStatus>,
}
impl Builder {
/// <p>The summary of the current status of the approval request.</p>
pub fn summary(mut self, input: impl Into<std::string::String>) -> Self {
self.summary = Some(input.into());
self
}
/// <p>The summary of the current status of the approval request.</p>
pub fn set_summary(mut self, input: std::option::Option<std::string::String>) -> Self {
self.summary = input;
self
}
/// <p>The response submitted by a reviewer assigned to an approval action request.</p>
pub fn status(mut self, input: crate::model::ApprovalStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The response submitted by a reviewer assigned to an approval action request.</p>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::ApprovalStatus>,
) -> Self {
self.status = input;
self
}
/// Consumes the builder and constructs a [`ApprovalResult`](crate::model::ApprovalResult).
pub fn build(self) -> crate::model::ApprovalResult {
crate::model::ApprovalResult {
summary: self.summary,
status: self.status,
}
}
}
}
impl ApprovalResult {
/// Creates a new builder-style object to manufacture [`ApprovalResult`](crate::model::ApprovalResult).
pub fn builder() -> crate::model::approval_result::Builder {
crate::model::approval_result::Builder::default()
}
}
/// When writing a match expression against `ApprovalStatus`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let approvalstatus = unimplemented!();
/// match approvalstatus {
/// ApprovalStatus::Approved => { /* ... */ },
/// ApprovalStatus::Rejected => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `approvalstatus` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ApprovalStatus::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ApprovalStatus::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ApprovalStatus::NewFeature` is defined.
/// Specifically, when `approvalstatus` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ApprovalStatus::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ApprovalStatus {
#[allow(missing_docs)] // documentation missing in model
Approved,
#[allow(missing_docs)] // documentation missing in model
Rejected,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ApprovalStatus {
fn from(s: &str) -> Self {
match s {
"Approved" => ApprovalStatus::Approved,
"Rejected" => ApprovalStatus::Rejected,
other => ApprovalStatus::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for ApprovalStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ApprovalStatus::from(s))
}
}
impl ApprovalStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ApprovalStatus::Approved => "Approved",
ApprovalStatus::Rejected => "Rejected",
ApprovalStatus::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Approved", "Rejected"]
}
}
impl AsRef<str> for ApprovalStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Represents information about the version (or revision) of an action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionRevision {
/// <p>The system-generated unique ID that identifies the revision number of the action.</p>
#[doc(hidden)]
pub revision_id: std::option::Option<std::string::String>,
/// <p>The unique identifier of the change that set the state to this revision (for example, a deployment ID or timestamp).</p>
#[doc(hidden)]
pub revision_change_id: std::option::Option<std::string::String>,
/// <p>The date and time when the most recent version of the action was created, in timestamp format.</p>
#[doc(hidden)]
pub created: std::option::Option<aws_smithy_types::DateTime>,
}
impl ActionRevision {
/// <p>The system-generated unique ID that identifies the revision number of the action.</p>
pub fn revision_id(&self) -> std::option::Option<&str> {
self.revision_id.as_deref()
}
/// <p>The unique identifier of the change that set the state to this revision (for example, a deployment ID or timestamp).</p>
pub fn revision_change_id(&self) -> std::option::Option<&str> {
self.revision_change_id.as_deref()
}
/// <p>The date and time when the most recent version of the action was created, in timestamp format.</p>
pub fn created(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created.as_ref()
}
}
/// See [`ActionRevision`](crate::model::ActionRevision).
pub mod action_revision {
/// A builder for [`ActionRevision`](crate::model::ActionRevision).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) revision_id: std::option::Option<std::string::String>,
pub(crate) revision_change_id: std::option::Option<std::string::String>,
pub(crate) created: std::option::Option<aws_smithy_types::DateTime>,
}
impl Builder {
/// <p>The system-generated unique ID that identifies the revision number of the action.</p>
pub fn revision_id(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_id = Some(input.into());
self
}
/// <p>The system-generated unique ID that identifies the revision number of the action.</p>
pub fn set_revision_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_id = input;
self
}
/// <p>The unique identifier of the change that set the state to this revision (for example, a deployment ID or timestamp).</p>
pub fn revision_change_id(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_change_id = Some(input.into());
self
}
/// <p>The unique identifier of the change that set the state to this revision (for example, a deployment ID or timestamp).</p>
pub fn set_revision_change_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_change_id = input;
self
}
/// <p>The date and time when the most recent version of the action was created, in timestamp format.</p>
pub fn created(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created = Some(input);
self
}
/// <p>The date and time when the most recent version of the action was created, in timestamp format.</p>
pub fn set_created(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created = input;
self
}
/// Consumes the builder and constructs a [`ActionRevision`](crate::model::ActionRevision).
pub fn build(self) -> crate::model::ActionRevision {
crate::model::ActionRevision {
revision_id: self.revision_id,
revision_change_id: self.revision_change_id,
created: self.created,
}
}
}
}
impl ActionRevision {
/// Creates a new builder-style object to manufacture [`ActionRevision`](crate::model::ActionRevision).
pub fn builder() -> crate::model::action_revision::Builder {
crate::model::action_revision::Builder::default()
}
}
/// <p>A response to a <code>PollForThirdPartyJobs</code> request returned by AWS CodePipeline when there is a job to be worked on by a partner action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ThirdPartyJob {
/// <p>The <code>clientToken</code> portion of the <code>clientId</code> and <code>clientToken</code> pair used to verify that the calling entity is allowed access to the job and its details.</p>
#[doc(hidden)]
pub client_id: std::option::Option<std::string::String>,
/// <p>The identifier used to identify the job in AWS CodePipeline.</p>
#[doc(hidden)]
pub job_id: std::option::Option<std::string::String>,
}
impl ThirdPartyJob {
/// <p>The <code>clientToken</code> portion of the <code>clientId</code> and <code>clientToken</code> pair used to verify that the calling entity is allowed access to the job and its details.</p>
pub fn client_id(&self) -> std::option::Option<&str> {
self.client_id.as_deref()
}
/// <p>The identifier used to identify the job in AWS CodePipeline.</p>
pub fn job_id(&self) -> std::option::Option<&str> {
self.job_id.as_deref()
}
}
/// See [`ThirdPartyJob`](crate::model::ThirdPartyJob).
pub mod third_party_job {
/// A builder for [`ThirdPartyJob`](crate::model::ThirdPartyJob).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) client_id: std::option::Option<std::string::String>,
pub(crate) job_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The <code>clientToken</code> portion of the <code>clientId</code> and <code>clientToken</code> pair used to verify that the calling entity is allowed access to the job and its details.</p>
pub fn client_id(mut self, input: impl Into<std::string::String>) -> Self {
self.client_id = Some(input.into());
self
}
/// <p>The <code>clientToken</code> portion of the <code>clientId</code> and <code>clientToken</code> pair used to verify that the calling entity is allowed access to the job and its details.</p>
pub fn set_client_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.client_id = input;
self
}
/// <p>The identifier used to identify the job in AWS CodePipeline.</p>
pub fn job_id(mut self, input: impl Into<std::string::String>) -> Self {
self.job_id = Some(input.into());
self
}
/// <p>The identifier used to identify the job in AWS CodePipeline.</p>
pub fn set_job_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.job_id = input;
self
}
/// Consumes the builder and constructs a [`ThirdPartyJob`](crate::model::ThirdPartyJob).
pub fn build(self) -> crate::model::ThirdPartyJob {
crate::model::ThirdPartyJob {
client_id: self.client_id,
job_id: self.job_id,
}
}
}
}
impl ThirdPartyJob {
/// Creates a new builder-style object to manufacture [`ThirdPartyJob`](crate::model::ThirdPartyJob).
pub fn builder() -> crate::model::third_party_job::Builder {
crate::model::third_party_job::Builder::default()
}
}
/// <p>Represents information about a job.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Job {
/// <p>The unique system-generated ID of the job.</p>
#[doc(hidden)]
pub id: std::option::Option<std::string::String>,
/// <p>Other data about a job.</p>
#[doc(hidden)]
pub data: std::option::Option<crate::model::JobData>,
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeJob</code> request.</p>
#[doc(hidden)]
pub nonce: std::option::Option<std::string::String>,
/// <p>The ID of the AWS account to use when performing the job.</p>
#[doc(hidden)]
pub account_id: std::option::Option<std::string::String>,
}
impl Job {
/// <p>The unique system-generated ID of the job.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>Other data about a job.</p>
pub fn data(&self) -> std::option::Option<&crate::model::JobData> {
self.data.as_ref()
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeJob</code> request.</p>
pub fn nonce(&self) -> std::option::Option<&str> {
self.nonce.as_deref()
}
/// <p>The ID of the AWS account to use when performing the job.</p>
pub fn account_id(&self) -> std::option::Option<&str> {
self.account_id.as_deref()
}
}
/// See [`Job`](crate::model::Job).
pub mod job {
/// A builder for [`Job`](crate::model::Job).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) data: std::option::Option<crate::model::JobData>,
pub(crate) nonce: std::option::Option<std::string::String>,
pub(crate) account_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The unique system-generated ID of the job.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The unique system-generated ID of the job.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>Other data about a job.</p>
pub fn data(mut self, input: crate::model::JobData) -> Self {
self.data = Some(input);
self
}
/// <p>Other data about a job.</p>
pub fn set_data(mut self, input: std::option::Option<crate::model::JobData>) -> Self {
self.data = input;
self
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeJob</code> request.</p>
pub fn nonce(mut self, input: impl Into<std::string::String>) -> Self {
self.nonce = Some(input.into());
self
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeJob</code> request.</p>
pub fn set_nonce(mut self, input: std::option::Option<std::string::String>) -> Self {
self.nonce = input;
self
}
/// <p>The ID of the AWS account to use when performing the job.</p>
pub fn account_id(mut self, input: impl Into<std::string::String>) -> Self {
self.account_id = Some(input.into());
self
}
/// <p>The ID of the AWS account to use when performing the job.</p>
pub fn set_account_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.account_id = input;
self
}
/// Consumes the builder and constructs a [`Job`](crate::model::Job).
pub fn build(self) -> crate::model::Job {
crate::model::Job {
id: self.id,
data: self.data,
nonce: self.nonce,
account_id: self.account_id,
}
}
}
}
impl Job {
/// Creates a new builder-style object to manufacture [`Job`](crate::model::Job).
pub fn builder() -> crate::model::job::Builder {
crate::model::job::Builder::default()
}
}
/// <p>Represents other information about a job required for a job worker to complete the job.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct JobData {
/// <p>Represents information about an action type.</p>
#[doc(hidden)]
pub action_type_id: std::option::Option<crate::model::ActionTypeId>,
/// <p>Represents information about an action configuration.</p>
#[doc(hidden)]
pub action_configuration: std::option::Option<crate::model::ActionConfiguration>,
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Includes <code>pipelineArn</code> and <code>pipelineExecutionId</code> for custom jobs.</p>
/// </note>
#[doc(hidden)]
pub pipeline_context: std::option::Option<crate::model::PipelineContext>,
/// <p>The artifact supplied to the job.</p>
#[doc(hidden)]
pub input_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
/// <p>The output of the job.</p>
#[doc(hidden)]
pub output_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifacts for the pipeline in AWS CodePipeline.</p>
#[doc(hidden)]
pub artifact_credentials: std::option::Option<crate::model::AwsSessionCredentials>,
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, required by a job to continue the job asynchronously.</p>
#[doc(hidden)]
pub continuation_token: std::option::Option<std::string::String>,
/// <p>Represents information about the key used to encrypt data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. </p>
#[doc(hidden)]
pub encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl JobData {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(&self) -> std::option::Option<&crate::model::ActionTypeId> {
self.action_type_id.as_ref()
}
/// <p>Represents information about an action configuration.</p>
pub fn action_configuration(&self) -> std::option::Option<&crate::model::ActionConfiguration> {
self.action_configuration.as_ref()
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Includes <code>pipelineArn</code> and <code>pipelineExecutionId</code> for custom jobs.</p>
/// </note>
pub fn pipeline_context(&self) -> std::option::Option<&crate::model::PipelineContext> {
self.pipeline_context.as_ref()
}
/// <p>The artifact supplied to the job.</p>
pub fn input_artifacts(&self) -> std::option::Option<&[crate::model::Artifact]> {
self.input_artifacts.as_deref()
}
/// <p>The output of the job.</p>
pub fn output_artifacts(&self) -> std::option::Option<&[crate::model::Artifact]> {
self.output_artifacts.as_deref()
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifacts for the pipeline in AWS CodePipeline.</p>
pub fn artifact_credentials(
&self,
) -> std::option::Option<&crate::model::AwsSessionCredentials> {
self.artifact_credentials.as_ref()
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, required by a job to continue the job asynchronously.</p>
pub fn continuation_token(&self) -> std::option::Option<&str> {
self.continuation_token.as_deref()
}
/// <p>Represents information about the key used to encrypt data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. </p>
pub fn encryption_key(&self) -> std::option::Option<&crate::model::EncryptionKey> {
self.encryption_key.as_ref()
}
}
impl std::fmt::Debug for JobData {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("JobData");
formatter.field("action_type_id", &self.action_type_id);
formatter.field("action_configuration", &self.action_configuration);
formatter.field("pipeline_context", &self.pipeline_context);
formatter.field("input_artifacts", &self.input_artifacts);
formatter.field("output_artifacts", &self.output_artifacts);
formatter.field("artifact_credentials", &"*** Sensitive Data Redacted ***");
formatter.field("continuation_token", &self.continuation_token);
formatter.field("encryption_key", &self.encryption_key);
formatter.finish()
}
}
/// See [`JobData`](crate::model::JobData).
pub mod job_data {
/// A builder for [`JobData`](crate::model::JobData).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default)]
pub struct Builder {
pub(crate) action_type_id: std::option::Option<crate::model::ActionTypeId>,
pub(crate) action_configuration: std::option::Option<crate::model::ActionConfiguration>,
pub(crate) pipeline_context: std::option::Option<crate::model::PipelineContext>,
pub(crate) input_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
pub(crate) output_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
pub(crate) artifact_credentials: std::option::Option<crate::model::AwsSessionCredentials>,
pub(crate) continuation_token: std::option::Option<std::string::String>,
pub(crate) encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl Builder {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(mut self, input: crate::model::ActionTypeId) -> Self {
self.action_type_id = Some(input);
self
}
/// <p>Represents information about an action type.</p>
pub fn set_action_type_id(
mut self,
input: std::option::Option<crate::model::ActionTypeId>,
) -> Self {
self.action_type_id = input;
self
}
/// <p>Represents information about an action configuration.</p>
pub fn action_configuration(mut self, input: crate::model::ActionConfiguration) -> Self {
self.action_configuration = Some(input);
self
}
/// <p>Represents information about an action configuration.</p>
pub fn set_action_configuration(
mut self,
input: std::option::Option<crate::model::ActionConfiguration>,
) -> Self {
self.action_configuration = input;
self
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Includes <code>pipelineArn</code> and <code>pipelineExecutionId</code> for custom jobs.</p>
/// </note>
pub fn pipeline_context(mut self, input: crate::model::PipelineContext) -> Self {
self.pipeline_context = Some(input);
self
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Includes <code>pipelineArn</code> and <code>pipelineExecutionId</code> for custom jobs.</p>
/// </note>
pub fn set_pipeline_context(
mut self,
input: std::option::Option<crate::model::PipelineContext>,
) -> Self {
self.pipeline_context = input;
self
}
/// Appends an item to `input_artifacts`.
///
/// To override the contents of this collection use [`set_input_artifacts`](Self::set_input_artifacts).
///
/// <p>The artifact supplied to the job.</p>
pub fn input_artifacts(mut self, input: crate::model::Artifact) -> Self {
let mut v = self.input_artifacts.unwrap_or_default();
v.push(input);
self.input_artifacts = Some(v);
self
}
/// <p>The artifact supplied to the job.</p>
pub fn set_input_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
) -> Self {
self.input_artifacts = input;
self
}
/// Appends an item to `output_artifacts`.
///
/// To override the contents of this collection use [`set_output_artifacts`](Self::set_output_artifacts).
///
/// <p>The output of the job.</p>
pub fn output_artifacts(mut self, input: crate::model::Artifact) -> Self {
let mut v = self.output_artifacts.unwrap_or_default();
v.push(input);
self.output_artifacts = Some(v);
self
}
/// <p>The output of the job.</p>
pub fn set_output_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
) -> Self {
self.output_artifacts = input;
self
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifacts for the pipeline in AWS CodePipeline.</p>
pub fn artifact_credentials(mut self, input: crate::model::AwsSessionCredentials) -> Self {
self.artifact_credentials = Some(input);
self
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifacts for the pipeline in AWS CodePipeline.</p>
pub fn set_artifact_credentials(
mut self,
input: std::option::Option<crate::model::AwsSessionCredentials>,
) -> Self {
self.artifact_credentials = input;
self
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, required by a job to continue the job asynchronously.</p>
pub fn continuation_token(mut self, input: impl Into<std::string::String>) -> Self {
self.continuation_token = Some(input.into());
self
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, required by a job to continue the job asynchronously.</p>
pub fn set_continuation_token(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.continuation_token = input;
self
}
/// <p>Represents information about the key used to encrypt data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. </p>
pub fn encryption_key(mut self, input: crate::model::EncryptionKey) -> Self {
self.encryption_key = Some(input);
self
}
/// <p>Represents information about the key used to encrypt data in the artifact store, such as an AWS Key Management Service (AWS KMS) key. </p>
pub fn set_encryption_key(
mut self,
input: std::option::Option<crate::model::EncryptionKey>,
) -> Self {
self.encryption_key = input;
self
}
/// Consumes the builder and constructs a [`JobData`](crate::model::JobData).
pub fn build(self) -> crate::model::JobData {
crate::model::JobData {
action_type_id: self.action_type_id,
action_configuration: self.action_configuration,
pipeline_context: self.pipeline_context,
input_artifacts: self.input_artifacts,
output_artifacts: self.output_artifacts,
artifact_credentials: self.artifact_credentials,
continuation_token: self.continuation_token,
encryption_key: self.encryption_key,
}
}
}
impl std::fmt::Debug for Builder {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Builder");
formatter.field("action_type_id", &self.action_type_id);
formatter.field("action_configuration", &self.action_configuration);
formatter.field("pipeline_context", &self.pipeline_context);
formatter.field("input_artifacts", &self.input_artifacts);
formatter.field("output_artifacts", &self.output_artifacts);
formatter.field("artifact_credentials", &"*** Sensitive Data Redacted ***");
formatter.field("continuation_token", &self.continuation_token);
formatter.field("encryption_key", &self.encryption_key);
formatter.finish()
}
}
}
impl JobData {
/// Creates a new builder-style object to manufacture [`JobData`](crate::model::JobData).
pub fn builder() -> crate::model::job_data::Builder {
crate::model::job_data::Builder::default()
}
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifact for the pipeline in AWS CodePipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct AwsSessionCredentials {
/// <p>The access key for the session.</p>
#[doc(hidden)]
pub access_key_id: std::option::Option<std::string::String>,
/// <p>The secret access key for the session.</p>
#[doc(hidden)]
pub secret_access_key: std::option::Option<std::string::String>,
/// <p>The token for the session.</p>
#[doc(hidden)]
pub session_token: std::option::Option<std::string::String>,
}
impl AwsSessionCredentials {
/// <p>The access key for the session.</p>
pub fn access_key_id(&self) -> std::option::Option<&str> {
self.access_key_id.as_deref()
}
/// <p>The secret access key for the session.</p>
pub fn secret_access_key(&self) -> std::option::Option<&str> {
self.secret_access_key.as_deref()
}
/// <p>The token for the session.</p>
pub fn session_token(&self) -> std::option::Option<&str> {
self.session_token.as_deref()
}
}
impl std::fmt::Debug for AwsSessionCredentials {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("AwsSessionCredentials");
formatter.field("access_key_id", &"*** Sensitive Data Redacted ***");
formatter.field("secret_access_key", &"*** Sensitive Data Redacted ***");
formatter.field("session_token", &"*** Sensitive Data Redacted ***");
formatter.finish()
}
}
/// See [`AwsSessionCredentials`](crate::model::AwsSessionCredentials).
pub mod aws_session_credentials {
/// A builder for [`AwsSessionCredentials`](crate::model::AwsSessionCredentials).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default)]
pub struct Builder {
pub(crate) access_key_id: std::option::Option<std::string::String>,
pub(crate) secret_access_key: std::option::Option<std::string::String>,
pub(crate) session_token: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The access key for the session.</p>
pub fn access_key_id(mut self, input: impl Into<std::string::String>) -> Self {
self.access_key_id = Some(input.into());
self
}
/// <p>The access key for the session.</p>
pub fn set_access_key_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.access_key_id = input;
self
}
/// <p>The secret access key for the session.</p>
pub fn secret_access_key(mut self, input: impl Into<std::string::String>) -> Self {
self.secret_access_key = Some(input.into());
self
}
/// <p>The secret access key for the session.</p>
pub fn set_secret_access_key(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.secret_access_key = input;
self
}
/// <p>The token for the session.</p>
pub fn session_token(mut self, input: impl Into<std::string::String>) -> Self {
self.session_token = Some(input.into());
self
}
/// <p>The token for the session.</p>
pub fn set_session_token(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.session_token = input;
self
}
/// Consumes the builder and constructs a [`AwsSessionCredentials`](crate::model::AwsSessionCredentials).
pub fn build(self) -> crate::model::AwsSessionCredentials {
crate::model::AwsSessionCredentials {
access_key_id: self.access_key_id,
secret_access_key: self.secret_access_key,
session_token: self.session_token,
}
}
}
impl std::fmt::Debug for Builder {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Builder");
formatter.field("access_key_id", &"*** Sensitive Data Redacted ***");
formatter.field("secret_access_key", &"*** Sensitive Data Redacted ***");
formatter.field("session_token", &"*** Sensitive Data Redacted ***");
formatter.finish()
}
}
}
impl AwsSessionCredentials {
/// Creates a new builder-style object to manufacture [`AwsSessionCredentials`](crate::model::AwsSessionCredentials).
pub fn builder() -> crate::model::aws_session_credentials::Builder {
crate::model::aws_session_credentials::Builder::default()
}
}
/// <p>Represents information about an artifact that is worked on by actions in the pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct Artifact {
/// <p>The artifact's name.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The artifact's revision ID. Depending on the type of object, this could be a commit ID (GitHub) or a revision ID (Amazon S3).</p>
#[doc(hidden)]
pub revision: std::option::Option<std::string::String>,
/// <p>The location of an artifact.</p>
#[doc(hidden)]
pub location: std::option::Option<crate::model::ArtifactLocation>,
}
impl Artifact {
/// <p>The artifact's name.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The artifact's revision ID. Depending on the type of object, this could be a commit ID (GitHub) or a revision ID (Amazon S3).</p>
pub fn revision(&self) -> std::option::Option<&str> {
self.revision.as_deref()
}
/// <p>The location of an artifact.</p>
pub fn location(&self) -> std::option::Option<&crate::model::ArtifactLocation> {
self.location.as_ref()
}
}
/// See [`Artifact`](crate::model::Artifact).
pub mod artifact {
/// A builder for [`Artifact`](crate::model::Artifact).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) revision: std::option::Option<std::string::String>,
pub(crate) location: std::option::Option<crate::model::ArtifactLocation>,
}
impl Builder {
/// <p>The artifact's name.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The artifact's name.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The artifact's revision ID. Depending on the type of object, this could be a commit ID (GitHub) or a revision ID (Amazon S3).</p>
pub fn revision(mut self, input: impl Into<std::string::String>) -> Self {
self.revision = Some(input.into());
self
}
/// <p>The artifact's revision ID. Depending on the type of object, this could be a commit ID (GitHub) or a revision ID (Amazon S3).</p>
pub fn set_revision(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision = input;
self
}
/// <p>The location of an artifact.</p>
pub fn location(mut self, input: crate::model::ArtifactLocation) -> Self {
self.location = Some(input);
self
}
/// <p>The location of an artifact.</p>
pub fn set_location(
mut self,
input: std::option::Option<crate::model::ArtifactLocation>,
) -> Self {
self.location = input;
self
}
/// Consumes the builder and constructs a [`Artifact`](crate::model::Artifact).
pub fn build(self) -> crate::model::Artifact {
crate::model::Artifact {
name: self.name,
revision: self.revision,
location: self.location,
}
}
}
}
impl Artifact {
/// Creates a new builder-style object to manufacture [`Artifact`](crate::model::Artifact).
pub fn builder() -> crate::model::artifact::Builder {
crate::model::artifact::Builder::default()
}
}
/// <p>Represents information about the location of an artifact.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ArtifactLocation {
/// <p>The type of artifact in the location.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::ArtifactLocationType>,
/// <p>The S3 bucket that contains the artifact.</p>
#[doc(hidden)]
pub s3_location: std::option::Option<crate::model::S3ArtifactLocation>,
}
impl ArtifactLocation {
/// <p>The type of artifact in the location.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::ArtifactLocationType> {
self.r#type.as_ref()
}
/// <p>The S3 bucket that contains the artifact.</p>
pub fn s3_location(&self) -> std::option::Option<&crate::model::S3ArtifactLocation> {
self.s3_location.as_ref()
}
}
/// See [`ArtifactLocation`](crate::model::ArtifactLocation).
pub mod artifact_location {
/// A builder for [`ArtifactLocation`](crate::model::ArtifactLocation).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) r#type: std::option::Option<crate::model::ArtifactLocationType>,
pub(crate) s3_location: std::option::Option<crate::model::S3ArtifactLocation>,
}
impl Builder {
/// <p>The type of artifact in the location.</p>
pub fn r#type(mut self, input: crate::model::ArtifactLocationType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of artifact in the location.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::ArtifactLocationType>,
) -> Self {
self.r#type = input;
self
}
/// <p>The S3 bucket that contains the artifact.</p>
pub fn s3_location(mut self, input: crate::model::S3ArtifactLocation) -> Self {
self.s3_location = Some(input);
self
}
/// <p>The S3 bucket that contains the artifact.</p>
pub fn set_s3_location(
mut self,
input: std::option::Option<crate::model::S3ArtifactLocation>,
) -> Self {
self.s3_location = input;
self
}
/// Consumes the builder and constructs a [`ArtifactLocation`](crate::model::ArtifactLocation).
pub fn build(self) -> crate::model::ArtifactLocation {
crate::model::ArtifactLocation {
r#type: self.r#type,
s3_location: self.s3_location,
}
}
}
}
impl ArtifactLocation {
/// Creates a new builder-style object to manufacture [`ArtifactLocation`](crate::model::ArtifactLocation).
pub fn builder() -> crate::model::artifact_location::Builder {
crate::model::artifact_location::Builder::default()
}
}
/// <p>The location of the S3 bucket that contains a revision.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct S3ArtifactLocation {
/// <p>The name of the S3 bucket.</p>
#[doc(hidden)]
pub bucket_name: std::option::Option<std::string::String>,
/// <p>The key of the object in the S3 bucket, which uniquely identifies the object in the bucket.</p>
#[doc(hidden)]
pub object_key: std::option::Option<std::string::String>,
}
impl S3ArtifactLocation {
/// <p>The name of the S3 bucket.</p>
pub fn bucket_name(&self) -> std::option::Option<&str> {
self.bucket_name.as_deref()
}
/// <p>The key of the object in the S3 bucket, which uniquely identifies the object in the bucket.</p>
pub fn object_key(&self) -> std::option::Option<&str> {
self.object_key.as_deref()
}
}
/// See [`S3ArtifactLocation`](crate::model::S3ArtifactLocation).
pub mod s3_artifact_location {
/// A builder for [`S3ArtifactLocation`](crate::model::S3ArtifactLocation).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) bucket_name: std::option::Option<std::string::String>,
pub(crate) object_key: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the S3 bucket.</p>
pub fn bucket_name(mut self, input: impl Into<std::string::String>) -> Self {
self.bucket_name = Some(input.into());
self
}
/// <p>The name of the S3 bucket.</p>
pub fn set_bucket_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.bucket_name = input;
self
}
/// <p>The key of the object in the S3 bucket, which uniquely identifies the object in the bucket.</p>
pub fn object_key(mut self, input: impl Into<std::string::String>) -> Self {
self.object_key = Some(input.into());
self
}
/// <p>The key of the object in the S3 bucket, which uniquely identifies the object in the bucket.</p>
pub fn set_object_key(mut self, input: std::option::Option<std::string::String>) -> Self {
self.object_key = input;
self
}
/// Consumes the builder and constructs a [`S3ArtifactLocation`](crate::model::S3ArtifactLocation).
pub fn build(self) -> crate::model::S3ArtifactLocation {
crate::model::S3ArtifactLocation {
bucket_name: self.bucket_name,
object_key: self.object_key,
}
}
}
}
impl S3ArtifactLocation {
/// Creates a new builder-style object to manufacture [`S3ArtifactLocation`](crate::model::S3ArtifactLocation).
pub fn builder() -> crate::model::s3_artifact_location::Builder {
crate::model::s3_artifact_location::Builder::default()
}
}
/// When writing a match expression against `ArtifactLocationType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let artifactlocationtype = unimplemented!();
/// match artifactlocationtype {
/// ArtifactLocationType::S3 => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `artifactlocationtype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ArtifactLocationType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ArtifactLocationType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ArtifactLocationType::NewFeature` is defined.
/// Specifically, when `artifactlocationtype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ArtifactLocationType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ArtifactLocationType {
#[allow(missing_docs)] // documentation missing in model
S3,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ArtifactLocationType {
fn from(s: &str) -> Self {
match s {
"S3" => ArtifactLocationType::S3,
other => {
ArtifactLocationType::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for ArtifactLocationType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ArtifactLocationType::from(s))
}
}
impl ArtifactLocationType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ArtifactLocationType::S3 => "S3",
ArtifactLocationType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["S3"]
}
}
impl AsRef<str> for ArtifactLocationType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>PipelineContext contains <code>pipelineArn</code> and <code>pipelineExecutionId</code> for custom action jobs. The <code>pipelineArn</code> and <code>pipelineExecutionId</code> fields are not populated for ThirdParty action jobs.</p>
/// </note>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineContext {
/// <p>The name of the pipeline. This is a user-specified value. Pipeline names must be unique across all pipeline names under an Amazon Web Services account.</p>
#[doc(hidden)]
pub pipeline_name: std::option::Option<std::string::String>,
/// <p>The stage of the pipeline.</p>
#[doc(hidden)]
pub stage: std::option::Option<crate::model::StageContext>,
/// <p>The context of an action to a job worker in the stage of a pipeline.</p>
#[doc(hidden)]
pub action: std::option::Option<crate::model::ActionContext>,
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
#[doc(hidden)]
pub pipeline_arn: std::option::Option<std::string::String>,
/// <p>The execution ID of the pipeline.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
}
impl PipelineContext {
/// <p>The name of the pipeline. This is a user-specified value. Pipeline names must be unique across all pipeline names under an Amazon Web Services account.</p>
pub fn pipeline_name(&self) -> std::option::Option<&str> {
self.pipeline_name.as_deref()
}
/// <p>The stage of the pipeline.</p>
pub fn stage(&self) -> std::option::Option<&crate::model::StageContext> {
self.stage.as_ref()
}
/// <p>The context of an action to a job worker in the stage of a pipeline.</p>
pub fn action(&self) -> std::option::Option<&crate::model::ActionContext> {
self.action.as_ref()
}
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn pipeline_arn(&self) -> std::option::Option<&str> {
self.pipeline_arn.as_deref()
}
/// <p>The execution ID of the pipeline.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
}
/// See [`PipelineContext`](crate::model::PipelineContext).
pub mod pipeline_context {
/// A builder for [`PipelineContext`](crate::model::PipelineContext).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_name: std::option::Option<std::string::String>,
pub(crate) stage: std::option::Option<crate::model::StageContext>,
pub(crate) action: std::option::Option<crate::model::ActionContext>,
pub(crate) pipeline_arn: std::option::Option<std::string::String>,
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the pipeline. This is a user-specified value. Pipeline names must be unique across all pipeline names under an Amazon Web Services account.</p>
pub fn pipeline_name(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_name = Some(input.into());
self
}
/// <p>The name of the pipeline. This is a user-specified value. Pipeline names must be unique across all pipeline names under an Amazon Web Services account.</p>
pub fn set_pipeline_name(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_name = input;
self
}
/// <p>The stage of the pipeline.</p>
pub fn stage(mut self, input: crate::model::StageContext) -> Self {
self.stage = Some(input);
self
}
/// <p>The stage of the pipeline.</p>
pub fn set_stage(mut self, input: std::option::Option<crate::model::StageContext>) -> Self {
self.stage = input;
self
}
/// <p>The context of an action to a job worker in the stage of a pipeline.</p>
pub fn action(mut self, input: crate::model::ActionContext) -> Self {
self.action = Some(input);
self
}
/// <p>The context of an action to a job worker in the stage of a pipeline.</p>
pub fn set_action(
mut self,
input: std::option::Option<crate::model::ActionContext>,
) -> Self {
self.action = input;
self
}
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn pipeline_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn set_pipeline_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.pipeline_arn = input;
self
}
/// <p>The execution ID of the pipeline.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The execution ID of the pipeline.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// Consumes the builder and constructs a [`PipelineContext`](crate::model::PipelineContext).
pub fn build(self) -> crate::model::PipelineContext {
crate::model::PipelineContext {
pipeline_name: self.pipeline_name,
stage: self.stage,
action: self.action,
pipeline_arn: self.pipeline_arn,
pipeline_execution_id: self.pipeline_execution_id,
}
}
}
}
impl PipelineContext {
/// Creates a new builder-style object to manufacture [`PipelineContext`](crate::model::PipelineContext).
pub fn builder() -> crate::model::pipeline_context::Builder {
crate::model::pipeline_context::Builder::default()
}
}
/// <p>Represents the context of an action in the stage of a pipeline to a job worker.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionContext {
/// <p>The name of the action in the context of a job.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The system-generated unique ID that corresponds to an action's execution.</p>
#[doc(hidden)]
pub action_execution_id: std::option::Option<std::string::String>,
}
impl ActionContext {
/// <p>The name of the action in the context of a job.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The system-generated unique ID that corresponds to an action's execution.</p>
pub fn action_execution_id(&self) -> std::option::Option<&str> {
self.action_execution_id.as_deref()
}
}
/// See [`ActionContext`](crate::model::ActionContext).
pub mod action_context {
/// A builder for [`ActionContext`](crate::model::ActionContext).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) action_execution_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the action in the context of a job.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the action in the context of a job.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The system-generated unique ID that corresponds to an action's execution.</p>
pub fn action_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.action_execution_id = Some(input.into());
self
}
/// <p>The system-generated unique ID that corresponds to an action's execution.</p>
pub fn set_action_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.action_execution_id = input;
self
}
/// Consumes the builder and constructs a [`ActionContext`](crate::model::ActionContext).
pub fn build(self) -> crate::model::ActionContext {
crate::model::ActionContext {
name: self.name,
action_execution_id: self.action_execution_id,
}
}
}
}
impl ActionContext {
/// Creates a new builder-style object to manufacture [`ActionContext`](crate::model::ActionContext).
pub fn builder() -> crate::model::action_context::Builder {
crate::model::action_context::Builder::default()
}
}
/// <p>Represents information about a stage to a job worker.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct StageContext {
/// <p>The name of the stage.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
}
impl StageContext {
/// <p>The name of the stage.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
}
/// See [`StageContext`](crate::model::StageContext).
pub mod stage_context {
/// A builder for [`StageContext`](crate::model::StageContext).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the stage.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the stage.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// Consumes the builder and constructs a [`StageContext`](crate::model::StageContext).
pub fn build(self) -> crate::model::StageContext {
crate::model::StageContext { name: self.name }
}
}
}
impl StageContext {
/// Creates a new builder-style object to manufacture [`StageContext`](crate::model::StageContext).
pub fn builder() -> crate::model::stage_context::Builder {
crate::model::stage_context::Builder::default()
}
}
/// <p>Represents information about an action configuration.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionConfiguration {
/// <p>The configuration data for the action.</p>
#[doc(hidden)]
pub configuration:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
}
impl ActionConfiguration {
/// <p>The configuration data for the action.</p>
pub fn configuration(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.configuration.as_ref()
}
}
/// See [`ActionConfiguration`](crate::model::ActionConfiguration).
pub mod action_configuration {
/// A builder for [`ActionConfiguration`](crate::model::ActionConfiguration).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) configuration: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
}
impl Builder {
/// Adds a key-value pair to `configuration`.
///
/// To override the contents of this collection use [`set_configuration`](Self::set_configuration).
///
/// <p>The configuration data for the action.</p>
pub fn configuration(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.configuration.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.configuration = Some(hash_map);
self
}
/// <p>The configuration data for the action.</p>
pub fn set_configuration(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.configuration = input;
self
}
/// Consumes the builder and constructs a [`ActionConfiguration`](crate::model::ActionConfiguration).
pub fn build(self) -> crate::model::ActionConfiguration {
crate::model::ActionConfiguration {
configuration: self.configuration,
}
}
}
}
impl ActionConfiguration {
/// Creates a new builder-style object to manufacture [`ActionConfiguration`](crate::model::ActionConfiguration).
pub fn builder() -> crate::model::action_configuration::Builder {
crate::model::action_configuration::Builder::default()
}
}
/// <p>Returns a summary of a pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineSummary {
/// <p>The name of the pipeline.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The version number of the pipeline.</p>
#[doc(hidden)]
pub version: std::option::Option<i32>,
/// <p>The date and time the pipeline was created, in timestamp format.</p>
#[doc(hidden)]
pub created: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The date and time of the last update to the pipeline, in timestamp format.</p>
#[doc(hidden)]
pub updated: std::option::Option<aws_smithy_types::DateTime>,
}
impl PipelineSummary {
/// <p>The name of the pipeline.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The version number of the pipeline.</p>
pub fn version(&self) -> std::option::Option<i32> {
self.version
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn created(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created.as_ref()
}
/// <p>The date and time of the last update to the pipeline, in timestamp format.</p>
pub fn updated(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.updated.as_ref()
}
}
/// See [`PipelineSummary`](crate::model::PipelineSummary).
pub mod pipeline_summary {
/// A builder for [`PipelineSummary`](crate::model::PipelineSummary).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) version: std::option::Option<i32>,
pub(crate) created: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) updated: std::option::Option<aws_smithy_types::DateTime>,
}
impl Builder {
/// <p>The name of the pipeline.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the pipeline.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The version number of the pipeline.</p>
pub fn version(mut self, input: i32) -> Self {
self.version = Some(input);
self
}
/// <p>The version number of the pipeline.</p>
pub fn set_version(mut self, input: std::option::Option<i32>) -> Self {
self.version = input;
self
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn created(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created = Some(input);
self
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn set_created(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created = input;
self
}
/// <p>The date and time of the last update to the pipeline, in timestamp format.</p>
pub fn updated(mut self, input: aws_smithy_types::DateTime) -> Self {
self.updated = Some(input);
self
}
/// <p>The date and time of the last update to the pipeline, in timestamp format.</p>
pub fn set_updated(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.updated = input;
self
}
/// Consumes the builder and constructs a [`PipelineSummary`](crate::model::PipelineSummary).
pub fn build(self) -> crate::model::PipelineSummary {
crate::model::PipelineSummary {
name: self.name,
version: self.version,
created: self.created,
updated: self.updated,
}
}
}
}
impl PipelineSummary {
/// Creates a new builder-style object to manufacture [`PipelineSummary`](crate::model::PipelineSummary).
pub fn builder() -> crate::model::pipeline_summary::Builder {
crate::model::pipeline_summary::Builder::default()
}
}
/// <p>Summary information about a pipeline execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineExecutionSummary {
/// <p>The ID of the pipeline execution.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
#[doc(hidden)]
pub status: std::option::Option<crate::model::PipelineExecutionStatus>,
/// <p>The date and time when the pipeline execution began, in timestamp format.</p>
#[doc(hidden)]
pub start_time: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The date and time of the last change to the pipeline execution, in timestamp format.</p>
#[doc(hidden)]
pub last_update_time: std::option::Option<aws_smithy_types::DateTime>,
/// <p>A list of the source artifact revisions that initiated a pipeline execution.</p>
#[doc(hidden)]
pub source_revisions: std::option::Option<std::vec::Vec<crate::model::SourceRevision>>,
/// <p>The interaction or event that started a pipeline execution, such as automated change detection or a <code>StartPipelineExecution</code> API call.</p>
#[doc(hidden)]
pub trigger: std::option::Option<crate::model::ExecutionTrigger>,
/// <p>The interaction that stopped a pipeline execution.</p>
#[doc(hidden)]
pub stop_trigger: std::option::Option<crate::model::StopExecutionTrigger>,
}
impl PipelineExecutionSummary {
/// <p>The ID of the pipeline execution.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn status(&self) -> std::option::Option<&crate::model::PipelineExecutionStatus> {
self.status.as_ref()
}
/// <p>The date and time when the pipeline execution began, in timestamp format.</p>
pub fn start_time(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.start_time.as_ref()
}
/// <p>The date and time of the last change to the pipeline execution, in timestamp format.</p>
pub fn last_update_time(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_update_time.as_ref()
}
/// <p>A list of the source artifact revisions that initiated a pipeline execution.</p>
pub fn source_revisions(&self) -> std::option::Option<&[crate::model::SourceRevision]> {
self.source_revisions.as_deref()
}
/// <p>The interaction or event that started a pipeline execution, such as automated change detection or a <code>StartPipelineExecution</code> API call.</p>
pub fn trigger(&self) -> std::option::Option<&crate::model::ExecutionTrigger> {
self.trigger.as_ref()
}
/// <p>The interaction that stopped a pipeline execution.</p>
pub fn stop_trigger(&self) -> std::option::Option<&crate::model::StopExecutionTrigger> {
self.stop_trigger.as_ref()
}
}
/// See [`PipelineExecutionSummary`](crate::model::PipelineExecutionSummary).
pub mod pipeline_execution_summary {
/// A builder for [`PipelineExecutionSummary`](crate::model::PipelineExecutionSummary).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::PipelineExecutionStatus>,
pub(crate) start_time: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) last_update_time: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) source_revisions:
std::option::Option<std::vec::Vec<crate::model::SourceRevision>>,
pub(crate) trigger: std::option::Option<crate::model::ExecutionTrigger>,
pub(crate) stop_trigger: std::option::Option<crate::model::StopExecutionTrigger>,
}
impl Builder {
/// <p>The ID of the pipeline execution.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The ID of the pipeline execution.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn status(mut self, input: crate::model::PipelineExecutionStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::PipelineExecutionStatus>,
) -> Self {
self.status = input;
self
}
/// <p>The date and time when the pipeline execution began, in timestamp format.</p>
pub fn start_time(mut self, input: aws_smithy_types::DateTime) -> Self {
self.start_time = Some(input);
self
}
/// <p>The date and time when the pipeline execution began, in timestamp format.</p>
pub fn set_start_time(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.start_time = input;
self
}
/// <p>The date and time of the last change to the pipeline execution, in timestamp format.</p>
pub fn last_update_time(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_update_time = Some(input);
self
}
/// <p>The date and time of the last change to the pipeline execution, in timestamp format.</p>
pub fn set_last_update_time(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_update_time = input;
self
}
/// Appends an item to `source_revisions`.
///
/// To override the contents of this collection use [`set_source_revisions`](Self::set_source_revisions).
///
/// <p>A list of the source artifact revisions that initiated a pipeline execution.</p>
pub fn source_revisions(mut self, input: crate::model::SourceRevision) -> Self {
let mut v = self.source_revisions.unwrap_or_default();
v.push(input);
self.source_revisions = Some(v);
self
}
/// <p>A list of the source artifact revisions that initiated a pipeline execution.</p>
pub fn set_source_revisions(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::SourceRevision>>,
) -> Self {
self.source_revisions = input;
self
}
/// <p>The interaction or event that started a pipeline execution, such as automated change detection or a <code>StartPipelineExecution</code> API call.</p>
pub fn trigger(mut self, input: crate::model::ExecutionTrigger) -> Self {
self.trigger = Some(input);
self
}
/// <p>The interaction or event that started a pipeline execution, such as automated change detection or a <code>StartPipelineExecution</code> API call.</p>
pub fn set_trigger(
mut self,
input: std::option::Option<crate::model::ExecutionTrigger>,
) -> Self {
self.trigger = input;
self
}
/// <p>The interaction that stopped a pipeline execution.</p>
pub fn stop_trigger(mut self, input: crate::model::StopExecutionTrigger) -> Self {
self.stop_trigger = Some(input);
self
}
/// <p>The interaction that stopped a pipeline execution.</p>
pub fn set_stop_trigger(
mut self,
input: std::option::Option<crate::model::StopExecutionTrigger>,
) -> Self {
self.stop_trigger = input;
self
}
/// Consumes the builder and constructs a [`PipelineExecutionSummary`](crate::model::PipelineExecutionSummary).
pub fn build(self) -> crate::model::PipelineExecutionSummary {
crate::model::PipelineExecutionSummary {
pipeline_execution_id: self.pipeline_execution_id,
status: self.status,
start_time: self.start_time,
last_update_time: self.last_update_time,
source_revisions: self.source_revisions,
trigger: self.trigger,
stop_trigger: self.stop_trigger,
}
}
}
}
impl PipelineExecutionSummary {
/// Creates a new builder-style object to manufacture [`PipelineExecutionSummary`](crate::model::PipelineExecutionSummary).
pub fn builder() -> crate::model::pipeline_execution_summary::Builder {
crate::model::pipeline_execution_summary::Builder::default()
}
}
/// <p>The interaction that stopped a pipeline execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct StopExecutionTrigger {
/// <p>The user-specified reason the pipeline was stopped.</p>
#[doc(hidden)]
pub reason: std::option::Option<std::string::String>,
}
impl StopExecutionTrigger {
/// <p>The user-specified reason the pipeline was stopped.</p>
pub fn reason(&self) -> std::option::Option<&str> {
self.reason.as_deref()
}
}
/// See [`StopExecutionTrigger`](crate::model::StopExecutionTrigger).
pub mod stop_execution_trigger {
/// A builder for [`StopExecutionTrigger`](crate::model::StopExecutionTrigger).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) reason: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The user-specified reason the pipeline was stopped.</p>
pub fn reason(mut self, input: impl Into<std::string::String>) -> Self {
self.reason = Some(input.into());
self
}
/// <p>The user-specified reason the pipeline was stopped.</p>
pub fn set_reason(mut self, input: std::option::Option<std::string::String>) -> Self {
self.reason = input;
self
}
/// Consumes the builder and constructs a [`StopExecutionTrigger`](crate::model::StopExecutionTrigger).
pub fn build(self) -> crate::model::StopExecutionTrigger {
crate::model::StopExecutionTrigger {
reason: self.reason,
}
}
}
}
impl StopExecutionTrigger {
/// Creates a new builder-style object to manufacture [`StopExecutionTrigger`](crate::model::StopExecutionTrigger).
pub fn builder() -> crate::model::stop_execution_trigger::Builder {
crate::model::stop_execution_trigger::Builder::default()
}
}
/// <p>The interaction or event that started a pipeline execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ExecutionTrigger {
/// <p>The type of change-detection method, command, or user interaction that started a pipeline execution.</p>
#[doc(hidden)]
pub trigger_type: std::option::Option<crate::model::TriggerType>,
/// <p>Detail related to the event that started a pipeline execution, such as the webhook ARN of the webhook that triggered the pipeline execution or the user ARN for a user-initiated <code>start-pipeline-execution</code> CLI command.</p>
#[doc(hidden)]
pub trigger_detail: std::option::Option<std::string::String>,
}
impl ExecutionTrigger {
/// <p>The type of change-detection method, command, or user interaction that started a pipeline execution.</p>
pub fn trigger_type(&self) -> std::option::Option<&crate::model::TriggerType> {
self.trigger_type.as_ref()
}
/// <p>Detail related to the event that started a pipeline execution, such as the webhook ARN of the webhook that triggered the pipeline execution or the user ARN for a user-initiated <code>start-pipeline-execution</code> CLI command.</p>
pub fn trigger_detail(&self) -> std::option::Option<&str> {
self.trigger_detail.as_deref()
}
}
/// See [`ExecutionTrigger`](crate::model::ExecutionTrigger).
pub mod execution_trigger {
/// A builder for [`ExecutionTrigger`](crate::model::ExecutionTrigger).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) trigger_type: std::option::Option<crate::model::TriggerType>,
pub(crate) trigger_detail: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The type of change-detection method, command, or user interaction that started a pipeline execution.</p>
pub fn trigger_type(mut self, input: crate::model::TriggerType) -> Self {
self.trigger_type = Some(input);
self
}
/// <p>The type of change-detection method, command, or user interaction that started a pipeline execution.</p>
pub fn set_trigger_type(
mut self,
input: std::option::Option<crate::model::TriggerType>,
) -> Self {
self.trigger_type = input;
self
}
/// <p>Detail related to the event that started a pipeline execution, such as the webhook ARN of the webhook that triggered the pipeline execution or the user ARN for a user-initiated <code>start-pipeline-execution</code> CLI command.</p>
pub fn trigger_detail(mut self, input: impl Into<std::string::String>) -> Self {
self.trigger_detail = Some(input.into());
self
}
/// <p>Detail related to the event that started a pipeline execution, such as the webhook ARN of the webhook that triggered the pipeline execution or the user ARN for a user-initiated <code>start-pipeline-execution</code> CLI command.</p>
pub fn set_trigger_detail(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.trigger_detail = input;
self
}
/// Consumes the builder and constructs a [`ExecutionTrigger`](crate::model::ExecutionTrigger).
pub fn build(self) -> crate::model::ExecutionTrigger {
crate::model::ExecutionTrigger {
trigger_type: self.trigger_type,
trigger_detail: self.trigger_detail,
}
}
}
}
impl ExecutionTrigger {
/// Creates a new builder-style object to manufacture [`ExecutionTrigger`](crate::model::ExecutionTrigger).
pub fn builder() -> crate::model::execution_trigger::Builder {
crate::model::execution_trigger::Builder::default()
}
}
/// When writing a match expression against `TriggerType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let triggertype = unimplemented!();
/// match triggertype {
/// TriggerType::CloudWatchEvent => { /* ... */ },
/// TriggerType::CreatePipeline => { /* ... */ },
/// TriggerType::PollForSourceChanges => { /* ... */ },
/// TriggerType::PutActionRevision => { /* ... */ },
/// TriggerType::StartPipelineExecution => { /* ... */ },
/// TriggerType::Webhook => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `triggertype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `TriggerType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `TriggerType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `TriggerType::NewFeature` is defined.
/// Specifically, when `triggertype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `TriggerType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum TriggerType {
#[allow(missing_docs)] // documentation missing in model
CloudWatchEvent,
#[allow(missing_docs)] // documentation missing in model
CreatePipeline,
#[allow(missing_docs)] // documentation missing in model
PollForSourceChanges,
#[allow(missing_docs)] // documentation missing in model
PutActionRevision,
#[allow(missing_docs)] // documentation missing in model
StartPipelineExecution,
#[allow(missing_docs)] // documentation missing in model
Webhook,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for TriggerType {
fn from(s: &str) -> Self {
match s {
"CloudWatchEvent" => TriggerType::CloudWatchEvent,
"CreatePipeline" => TriggerType::CreatePipeline,
"PollForSourceChanges" => TriggerType::PollForSourceChanges,
"PutActionRevision" => TriggerType::PutActionRevision,
"StartPipelineExecution" => TriggerType::StartPipelineExecution,
"Webhook" => TriggerType::Webhook,
other => TriggerType::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for TriggerType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(TriggerType::from(s))
}
}
impl TriggerType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
TriggerType::CloudWatchEvent => "CloudWatchEvent",
TriggerType::CreatePipeline => "CreatePipeline",
TriggerType::PollForSourceChanges => "PollForSourceChanges",
TriggerType::PutActionRevision => "PutActionRevision",
TriggerType::StartPipelineExecution => "StartPipelineExecution",
TriggerType::Webhook => "Webhook",
TriggerType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&[
"CloudWatchEvent",
"CreatePipeline",
"PollForSourceChanges",
"PutActionRevision",
"StartPipelineExecution",
"Webhook",
]
}
}
impl AsRef<str> for TriggerType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Information about the version (or revision) of a source artifact that initiated a pipeline execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct SourceRevision {
/// <p>The name of the action that processed the revision to the source artifact.</p>
#[doc(hidden)]
pub action_name: std::option::Option<std::string::String>,
/// <p>The system-generated unique ID that identifies the revision number of the artifact.</p>
#[doc(hidden)]
pub revision_id: std::option::Option<std::string::String>,
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
#[doc(hidden)]
pub revision_summary: std::option::Option<std::string::String>,
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
#[doc(hidden)]
pub revision_url: std::option::Option<std::string::String>,
}
impl SourceRevision {
/// <p>The name of the action that processed the revision to the source artifact.</p>
pub fn action_name(&self) -> std::option::Option<&str> {
self.action_name.as_deref()
}
/// <p>The system-generated unique ID that identifies the revision number of the artifact.</p>
pub fn revision_id(&self) -> std::option::Option<&str> {
self.revision_id.as_deref()
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn revision_summary(&self) -> std::option::Option<&str> {
self.revision_summary.as_deref()
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn revision_url(&self) -> std::option::Option<&str> {
self.revision_url.as_deref()
}
}
/// See [`SourceRevision`](crate::model::SourceRevision).
pub mod source_revision {
/// A builder for [`SourceRevision`](crate::model::SourceRevision).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) action_name: std::option::Option<std::string::String>,
pub(crate) revision_id: std::option::Option<std::string::String>,
pub(crate) revision_summary: std::option::Option<std::string::String>,
pub(crate) revision_url: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the action that processed the revision to the source artifact.</p>
pub fn action_name(mut self, input: impl Into<std::string::String>) -> Self {
self.action_name = Some(input.into());
self
}
/// <p>The name of the action that processed the revision to the source artifact.</p>
pub fn set_action_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.action_name = input;
self
}
/// <p>The system-generated unique ID that identifies the revision number of the artifact.</p>
pub fn revision_id(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_id = Some(input.into());
self
}
/// <p>The system-generated unique ID that identifies the revision number of the artifact.</p>
pub fn set_revision_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_id = input;
self
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn revision_summary(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_summary = Some(input.into());
self
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn set_revision_summary(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_summary = input;
self
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn revision_url(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_url = Some(input.into());
self
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn set_revision_url(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_url = input;
self
}
/// Consumes the builder and constructs a [`SourceRevision`](crate::model::SourceRevision).
pub fn build(self) -> crate::model::SourceRevision {
crate::model::SourceRevision {
action_name: self.action_name,
revision_id: self.revision_id,
revision_summary: self.revision_summary,
revision_url: self.revision_url,
}
}
}
}
impl SourceRevision {
/// Creates a new builder-style object to manufacture [`SourceRevision`](crate::model::SourceRevision).
pub fn builder() -> crate::model::source_revision::Builder {
crate::model::source_revision::Builder::default()
}
}
/// When writing a match expression against `PipelineExecutionStatus`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let pipelineexecutionstatus = unimplemented!();
/// match pipelineexecutionstatus {
/// PipelineExecutionStatus::Cancelled => { /* ... */ },
/// PipelineExecutionStatus::Failed => { /* ... */ },
/// PipelineExecutionStatus::InProgress => { /* ... */ },
/// PipelineExecutionStatus::Stopped => { /* ... */ },
/// PipelineExecutionStatus::Stopping => { /* ... */ },
/// PipelineExecutionStatus::Succeeded => { /* ... */ },
/// PipelineExecutionStatus::Superseded => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `pipelineexecutionstatus` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `PipelineExecutionStatus::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `PipelineExecutionStatus::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `PipelineExecutionStatus::NewFeature` is defined.
/// Specifically, when `pipelineexecutionstatus` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `PipelineExecutionStatus::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum PipelineExecutionStatus {
#[allow(missing_docs)] // documentation missing in model
Cancelled,
#[allow(missing_docs)] // documentation missing in model
Failed,
#[allow(missing_docs)] // documentation missing in model
InProgress,
#[allow(missing_docs)] // documentation missing in model
Stopped,
#[allow(missing_docs)] // documentation missing in model
Stopping,
#[allow(missing_docs)] // documentation missing in model
Succeeded,
#[allow(missing_docs)] // documentation missing in model
Superseded,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for PipelineExecutionStatus {
fn from(s: &str) -> Self {
match s {
"Cancelled" => PipelineExecutionStatus::Cancelled,
"Failed" => PipelineExecutionStatus::Failed,
"InProgress" => PipelineExecutionStatus::InProgress,
"Stopped" => PipelineExecutionStatus::Stopped,
"Stopping" => PipelineExecutionStatus::Stopping,
"Succeeded" => PipelineExecutionStatus::Succeeded,
"Superseded" => PipelineExecutionStatus::Superseded,
other => PipelineExecutionStatus::Unknown(crate::types::UnknownVariantValue(
other.to_owned(),
)),
}
}
}
impl std::str::FromStr for PipelineExecutionStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(PipelineExecutionStatus::from(s))
}
}
impl PipelineExecutionStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
PipelineExecutionStatus::Cancelled => "Cancelled",
PipelineExecutionStatus::Failed => "Failed",
PipelineExecutionStatus::InProgress => "InProgress",
PipelineExecutionStatus::Stopped => "Stopped",
PipelineExecutionStatus::Stopping => "Stopping",
PipelineExecutionStatus::Succeeded => "Succeeded",
PipelineExecutionStatus::Superseded => "Superseded",
PipelineExecutionStatus::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&[
"Cancelled",
"Failed",
"InProgress",
"Stopped",
"Stopping",
"Succeeded",
"Superseded",
]
}
}
impl AsRef<str> for PipelineExecutionStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Returns information about the details of an action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionType {
/// <p>Represents information about an action type.</p>
#[doc(hidden)]
pub id: std::option::Option<crate::model::ActionTypeId>,
/// <p>The settings for the action type.</p>
#[doc(hidden)]
pub settings: std::option::Option<crate::model::ActionTypeSettings>,
/// <p>The configuration properties for the action type.</p>
#[doc(hidden)]
pub action_configuration_properties:
std::option::Option<std::vec::Vec<crate::model::ActionConfigurationProperty>>,
/// <p>The details of the input artifact for the action, such as its commit ID.</p>
#[doc(hidden)]
pub input_artifact_details: std::option::Option<crate::model::ArtifactDetails>,
/// <p>The details of the output artifact of the action, such as its commit ID.</p>
#[doc(hidden)]
pub output_artifact_details: std::option::Option<crate::model::ArtifactDetails>,
}
impl ActionType {
/// <p>Represents information about an action type.</p>
pub fn id(&self) -> std::option::Option<&crate::model::ActionTypeId> {
self.id.as_ref()
}
/// <p>The settings for the action type.</p>
pub fn settings(&self) -> std::option::Option<&crate::model::ActionTypeSettings> {
self.settings.as_ref()
}
/// <p>The configuration properties for the action type.</p>
pub fn action_configuration_properties(
&self,
) -> std::option::Option<&[crate::model::ActionConfigurationProperty]> {
self.action_configuration_properties.as_deref()
}
/// <p>The details of the input artifact for the action, such as its commit ID.</p>
pub fn input_artifact_details(&self) -> std::option::Option<&crate::model::ArtifactDetails> {
self.input_artifact_details.as_ref()
}
/// <p>The details of the output artifact of the action, such as its commit ID.</p>
pub fn output_artifact_details(&self) -> std::option::Option<&crate::model::ArtifactDetails> {
self.output_artifact_details.as_ref()
}
}
/// See [`ActionType`](crate::model::ActionType).
pub mod action_type {
/// A builder for [`ActionType`](crate::model::ActionType).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<crate::model::ActionTypeId>,
pub(crate) settings: std::option::Option<crate::model::ActionTypeSettings>,
pub(crate) action_configuration_properties:
std::option::Option<std::vec::Vec<crate::model::ActionConfigurationProperty>>,
pub(crate) input_artifact_details: std::option::Option<crate::model::ArtifactDetails>,
pub(crate) output_artifact_details: std::option::Option<crate::model::ArtifactDetails>,
}
impl Builder {
/// <p>Represents information about an action type.</p>
pub fn id(mut self, input: crate::model::ActionTypeId) -> Self {
self.id = Some(input);
self
}
/// <p>Represents information about an action type.</p>
pub fn set_id(mut self, input: std::option::Option<crate::model::ActionTypeId>) -> Self {
self.id = input;
self
}
/// <p>The settings for the action type.</p>
pub fn settings(mut self, input: crate::model::ActionTypeSettings) -> Self {
self.settings = Some(input);
self
}
/// <p>The settings for the action type.</p>
pub fn set_settings(
mut self,
input: std::option::Option<crate::model::ActionTypeSettings>,
) -> Self {
self.settings = input;
self
}
/// Appends an item to `action_configuration_properties`.
///
/// To override the contents of this collection use [`set_action_configuration_properties`](Self::set_action_configuration_properties).
///
/// <p>The configuration properties for the action type.</p>
pub fn action_configuration_properties(
mut self,
input: crate::model::ActionConfigurationProperty,
) -> Self {
let mut v = self.action_configuration_properties.unwrap_or_default();
v.push(input);
self.action_configuration_properties = Some(v);
self
}
/// <p>The configuration properties for the action type.</p>
pub fn set_action_configuration_properties(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ActionConfigurationProperty>>,
) -> Self {
self.action_configuration_properties = input;
self
}
/// <p>The details of the input artifact for the action, such as its commit ID.</p>
pub fn input_artifact_details(mut self, input: crate::model::ArtifactDetails) -> Self {
self.input_artifact_details = Some(input);
self
}
/// <p>The details of the input artifact for the action, such as its commit ID.</p>
pub fn set_input_artifact_details(
mut self,
input: std::option::Option<crate::model::ArtifactDetails>,
) -> Self {
self.input_artifact_details = input;
self
}
/// <p>The details of the output artifact of the action, such as its commit ID.</p>
pub fn output_artifact_details(mut self, input: crate::model::ArtifactDetails) -> Self {
self.output_artifact_details = Some(input);
self
}
/// <p>The details of the output artifact of the action, such as its commit ID.</p>
pub fn set_output_artifact_details(
mut self,
input: std::option::Option<crate::model::ArtifactDetails>,
) -> Self {
self.output_artifact_details = input;
self
}
/// Consumes the builder and constructs a [`ActionType`](crate::model::ActionType).
pub fn build(self) -> crate::model::ActionType {
crate::model::ActionType {
id: self.id,
settings: self.settings,
action_configuration_properties: self.action_configuration_properties,
input_artifact_details: self.input_artifact_details,
output_artifact_details: self.output_artifact_details,
}
}
}
}
impl ActionType {
/// Creates a new builder-style object to manufacture [`ActionType`](crate::model::ActionType).
pub fn builder() -> crate::model::action_type::Builder {
crate::model::action_type::Builder::default()
}
}
/// <p>Returns information about the details of an artifact.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ArtifactDetails {
/// <p>The minimum number of artifacts allowed for the action type.</p>
#[doc(hidden)]
pub minimum_count: i32,
/// <p>The maximum number of artifacts allowed for the action type.</p>
#[doc(hidden)]
pub maximum_count: i32,
}
impl ArtifactDetails {
/// <p>The minimum number of artifacts allowed for the action type.</p>
pub fn minimum_count(&self) -> i32 {
self.minimum_count
}
/// <p>The maximum number of artifacts allowed for the action type.</p>
pub fn maximum_count(&self) -> i32 {
self.maximum_count
}
}
/// See [`ArtifactDetails`](crate::model::ArtifactDetails).
pub mod artifact_details {
/// A builder for [`ArtifactDetails`](crate::model::ArtifactDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) minimum_count: std::option::Option<i32>,
pub(crate) maximum_count: std::option::Option<i32>,
}
impl Builder {
/// <p>The minimum number of artifacts allowed for the action type.</p>
pub fn minimum_count(mut self, input: i32) -> Self {
self.minimum_count = Some(input);
self
}
/// <p>The minimum number of artifacts allowed for the action type.</p>
pub fn set_minimum_count(mut self, input: std::option::Option<i32>) -> Self {
self.minimum_count = input;
self
}
/// <p>The maximum number of artifacts allowed for the action type.</p>
pub fn maximum_count(mut self, input: i32) -> Self {
self.maximum_count = Some(input);
self
}
/// <p>The maximum number of artifacts allowed for the action type.</p>
pub fn set_maximum_count(mut self, input: std::option::Option<i32>) -> Self {
self.maximum_count = input;
self
}
/// Consumes the builder and constructs a [`ArtifactDetails`](crate::model::ArtifactDetails).
pub fn build(self) -> crate::model::ArtifactDetails {
crate::model::ArtifactDetails {
minimum_count: self.minimum_count.unwrap_or_default(),
maximum_count: self.maximum_count.unwrap_or_default(),
}
}
}
}
impl ArtifactDetails {
/// Creates a new builder-style object to manufacture [`ArtifactDetails`](crate::model::ArtifactDetails).
pub fn builder() -> crate::model::artifact_details::Builder {
crate::model::artifact_details::Builder::default()
}
}
/// <p>Represents information about an action configuration property.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionConfigurationProperty {
/// <p>The name of the action configuration property.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>Whether the configuration property is a required value.</p>
#[doc(hidden)]
pub required: bool,
/// <p>Whether the configuration property is a key.</p>
#[doc(hidden)]
pub key: bool,
/// <p>Whether the configuration property is secret. Secrets are hidden from all calls except for <code>GetJobDetails</code>, <code>GetThirdPartyJobDetails</code>, <code>PollForJobs</code>, and <code>PollForThirdPartyJobs</code>.</p>
/// <p>When updating a pipeline, passing * * * * * without changing any other values of the action preserves the previous value of the secret.</p>
#[doc(hidden)]
pub secret: bool,
/// <p>Indicates that the property is used with <code>PollForJobs</code>. When creating a custom action, an action can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
/// <p>If you create a pipeline with a custom action type, and that custom action contains a queryable property, the value for that configuration property is subject to other restrictions. The value must be less than or equal to twenty (20) characters. The value can contain only alphanumeric characters, underscores, and hyphens.</p>
#[doc(hidden)]
pub queryable: bool,
/// <p>The description of the action configuration property that is displayed to users.</p>
#[doc(hidden)]
pub description: std::option::Option<std::string::String>,
/// <p>The type of the configuration property.</p>
#[doc(hidden)]
pub r#type: std::option::Option<crate::model::ActionConfigurationPropertyType>,
}
impl ActionConfigurationProperty {
/// <p>The name of the action configuration property.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>Whether the configuration property is a required value.</p>
pub fn required(&self) -> bool {
self.required
}
/// <p>Whether the configuration property is a key.</p>
pub fn key(&self) -> bool {
self.key
}
/// <p>Whether the configuration property is secret. Secrets are hidden from all calls except for <code>GetJobDetails</code>, <code>GetThirdPartyJobDetails</code>, <code>PollForJobs</code>, and <code>PollForThirdPartyJobs</code>.</p>
/// <p>When updating a pipeline, passing * * * * * without changing any other values of the action preserves the previous value of the secret.</p>
pub fn secret(&self) -> bool {
self.secret
}
/// <p>Indicates that the property is used with <code>PollForJobs</code>. When creating a custom action, an action can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
/// <p>If you create a pipeline with a custom action type, and that custom action contains a queryable property, the value for that configuration property is subject to other restrictions. The value must be less than or equal to twenty (20) characters. The value can contain only alphanumeric characters, underscores, and hyphens.</p>
pub fn queryable(&self) -> bool {
self.queryable
}
/// <p>The description of the action configuration property that is displayed to users.</p>
pub fn description(&self) -> std::option::Option<&str> {
self.description.as_deref()
}
/// <p>The type of the configuration property.</p>
pub fn r#type(&self) -> std::option::Option<&crate::model::ActionConfigurationPropertyType> {
self.r#type.as_ref()
}
}
/// See [`ActionConfigurationProperty`](crate::model::ActionConfigurationProperty).
pub mod action_configuration_property {
/// A builder for [`ActionConfigurationProperty`](crate::model::ActionConfigurationProperty).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) required: std::option::Option<bool>,
pub(crate) key: std::option::Option<bool>,
pub(crate) secret: std::option::Option<bool>,
pub(crate) queryable: std::option::Option<bool>,
pub(crate) description: std::option::Option<std::string::String>,
pub(crate) r#type: std::option::Option<crate::model::ActionConfigurationPropertyType>,
}
impl Builder {
/// <p>The name of the action configuration property.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of the action configuration property.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>Whether the configuration property is a required value.</p>
pub fn required(mut self, input: bool) -> Self {
self.required = Some(input);
self
}
/// <p>Whether the configuration property is a required value.</p>
pub fn set_required(mut self, input: std::option::Option<bool>) -> Self {
self.required = input;
self
}
/// <p>Whether the configuration property is a key.</p>
pub fn key(mut self, input: bool) -> Self {
self.key = Some(input);
self
}
/// <p>Whether the configuration property is a key.</p>
pub fn set_key(mut self, input: std::option::Option<bool>) -> Self {
self.key = input;
self
}
/// <p>Whether the configuration property is secret. Secrets are hidden from all calls except for <code>GetJobDetails</code>, <code>GetThirdPartyJobDetails</code>, <code>PollForJobs</code>, and <code>PollForThirdPartyJobs</code>.</p>
/// <p>When updating a pipeline, passing * * * * * without changing any other values of the action preserves the previous value of the secret.</p>
pub fn secret(mut self, input: bool) -> Self {
self.secret = Some(input);
self
}
/// <p>Whether the configuration property is secret. Secrets are hidden from all calls except for <code>GetJobDetails</code>, <code>GetThirdPartyJobDetails</code>, <code>PollForJobs</code>, and <code>PollForThirdPartyJobs</code>.</p>
/// <p>When updating a pipeline, passing * * * * * without changing any other values of the action preserves the previous value of the secret.</p>
pub fn set_secret(mut self, input: std::option::Option<bool>) -> Self {
self.secret = input;
self
}
/// <p>Indicates that the property is used with <code>PollForJobs</code>. When creating a custom action, an action can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
/// <p>If you create a pipeline with a custom action type, and that custom action contains a queryable property, the value for that configuration property is subject to other restrictions. The value must be less than or equal to twenty (20) characters. The value can contain only alphanumeric characters, underscores, and hyphens.</p>
pub fn queryable(mut self, input: bool) -> Self {
self.queryable = Some(input);
self
}
/// <p>Indicates that the property is used with <code>PollForJobs</code>. When creating a custom action, an action can have up to one queryable property. If it has one, that property must be both required and not secret.</p>
/// <p>If you create a pipeline with a custom action type, and that custom action contains a queryable property, the value for that configuration property is subject to other restrictions. The value must be less than or equal to twenty (20) characters. The value can contain only alphanumeric characters, underscores, and hyphens.</p>
pub fn set_queryable(mut self, input: std::option::Option<bool>) -> Self {
self.queryable = input;
self
}
/// <p>The description of the action configuration property that is displayed to users.</p>
pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
self.description = Some(input.into());
self
}
/// <p>The description of the action configuration property that is displayed to users.</p>
pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
self.description = input;
self
}
/// <p>The type of the configuration property.</p>
pub fn r#type(mut self, input: crate::model::ActionConfigurationPropertyType) -> Self {
self.r#type = Some(input);
self
}
/// <p>The type of the configuration property.</p>
pub fn set_type(
mut self,
input: std::option::Option<crate::model::ActionConfigurationPropertyType>,
) -> Self {
self.r#type = input;
self
}
/// Consumes the builder and constructs a [`ActionConfigurationProperty`](crate::model::ActionConfigurationProperty).
pub fn build(self) -> crate::model::ActionConfigurationProperty {
crate::model::ActionConfigurationProperty {
name: self.name,
required: self.required.unwrap_or_default(),
key: self.key.unwrap_or_default(),
secret: self.secret.unwrap_or_default(),
queryable: self.queryable.unwrap_or_default(),
description: self.description,
r#type: self.r#type,
}
}
}
}
impl ActionConfigurationProperty {
/// Creates a new builder-style object to manufacture [`ActionConfigurationProperty`](crate::model::ActionConfigurationProperty).
pub fn builder() -> crate::model::action_configuration_property::Builder {
crate::model::action_configuration_property::Builder::default()
}
}
/// When writing a match expression against `ActionConfigurationPropertyType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let actionconfigurationpropertytype = unimplemented!();
/// match actionconfigurationpropertytype {
/// ActionConfigurationPropertyType::Boolean => { /* ... */ },
/// ActionConfigurationPropertyType::Number => { /* ... */ },
/// ActionConfigurationPropertyType::String => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `actionconfigurationpropertytype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ActionConfigurationPropertyType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ActionConfigurationPropertyType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ActionConfigurationPropertyType::NewFeature` is defined.
/// Specifically, when `actionconfigurationpropertytype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ActionConfigurationPropertyType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ActionConfigurationPropertyType {
#[allow(missing_docs)] // documentation missing in model
Boolean,
#[allow(missing_docs)] // documentation missing in model
Number,
#[allow(missing_docs)] // documentation missing in model
String,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ActionConfigurationPropertyType {
fn from(s: &str) -> Self {
match s {
"Boolean" => ActionConfigurationPropertyType::Boolean,
"Number" => ActionConfigurationPropertyType::Number,
"String" => ActionConfigurationPropertyType::String,
other => ActionConfigurationPropertyType::Unknown(crate::types::UnknownVariantValue(
other.to_owned(),
)),
}
}
}
impl std::str::FromStr for ActionConfigurationPropertyType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ActionConfigurationPropertyType::from(s))
}
}
impl ActionConfigurationPropertyType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ActionConfigurationPropertyType::Boolean => "Boolean",
ActionConfigurationPropertyType::Number => "Number",
ActionConfigurationPropertyType::String => "String",
ActionConfigurationPropertyType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Boolean", "Number", "String"]
}
}
impl AsRef<str> for ActionConfigurationPropertyType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Returns information about the settings for an action type.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionTypeSettings {
/// <p>The URL of a sign-up page where users can sign up for an external service and perform initial configuration of the action provided by that service.</p>
#[doc(hidden)]
pub third_party_configuration_url: std::option::Option<std::string::String>,
/// <p>The URL returned to the AWS CodePipeline console that provides a deep link to the resources of the external system, such as the configuration page for an AWS CodeDeploy deployment group. This link is provided as part of the action display in the pipeline.</p>
#[doc(hidden)]
pub entity_url_template: std::option::Option<std::string::String>,
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the top-level landing page for the external system, such as the console page for AWS CodeDeploy. This link is shown on the pipeline view page in the AWS CodePipeline console and provides a link to the execution entity of the external action.</p>
#[doc(hidden)]
pub execution_url_template: std::option::Option<std::string::String>,
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
#[doc(hidden)]
pub revision_url_template: std::option::Option<std::string::String>,
}
impl ActionTypeSettings {
/// <p>The URL of a sign-up page where users can sign up for an external service and perform initial configuration of the action provided by that service.</p>
pub fn third_party_configuration_url(&self) -> std::option::Option<&str> {
self.third_party_configuration_url.as_deref()
}
/// <p>The URL returned to the AWS CodePipeline console that provides a deep link to the resources of the external system, such as the configuration page for an AWS CodeDeploy deployment group. This link is provided as part of the action display in the pipeline.</p>
pub fn entity_url_template(&self) -> std::option::Option<&str> {
self.entity_url_template.as_deref()
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the top-level landing page for the external system, such as the console page for AWS CodeDeploy. This link is shown on the pipeline view page in the AWS CodePipeline console and provides a link to the execution entity of the external action.</p>
pub fn execution_url_template(&self) -> std::option::Option<&str> {
self.execution_url_template.as_deref()
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn revision_url_template(&self) -> std::option::Option<&str> {
self.revision_url_template.as_deref()
}
}
/// See [`ActionTypeSettings`](crate::model::ActionTypeSettings).
pub mod action_type_settings {
/// A builder for [`ActionTypeSettings`](crate::model::ActionTypeSettings).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) third_party_configuration_url: std::option::Option<std::string::String>,
pub(crate) entity_url_template: std::option::Option<std::string::String>,
pub(crate) execution_url_template: std::option::Option<std::string::String>,
pub(crate) revision_url_template: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The URL of a sign-up page where users can sign up for an external service and perform initial configuration of the action provided by that service.</p>
pub fn third_party_configuration_url(
mut self,
input: impl Into<std::string::String>,
) -> Self {
self.third_party_configuration_url = Some(input.into());
self
}
/// <p>The URL of a sign-up page where users can sign up for an external service and perform initial configuration of the action provided by that service.</p>
pub fn set_third_party_configuration_url(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.third_party_configuration_url = input;
self
}
/// <p>The URL returned to the AWS CodePipeline console that provides a deep link to the resources of the external system, such as the configuration page for an AWS CodeDeploy deployment group. This link is provided as part of the action display in the pipeline.</p>
pub fn entity_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.entity_url_template = Some(input.into());
self
}
/// <p>The URL returned to the AWS CodePipeline console that provides a deep link to the resources of the external system, such as the configuration page for an AWS CodeDeploy deployment group. This link is provided as part of the action display in the pipeline.</p>
pub fn set_entity_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.entity_url_template = input;
self
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the top-level landing page for the external system, such as the console page for AWS CodeDeploy. This link is shown on the pipeline view page in the AWS CodePipeline console and provides a link to the execution entity of the external action.</p>
pub fn execution_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.execution_url_template = Some(input.into());
self
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the top-level landing page for the external system, such as the console page for AWS CodeDeploy. This link is shown on the pipeline view page in the AWS CodePipeline console and provides a link to the execution entity of the external action.</p>
pub fn set_execution_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.execution_url_template = input;
self
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn revision_url_template(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_url_template = Some(input.into());
self
}
/// <p>The URL returned to the AWS CodePipeline console that contains a link to the page where customers can update or change the configuration of the external action.</p>
pub fn set_revision_url_template(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_url_template = input;
self
}
/// Consumes the builder and constructs a [`ActionTypeSettings`](crate::model::ActionTypeSettings).
pub fn build(self) -> crate::model::ActionTypeSettings {
crate::model::ActionTypeSettings {
third_party_configuration_url: self.third_party_configuration_url,
entity_url_template: self.entity_url_template,
execution_url_template: self.execution_url_template,
revision_url_template: self.revision_url_template,
}
}
}
}
impl ActionTypeSettings {
/// Creates a new builder-style object to manufacture [`ActionTypeSettings`](crate::model::ActionTypeSettings).
pub fn builder() -> crate::model::action_type_settings::Builder {
crate::model::action_type_settings::Builder::default()
}
}
/// <p>Returns information about an execution of an action, including the action execution ID, and the name, version, and timing of the action. </p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecutionDetail {
/// <p>The pipeline execution ID for the action execution.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
/// <p>The action execution ID.</p>
#[doc(hidden)]
pub action_execution_id: std::option::Option<std::string::String>,
/// <p>The version of the pipeline where the action was run.</p>
#[doc(hidden)]
pub pipeline_version: std::option::Option<i32>,
/// <p>The name of the stage that contains the action.</p>
#[doc(hidden)]
pub stage_name: std::option::Option<std::string::String>,
/// <p>The name of the action.</p>
#[doc(hidden)]
pub action_name: std::option::Option<std::string::String>,
/// <p>The start time of the action execution.</p>
#[doc(hidden)]
pub start_time: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The last update time of the action execution.</p>
#[doc(hidden)]
pub last_update_time: std::option::Option<aws_smithy_types::DateTime>,
/// <p> The status of the action execution. Status categories are <code>InProgress</code>, <code>Succeeded</code>, and <code>Failed</code>.</p>
#[doc(hidden)]
pub status: std::option::Option<crate::model::ActionExecutionStatus>,
/// <p>Input details for the action execution, such as role ARN, Region, and input artifacts.</p>
#[doc(hidden)]
pub input: std::option::Option<crate::model::ActionExecutionInput>,
/// <p>Output details for the action execution, such as the action execution result.</p>
#[doc(hidden)]
pub output: std::option::Option<crate::model::ActionExecutionOutput>,
}
impl ActionExecutionDetail {
/// <p>The pipeline execution ID for the action execution.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
/// <p>The action execution ID.</p>
pub fn action_execution_id(&self) -> std::option::Option<&str> {
self.action_execution_id.as_deref()
}
/// <p>The version of the pipeline where the action was run.</p>
pub fn pipeline_version(&self) -> std::option::Option<i32> {
self.pipeline_version
}
/// <p>The name of the stage that contains the action.</p>
pub fn stage_name(&self) -> std::option::Option<&str> {
self.stage_name.as_deref()
}
/// <p>The name of the action.</p>
pub fn action_name(&self) -> std::option::Option<&str> {
self.action_name.as_deref()
}
/// <p>The start time of the action execution.</p>
pub fn start_time(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.start_time.as_ref()
}
/// <p>The last update time of the action execution.</p>
pub fn last_update_time(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_update_time.as_ref()
}
/// <p> The status of the action execution. Status categories are <code>InProgress</code>, <code>Succeeded</code>, and <code>Failed</code>.</p>
pub fn status(&self) -> std::option::Option<&crate::model::ActionExecutionStatus> {
self.status.as_ref()
}
/// <p>Input details for the action execution, such as role ARN, Region, and input artifacts.</p>
pub fn input(&self) -> std::option::Option<&crate::model::ActionExecutionInput> {
self.input.as_ref()
}
/// <p>Output details for the action execution, such as the action execution result.</p>
pub fn output(&self) -> std::option::Option<&crate::model::ActionExecutionOutput> {
self.output.as_ref()
}
}
/// See [`ActionExecutionDetail`](crate::model::ActionExecutionDetail).
pub mod action_execution_detail {
/// A builder for [`ActionExecutionDetail`](crate::model::ActionExecutionDetail).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
pub(crate) action_execution_id: std::option::Option<std::string::String>,
pub(crate) pipeline_version: std::option::Option<i32>,
pub(crate) stage_name: std::option::Option<std::string::String>,
pub(crate) action_name: std::option::Option<std::string::String>,
pub(crate) start_time: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) last_update_time: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) status: std::option::Option<crate::model::ActionExecutionStatus>,
pub(crate) input: std::option::Option<crate::model::ActionExecutionInput>,
pub(crate) output: std::option::Option<crate::model::ActionExecutionOutput>,
}
impl Builder {
/// <p>The pipeline execution ID for the action execution.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The pipeline execution ID for the action execution.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// <p>The action execution ID.</p>
pub fn action_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.action_execution_id = Some(input.into());
self
}
/// <p>The action execution ID.</p>
pub fn set_action_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.action_execution_id = input;
self
}
/// <p>The version of the pipeline where the action was run.</p>
pub fn pipeline_version(mut self, input: i32) -> Self {
self.pipeline_version = Some(input);
self
}
/// <p>The version of the pipeline where the action was run.</p>
pub fn set_pipeline_version(mut self, input: std::option::Option<i32>) -> Self {
self.pipeline_version = input;
self
}
/// <p>The name of the stage that contains the action.</p>
pub fn stage_name(mut self, input: impl Into<std::string::String>) -> Self {
self.stage_name = Some(input.into());
self
}
/// <p>The name of the stage that contains the action.</p>
pub fn set_stage_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.stage_name = input;
self
}
/// <p>The name of the action.</p>
pub fn action_name(mut self, input: impl Into<std::string::String>) -> Self {
self.action_name = Some(input.into());
self
}
/// <p>The name of the action.</p>
pub fn set_action_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.action_name = input;
self
}
/// <p>The start time of the action execution.</p>
pub fn start_time(mut self, input: aws_smithy_types::DateTime) -> Self {
self.start_time = Some(input);
self
}
/// <p>The start time of the action execution.</p>
pub fn set_start_time(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.start_time = input;
self
}
/// <p>The last update time of the action execution.</p>
pub fn last_update_time(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_update_time = Some(input);
self
}
/// <p>The last update time of the action execution.</p>
pub fn set_last_update_time(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_update_time = input;
self
}
/// <p> The status of the action execution. Status categories are <code>InProgress</code>, <code>Succeeded</code>, and <code>Failed</code>.</p>
pub fn status(mut self, input: crate::model::ActionExecutionStatus) -> Self {
self.status = Some(input);
self
}
/// <p> The status of the action execution. Status categories are <code>InProgress</code>, <code>Succeeded</code>, and <code>Failed</code>.</p>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::ActionExecutionStatus>,
) -> Self {
self.status = input;
self
}
/// <p>Input details for the action execution, such as role ARN, Region, and input artifacts.</p>
pub fn input(mut self, input: crate::model::ActionExecutionInput) -> Self {
self.input = Some(input);
self
}
/// <p>Input details for the action execution, such as role ARN, Region, and input artifacts.</p>
pub fn set_input(
mut self,
input: std::option::Option<crate::model::ActionExecutionInput>,
) -> Self {
self.input = input;
self
}
/// <p>Output details for the action execution, such as the action execution result.</p>
pub fn output(mut self, input: crate::model::ActionExecutionOutput) -> Self {
self.output = Some(input);
self
}
/// <p>Output details for the action execution, such as the action execution result.</p>
pub fn set_output(
mut self,
input: std::option::Option<crate::model::ActionExecutionOutput>,
) -> Self {
self.output = input;
self
}
/// Consumes the builder and constructs a [`ActionExecutionDetail`](crate::model::ActionExecutionDetail).
pub fn build(self) -> crate::model::ActionExecutionDetail {
crate::model::ActionExecutionDetail {
pipeline_execution_id: self.pipeline_execution_id,
action_execution_id: self.action_execution_id,
pipeline_version: self.pipeline_version,
stage_name: self.stage_name,
action_name: self.action_name,
start_time: self.start_time,
last_update_time: self.last_update_time,
status: self.status,
input: self.input,
output: self.output,
}
}
}
}
impl ActionExecutionDetail {
/// Creates a new builder-style object to manufacture [`ActionExecutionDetail`](crate::model::ActionExecutionDetail).
pub fn builder() -> crate::model::action_execution_detail::Builder {
crate::model::action_execution_detail::Builder::default()
}
}
/// <p>Output details listed for an action execution, such as the action execution result.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecutionOutput {
/// <p>Details of output artifacts of the action that correspond to the action execution.</p>
#[doc(hidden)]
pub output_artifacts: std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
/// <p>Execution result information listed in the output details for an action execution.</p>
#[doc(hidden)]
pub execution_result: std::option::Option<crate::model::ActionExecutionResult>,
/// <p>The outputVariables field shows the key-value pairs that were output as part of that execution.</p>
#[doc(hidden)]
pub output_variables:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
}
impl ActionExecutionOutput {
/// <p>Details of output artifacts of the action that correspond to the action execution.</p>
pub fn output_artifacts(&self) -> std::option::Option<&[crate::model::ArtifactDetail]> {
self.output_artifacts.as_deref()
}
/// <p>Execution result information listed in the output details for an action execution.</p>
pub fn execution_result(&self) -> std::option::Option<&crate::model::ActionExecutionResult> {
self.execution_result.as_ref()
}
/// <p>The outputVariables field shows the key-value pairs that were output as part of that execution.</p>
pub fn output_variables(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.output_variables.as_ref()
}
}
/// See [`ActionExecutionOutput`](crate::model::ActionExecutionOutput).
pub mod action_execution_output {
/// A builder for [`ActionExecutionOutput`](crate::model::ActionExecutionOutput).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) output_artifacts:
std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
pub(crate) execution_result: std::option::Option<crate::model::ActionExecutionResult>,
pub(crate) output_variables: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
}
impl Builder {
/// Appends an item to `output_artifacts`.
///
/// To override the contents of this collection use [`set_output_artifacts`](Self::set_output_artifacts).
///
/// <p>Details of output artifacts of the action that correspond to the action execution.</p>
pub fn output_artifacts(mut self, input: crate::model::ArtifactDetail) -> Self {
let mut v = self.output_artifacts.unwrap_or_default();
v.push(input);
self.output_artifacts = Some(v);
self
}
/// <p>Details of output artifacts of the action that correspond to the action execution.</p>
pub fn set_output_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
) -> Self {
self.output_artifacts = input;
self
}
/// <p>Execution result information listed in the output details for an action execution.</p>
pub fn execution_result(mut self, input: crate::model::ActionExecutionResult) -> Self {
self.execution_result = Some(input);
self
}
/// <p>Execution result information listed in the output details for an action execution.</p>
pub fn set_execution_result(
mut self,
input: std::option::Option<crate::model::ActionExecutionResult>,
) -> Self {
self.execution_result = input;
self
}
/// Adds a key-value pair to `output_variables`.
///
/// To override the contents of this collection use [`set_output_variables`](Self::set_output_variables).
///
/// <p>The outputVariables field shows the key-value pairs that were output as part of that execution.</p>
pub fn output_variables(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.output_variables.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.output_variables = Some(hash_map);
self
}
/// <p>The outputVariables field shows the key-value pairs that were output as part of that execution.</p>
pub fn set_output_variables(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.output_variables = input;
self
}
/// Consumes the builder and constructs a [`ActionExecutionOutput`](crate::model::ActionExecutionOutput).
pub fn build(self) -> crate::model::ActionExecutionOutput {
crate::model::ActionExecutionOutput {
output_artifacts: self.output_artifacts,
execution_result: self.execution_result,
output_variables: self.output_variables,
}
}
}
}
impl ActionExecutionOutput {
/// Creates a new builder-style object to manufacture [`ActionExecutionOutput`](crate::model::ActionExecutionOutput).
pub fn builder() -> crate::model::action_execution_output::Builder {
crate::model::action_execution_output::Builder::default()
}
}
/// <p>Execution result information, such as the external execution ID.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecutionResult {
/// <p>The action provider's external ID for the action execution.</p>
#[doc(hidden)]
pub external_execution_id: std::option::Option<std::string::String>,
/// <p>The action provider's summary for the action execution.</p>
#[doc(hidden)]
pub external_execution_summary: std::option::Option<std::string::String>,
/// <p>The deepest external link to the external resource (for example, a repository URL or deployment endpoint) that is used when running the action.</p>
#[doc(hidden)]
pub external_execution_url: std::option::Option<std::string::String>,
}
impl ActionExecutionResult {
/// <p>The action provider's external ID for the action execution.</p>
pub fn external_execution_id(&self) -> std::option::Option<&str> {
self.external_execution_id.as_deref()
}
/// <p>The action provider's summary for the action execution.</p>
pub fn external_execution_summary(&self) -> std::option::Option<&str> {
self.external_execution_summary.as_deref()
}
/// <p>The deepest external link to the external resource (for example, a repository URL or deployment endpoint) that is used when running the action.</p>
pub fn external_execution_url(&self) -> std::option::Option<&str> {
self.external_execution_url.as_deref()
}
}
/// See [`ActionExecutionResult`](crate::model::ActionExecutionResult).
pub mod action_execution_result {
/// A builder for [`ActionExecutionResult`](crate::model::ActionExecutionResult).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) external_execution_id: std::option::Option<std::string::String>,
pub(crate) external_execution_summary: std::option::Option<std::string::String>,
pub(crate) external_execution_url: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The action provider's external ID for the action execution.</p>
pub fn external_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_id = Some(input.into());
self
}
/// <p>The action provider's external ID for the action execution.</p>
pub fn set_external_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_id = input;
self
}
/// <p>The action provider's summary for the action execution.</p>
pub fn external_execution_summary(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_summary = Some(input.into());
self
}
/// <p>The action provider's summary for the action execution.</p>
pub fn set_external_execution_summary(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_summary = input;
self
}
/// <p>The deepest external link to the external resource (for example, a repository URL or deployment endpoint) that is used when running the action.</p>
pub fn external_execution_url(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_url = Some(input.into());
self
}
/// <p>The deepest external link to the external resource (for example, a repository URL or deployment endpoint) that is used when running the action.</p>
pub fn set_external_execution_url(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_url = input;
self
}
/// Consumes the builder and constructs a [`ActionExecutionResult`](crate::model::ActionExecutionResult).
pub fn build(self) -> crate::model::ActionExecutionResult {
crate::model::ActionExecutionResult {
external_execution_id: self.external_execution_id,
external_execution_summary: self.external_execution_summary,
external_execution_url: self.external_execution_url,
}
}
}
}
impl ActionExecutionResult {
/// Creates a new builder-style object to manufacture [`ActionExecutionResult`](crate::model::ActionExecutionResult).
pub fn builder() -> crate::model::action_execution_result::Builder {
crate::model::action_execution_result::Builder::default()
}
}
/// <p>Artifact details for the action execution, such as the artifact location.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ArtifactDetail {
/// <p>The artifact object name for the action execution.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The Amazon S3 artifact location for the action execution.</p>
#[doc(hidden)]
pub s3location: std::option::Option<crate::model::S3Location>,
}
impl ArtifactDetail {
/// <p>The artifact object name for the action execution.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The Amazon S3 artifact location for the action execution.</p>
pub fn s3location(&self) -> std::option::Option<&crate::model::S3Location> {
self.s3location.as_ref()
}
}
/// See [`ArtifactDetail`](crate::model::ArtifactDetail).
pub mod artifact_detail {
/// A builder for [`ArtifactDetail`](crate::model::ArtifactDetail).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) s3location: std::option::Option<crate::model::S3Location>,
}
impl Builder {
/// <p>The artifact object name for the action execution.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The artifact object name for the action execution.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The Amazon S3 artifact location for the action execution.</p>
pub fn s3location(mut self, input: crate::model::S3Location) -> Self {
self.s3location = Some(input);
self
}
/// <p>The Amazon S3 artifact location for the action execution.</p>
pub fn set_s3location(
mut self,
input: std::option::Option<crate::model::S3Location>,
) -> Self {
self.s3location = input;
self
}
/// Consumes the builder and constructs a [`ArtifactDetail`](crate::model::ArtifactDetail).
pub fn build(self) -> crate::model::ArtifactDetail {
crate::model::ArtifactDetail {
name: self.name,
s3location: self.s3location,
}
}
}
}
impl ArtifactDetail {
/// Creates a new builder-style object to manufacture [`ArtifactDetail`](crate::model::ArtifactDetail).
pub fn builder() -> crate::model::artifact_detail::Builder {
crate::model::artifact_detail::Builder::default()
}
}
/// <p>The Amazon S3 artifact location for an action's artifacts.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct S3Location {
/// <p>The Amazon S3 artifact bucket for an action's artifacts.</p>
#[doc(hidden)]
pub bucket: std::option::Option<std::string::String>,
/// <p>The artifact name.</p>
#[doc(hidden)]
pub key: std::option::Option<std::string::String>,
}
impl S3Location {
/// <p>The Amazon S3 artifact bucket for an action's artifacts.</p>
pub fn bucket(&self) -> std::option::Option<&str> {
self.bucket.as_deref()
}
/// <p>The artifact name.</p>
pub fn key(&self) -> std::option::Option<&str> {
self.key.as_deref()
}
}
/// See [`S3Location`](crate::model::S3Location).
pub mod s3_location {
/// A builder for [`S3Location`](crate::model::S3Location).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) bucket: std::option::Option<std::string::String>,
pub(crate) key: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The Amazon S3 artifact bucket for an action's artifacts.</p>
pub fn bucket(mut self, input: impl Into<std::string::String>) -> Self {
self.bucket = Some(input.into());
self
}
/// <p>The Amazon S3 artifact bucket for an action's artifacts.</p>
pub fn set_bucket(mut self, input: std::option::Option<std::string::String>) -> Self {
self.bucket = input;
self
}
/// <p>The artifact name.</p>
pub fn key(mut self, input: impl Into<std::string::String>) -> Self {
self.key = Some(input.into());
self
}
/// <p>The artifact name.</p>
pub fn set_key(mut self, input: std::option::Option<std::string::String>) -> Self {
self.key = input;
self
}
/// Consumes the builder and constructs a [`S3Location`](crate::model::S3Location).
pub fn build(self) -> crate::model::S3Location {
crate::model::S3Location {
bucket: self.bucket,
key: self.key,
}
}
}
}
impl S3Location {
/// Creates a new builder-style object to manufacture [`S3Location`](crate::model::S3Location).
pub fn builder() -> crate::model::s3_location::Builder {
crate::model::s3_location::Builder::default()
}
}
/// <p>Input information used for an action execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecutionInput {
/// <p>Represents information about an action type.</p>
#[doc(hidden)]
pub action_type_id: std::option::Option<crate::model::ActionTypeId>,
/// <p>Configuration data for an action execution.</p>
#[doc(hidden)]
pub configuration:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
/// <p>Configuration data for an action execution with all variable references replaced with their real values for the execution.</p>
#[doc(hidden)]
pub resolved_configuration:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline. </p>
#[doc(hidden)]
pub role_arn: std::option::Option<std::string::String>,
/// <p>The AWS Region for the action, such as us-east-1.</p>
#[doc(hidden)]
pub region: std::option::Option<std::string::String>,
/// <p>Details of input artifacts of the action that correspond to the action execution.</p>
#[doc(hidden)]
pub input_artifacts: std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
#[doc(hidden)]
pub namespace: std::option::Option<std::string::String>,
}
impl ActionExecutionInput {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(&self) -> std::option::Option<&crate::model::ActionTypeId> {
self.action_type_id.as_ref()
}
/// <p>Configuration data for an action execution.</p>
pub fn configuration(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.configuration.as_ref()
}
/// <p>Configuration data for an action execution with all variable references replaced with their real values for the execution.</p>
pub fn resolved_configuration(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.resolved_configuration.as_ref()
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline. </p>
pub fn role_arn(&self) -> std::option::Option<&str> {
self.role_arn.as_deref()
}
/// <p>The AWS Region for the action, such as us-east-1.</p>
pub fn region(&self) -> std::option::Option<&str> {
self.region.as_deref()
}
/// <p>Details of input artifacts of the action that correspond to the action execution.</p>
pub fn input_artifacts(&self) -> std::option::Option<&[crate::model::ArtifactDetail]> {
self.input_artifacts.as_deref()
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn namespace(&self) -> std::option::Option<&str> {
self.namespace.as_deref()
}
}
/// See [`ActionExecutionInput`](crate::model::ActionExecutionInput).
pub mod action_execution_input {
/// A builder for [`ActionExecutionInput`](crate::model::ActionExecutionInput).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) action_type_id: std::option::Option<crate::model::ActionTypeId>,
pub(crate) configuration: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
pub(crate) resolved_configuration: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
pub(crate) role_arn: std::option::Option<std::string::String>,
pub(crate) region: std::option::Option<std::string::String>,
pub(crate) input_artifacts:
std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
pub(crate) namespace: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(mut self, input: crate::model::ActionTypeId) -> Self {
self.action_type_id = Some(input);
self
}
/// <p>Represents information about an action type.</p>
pub fn set_action_type_id(
mut self,
input: std::option::Option<crate::model::ActionTypeId>,
) -> Self {
self.action_type_id = input;
self
}
/// Adds a key-value pair to `configuration`.
///
/// To override the contents of this collection use [`set_configuration`](Self::set_configuration).
///
/// <p>Configuration data for an action execution.</p>
pub fn configuration(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.configuration.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.configuration = Some(hash_map);
self
}
/// <p>Configuration data for an action execution.</p>
pub fn set_configuration(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.configuration = input;
self
}
/// Adds a key-value pair to `resolved_configuration`.
///
/// To override the contents of this collection use [`set_resolved_configuration`](Self::set_resolved_configuration).
///
/// <p>Configuration data for an action execution with all variable references replaced with their real values for the execution.</p>
pub fn resolved_configuration(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.resolved_configuration.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.resolved_configuration = Some(hash_map);
self
}
/// <p>Configuration data for an action execution with all variable references replaced with their real values for the execution.</p>
pub fn set_resolved_configuration(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.resolved_configuration = input;
self
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline. </p>
pub fn role_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.role_arn = Some(input.into());
self
}
/// <p>The ARN of the IAM service role that performs the declared action. This is assumed through the roleArn for the pipeline. </p>
pub fn set_role_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.role_arn = input;
self
}
/// <p>The AWS Region for the action, such as us-east-1.</p>
pub fn region(mut self, input: impl Into<std::string::String>) -> Self {
self.region = Some(input.into());
self
}
/// <p>The AWS Region for the action, such as us-east-1.</p>
pub fn set_region(mut self, input: std::option::Option<std::string::String>) -> Self {
self.region = input;
self
}
/// Appends an item to `input_artifacts`.
///
/// To override the contents of this collection use [`set_input_artifacts`](Self::set_input_artifacts).
///
/// <p>Details of input artifacts of the action that correspond to the action execution.</p>
pub fn input_artifacts(mut self, input: crate::model::ArtifactDetail) -> Self {
let mut v = self.input_artifacts.unwrap_or_default();
v.push(input);
self.input_artifacts = Some(v);
self
}
/// <p>Details of input artifacts of the action that correspond to the action execution.</p>
pub fn set_input_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ArtifactDetail>>,
) -> Self {
self.input_artifacts = input;
self
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn namespace(mut self, input: impl Into<std::string::String>) -> Self {
self.namespace = Some(input.into());
self
}
/// <p>The variable namespace associated with the action. All variables produced as output by this action fall under this namespace.</p>
pub fn set_namespace(mut self, input: std::option::Option<std::string::String>) -> Self {
self.namespace = input;
self
}
/// Consumes the builder and constructs a [`ActionExecutionInput`](crate::model::ActionExecutionInput).
pub fn build(self) -> crate::model::ActionExecutionInput {
crate::model::ActionExecutionInput {
action_type_id: self.action_type_id,
configuration: self.configuration,
resolved_configuration: self.resolved_configuration,
role_arn: self.role_arn,
region: self.region,
input_artifacts: self.input_artifacts,
namespace: self.namespace,
}
}
}
}
impl ActionExecutionInput {
/// Creates a new builder-style object to manufacture [`ActionExecutionInput`](crate::model::ActionExecutionInput).
pub fn builder() -> crate::model::action_execution_input::Builder {
crate::model::action_execution_input::Builder::default()
}
}
/// When writing a match expression against `ActionExecutionStatus`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let actionexecutionstatus = unimplemented!();
/// match actionexecutionstatus {
/// ActionExecutionStatus::Abandoned => { /* ... */ },
/// ActionExecutionStatus::Failed => { /* ... */ },
/// ActionExecutionStatus::InProgress => { /* ... */ },
/// ActionExecutionStatus::Succeeded => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `actionexecutionstatus` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `ActionExecutionStatus::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `ActionExecutionStatus::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `ActionExecutionStatus::NewFeature` is defined.
/// Specifically, when `actionexecutionstatus` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `ActionExecutionStatus::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum ActionExecutionStatus {
#[allow(missing_docs)] // documentation missing in model
Abandoned,
#[allow(missing_docs)] // documentation missing in model
Failed,
#[allow(missing_docs)] // documentation missing in model
InProgress,
#[allow(missing_docs)] // documentation missing in model
Succeeded,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for ActionExecutionStatus {
fn from(s: &str) -> Self {
match s {
"Abandoned" => ActionExecutionStatus::Abandoned,
"Failed" => ActionExecutionStatus::Failed,
"InProgress" => ActionExecutionStatus::InProgress,
"Succeeded" => ActionExecutionStatus::Succeeded,
other => {
ActionExecutionStatus::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for ActionExecutionStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(ActionExecutionStatus::from(s))
}
}
impl ActionExecutionStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
ActionExecutionStatus::Abandoned => "Abandoned",
ActionExecutionStatus::Failed => "Failed",
ActionExecutionStatus::InProgress => "InProgress",
ActionExecutionStatus::Succeeded => "Succeeded",
ActionExecutionStatus::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Abandoned", "Failed", "InProgress", "Succeeded"]
}
}
impl AsRef<str> for ActionExecutionStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Filter values for the action execution.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecutionFilter {
/// <p>The pipeline execution ID used to filter action execution history.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
}
impl ActionExecutionFilter {
/// <p>The pipeline execution ID used to filter action execution history.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
}
/// See [`ActionExecutionFilter`](crate::model::ActionExecutionFilter).
pub mod action_execution_filter {
/// A builder for [`ActionExecutionFilter`](crate::model::ActionExecutionFilter).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The pipeline execution ID used to filter action execution history.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The pipeline execution ID used to filter action execution history.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// Consumes the builder and constructs a [`ActionExecutionFilter`](crate::model::ActionExecutionFilter).
pub fn build(self) -> crate::model::ActionExecutionFilter {
crate::model::ActionExecutionFilter {
pipeline_execution_id: self.pipeline_execution_id,
}
}
}
}
impl ActionExecutionFilter {
/// Creates a new builder-style object to manufacture [`ActionExecutionFilter`](crate::model::ActionExecutionFilter).
pub fn builder() -> crate::model::action_execution_filter::Builder {
crate::model::action_execution_filter::Builder::default()
}
}
/// <p>The details of a job sent in response to a <code>GetThirdPartyJobDetails</code> request.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ThirdPartyJobDetails {
/// <p>The identifier used to identify the job details in AWS CodePipeline.</p>
#[doc(hidden)]
pub id: std::option::Option<std::string::String>,
/// <p>The data to be returned by the third party job worker.</p>
#[doc(hidden)]
pub data: std::option::Option<crate::model::ThirdPartyJobData>,
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeThirdPartyJob</code> request.</p>
#[doc(hidden)]
pub nonce: std::option::Option<std::string::String>,
}
impl ThirdPartyJobDetails {
/// <p>The identifier used to identify the job details in AWS CodePipeline.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>The data to be returned by the third party job worker.</p>
pub fn data(&self) -> std::option::Option<&crate::model::ThirdPartyJobData> {
self.data.as_ref()
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeThirdPartyJob</code> request.</p>
pub fn nonce(&self) -> std::option::Option<&str> {
self.nonce.as_deref()
}
}
/// See [`ThirdPartyJobDetails`](crate::model::ThirdPartyJobDetails).
pub mod third_party_job_details {
/// A builder for [`ThirdPartyJobDetails`](crate::model::ThirdPartyJobDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) data: std::option::Option<crate::model::ThirdPartyJobData>,
pub(crate) nonce: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The identifier used to identify the job details in AWS CodePipeline.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The identifier used to identify the job details in AWS CodePipeline.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>The data to be returned by the third party job worker.</p>
pub fn data(mut self, input: crate::model::ThirdPartyJobData) -> Self {
self.data = Some(input);
self
}
/// <p>The data to be returned by the third party job worker.</p>
pub fn set_data(
mut self,
input: std::option::Option<crate::model::ThirdPartyJobData>,
) -> Self {
self.data = input;
self
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeThirdPartyJob</code> request.</p>
pub fn nonce(mut self, input: impl Into<std::string::String>) -> Self {
self.nonce = Some(input.into());
self
}
/// <p>A system-generated random number that AWS CodePipeline uses to ensure that the job is being worked on by only one job worker. Use this number in an <code>AcknowledgeThirdPartyJob</code> request.</p>
pub fn set_nonce(mut self, input: std::option::Option<std::string::String>) -> Self {
self.nonce = input;
self
}
/// Consumes the builder and constructs a [`ThirdPartyJobDetails`](crate::model::ThirdPartyJobDetails).
pub fn build(self) -> crate::model::ThirdPartyJobDetails {
crate::model::ThirdPartyJobDetails {
id: self.id,
data: self.data,
nonce: self.nonce,
}
}
}
}
impl ThirdPartyJobDetails {
/// Creates a new builder-style object to manufacture [`ThirdPartyJobDetails`](crate::model::ThirdPartyJobDetails).
pub fn builder() -> crate::model::third_party_job_details::Builder {
crate::model::third_party_job_details::Builder::default()
}
}
/// <p>Represents information about the job data for a partner action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq)]
pub struct ThirdPartyJobData {
/// <p>Represents information about an action type.</p>
#[doc(hidden)]
pub action_type_id: std::option::Option<crate::model::ActionTypeId>,
/// <p>Represents information about an action configuration.</p>
#[doc(hidden)]
pub action_configuration: std::option::Option<crate::model::ActionConfiguration>,
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Does not include <code>pipelineArn</code> and <code>pipelineExecutionId</code> for ThirdParty jobs.</p>
/// </note>
#[doc(hidden)]
pub pipeline_context: std::option::Option<crate::model::PipelineContext>,
/// <p>The name of the artifact that is worked on by the action, if any. This name might be system-generated, such as "MyApp", or it might be defined by the user when the action is created. The input artifact name must match the name of an output artifact generated by an action in an earlier action or stage of the pipeline.</p>
#[doc(hidden)]
pub input_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
/// <p>The name of the artifact that is the result of the action, if any. This name might be system-generated, such as "MyBuiltApp", or it might be defined by the user when the action is created.</p>
#[doc(hidden)]
pub output_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifact for the pipeline in AWS CodePipeline. </p>
#[doc(hidden)]
pub artifact_credentials: std::option::Option<crate::model::AwsSessionCredentials>,
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, that a job requires to continue the job asynchronously.</p>
#[doc(hidden)]
pub continuation_token: std::option::Option<std::string::String>,
/// <p>The encryption key used to encrypt and decrypt data in the artifact store for the pipeline, such as an AWS Key Management Service (AWS KMS) key. This is optional and might not be present.</p>
#[doc(hidden)]
pub encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl ThirdPartyJobData {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(&self) -> std::option::Option<&crate::model::ActionTypeId> {
self.action_type_id.as_ref()
}
/// <p>Represents information about an action configuration.</p>
pub fn action_configuration(&self) -> std::option::Option<&crate::model::ActionConfiguration> {
self.action_configuration.as_ref()
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Does not include <code>pipelineArn</code> and <code>pipelineExecutionId</code> for ThirdParty jobs.</p>
/// </note>
pub fn pipeline_context(&self) -> std::option::Option<&crate::model::PipelineContext> {
self.pipeline_context.as_ref()
}
/// <p>The name of the artifact that is worked on by the action, if any. This name might be system-generated, such as "MyApp", or it might be defined by the user when the action is created. The input artifact name must match the name of an output artifact generated by an action in an earlier action or stage of the pipeline.</p>
pub fn input_artifacts(&self) -> std::option::Option<&[crate::model::Artifact]> {
self.input_artifacts.as_deref()
}
/// <p>The name of the artifact that is the result of the action, if any. This name might be system-generated, such as "MyBuiltApp", or it might be defined by the user when the action is created.</p>
pub fn output_artifacts(&self) -> std::option::Option<&[crate::model::Artifact]> {
self.output_artifacts.as_deref()
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifact for the pipeline in AWS CodePipeline. </p>
pub fn artifact_credentials(
&self,
) -> std::option::Option<&crate::model::AwsSessionCredentials> {
self.artifact_credentials.as_ref()
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, that a job requires to continue the job asynchronously.</p>
pub fn continuation_token(&self) -> std::option::Option<&str> {
self.continuation_token.as_deref()
}
/// <p>The encryption key used to encrypt and decrypt data in the artifact store for the pipeline, such as an AWS Key Management Service (AWS KMS) key. This is optional and might not be present.</p>
pub fn encryption_key(&self) -> std::option::Option<&crate::model::EncryptionKey> {
self.encryption_key.as_ref()
}
}
impl std::fmt::Debug for ThirdPartyJobData {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("ThirdPartyJobData");
formatter.field("action_type_id", &self.action_type_id);
formatter.field("action_configuration", &self.action_configuration);
formatter.field("pipeline_context", &self.pipeline_context);
formatter.field("input_artifacts", &self.input_artifacts);
formatter.field("output_artifacts", &self.output_artifacts);
formatter.field("artifact_credentials", &"*** Sensitive Data Redacted ***");
formatter.field("continuation_token", &self.continuation_token);
formatter.field("encryption_key", &self.encryption_key);
formatter.finish()
}
}
/// See [`ThirdPartyJobData`](crate::model::ThirdPartyJobData).
pub mod third_party_job_data {
/// A builder for [`ThirdPartyJobData`](crate::model::ThirdPartyJobData).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default)]
pub struct Builder {
pub(crate) action_type_id: std::option::Option<crate::model::ActionTypeId>,
pub(crate) action_configuration: std::option::Option<crate::model::ActionConfiguration>,
pub(crate) pipeline_context: std::option::Option<crate::model::PipelineContext>,
pub(crate) input_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
pub(crate) output_artifacts: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
pub(crate) artifact_credentials: std::option::Option<crate::model::AwsSessionCredentials>,
pub(crate) continuation_token: std::option::Option<std::string::String>,
pub(crate) encryption_key: std::option::Option<crate::model::EncryptionKey>,
}
impl Builder {
/// <p>Represents information about an action type.</p>
pub fn action_type_id(mut self, input: crate::model::ActionTypeId) -> Self {
self.action_type_id = Some(input);
self
}
/// <p>Represents information about an action type.</p>
pub fn set_action_type_id(
mut self,
input: std::option::Option<crate::model::ActionTypeId>,
) -> Self {
self.action_type_id = input;
self
}
/// <p>Represents information about an action configuration.</p>
pub fn action_configuration(mut self, input: crate::model::ActionConfiguration) -> Self {
self.action_configuration = Some(input);
self
}
/// <p>Represents information about an action configuration.</p>
pub fn set_action_configuration(
mut self,
input: std::option::Option<crate::model::ActionConfiguration>,
) -> Self {
self.action_configuration = input;
self
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Does not include <code>pipelineArn</code> and <code>pipelineExecutionId</code> for ThirdParty jobs.</p>
/// </note>
pub fn pipeline_context(mut self, input: crate::model::PipelineContext) -> Self {
self.pipeline_context = Some(input);
self
}
/// <p>Represents information about a pipeline to a job worker.</p> <note>
/// <p>Does not include <code>pipelineArn</code> and <code>pipelineExecutionId</code> for ThirdParty jobs.</p>
/// </note>
pub fn set_pipeline_context(
mut self,
input: std::option::Option<crate::model::PipelineContext>,
) -> Self {
self.pipeline_context = input;
self
}
/// Appends an item to `input_artifacts`.
///
/// To override the contents of this collection use [`set_input_artifacts`](Self::set_input_artifacts).
///
/// <p>The name of the artifact that is worked on by the action, if any. This name might be system-generated, such as "MyApp", or it might be defined by the user when the action is created. The input artifact name must match the name of an output artifact generated by an action in an earlier action or stage of the pipeline.</p>
pub fn input_artifacts(mut self, input: crate::model::Artifact) -> Self {
let mut v = self.input_artifacts.unwrap_or_default();
v.push(input);
self.input_artifacts = Some(v);
self
}
/// <p>The name of the artifact that is worked on by the action, if any. This name might be system-generated, such as "MyApp", or it might be defined by the user when the action is created. The input artifact name must match the name of an output artifact generated by an action in an earlier action or stage of the pipeline.</p>
pub fn set_input_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
) -> Self {
self.input_artifacts = input;
self
}
/// Appends an item to `output_artifacts`.
///
/// To override the contents of this collection use [`set_output_artifacts`](Self::set_output_artifacts).
///
/// <p>The name of the artifact that is the result of the action, if any. This name might be system-generated, such as "MyBuiltApp", or it might be defined by the user when the action is created.</p>
pub fn output_artifacts(mut self, input: crate::model::Artifact) -> Self {
let mut v = self.output_artifacts.unwrap_or_default();
v.push(input);
self.output_artifacts = Some(v);
self
}
/// <p>The name of the artifact that is the result of the action, if any. This name might be system-generated, such as "MyBuiltApp", or it might be defined by the user when the action is created.</p>
pub fn set_output_artifacts(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::Artifact>>,
) -> Self {
self.output_artifacts = input;
self
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifact for the pipeline in AWS CodePipeline. </p>
pub fn artifact_credentials(mut self, input: crate::model::AwsSessionCredentials) -> Self {
self.artifact_credentials = Some(input);
self
}
/// <p>Represents an AWS session credentials object. These credentials are temporary credentials that are issued by AWS Secure Token Service (STS). They can be used to access input and output artifacts in the S3 bucket used to store artifact for the pipeline in AWS CodePipeline. </p>
pub fn set_artifact_credentials(
mut self,
input: std::option::Option<crate::model::AwsSessionCredentials>,
) -> Self {
self.artifact_credentials = input;
self
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, that a job requires to continue the job asynchronously.</p>
pub fn continuation_token(mut self, input: impl Into<std::string::String>) -> Self {
self.continuation_token = Some(input.into());
self
}
/// <p>A system-generated token, such as a AWS CodeDeploy deployment ID, that a job requires to continue the job asynchronously.</p>
pub fn set_continuation_token(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.continuation_token = input;
self
}
/// <p>The encryption key used to encrypt and decrypt data in the artifact store for the pipeline, such as an AWS Key Management Service (AWS KMS) key. This is optional and might not be present.</p>
pub fn encryption_key(mut self, input: crate::model::EncryptionKey) -> Self {
self.encryption_key = Some(input);
self
}
/// <p>The encryption key used to encrypt and decrypt data in the artifact store for the pipeline, such as an AWS Key Management Service (AWS KMS) key. This is optional and might not be present.</p>
pub fn set_encryption_key(
mut self,
input: std::option::Option<crate::model::EncryptionKey>,
) -> Self {
self.encryption_key = input;
self
}
/// Consumes the builder and constructs a [`ThirdPartyJobData`](crate::model::ThirdPartyJobData).
pub fn build(self) -> crate::model::ThirdPartyJobData {
crate::model::ThirdPartyJobData {
action_type_id: self.action_type_id,
action_configuration: self.action_configuration,
pipeline_context: self.pipeline_context,
input_artifacts: self.input_artifacts,
output_artifacts: self.output_artifacts,
artifact_credentials: self.artifact_credentials,
continuation_token: self.continuation_token,
encryption_key: self.encryption_key,
}
}
}
impl std::fmt::Debug for Builder {
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
let mut formatter = f.debug_struct("Builder");
formatter.field("action_type_id", &self.action_type_id);
formatter.field("action_configuration", &self.action_configuration);
formatter.field("pipeline_context", &self.pipeline_context);
formatter.field("input_artifacts", &self.input_artifacts);
formatter.field("output_artifacts", &self.output_artifacts);
formatter.field("artifact_credentials", &"*** Sensitive Data Redacted ***");
formatter.field("continuation_token", &self.continuation_token);
formatter.field("encryption_key", &self.encryption_key);
formatter.finish()
}
}
}
impl ThirdPartyJobData {
/// Creates a new builder-style object to manufacture [`ThirdPartyJobData`](crate::model::ThirdPartyJobData).
pub fn builder() -> crate::model::third_party_job_data::Builder {
crate::model::third_party_job_data::Builder::default()
}
}
/// <p>Represents information about the state of the stage.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct StageState {
/// <p>The name of the stage.</p>
#[doc(hidden)]
pub stage_name: std::option::Option<std::string::String>,
/// <p>Represents information about the run of a stage.</p>
#[doc(hidden)]
pub inbound_execution: std::option::Option<crate::model::StageExecution>,
/// <p>The state of the inbound transition, which is either enabled or disabled.</p>
#[doc(hidden)]
pub inbound_transition_state: std::option::Option<crate::model::TransitionState>,
/// <p>The state of the stage.</p>
#[doc(hidden)]
pub action_states: std::option::Option<std::vec::Vec<crate::model::ActionState>>,
/// <p>Information about the latest execution in the stage, including its ID and status.</p>
#[doc(hidden)]
pub latest_execution: std::option::Option<crate::model::StageExecution>,
}
impl StageState {
/// <p>The name of the stage.</p>
pub fn stage_name(&self) -> std::option::Option<&str> {
self.stage_name.as_deref()
}
/// <p>Represents information about the run of a stage.</p>
pub fn inbound_execution(&self) -> std::option::Option<&crate::model::StageExecution> {
self.inbound_execution.as_ref()
}
/// <p>The state of the inbound transition, which is either enabled or disabled.</p>
pub fn inbound_transition_state(&self) -> std::option::Option<&crate::model::TransitionState> {
self.inbound_transition_state.as_ref()
}
/// <p>The state of the stage.</p>
pub fn action_states(&self) -> std::option::Option<&[crate::model::ActionState]> {
self.action_states.as_deref()
}
/// <p>Information about the latest execution in the stage, including its ID and status.</p>
pub fn latest_execution(&self) -> std::option::Option<&crate::model::StageExecution> {
self.latest_execution.as_ref()
}
}
/// See [`StageState`](crate::model::StageState).
pub mod stage_state {
/// A builder for [`StageState`](crate::model::StageState).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) stage_name: std::option::Option<std::string::String>,
pub(crate) inbound_execution: std::option::Option<crate::model::StageExecution>,
pub(crate) inbound_transition_state: std::option::Option<crate::model::TransitionState>,
pub(crate) action_states: std::option::Option<std::vec::Vec<crate::model::ActionState>>,
pub(crate) latest_execution: std::option::Option<crate::model::StageExecution>,
}
impl Builder {
/// <p>The name of the stage.</p>
pub fn stage_name(mut self, input: impl Into<std::string::String>) -> Self {
self.stage_name = Some(input.into());
self
}
/// <p>The name of the stage.</p>
pub fn set_stage_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.stage_name = input;
self
}
/// <p>Represents information about the run of a stage.</p>
pub fn inbound_execution(mut self, input: crate::model::StageExecution) -> Self {
self.inbound_execution = Some(input);
self
}
/// <p>Represents information about the run of a stage.</p>
pub fn set_inbound_execution(
mut self,
input: std::option::Option<crate::model::StageExecution>,
) -> Self {
self.inbound_execution = input;
self
}
/// <p>The state of the inbound transition, which is either enabled or disabled.</p>
pub fn inbound_transition_state(mut self, input: crate::model::TransitionState) -> Self {
self.inbound_transition_state = Some(input);
self
}
/// <p>The state of the inbound transition, which is either enabled or disabled.</p>
pub fn set_inbound_transition_state(
mut self,
input: std::option::Option<crate::model::TransitionState>,
) -> Self {
self.inbound_transition_state = input;
self
}
/// Appends an item to `action_states`.
///
/// To override the contents of this collection use [`set_action_states`](Self::set_action_states).
///
/// <p>The state of the stage.</p>
pub fn action_states(mut self, input: crate::model::ActionState) -> Self {
let mut v = self.action_states.unwrap_or_default();
v.push(input);
self.action_states = Some(v);
self
}
/// <p>The state of the stage.</p>
pub fn set_action_states(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ActionState>>,
) -> Self {
self.action_states = input;
self
}
/// <p>Information about the latest execution in the stage, including its ID and status.</p>
pub fn latest_execution(mut self, input: crate::model::StageExecution) -> Self {
self.latest_execution = Some(input);
self
}
/// <p>Information about the latest execution in the stage, including its ID and status.</p>
pub fn set_latest_execution(
mut self,
input: std::option::Option<crate::model::StageExecution>,
) -> Self {
self.latest_execution = input;
self
}
/// Consumes the builder and constructs a [`StageState`](crate::model::StageState).
pub fn build(self) -> crate::model::StageState {
crate::model::StageState {
stage_name: self.stage_name,
inbound_execution: self.inbound_execution,
inbound_transition_state: self.inbound_transition_state,
action_states: self.action_states,
latest_execution: self.latest_execution,
}
}
}
}
impl StageState {
/// Creates a new builder-style object to manufacture [`StageState`](crate::model::StageState).
pub fn builder() -> crate::model::stage_state::Builder {
crate::model::stage_state::Builder::default()
}
}
/// <p>Represents information about the run of a stage.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct StageExecution {
/// <p>The ID of the pipeline execution associated with the stage.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
/// <p>The status of the stage, or for a completed stage, the last status of the stage.</p> <note>
/// <p>A status of cancelled means that the pipeline’s definition was updated before the stage execution could be completed.</p>
/// </note>
#[doc(hidden)]
pub status: std::option::Option<crate::model::StageExecutionStatus>,
}
impl StageExecution {
/// <p>The ID of the pipeline execution associated with the stage.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
/// <p>The status of the stage, or for a completed stage, the last status of the stage.</p> <note>
/// <p>A status of cancelled means that the pipeline’s definition was updated before the stage execution could be completed.</p>
/// </note>
pub fn status(&self) -> std::option::Option<&crate::model::StageExecutionStatus> {
self.status.as_ref()
}
}
/// See [`StageExecution`](crate::model::StageExecution).
pub mod stage_execution {
/// A builder for [`StageExecution`](crate::model::StageExecution).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::StageExecutionStatus>,
}
impl Builder {
/// <p>The ID of the pipeline execution associated with the stage.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The ID of the pipeline execution associated with the stage.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// <p>The status of the stage, or for a completed stage, the last status of the stage.</p> <note>
/// <p>A status of cancelled means that the pipeline’s definition was updated before the stage execution could be completed.</p>
/// </note>
pub fn status(mut self, input: crate::model::StageExecutionStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The status of the stage, or for a completed stage, the last status of the stage.</p> <note>
/// <p>A status of cancelled means that the pipeline’s definition was updated before the stage execution could be completed.</p>
/// </note>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::StageExecutionStatus>,
) -> Self {
self.status = input;
self
}
/// Consumes the builder and constructs a [`StageExecution`](crate::model::StageExecution).
pub fn build(self) -> crate::model::StageExecution {
crate::model::StageExecution {
pipeline_execution_id: self.pipeline_execution_id,
status: self.status,
}
}
}
}
impl StageExecution {
/// Creates a new builder-style object to manufacture [`StageExecution`](crate::model::StageExecution).
pub fn builder() -> crate::model::stage_execution::Builder {
crate::model::stage_execution::Builder::default()
}
}
/// When writing a match expression against `StageExecutionStatus`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let stageexecutionstatus = unimplemented!();
/// match stageexecutionstatus {
/// StageExecutionStatus::Cancelled => { /* ... */ },
/// StageExecutionStatus::Failed => { /* ... */ },
/// StageExecutionStatus::InProgress => { /* ... */ },
/// StageExecutionStatus::Stopped => { /* ... */ },
/// StageExecutionStatus::Stopping => { /* ... */ },
/// StageExecutionStatus::Succeeded => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `stageexecutionstatus` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `StageExecutionStatus::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `StageExecutionStatus::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `StageExecutionStatus::NewFeature` is defined.
/// Specifically, when `stageexecutionstatus` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `StageExecutionStatus::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum StageExecutionStatus {
#[allow(missing_docs)] // documentation missing in model
Cancelled,
#[allow(missing_docs)] // documentation missing in model
Failed,
#[allow(missing_docs)] // documentation missing in model
InProgress,
#[allow(missing_docs)] // documentation missing in model
Stopped,
#[allow(missing_docs)] // documentation missing in model
Stopping,
#[allow(missing_docs)] // documentation missing in model
Succeeded,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for StageExecutionStatus {
fn from(s: &str) -> Self {
match s {
"Cancelled" => StageExecutionStatus::Cancelled,
"Failed" => StageExecutionStatus::Failed,
"InProgress" => StageExecutionStatus::InProgress,
"Stopped" => StageExecutionStatus::Stopped,
"Stopping" => StageExecutionStatus::Stopping,
"Succeeded" => StageExecutionStatus::Succeeded,
other => {
StageExecutionStatus::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for StageExecutionStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(StageExecutionStatus::from(s))
}
}
impl StageExecutionStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
StageExecutionStatus::Cancelled => "Cancelled",
StageExecutionStatus::Failed => "Failed",
StageExecutionStatus::InProgress => "InProgress",
StageExecutionStatus::Stopped => "Stopped",
StageExecutionStatus::Stopping => "Stopping",
StageExecutionStatus::Succeeded => "Succeeded",
StageExecutionStatus::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&[
"Cancelled",
"Failed",
"InProgress",
"Stopped",
"Stopping",
"Succeeded",
]
}
}
impl AsRef<str> for StageExecutionStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// <p>Represents information about the state of an action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionState {
/// <p>The name of the action.</p>
#[doc(hidden)]
pub action_name: std::option::Option<std::string::String>,
/// <p>Represents information about the version (or revision) of an action.</p>
#[doc(hidden)]
pub current_revision: std::option::Option<crate::model::ActionRevision>,
/// <p>Represents information about the run of an action.</p>
#[doc(hidden)]
pub latest_execution: std::option::Option<crate::model::ActionExecution>,
/// <p>A URL link for more information about the state of the action, such as a deployment group details page.</p>
#[doc(hidden)]
pub entity_url: std::option::Option<std::string::String>,
/// <p>A URL link for more information about the revision, such as a commit details page.</p>
#[doc(hidden)]
pub revision_url: std::option::Option<std::string::String>,
}
impl ActionState {
/// <p>The name of the action.</p>
pub fn action_name(&self) -> std::option::Option<&str> {
self.action_name.as_deref()
}
/// <p>Represents information about the version (or revision) of an action.</p>
pub fn current_revision(&self) -> std::option::Option<&crate::model::ActionRevision> {
self.current_revision.as_ref()
}
/// <p>Represents information about the run of an action.</p>
pub fn latest_execution(&self) -> std::option::Option<&crate::model::ActionExecution> {
self.latest_execution.as_ref()
}
/// <p>A URL link for more information about the state of the action, such as a deployment group details page.</p>
pub fn entity_url(&self) -> std::option::Option<&str> {
self.entity_url.as_deref()
}
/// <p>A URL link for more information about the revision, such as a commit details page.</p>
pub fn revision_url(&self) -> std::option::Option<&str> {
self.revision_url.as_deref()
}
}
/// See [`ActionState`](crate::model::ActionState).
pub mod action_state {
/// A builder for [`ActionState`](crate::model::ActionState).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) action_name: std::option::Option<std::string::String>,
pub(crate) current_revision: std::option::Option<crate::model::ActionRevision>,
pub(crate) latest_execution: std::option::Option<crate::model::ActionExecution>,
pub(crate) entity_url: std::option::Option<std::string::String>,
pub(crate) revision_url: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of the action.</p>
pub fn action_name(mut self, input: impl Into<std::string::String>) -> Self {
self.action_name = Some(input.into());
self
}
/// <p>The name of the action.</p>
pub fn set_action_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.action_name = input;
self
}
/// <p>Represents information about the version (or revision) of an action.</p>
pub fn current_revision(mut self, input: crate::model::ActionRevision) -> Self {
self.current_revision = Some(input);
self
}
/// <p>Represents information about the version (or revision) of an action.</p>
pub fn set_current_revision(
mut self,
input: std::option::Option<crate::model::ActionRevision>,
) -> Self {
self.current_revision = input;
self
}
/// <p>Represents information about the run of an action.</p>
pub fn latest_execution(mut self, input: crate::model::ActionExecution) -> Self {
self.latest_execution = Some(input);
self
}
/// <p>Represents information about the run of an action.</p>
pub fn set_latest_execution(
mut self,
input: std::option::Option<crate::model::ActionExecution>,
) -> Self {
self.latest_execution = input;
self
}
/// <p>A URL link for more information about the state of the action, such as a deployment group details page.</p>
pub fn entity_url(mut self, input: impl Into<std::string::String>) -> Self {
self.entity_url = Some(input.into());
self
}
/// <p>A URL link for more information about the state of the action, such as a deployment group details page.</p>
pub fn set_entity_url(mut self, input: std::option::Option<std::string::String>) -> Self {
self.entity_url = input;
self
}
/// <p>A URL link for more information about the revision, such as a commit details page.</p>
pub fn revision_url(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_url = Some(input.into());
self
}
/// <p>A URL link for more information about the revision, such as a commit details page.</p>
pub fn set_revision_url(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_url = input;
self
}
/// Consumes the builder and constructs a [`ActionState`](crate::model::ActionState).
pub fn build(self) -> crate::model::ActionState {
crate::model::ActionState {
action_name: self.action_name,
current_revision: self.current_revision,
latest_execution: self.latest_execution,
entity_url: self.entity_url,
revision_url: self.revision_url,
}
}
}
}
impl ActionState {
/// Creates a new builder-style object to manufacture [`ActionState`](crate::model::ActionState).
pub fn builder() -> crate::model::action_state::Builder {
crate::model::action_state::Builder::default()
}
}
/// <p>Represents information about the run of an action.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ActionExecution {
/// <p>ID of the workflow action execution in the current stage. Use the <code>GetPipelineState</code> action to retrieve the current action execution details of the current stage.</p> <note>
/// <p>For older executions, this field might be empty. The action execution ID is available for executions run on or after March 2020.</p>
/// </note>
#[doc(hidden)]
pub action_execution_id: std::option::Option<std::string::String>,
/// <p>The status of the action, or for a completed action, the last status of the action.</p>
#[doc(hidden)]
pub status: std::option::Option<crate::model::ActionExecutionStatus>,
/// <p>A summary of the run of the action.</p>
#[doc(hidden)]
pub summary: std::option::Option<std::string::String>,
/// <p>The last status change of the action.</p>
#[doc(hidden)]
pub last_status_change: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the <code>GetPipelineState</code> command. It is used to validate that the approval request corresponding to this token is still valid.</p>
#[doc(hidden)]
pub token: std::option::Option<std::string::String>,
/// <p>The ARN of the user who last changed the pipeline.</p>
#[doc(hidden)]
pub last_updated_by: std::option::Option<std::string::String>,
/// <p>The external ID of the run of the action.</p>
#[doc(hidden)]
pub external_execution_id: std::option::Option<std::string::String>,
/// <p>The URL of a resource external to AWS that is used when running the action (for example, an external repository URL).</p>
#[doc(hidden)]
pub external_execution_url: std::option::Option<std::string::String>,
/// <p>A percentage of completeness of the action as it runs.</p>
#[doc(hidden)]
pub percent_complete: std::option::Option<i32>,
/// <p>The details of an error returned by a URL external to AWS.</p>
#[doc(hidden)]
pub error_details: std::option::Option<crate::model::ErrorDetails>,
}
impl ActionExecution {
/// <p>ID of the workflow action execution in the current stage. Use the <code>GetPipelineState</code> action to retrieve the current action execution details of the current stage.</p> <note>
/// <p>For older executions, this field might be empty. The action execution ID is available for executions run on or after March 2020.</p>
/// </note>
pub fn action_execution_id(&self) -> std::option::Option<&str> {
self.action_execution_id.as_deref()
}
/// <p>The status of the action, or for a completed action, the last status of the action.</p>
pub fn status(&self) -> std::option::Option<&crate::model::ActionExecutionStatus> {
self.status.as_ref()
}
/// <p>A summary of the run of the action.</p>
pub fn summary(&self) -> std::option::Option<&str> {
self.summary.as_deref()
}
/// <p>The last status change of the action.</p>
pub fn last_status_change(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_status_change.as_ref()
}
/// <p>The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the <code>GetPipelineState</code> command. It is used to validate that the approval request corresponding to this token is still valid.</p>
pub fn token(&self) -> std::option::Option<&str> {
self.token.as_deref()
}
/// <p>The ARN of the user who last changed the pipeline.</p>
pub fn last_updated_by(&self) -> std::option::Option<&str> {
self.last_updated_by.as_deref()
}
/// <p>The external ID of the run of the action.</p>
pub fn external_execution_id(&self) -> std::option::Option<&str> {
self.external_execution_id.as_deref()
}
/// <p>The URL of a resource external to AWS that is used when running the action (for example, an external repository URL).</p>
pub fn external_execution_url(&self) -> std::option::Option<&str> {
self.external_execution_url.as_deref()
}
/// <p>A percentage of completeness of the action as it runs.</p>
pub fn percent_complete(&self) -> std::option::Option<i32> {
self.percent_complete
}
/// <p>The details of an error returned by a URL external to AWS.</p>
pub fn error_details(&self) -> std::option::Option<&crate::model::ErrorDetails> {
self.error_details.as_ref()
}
}
/// See [`ActionExecution`](crate::model::ActionExecution).
pub mod action_execution {
/// A builder for [`ActionExecution`](crate::model::ActionExecution).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) action_execution_id: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::ActionExecutionStatus>,
pub(crate) summary: std::option::Option<std::string::String>,
pub(crate) last_status_change: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) token: std::option::Option<std::string::String>,
pub(crate) last_updated_by: std::option::Option<std::string::String>,
pub(crate) external_execution_id: std::option::Option<std::string::String>,
pub(crate) external_execution_url: std::option::Option<std::string::String>,
pub(crate) percent_complete: std::option::Option<i32>,
pub(crate) error_details: std::option::Option<crate::model::ErrorDetails>,
}
impl Builder {
/// <p>ID of the workflow action execution in the current stage. Use the <code>GetPipelineState</code> action to retrieve the current action execution details of the current stage.</p> <note>
/// <p>For older executions, this field might be empty. The action execution ID is available for executions run on or after March 2020.</p>
/// </note>
pub fn action_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.action_execution_id = Some(input.into());
self
}
/// <p>ID of the workflow action execution in the current stage. Use the <code>GetPipelineState</code> action to retrieve the current action execution details of the current stage.</p> <note>
/// <p>For older executions, this field might be empty. The action execution ID is available for executions run on or after March 2020.</p>
/// </note>
pub fn set_action_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.action_execution_id = input;
self
}
/// <p>The status of the action, or for a completed action, the last status of the action.</p>
pub fn status(mut self, input: crate::model::ActionExecutionStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The status of the action, or for a completed action, the last status of the action.</p>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::ActionExecutionStatus>,
) -> Self {
self.status = input;
self
}
/// <p>A summary of the run of the action.</p>
pub fn summary(mut self, input: impl Into<std::string::String>) -> Self {
self.summary = Some(input.into());
self
}
/// <p>A summary of the run of the action.</p>
pub fn set_summary(mut self, input: std::option::Option<std::string::String>) -> Self {
self.summary = input;
self
}
/// <p>The last status change of the action.</p>
pub fn last_status_change(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_status_change = Some(input);
self
}
/// <p>The last status change of the action.</p>
pub fn set_last_status_change(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_status_change = input;
self
}
/// <p>The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the <code>GetPipelineState</code> command. It is used to validate that the approval request corresponding to this token is still valid.</p>
pub fn token(mut self, input: impl Into<std::string::String>) -> Self {
self.token = Some(input.into());
self
}
/// <p>The system-generated token used to identify a unique approval request. The token for each open approval request can be obtained using the <code>GetPipelineState</code> command. It is used to validate that the approval request corresponding to this token is still valid.</p>
pub fn set_token(mut self, input: std::option::Option<std::string::String>) -> Self {
self.token = input;
self
}
/// <p>The ARN of the user who last changed the pipeline.</p>
pub fn last_updated_by(mut self, input: impl Into<std::string::String>) -> Self {
self.last_updated_by = Some(input.into());
self
}
/// <p>The ARN of the user who last changed the pipeline.</p>
pub fn set_last_updated_by(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.last_updated_by = input;
self
}
/// <p>The external ID of the run of the action.</p>
pub fn external_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_id = Some(input.into());
self
}
/// <p>The external ID of the run of the action.</p>
pub fn set_external_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_id = input;
self
}
/// <p>The URL of a resource external to AWS that is used when running the action (for example, an external repository URL).</p>
pub fn external_execution_url(mut self, input: impl Into<std::string::String>) -> Self {
self.external_execution_url = Some(input.into());
self
}
/// <p>The URL of a resource external to AWS that is used when running the action (for example, an external repository URL).</p>
pub fn set_external_execution_url(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.external_execution_url = input;
self
}
/// <p>A percentage of completeness of the action as it runs.</p>
pub fn percent_complete(mut self, input: i32) -> Self {
self.percent_complete = Some(input);
self
}
/// <p>A percentage of completeness of the action as it runs.</p>
pub fn set_percent_complete(mut self, input: std::option::Option<i32>) -> Self {
self.percent_complete = input;
self
}
/// <p>The details of an error returned by a URL external to AWS.</p>
pub fn error_details(mut self, input: crate::model::ErrorDetails) -> Self {
self.error_details = Some(input);
self
}
/// <p>The details of an error returned by a URL external to AWS.</p>
pub fn set_error_details(
mut self,
input: std::option::Option<crate::model::ErrorDetails>,
) -> Self {
self.error_details = input;
self
}
/// Consumes the builder and constructs a [`ActionExecution`](crate::model::ActionExecution).
pub fn build(self) -> crate::model::ActionExecution {
crate::model::ActionExecution {
action_execution_id: self.action_execution_id,
status: self.status,
summary: self.summary,
last_status_change: self.last_status_change,
token: self.token,
last_updated_by: self.last_updated_by,
external_execution_id: self.external_execution_id,
external_execution_url: self.external_execution_url,
percent_complete: self.percent_complete,
error_details: self.error_details,
}
}
}
}
impl ActionExecution {
/// Creates a new builder-style object to manufacture [`ActionExecution`](crate::model::ActionExecution).
pub fn builder() -> crate::model::action_execution::Builder {
crate::model::action_execution::Builder::default()
}
}
/// <p>Represents information about an error in AWS CodePipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ErrorDetails {
/// <p>The system ID or number code of the error.</p>
#[doc(hidden)]
pub code: std::option::Option<std::string::String>,
/// <p>The text of the error message.</p>
#[doc(hidden)]
pub message: std::option::Option<std::string::String>,
}
impl ErrorDetails {
/// <p>The system ID or number code of the error.</p>
pub fn code(&self) -> std::option::Option<&str> {
self.code.as_deref()
}
/// <p>The text of the error message.</p>
pub fn message(&self) -> std::option::Option<&str> {
self.message.as_deref()
}
}
/// See [`ErrorDetails`](crate::model::ErrorDetails).
pub mod error_details {
/// A builder for [`ErrorDetails`](crate::model::ErrorDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) code: std::option::Option<std::string::String>,
pub(crate) message: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The system ID or number code of the error.</p>
pub fn code(mut self, input: impl Into<std::string::String>) -> Self {
self.code = Some(input.into());
self
}
/// <p>The system ID or number code of the error.</p>
pub fn set_code(mut self, input: std::option::Option<std::string::String>) -> Self {
self.code = input;
self
}
/// <p>The text of the error message.</p>
pub fn message(mut self, input: impl Into<std::string::String>) -> Self {
self.message = Some(input.into());
self
}
/// <p>The text of the error message.</p>
pub fn set_message(mut self, input: std::option::Option<std::string::String>) -> Self {
self.message = input;
self
}
/// Consumes the builder and constructs a [`ErrorDetails`](crate::model::ErrorDetails).
pub fn build(self) -> crate::model::ErrorDetails {
crate::model::ErrorDetails {
code: self.code,
message: self.message,
}
}
}
}
impl ErrorDetails {
/// Creates a new builder-style object to manufacture [`ErrorDetails`](crate::model::ErrorDetails).
pub fn builder() -> crate::model::error_details::Builder {
crate::model::error_details::Builder::default()
}
}
/// <p>Represents information about the state of transitions between one stage and another stage.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct TransitionState {
/// <p>Whether the transition between stages is enabled (true) or disabled (false).</p>
#[doc(hidden)]
pub enabled: bool,
/// <p>The ID of the user who last changed the transition state.</p>
#[doc(hidden)]
pub last_changed_by: std::option::Option<std::string::String>,
/// <p>The timestamp when the transition state was last changed.</p>
#[doc(hidden)]
pub last_changed_at: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The user-specified reason why the transition between two stages of a pipeline was disabled.</p>
#[doc(hidden)]
pub disabled_reason: std::option::Option<std::string::String>,
}
impl TransitionState {
/// <p>Whether the transition between stages is enabled (true) or disabled (false).</p>
pub fn enabled(&self) -> bool {
self.enabled
}
/// <p>The ID of the user who last changed the transition state.</p>
pub fn last_changed_by(&self) -> std::option::Option<&str> {
self.last_changed_by.as_deref()
}
/// <p>The timestamp when the transition state was last changed.</p>
pub fn last_changed_at(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.last_changed_at.as_ref()
}
/// <p>The user-specified reason why the transition between two stages of a pipeline was disabled.</p>
pub fn disabled_reason(&self) -> std::option::Option<&str> {
self.disabled_reason.as_deref()
}
}
/// See [`TransitionState`](crate::model::TransitionState).
pub mod transition_state {
/// A builder for [`TransitionState`](crate::model::TransitionState).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) enabled: std::option::Option<bool>,
pub(crate) last_changed_by: std::option::Option<std::string::String>,
pub(crate) last_changed_at: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) disabled_reason: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>Whether the transition between stages is enabled (true) or disabled (false).</p>
pub fn enabled(mut self, input: bool) -> Self {
self.enabled = Some(input);
self
}
/// <p>Whether the transition between stages is enabled (true) or disabled (false).</p>
pub fn set_enabled(mut self, input: std::option::Option<bool>) -> Self {
self.enabled = input;
self
}
/// <p>The ID of the user who last changed the transition state.</p>
pub fn last_changed_by(mut self, input: impl Into<std::string::String>) -> Self {
self.last_changed_by = Some(input.into());
self
}
/// <p>The ID of the user who last changed the transition state.</p>
pub fn set_last_changed_by(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.last_changed_by = input;
self
}
/// <p>The timestamp when the transition state was last changed.</p>
pub fn last_changed_at(mut self, input: aws_smithy_types::DateTime) -> Self {
self.last_changed_at = Some(input);
self
}
/// <p>The timestamp when the transition state was last changed.</p>
pub fn set_last_changed_at(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.last_changed_at = input;
self
}
/// <p>The user-specified reason why the transition between two stages of a pipeline was disabled.</p>
pub fn disabled_reason(mut self, input: impl Into<std::string::String>) -> Self {
self.disabled_reason = Some(input.into());
self
}
/// <p>The user-specified reason why the transition between two stages of a pipeline was disabled.</p>
pub fn set_disabled_reason(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.disabled_reason = input;
self
}
/// Consumes the builder and constructs a [`TransitionState`](crate::model::TransitionState).
pub fn build(self) -> crate::model::TransitionState {
crate::model::TransitionState {
enabled: self.enabled.unwrap_or_default(),
last_changed_by: self.last_changed_by,
last_changed_at: self.last_changed_at,
disabled_reason: self.disabled_reason,
}
}
}
}
impl TransitionState {
/// Creates a new builder-style object to manufacture [`TransitionState`](crate::model::TransitionState).
pub fn builder() -> crate::model::transition_state::Builder {
crate::model::transition_state::Builder::default()
}
}
/// <p>Represents information about an execution of a pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineExecution {
/// <p>The name of the pipeline with the specified pipeline execution.</p>
#[doc(hidden)]
pub pipeline_name: std::option::Option<std::string::String>,
/// <p>The version number of the pipeline with the specified pipeline execution.</p>
#[doc(hidden)]
pub pipeline_version: std::option::Option<i32>,
/// <p>The ID of the pipeline execution.</p>
#[doc(hidden)]
pub pipeline_execution_id: std::option::Option<std::string::String>,
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>Cancelled: The pipeline’s definition was updated before the pipeline execution could be completed.</p> </li>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
#[doc(hidden)]
pub status: std::option::Option<crate::model::PipelineExecutionStatus>,
/// <p>A summary that contains a description of the pipeline execution status.</p>
#[doc(hidden)]
pub status_summary: std::option::Option<std::string::String>,
/// <p>A list of <code>ArtifactRevision</code> objects included in a pipeline execution.</p>
#[doc(hidden)]
pub artifact_revisions: std::option::Option<std::vec::Vec<crate::model::ArtifactRevision>>,
}
impl PipelineExecution {
/// <p>The name of the pipeline with the specified pipeline execution.</p>
pub fn pipeline_name(&self) -> std::option::Option<&str> {
self.pipeline_name.as_deref()
}
/// <p>The version number of the pipeline with the specified pipeline execution.</p>
pub fn pipeline_version(&self) -> std::option::Option<i32> {
self.pipeline_version
}
/// <p>The ID of the pipeline execution.</p>
pub fn pipeline_execution_id(&self) -> std::option::Option<&str> {
self.pipeline_execution_id.as_deref()
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>Cancelled: The pipeline’s definition was updated before the pipeline execution could be completed.</p> </li>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn status(&self) -> std::option::Option<&crate::model::PipelineExecutionStatus> {
self.status.as_ref()
}
/// <p>A summary that contains a description of the pipeline execution status.</p>
pub fn status_summary(&self) -> std::option::Option<&str> {
self.status_summary.as_deref()
}
/// <p>A list of <code>ArtifactRevision</code> objects included in a pipeline execution.</p>
pub fn artifact_revisions(&self) -> std::option::Option<&[crate::model::ArtifactRevision]> {
self.artifact_revisions.as_deref()
}
}
/// See [`PipelineExecution`](crate::model::PipelineExecution).
pub mod pipeline_execution {
/// A builder for [`PipelineExecution`](crate::model::PipelineExecution).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_name: std::option::Option<std::string::String>,
pub(crate) pipeline_version: std::option::Option<i32>,
pub(crate) pipeline_execution_id: std::option::Option<std::string::String>,
pub(crate) status: std::option::Option<crate::model::PipelineExecutionStatus>,
pub(crate) status_summary: std::option::Option<std::string::String>,
pub(crate) artifact_revisions:
std::option::Option<std::vec::Vec<crate::model::ArtifactRevision>>,
}
impl Builder {
/// <p>The name of the pipeline with the specified pipeline execution.</p>
pub fn pipeline_name(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_name = Some(input.into());
self
}
/// <p>The name of the pipeline with the specified pipeline execution.</p>
pub fn set_pipeline_name(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_name = input;
self
}
/// <p>The version number of the pipeline with the specified pipeline execution.</p>
pub fn pipeline_version(mut self, input: i32) -> Self {
self.pipeline_version = Some(input);
self
}
/// <p>The version number of the pipeline with the specified pipeline execution.</p>
pub fn set_pipeline_version(mut self, input: std::option::Option<i32>) -> Self {
self.pipeline_version = input;
self
}
/// <p>The ID of the pipeline execution.</p>
pub fn pipeline_execution_id(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_execution_id = Some(input.into());
self
}
/// <p>The ID of the pipeline execution.</p>
pub fn set_pipeline_execution_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.pipeline_execution_id = input;
self
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>Cancelled: The pipeline’s definition was updated before the pipeline execution could be completed.</p> </li>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn status(mut self, input: crate::model::PipelineExecutionStatus) -> Self {
self.status = Some(input);
self
}
/// <p>The status of the pipeline execution.</p>
/// <ul>
/// <li> <p>Cancelled: The pipeline’s definition was updated before the pipeline execution could be completed.</p> </li>
/// <li> <p>InProgress: The pipeline execution is currently running.</p> </li>
/// <li> <p>Stopped: The pipeline execution was manually stopped. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Stopping: The pipeline execution received a request to be manually stopped. Depending on the selected stop mode, the execution is either completing or abandoning in-progress actions. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-executions-stopped">Stopped Executions</a>.</p> </li>
/// <li> <p>Succeeded: The pipeline execution was completed successfully. </p> </li>
/// <li> <p>Superseded: While this pipeline execution was waiting for the next stage to be completed, a newer pipeline execution advanced and continued through the pipeline instead. For more information, see <a href="https://docs.aws.amazon.com/codepipeline/latest/userguide/concepts.html#concepts-superseded">Superseded Executions</a>.</p> </li>
/// <li> <p>Failed: The pipeline execution was not completed successfully.</p> </li>
/// </ul>
pub fn set_status(
mut self,
input: std::option::Option<crate::model::PipelineExecutionStatus>,
) -> Self {
self.status = input;
self
}
/// <p>A summary that contains a description of the pipeline execution status.</p>
pub fn status_summary(mut self, input: impl Into<std::string::String>) -> Self {
self.status_summary = Some(input.into());
self
}
/// <p>A summary that contains a description of the pipeline execution status.</p>
pub fn set_status_summary(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.status_summary = input;
self
}
/// Appends an item to `artifact_revisions`.
///
/// To override the contents of this collection use [`set_artifact_revisions`](Self::set_artifact_revisions).
///
/// <p>A list of <code>ArtifactRevision</code> objects included in a pipeline execution.</p>
pub fn artifact_revisions(mut self, input: crate::model::ArtifactRevision) -> Self {
let mut v = self.artifact_revisions.unwrap_or_default();
v.push(input);
self.artifact_revisions = Some(v);
self
}
/// <p>A list of <code>ArtifactRevision</code> objects included in a pipeline execution.</p>
pub fn set_artifact_revisions(
mut self,
input: std::option::Option<std::vec::Vec<crate::model::ArtifactRevision>>,
) -> Self {
self.artifact_revisions = input;
self
}
/// Consumes the builder and constructs a [`PipelineExecution`](crate::model::PipelineExecution).
pub fn build(self) -> crate::model::PipelineExecution {
crate::model::PipelineExecution {
pipeline_name: self.pipeline_name,
pipeline_version: self.pipeline_version,
pipeline_execution_id: self.pipeline_execution_id,
status: self.status,
status_summary: self.status_summary,
artifact_revisions: self.artifact_revisions,
}
}
}
}
impl PipelineExecution {
/// Creates a new builder-style object to manufacture [`PipelineExecution`](crate::model::PipelineExecution).
pub fn builder() -> crate::model::pipeline_execution::Builder {
crate::model::pipeline_execution::Builder::default()
}
}
/// <p>Represents revision details of an artifact. </p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct ArtifactRevision {
/// <p>The name of an artifact. This name might be system-generated, such as "MyApp", or defined by the user when an action is created.</p>
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
/// <p>The revision ID of the artifact.</p>
#[doc(hidden)]
pub revision_id: std::option::Option<std::string::String>,
/// <p>An additional identifier for a revision, such as a commit date or, for artifacts stored in Amazon S3 buckets, the ETag value.</p>
#[doc(hidden)]
pub revision_change_identifier: std::option::Option<std::string::String>,
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
#[doc(hidden)]
pub revision_summary: std::option::Option<std::string::String>,
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
#[doc(hidden)]
pub created: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
#[doc(hidden)]
pub revision_url: std::option::Option<std::string::String>,
}
impl ArtifactRevision {
/// <p>The name of an artifact. This name might be system-generated, such as "MyApp", or defined by the user when an action is created.</p>
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
/// <p>The revision ID of the artifact.</p>
pub fn revision_id(&self) -> std::option::Option<&str> {
self.revision_id.as_deref()
}
/// <p>An additional identifier for a revision, such as a commit date or, for artifacts stored in Amazon S3 buckets, the ETag value.</p>
pub fn revision_change_identifier(&self) -> std::option::Option<&str> {
self.revision_change_identifier.as_deref()
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn revision_summary(&self) -> std::option::Option<&str> {
self.revision_summary.as_deref()
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn created(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created.as_ref()
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn revision_url(&self) -> std::option::Option<&str> {
self.revision_url.as_deref()
}
}
/// See [`ArtifactRevision`](crate::model::ArtifactRevision).
pub mod artifact_revision {
/// A builder for [`ArtifactRevision`](crate::model::ArtifactRevision).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) revision_id: std::option::Option<std::string::String>,
pub(crate) revision_change_identifier: std::option::Option<std::string::String>,
pub(crate) revision_summary: std::option::Option<std::string::String>,
pub(crate) created: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) revision_url: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The name of an artifact. This name might be system-generated, such as "MyApp", or defined by the user when an action is created.</p>
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
/// <p>The name of an artifact. This name might be system-generated, such as "MyApp", or defined by the user when an action is created.</p>
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
/// <p>The revision ID of the artifact.</p>
pub fn revision_id(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_id = Some(input.into());
self
}
/// <p>The revision ID of the artifact.</p>
pub fn set_revision_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_id = input;
self
}
/// <p>An additional identifier for a revision, such as a commit date or, for artifacts stored in Amazon S3 buckets, the ETag value.</p>
pub fn revision_change_identifier(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_change_identifier = Some(input.into());
self
}
/// <p>An additional identifier for a revision, such as a commit date or, for artifacts stored in Amazon S3 buckets, the ETag value.</p>
pub fn set_revision_change_identifier(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_change_identifier = input;
self
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn revision_summary(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_summary = Some(input.into());
self
}
/// <p>Summary information about the most recent revision of the artifact. For GitHub and AWS CodeCommit repositories, the commit message. For Amazon S3 buckets or actions, the user-provided content of a <code>codepipeline-artifact-revision-summary</code> key specified in the object metadata.</p>
pub fn set_revision_summary(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.revision_summary = input;
self
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn created(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created = Some(input);
self
}
/// <p>The date and time when the most recent revision of the artifact was created, in timestamp format.</p>
pub fn set_created(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created = input;
self
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn revision_url(mut self, input: impl Into<std::string::String>) -> Self {
self.revision_url = Some(input.into());
self
}
/// <p>The commit ID for the artifact revision. For artifacts stored in GitHub or AWS CodeCommit repositories, the commit ID is linked to a commit details page.</p>
pub fn set_revision_url(mut self, input: std::option::Option<std::string::String>) -> Self {
self.revision_url = input;
self
}
/// Consumes the builder and constructs a [`ArtifactRevision`](crate::model::ArtifactRevision).
pub fn build(self) -> crate::model::ArtifactRevision {
crate::model::ArtifactRevision {
name: self.name,
revision_id: self.revision_id,
revision_change_identifier: self.revision_change_identifier,
revision_summary: self.revision_summary,
created: self.created,
revision_url: self.revision_url,
}
}
}
}
impl ArtifactRevision {
/// Creates a new builder-style object to manufacture [`ArtifactRevision`](crate::model::ArtifactRevision).
pub fn builder() -> crate::model::artifact_revision::Builder {
crate::model::artifact_revision::Builder::default()
}
}
/// <p>Information about a pipeline.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct PipelineMetadata {
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
#[doc(hidden)]
pub pipeline_arn: std::option::Option<std::string::String>,
/// <p>The date and time the pipeline was created, in timestamp format.</p>
#[doc(hidden)]
pub created: std::option::Option<aws_smithy_types::DateTime>,
/// <p>The date and time the pipeline was last updated, in timestamp format.</p>
#[doc(hidden)]
pub updated: std::option::Option<aws_smithy_types::DateTime>,
}
impl PipelineMetadata {
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn pipeline_arn(&self) -> std::option::Option<&str> {
self.pipeline_arn.as_deref()
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn created(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.created.as_ref()
}
/// <p>The date and time the pipeline was last updated, in timestamp format.</p>
pub fn updated(&self) -> std::option::Option<&aws_smithy_types::DateTime> {
self.updated.as_ref()
}
}
/// See [`PipelineMetadata`](crate::model::PipelineMetadata).
pub mod pipeline_metadata {
/// A builder for [`PipelineMetadata`](crate::model::PipelineMetadata).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) pipeline_arn: std::option::Option<std::string::String>,
pub(crate) created: std::option::Option<aws_smithy_types::DateTime>,
pub(crate) updated: std::option::Option<aws_smithy_types::DateTime>,
}
impl Builder {
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn pipeline_arn(mut self, input: impl Into<std::string::String>) -> Self {
self.pipeline_arn = Some(input.into());
self
}
/// <p>The Amazon Resource Name (ARN) of the pipeline.</p>
pub fn set_pipeline_arn(mut self, input: std::option::Option<std::string::String>) -> Self {
self.pipeline_arn = input;
self
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn created(mut self, input: aws_smithy_types::DateTime) -> Self {
self.created = Some(input);
self
}
/// <p>The date and time the pipeline was created, in timestamp format.</p>
pub fn set_created(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.created = input;
self
}
/// <p>The date and time the pipeline was last updated, in timestamp format.</p>
pub fn updated(mut self, input: aws_smithy_types::DateTime) -> Self {
self.updated = Some(input);
self
}
/// <p>The date and time the pipeline was last updated, in timestamp format.</p>
pub fn set_updated(
mut self,
input: std::option::Option<aws_smithy_types::DateTime>,
) -> Self {
self.updated = input;
self
}
/// Consumes the builder and constructs a [`PipelineMetadata`](crate::model::PipelineMetadata).
pub fn build(self) -> crate::model::PipelineMetadata {
crate::model::PipelineMetadata {
pipeline_arn: self.pipeline_arn,
created: self.created,
updated: self.updated,
}
}
}
}
impl PipelineMetadata {
/// Creates a new builder-style object to manufacture [`PipelineMetadata`](crate::model::PipelineMetadata).
pub fn builder() -> crate::model::pipeline_metadata::Builder {
crate::model::pipeline_metadata::Builder::default()
}
}
/// <p>Represents information about the details of a job.</p>
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct JobDetails {
/// <p>The unique system-generated ID of the job.</p>
#[doc(hidden)]
pub id: std::option::Option<std::string::String>,
/// <p>Represents other information about a job required for a job worker to complete the job. </p>
#[doc(hidden)]
pub data: std::option::Option<crate::model::JobData>,
/// <p>The AWS account ID associated with the job.</p>
#[doc(hidden)]
pub account_id: std::option::Option<std::string::String>,
}
impl JobDetails {
/// <p>The unique system-generated ID of the job.</p>
pub fn id(&self) -> std::option::Option<&str> {
self.id.as_deref()
}
/// <p>Represents other information about a job required for a job worker to complete the job. </p>
pub fn data(&self) -> std::option::Option<&crate::model::JobData> {
self.data.as_ref()
}
/// <p>The AWS account ID associated with the job.</p>
pub fn account_id(&self) -> std::option::Option<&str> {
self.account_id.as_deref()
}
}
/// See [`JobDetails`](crate::model::JobDetails).
pub mod job_details {
/// A builder for [`JobDetails`](crate::model::JobDetails).
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct Builder {
pub(crate) id: std::option::Option<std::string::String>,
pub(crate) data: std::option::Option<crate::model::JobData>,
pub(crate) account_id: std::option::Option<std::string::String>,
}
impl Builder {
/// <p>The unique system-generated ID of the job.</p>
pub fn id(mut self, input: impl Into<std::string::String>) -> Self {
self.id = Some(input.into());
self
}
/// <p>The unique system-generated ID of the job.</p>
pub fn set_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.id = input;
self
}
/// <p>Represents other information about a job required for a job worker to complete the job. </p>
pub fn data(mut self, input: crate::model::JobData) -> Self {
self.data = Some(input);
self
}
/// <p>Represents other information about a job required for a job worker to complete the job. </p>
pub fn set_data(mut self, input: std::option::Option<crate::model::JobData>) -> Self {
self.data = input;
self
}
/// <p>The AWS account ID associated with the job.</p>
pub fn account_id(mut self, input: impl Into<std::string::String>) -> Self {
self.account_id = Some(input.into());
self
}
/// <p>The AWS account ID associated with the job.</p>
pub fn set_account_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.account_id = input;
self
}
/// Consumes the builder and constructs a [`JobDetails`](crate::model::JobDetails).
pub fn build(self) -> crate::model::JobDetails {
crate::model::JobDetails {
id: self.id,
data: self.data,
account_id: self.account_id,
}
}
}
}
impl JobDetails {
/// Creates a new builder-style object to manufacture [`JobDetails`](crate::model::JobDetails).
pub fn builder() -> crate::model::job_details::Builder {
crate::model::job_details::Builder::default()
}
}
/// When writing a match expression against `StageTransitionType`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let stagetransitiontype = unimplemented!();
/// match stagetransitiontype {
/// StageTransitionType::Inbound => { /* ... */ },
/// StageTransitionType::Outbound => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `stagetransitiontype` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `StageTransitionType::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `StageTransitionType::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `StageTransitionType::NewFeature` is defined.
/// Specifically, when `stagetransitiontype` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `StageTransitionType::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum StageTransitionType {
#[allow(missing_docs)] // documentation missing in model
Inbound,
#[allow(missing_docs)] // documentation missing in model
Outbound,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for StageTransitionType {
fn from(s: &str) -> Self {
match s {
"Inbound" => StageTransitionType::Inbound,
"Outbound" => StageTransitionType::Outbound,
other => {
StageTransitionType::Unknown(crate::types::UnknownVariantValue(other.to_owned()))
}
}
}
}
impl std::str::FromStr for StageTransitionType {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(StageTransitionType::from(s))
}
}
impl StageTransitionType {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
StageTransitionType::Inbound => "Inbound",
StageTransitionType::Outbound => "Outbound",
StageTransitionType::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&["Inbound", "Outbound"]
}
}
impl AsRef<str> for StageTransitionType {
fn as_ref(&self) -> &str {
self.as_str()
}
}
/// When writing a match expression against `JobStatus`, it is important to ensure
/// your code is forward-compatible. That is, if a match arm handles a case for a
/// feature that is supported by the service but has not been represented as an enum
/// variant in a current version of SDK, your code should continue to work when you
/// upgrade SDK to a future version in which the enum does include a variant for that
/// feature.
///
/// Here is an example of how you can make a match expression forward-compatible:
///
/// ```text
/// # let jobstatus = unimplemented!();
/// match jobstatus {
/// JobStatus::Created => { /* ... */ },
/// JobStatus::Dispatched => { /* ... */ },
/// JobStatus::Failed => { /* ... */ },
/// JobStatus::InProgress => { /* ... */ },
/// JobStatus::Queued => { /* ... */ },
/// JobStatus::Succeeded => { /* ... */ },
/// JobStatus::TimedOut => { /* ... */ },
/// other @ _ if other.as_str() == "NewFeature" => { /* handles a case for `NewFeature` */ },
/// _ => { /* ... */ },
/// }
/// ```
/// The above code demonstrates that when `jobstatus` represents
/// `NewFeature`, the execution path will lead to the second last match arm,
/// even though the enum does not contain a variant `JobStatus::NewFeature`
/// in the current version of SDK. The reason is that the variable `other`,
/// created by the `@` operator, is bound to
/// `JobStatus::Unknown(UnknownVariantValue("NewFeature".to_owned()))`
/// and calling `as_str` on it yields `"NewFeature"`.
/// This match expression is forward-compatible when executed with a newer
/// version of SDK where the variant `JobStatus::NewFeature` is defined.
/// Specifically, when `jobstatus` represents `NewFeature`,
/// the execution path will hit the second last match arm as before by virtue of
/// calling `as_str` on `JobStatus::NewFeature` also yielding `"NewFeature"`.
///
/// Explicitly matching on the `Unknown` variant should
/// be avoided for two reasons:
/// - The inner data `UnknownVariantValue` is opaque, and no further information can be extracted.
/// - It might inadvertently shadow other intended match arms.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(
std::clone::Clone,
std::cmp::Eq,
std::cmp::Ord,
std::cmp::PartialEq,
std::cmp::PartialOrd,
std::fmt::Debug,
std::hash::Hash,
)]
pub enum JobStatus {
#[allow(missing_docs)] // documentation missing in model
Created,
#[allow(missing_docs)] // documentation missing in model
Dispatched,
#[allow(missing_docs)] // documentation missing in model
Failed,
#[allow(missing_docs)] // documentation missing in model
InProgress,
#[allow(missing_docs)] // documentation missing in model
Queued,
#[allow(missing_docs)] // documentation missing in model
Succeeded,
#[allow(missing_docs)] // documentation missing in model
TimedOut,
/// `Unknown` contains new variants that have been added since this code was generated.
Unknown(crate::types::UnknownVariantValue),
}
impl std::convert::From<&str> for JobStatus {
fn from(s: &str) -> Self {
match s {
"Created" => JobStatus::Created,
"Dispatched" => JobStatus::Dispatched,
"Failed" => JobStatus::Failed,
"InProgress" => JobStatus::InProgress,
"Queued" => JobStatus::Queued,
"Succeeded" => JobStatus::Succeeded,
"TimedOut" => JobStatus::TimedOut,
other => JobStatus::Unknown(crate::types::UnknownVariantValue(other.to_owned())),
}
}
}
impl std::str::FromStr for JobStatus {
type Err = std::convert::Infallible;
fn from_str(s: &str) -> std::result::Result<Self, Self::Err> {
Ok(JobStatus::from(s))
}
}
impl JobStatus {
/// Returns the `&str` value of the enum member.
pub fn as_str(&self) -> &str {
match self {
JobStatus::Created => "Created",
JobStatus::Dispatched => "Dispatched",
JobStatus::Failed => "Failed",
JobStatus::InProgress => "InProgress",
JobStatus::Queued => "Queued",
JobStatus::Succeeded => "Succeeded",
JobStatus::TimedOut => "TimedOut",
JobStatus::Unknown(value) => value.as_str(),
}
}
/// Returns all the `&str` values of the enum members.
pub const fn values() -> &'static [&'static str] {
&[
"Created",
"Dispatched",
"Failed",
"InProgress",
"Queued",
"Succeeded",
"TimedOut",
]
}
}
impl AsRef<str> for JobStatus {
fn as_ref(&self) -> &str {
self.as_str()
}
}