'
13 |
14 | hr_faded: '
'
15 | hr_shaded: '
'
--------------------------------------------------------------------------------
/docs/_data/glossary.yml:
--------------------------------------------------------------------------------
1 | jekyll_platform: "Jekyll is a static site generator that builds sites using most modern web technologies."
2 |
3 | fractious: "Like a little mischevious child, full of annoying and constant trouble."
4 |
5 | gratuitous: "Something that is unwarranted and uncouth, like the social equivalent of a flagrant foul."
6 |
7 | haughty: "Proud and flaunting it. Holding your head high up like a snooty, too-good-for-everything rich person."
8 |
9 | impertinent: "Someone acting rude and insensitive to others."
10 |
11 | intrepid: "Brave and courageous especially in a difficult, dangerous situation."
--------------------------------------------------------------------------------
/docs/_data/sidebars/other.yml:
--------------------------------------------------------------------------------
1 |
2 | # Follow the pattern here for the URLs -- no slash at the beginning, and include the .html. The link here is rendered exactly as is in the Markdown references.
3 |
4 | entries:
5 | - title: other
6 | folders:
7 |
8 | - title: Other Links
9 | folderitems:
10 |
11 | - title: Automated links bookmark
12 | url: /mydoc_hyperlinks.html#automatedlinks
13 |
14 | - title: Bookmark links
15 | url: /mydoc_hyperlinks.html#bookmarklinks
16 |
17 | - title: Some link bookmark
18 | url: /mydoc_pages.html#someIdTag
19 |
--------------------------------------------------------------------------------
/docs/_data/sidebars/product1_sidebar.yml:
--------------------------------------------------------------------------------
1 | # This is your sidebar TOC. The sidebar code loops through sections here and provides the appropriate formatting.
2 |
3 |
4 | entries:
5 | - title: Sidebar
6 | product: Product1
7 | version: 1.0
8 | folders:
9 |
10 | - title:
11 | output: pdf
12 | type: frontmatter
13 | folderitems:
14 | - title:
15 | url: /titlepage.html
16 | output: pdf
17 | type: frontmatter
18 | - title:
19 | url: /tocpage.html
20 | output: pdf
21 | type: frontmatter
22 |
23 | - title: Getting Started
24 | output: web, pdf
25 | folderitems:
26 | - title: Product 1 home
27 | url: /p1_landing_page.html
28 | output: web
29 |
30 | - title: Sample 1
31 | url: /p1_sample1.html
32 | output: web, pdf
33 |
34 | - title: Sample 2
35 | url: /p1_sample2.html
36 | output: web, pdf
37 |
38 | - title: Sample 3
39 | url: /p1_sample3.html
40 | output: web, pdf
41 |
42 | - title: Another heading
43 | output: web, pdf
44 |
45 | folderitems:
46 | - title: Sample 4
47 | url: /p1_sample4.html
48 | output: web, pdf
49 |
50 | - title: Sample 5
51 | url: /p1_sample5.html
52 | output: web, pdf
53 |
54 | - title: Sample 6
55 | url: /p1_sample6.html
56 | output: web, pdf
57 |
58 | - title: Sample 7
59 | url: /p1_sample7.html
60 | output: web, pdf
61 |
--------------------------------------------------------------------------------
/docs/_data/sidebars/product2_sidebar.yml:
--------------------------------------------------------------------------------
1 | # This is your sidebar TOC. The sidebar code loops through sections here and provides the appropriate formatting.
2 |
3 | entries:
4 | - title: Product2
5 | product: Product2
6 | version: 1.0
7 | folders:
8 |
9 | - title:
10 | output: pdf
11 | type: frontmatter
12 | folderitems:
13 | - title:
14 | url: /titlepage.html
15 | output: pdf
16 | type: frontmatter
17 | - title:
18 | url: /tocpage.html
19 | output: pdf
20 | type: frontmatter
21 |
22 | - title: Introduction
23 | output: web, pdf
24 | folderitems:
25 |
26 | - title: Overview
27 | url: /p2_landing_page.html
28 | output: web
29 |
30 | - title: Simple Workflow
31 | output: web, pdf
32 | folderitems:
33 |
34 | - title: Sample 1
35 | url: /p2_sample1.html
36 | output: web, pdf
37 |
38 | - title: Sample 2
39 | url: /p2_sample2.html
40 | output: web, pdf
41 |
42 | - title: Sample 3
43 | url: /p2_sample3.html
44 | output: web, pdf
45 |
46 | - title: Sample 4
47 | url: /p2_sample4.html
48 | output: web, pdf
49 |
50 | - title: Sample 5
51 | url: /p2_sample5.html
52 | output: web, pdf
53 |
54 | - title: Complex Workflow
55 | output: web, pdf
56 | folderitems:
57 |
58 | - title: Sample 6
59 | url: /p2_sample6.html
60 | output: web, pdf
61 |
62 | - title: Sample 7
63 | url: /p2_sample7.html
64 | output: web, pdf
65 |
66 | - title: Sample 8
67 | url: /p2_sample8.html
68 | output: web, pdf
69 |
70 | - title: Sample 9
71 | url: /p2_sample9.html
72 | output: web, pdf
73 |
74 | - title: Sample 10
75 | url: /p2_sample10.html
76 | output: web, pdf
77 |
78 | - title: Sample 11
79 | url: /p2_sample11.html
80 | output: web, pdf
81 |
82 | - title: Sample 12
83 | url: /p2_sample12.html
84 | output: web, pdf
85 |
86 | - title: Sample 13
87 | url: /p2_sample13.html
88 | output: web, pdf
89 |
90 | - title: Sample 14
91 | url: /p2_sample14.html
92 | output: web, pdf
93 |
--------------------------------------------------------------------------------
/docs/_data/strings.yml:
--------------------------------------------------------------------------------
1 |
2 |
3 | # placed here for translation purposes
4 | search_placeholder_text: search...
5 | search_no_results_text: No results found.
6 |
--------------------------------------------------------------------------------
/docs/_data/tags.yml:
--------------------------------------------------------------------------------
1 | # Note:
2 | # If you are using the createtag script, don't leave an blank line at the end of this file.
3 | # In other words, the last line must be the last tag in the allowed-tags list.
4 | allowed-tags:
5 | - getting_started
6 | - content_types
7 | - navigation
8 | - formatting
9 | - publishing
10 | - single_sourcing
11 | - special_layouts
12 | - collaboration
13 | - news
14 | - troubleshooting
15 | - mobile
16 |
--------------------------------------------------------------------------------
/docs/_data/terms.yml:
--------------------------------------------------------------------------------
1 | apple: "apple - the fruit of a disiduous tree."
--------------------------------------------------------------------------------
/docs/_data/topnav.yml:
--------------------------------------------------------------------------------
1 | ## Topnav single links
2 | ## if you want to list an external url, use external_url instead of url. the theme will apply a different link base.
3 | topnav:
4 | - title: Topnav
5 | items:
6 | - title: GitHub
7 | external_url: https://github.com/FroMage/redpipe/
8 |
9 | #Topnav dropdowns
10 | topnav_dropdowns:
11 |
--------------------------------------------------------------------------------
/docs/_includes/archive.html:
--------------------------------------------------------------------------------
1 | ---
2 | layout: default
3 | type: archive
4 | ---
5 |
6 |
9 |
10 |
11 | {{ content }}
12 |
13 |
14 |
15 |
16 |
--------------------------------------------------------------------------------
/docs/_includes/callout.html:
--------------------------------------------------------------------------------
1 |
{{include.content}}
2 |
--------------------------------------------------------------------------------
/docs/_includes/custom/getting_started_series.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
18 |
19 |
--------------------------------------------------------------------------------
/docs/_includes/custom/getting_started_series_next.html:
--------------------------------------------------------------------------------
1 |
{% assign series_pages = site.tags.series_acme %}
2 | {% for p in pages %}
3 | {% if p.series == "Getting Started" %}
4 | {% assign nextTopic = page.weight | plus: "1" %}
5 | {% if p.weight == nextTopic %}
6 |
7 | {% endif %}
8 | {% endif %}
9 | {% endfor %}
10 |
--------------------------------------------------------------------------------
/docs/_includes/custom/series_acme.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
18 |
19 |
--------------------------------------------------------------------------------
/docs/_includes/custom/series_acme_next.html:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/docs/_includes/custom/usermap.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
→
5 |
6 |
→
7 |
8 |
→
9 |
10 |
→
11 |
12 |
13 |
14 |
15 |
--------------------------------------------------------------------------------
/docs/_includes/disqus.html:
--------------------------------------------------------------------------------
1 | {% if site.disqus_shortname %}
2 |
3 |
4 |
24 |
25 | {% endif %}
26 |
--------------------------------------------------------------------------------
/docs/_includes/feedback.html:
--------------------------------------------------------------------------------
1 |
2 | {% if site.feedback_text %}
3 | {% assign feedback_text = site.feedback_text %}
4 | {% else %}
5 | {% assign feedback_text = "Feedback" %}
6 | {% endif %}
7 |
8 | {% if site.feedback_link %}
9 | {{feedback_text}}
10 | {% else %}
11 | {{feedback_text}}
12 | {% endif %}
13 |
14 |
--------------------------------------------------------------------------------
/docs/_includes/footer.html:
--------------------------------------------------------------------------------
1 |
10 |
--------------------------------------------------------------------------------
/docs/_includes/google_analytics.html:
--------------------------------------------------------------------------------
1 |
2 |
3 | {% if site.google_analytics %}
4 |
5 |
6 | {% endif %}
--------------------------------------------------------------------------------
/docs/_includes/head_print.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
{% if page.homepage == true %} {{site.homepage_title}} {% elsif page.title %}{{ page.title }}{% endif %} | {{ site.site_title }}
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
23 |
24 |
29 |
--------------------------------------------------------------------------------
/docs/_includes/image.html:
--------------------------------------------------------------------------------
1 |
{% if {{include.url}} %}{% endif %}
{% if {{include.url}} %}{% endif %}{% if {{include.caption}} %}{{include.caption}}{% endif %}
2 |
--------------------------------------------------------------------------------
/docs/_includes/important.html:
--------------------------------------------------------------------------------
1 |
Important: {{include.content}}
--------------------------------------------------------------------------------
/docs/_includes/inline_image.html:
--------------------------------------------------------------------------------
1 |

2 |
--------------------------------------------------------------------------------
/docs/_includes/links.html:
--------------------------------------------------------------------------------
1 | {% comment %}Get links from each sidebar, as listed in the _config.yml file under sidebars{% endcomment %}
2 |
3 | {% for sidebar in site.sidebars %}
4 | {% for entry in site.data.sidebars[sidebar].entries %}
5 | {% for folder in entry.folders %}
6 | {% for folderitem in folder.folderitems %}
7 | {% if folderitem.url contains "html#" %}
8 | [{{folderitem.url | remove: "/" }}]: {{folderitem.url | remove: "/"}}
9 | {% else %}
10 | [{{folderitem.url | remove: "/" | remove: ".html"}}]: {{folderitem.url | remove: "/"}}
11 | {% endif %}
12 | {% for subfolders in folderitem.subfolders %}
13 | {% for subfolderitem in subfolders.subfolderitems %}
14 | [{{subfolderitem.url | remove: "/" | remove: ".html"}}]: {{subfolderitem.url | remove: "/"}}
15 | {% endfor %}
16 | {% endfor %}
17 | {% endfor %}
18 | {% endfor %}
19 | {% endfor %}
20 | {% endfor %}
21 |
22 |
23 | {% comment %} Get links from topnav {% endcomment %}
24 |
25 | {% for entry in site.data.topnav.topnav %}
26 | {% for item in entry.items %}
27 | {% if item.external_url == null %}
28 | [{{item.url | remove: "/" | remove: ".html"}}]: {{item.url | remove: "/"}}
29 | {% endif %}
30 | {% endfor %}
31 | {% endfor %}
32 |
33 | {% comment %}Get links from topnav dropdowns {% endcomment %}
34 |
35 | {% for entry in site.data.topnav.topnav_dropdowns %}
36 | {% for folder in entry.folders %}
37 | {% for folderitem in folder.folderitems %}
38 | {% if folderitem.external_url == null %}
39 | [{{folderitem.url | remove: "/" | remove: ".html"}}]: {{folderitem.url | remove: "/"}}
40 | {% endif %}
41 | {% endfor %}
42 | {% endfor %}
43 | {% endfor %}
44 |
45 |
--------------------------------------------------------------------------------
/docs/_includes/note.html:
--------------------------------------------------------------------------------
1 |
Note: {{include.content}}
2 |
--------------------------------------------------------------------------------
/docs/_includes/taglogic.html:
--------------------------------------------------------------------------------
1 |
The following pages and posts are tagged with
2 |
Title | Type | Excerpt |
3 |
4 | {% assign thisTag = page.tagName %}
5 | {% for page in site.pages %}
6 | {% for tag in page.tags %}
7 | {% if tag == thisTag %}
8 |
9 | {{page.title}} |
10 | Page |
11 | {% if page.summary %} {{ page.summary | strip_html | strip_newlines | truncate: 160 }} {% else %} {{ page.content | truncatewords: 50 | strip_html }} {% endif %} |
12 |
13 | {% endif %}
14 | {% endfor %}
15 | {% endfor %}
16 |
17 | {% assign thisTag = page.tagName %}
18 | {% for post in site.posts %}
19 | {% for tag in post.tags %}
20 | {% if tag == thisTag %}
21 |
22 | {{post.title}} |
23 | Post |
24 | {% if post.summary %} {{ post.summary | strip_html | strip_newlines | truncate: 160 }} {% else %} {{ post.content | truncatewords: 50 | strip_html }} {% endif %} |
25 |
26 | {% endif %}
27 | {% endfor %}
28 | {% endfor %}
29 |
30 |
31 |
32 |
33 |
--------------------------------------------------------------------------------
/docs/_includes/tip.html:
--------------------------------------------------------------------------------
1 |
Tip: {{include.content}}
--------------------------------------------------------------------------------
/docs/_includes/toc.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
20 |
21 |
22 |
--------------------------------------------------------------------------------
/docs/_includes/warning.html:
--------------------------------------------------------------------------------
1 |
Warning: {{include.content}}
--------------------------------------------------------------------------------
/docs/_layouts/default_print.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | {% include head_print.html %}
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 | {{content}}
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/docs/_layouts/none.html:
--------------------------------------------------------------------------------
1 | ---
2 | ---
3 | {{content}}
--------------------------------------------------------------------------------
/docs/_layouts/page.html:
--------------------------------------------------------------------------------
1 | ---
2 | layout: default
3 | ---
4 |
5 |
8 |
9 | {% if page.simple_map == true %}
10 |
11 |
16 |
17 | {% include custom/{{page.map_name}}.html %}
18 |
19 | {% elsif page.complex_map == true %}
20 |
21 |
26 |
27 | {% include custom/{{page.map_name}}.html %}
28 |
29 | {% endif %}
30 |
31 |
32 |
33 | {% if page.summary %}
34 |
{{page.summary}}
35 | {% endif %}
36 |
37 | {% unless page.toc == false %}
38 | {% include toc.html %}
39 | {% endunless %}
40 |
41 |
42 | {% if site.github_editme_path %}
43 |
44 |
Edit me
45 |
46 | {% endif %}
47 |
48 |
49 | {% if site.gitlab_editme_path %}
50 |
51 |
Edit me
52 |
53 | {% endif %}
54 |
55 | {{content}}
56 |
57 |
68 |
69 | {% include disqus.html %}
70 |
71 |
72 |
73 | {{site.data.alerts.hr_shaded}}
74 |
75 | {% include footer.html %}
76 |
--------------------------------------------------------------------------------
/docs/_layouts/page_print.html:
--------------------------------------------------------------------------------
1 | ---
2 | layout: default_print
3 | comments: true
4 | ---
5 |
8 |
9 |
10 |
11 | {% if page.summary %}
12 |
{{page.summary}}
13 | {% endif %}
14 | {{ content }}
15 |
16 |
--------------------------------------------------------------------------------
/docs/_layouts/post.html:
--------------------------------------------------------------------------------
1 | ---
2 | layout: default
3 | ---
4 |
5 |
6 |
21 |
22 |
23 |
24 | {% if page.summary %}
25 |
{{page.summary}}
26 | {% endif %}
27 |
28 | {{ content }}
29 |
30 |
31 |
32 |
33 |
34 |
35 | {% include disqus.html %}
36 |
37 | {{site.data.alerts.hr_shaded}}
38 |
39 | {% include footer.html %}
40 |
--------------------------------------------------------------------------------
/docs/css/boxshadowproperties.css:
--------------------------------------------------------------------------------
1 | /* box-shadow fonts return errors with prince, so extracting here to put in web output only */
2 |
3 | #search-demo-container ul#results-container {
4 | box-shadow: 2px 3px 2px #dedede;
5 | }
6 |
7 |
8 | hr.shaded {
9 | box-shadow: inset 0 6px 6px -6px rgba(0,0,0,0.5);
10 | }
11 |
12 | .videoThumbs img {
13 | box-shadow: 2px 2px 1px #f0f0f0;
14 | }
15 |
16 | .box {
17 | box-shadow: 2px 2px 4px #dedede;
18 | }
19 |
20 | @media (max-width: 1200px) {
21 | .navbar-collapse {
22 | box-shadow: inset 0 1px 0 rgba(255,255,255,0.1);
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/docs/css/fonts/FontAwesome.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/css/fonts/FontAwesome.otf
--------------------------------------------------------------------------------
/docs/css/fonts/fontawesome-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/css/fonts/fontawesome-webfont.eot
--------------------------------------------------------------------------------
/docs/css/fonts/fontawesome-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/css/fonts/fontawesome-webfont.ttf
--------------------------------------------------------------------------------
/docs/css/fonts/fontawesome-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/css/fonts/fontawesome-webfont.woff
--------------------------------------------------------------------------------
/docs/css/fonts/fontawesome-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/css/fonts/fontawesome-webfont.woff2
--------------------------------------------------------------------------------
/docs/css/modern-business.css:
--------------------------------------------------------------------------------
1 | /*!
2 | * Start Bootstrap - Modern Business HTML Template (http://startbootstrap.com)
3 | * Code licensed under the Apache License v2.0.
4 | * For details, see http://www.apache.org/licenses/LICENSE-2.0.
5 | */
6 |
7 | /* Global Styles */
8 |
9 | html,
10 | body {
11 | height: 100%;
12 | }
13 |
14 | .img-portfolio {
15 | margin-bottom: 30px;
16 | }
17 |
18 | .img-hover:hover {
19 | opacity: 0.8;
20 | }
21 |
22 | /* Home Page Carousel */
23 |
24 | header.carousel {
25 | height: 50%;
26 | }
27 |
28 | header.carousel .item,
29 | header.carousel .item.active,
30 | header.carousel .carousel-inner {
31 | height: 100%;
32 | }
33 |
34 | header.carousel .fill {
35 | width: 100%;
36 | height: 100%;
37 | background-position: center;
38 | background-size: cover;
39 | }
40 |
41 | /* 404 Page Styles */
42 |
43 | .error-404 {
44 | font-size: 100px;
45 | }
46 |
47 | /* Pricing Page Styles */
48 |
49 | .price {
50 | display: block;
51 | font-size: 50px;
52 | line-height: 50px;
53 | }
54 |
55 | .price sup {
56 | top: -20px;
57 | left: 2px;
58 | font-size: 20px;
59 | }
60 |
61 | .period {
62 | display: block;
63 | font-style: italic;
64 | }
65 |
66 | /* Footer Styles */
67 |
68 | footer {
69 | margin: 50px 0;
70 | }
71 |
72 | /* Responsive Styles */
73 |
74 | @media(max-width:991px) {
75 | .client-img,
76 | .img-related {
77 | margin-bottom: 30px;
78 | }
79 | }
80 |
81 | @media(max-width:767px) {
82 | .img-portfolio {
83 | margin-bottom: 15px;
84 | }
85 |
86 | header.carousel .carousel {
87 | height: 70%;
88 | }
89 | }
90 |
--------------------------------------------------------------------------------
/docs/feed.xml:
--------------------------------------------------------------------------------
1 | ---
2 | search: exclude
3 | layout: none
4 | ---
5 |
6 |
7 |
8 |
9 | {{ site.title | xml_escape }}
10 | {{ site.description | xml_escape }}
11 | {{ site.url }}/
12 |
13 | {{ site.time | date_to_rfc822 }}
14 | {{ site.time | date_to_rfc822 }}
15 | Jekyll v{{ jekyll.version }}
16 | {% for post in site.posts limit:10 %}
17 | -
18 | {{ post.title | xml_escape }}
19 | {{ post.content | xml_escape }}
20 | {{ post.date | date_to_rfc822 }}
21 | {{ post.url | prepend: site.url }}
22 | {{ post.url | prepend: site.url }}
23 | {% for tag in post.tags %}
24 | {{ tag | xml_escape }}
25 | {% endfor %}
26 | {% for tag in page.tags %}
27 | {{ cat | xml_escape }}
28 | {% endfor %}
29 |
30 | {% endfor %}
31 |
32 |
33 |
--------------------------------------------------------------------------------
/docs/fonts/FontAwesome.otf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/FontAwesome.otf
--------------------------------------------------------------------------------
/docs/fonts/fontawesome-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/fontawesome-webfont.eot
--------------------------------------------------------------------------------
/docs/fonts/fontawesome-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/fontawesome-webfont.ttf
--------------------------------------------------------------------------------
/docs/fonts/fontawesome-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/fontawesome-webfont.woff
--------------------------------------------------------------------------------
/docs/fonts/glyphicons-halflings-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/glyphicons-halflings-regular.eot
--------------------------------------------------------------------------------
/docs/fonts/glyphicons-halflings-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/glyphicons-halflings-regular.ttf
--------------------------------------------------------------------------------
/docs/fonts/glyphicons-halflings-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/glyphicons-halflings-regular.woff
--------------------------------------------------------------------------------
/docs/fonts/glyphicons-halflings-regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/fonts/glyphicons-halflings-regular.woff2
--------------------------------------------------------------------------------
/docs/images/androidsdkmanagericon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/androidsdkmanagericon.png
--------------------------------------------------------------------------------
/docs/images/authorizegithubscreen2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/authorizegithubscreen2.png
--------------------------------------------------------------------------------
/docs/images/authorizeongithub.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/authorizeongithub.png
--------------------------------------------------------------------------------
/docs/images/company_logo.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/company_logo.png
--------------------------------------------------------------------------------
/docs/images/company_logo_big.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/company_logo_big.png
--------------------------------------------------------------------------------
/docs/images/favicon.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/favicon.ico
--------------------------------------------------------------------------------
/docs/images/helpapi-01.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/helpapi-01.png
--------------------------------------------------------------------------------
/docs/images/illustratoroptions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/illustratoroptions.png
--------------------------------------------------------------------------------
/docs/images/itermexample.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/itermexample.png
--------------------------------------------------------------------------------
/docs/images/jekyll.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/jekyll.png
--------------------------------------------------------------------------------
/docs/images/killalljekyll.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/killalljekyll.png
--------------------------------------------------------------------------------
/docs/images/liningup.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/liningup.png
--------------------------------------------------------------------------------
/docs/images/redpipe-600.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/redpipe-600.png
--------------------------------------------------------------------------------
/docs/images/workflowarrow.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/docs/images/workflowarrow.png
--------------------------------------------------------------------------------
/docs/js/customscripts.js:
--------------------------------------------------------------------------------
1 | $('#mysidebar').height($(".nav").height());
2 |
3 |
4 | $( document ).ready(function() {
5 |
6 | //this script says, if the height of the viewport is greater than 800px, then insert affix class, which makes the nav bar float in a fixed
7 | // position as your scroll. if you have a lot of nav items, this height may not work for you.
8 | var h = $(window).height();
9 | //console.log (h);
10 | if (h > 800) {
11 | $( "#mysidebar" ).attr("class", "nav affix");
12 | }
13 | // activate tooltips. although this is a bootstrap js function, it must be activated this way in your theme.
14 | $('[data-toggle="tooltip"]').tooltip({
15 | placement : 'top'
16 | });
17 |
18 | /**
19 | * AnchorJS
20 | */
21 | anchors.add('h2,h3,h4,h5');
22 |
23 | });
24 |
25 | // needed for nav tabs on pages. See Formatting > Nav tabs for more details.
26 | // script from http://stackoverflow.com/questions/10523433/how-do-i-keep-the-current-tab-active-with-twitter-bootstrap-after-a-page-reload
27 | $(function() {
28 | var json, tabsState;
29 | $('a[data-toggle="pill"], a[data-toggle="tab"]').on('shown.bs.tab', function(e) {
30 | var href, json, parentId, tabsState;
31 |
32 | tabsState = localStorage.getItem("tabs-state");
33 | json = JSON.parse(tabsState || "{}");
34 | parentId = $(e.target).parents("ul.nav.nav-pills, ul.nav.nav-tabs").attr("id");
35 | href = $(e.target).attr('href');
36 | json[parentId] = href;
37 |
38 | return localStorage.setItem("tabs-state", JSON.stringify(json));
39 | });
40 |
41 | tabsState = localStorage.getItem("tabs-state");
42 | json = JSON.parse(tabsState || "{}");
43 |
44 | $.each(json, function(containerId, href) {
45 | return $("#" + containerId + " a[href=" + href + "]").tab('show');
46 | });
47 |
48 | $("ul.nav.nav-pills, ul.nav.nav-tabs").each(function() {
49 | var $this = $(this);
50 | if (!json[$this.attr("id")]) {
51 | return $this.find("a[data-toggle=tab]:first, a[data-toggle=pill]:first").tab("show");
52 | }
53 | });
54 | });
55 |
--------------------------------------------------------------------------------
/docs/js/jquery.ba-throttle-debounce.min.js:
--------------------------------------------------------------------------------
1 | /*
2 | * jQuery throttle / debounce - v1.1 - 3/7/2010
3 | * http://benalman.com/projects/jquery-throttle-debounce-plugin/
4 | *
5 | * Copyright (c) 2010 "Cowboy" Ben Alman
6 | * Dual licensed under the MIT and GPL licenses.
7 | * http://benalman.com/about/license/
8 | */
9 | (function(b,c){var $=b.jQuery||b.Cowboy||(b.Cowboy={}),a;$.throttle=a=function(e,f,j,i){var h,d=0;if(typeof f!=="boolean"){i=j;j=f;f=c}function g(){var o=this,m=+new Date()-d,n=arguments;function l(){d=+new Date();j.apply(o,n)}function k(){h=c}if(i&&!h){l()}h&&clearTimeout(h);if(i===c&&m>e){l()}else{if(f!==true){h=setTimeout(i?k:l,i===c?e-m:e)}}}if($.guid){g.guid=j.guid=j.guid||$.guid++}return g};$.debounce=function(d,e,f){return f===c?a(d,e,false):a(d,f,e!==false)}})(this);
--------------------------------------------------------------------------------
/docs/search.json:
--------------------------------------------------------------------------------
1 | ---
2 | title: search
3 | layout: none
4 | search: exclude
5 | ---
6 |
7 | [
8 | {% for page in site.pages %}
9 | {% unless page.search == "exclude" %}
10 | {
11 | "title": "{{ page.title | escape }}",
12 | "tags": "{{ page.tags }}",
13 | "keywords": "{{page.keywords}}",
14 | "url": "{{ page.url | remove: "/"}}",
15 | "summary": "{{page.summary | strip }}"
16 | }
17 | {% unless forloop.last and site.posts.size < 1 %},{% endunless %}
18 | {% endunless %}
19 | {% endfor %}
20 |
21 | {% for post in site.posts %}
22 |
23 | {
24 | "title": "{{ post.title | escape }}",
25 | "tags": "{{ post.tags }}",
26 | "keywords": "{{post.keywords}}",
27 | "url": "{{ post.url | remove: "/" }}",
28 | "summary": "{{post.summary | strip }}"
29 | }
30 | {% unless forloop.last %},{% endunless %}
31 | {% endfor %}
32 |
33 | ]
34 |
--------------------------------------------------------------------------------
/docs/sitemap.xml:
--------------------------------------------------------------------------------
1 | ---
2 | layout: none
3 | search: exclude
4 | ---
5 |
6 |
7 |
8 | {% for post in site.posts %}
9 | {% unless post.search == "exclude" %}
10 |
11 | {{site.url}}{{post.url}}
12 |
13 | {% endunless %}
14 | {% endfor %}
15 |
16 |
17 | {% for page in site.pages %}
18 | {% unless page.search == "exclude" %}
19 |
20 | {{site.url}}{{ page.url}}
21 |
22 | {% endunless %}
23 | {% endfor %}
24 |
--------------------------------------------------------------------------------
/redpipe-cdi/.classpath:
--------------------------------------------------------------------------------
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 |
--------------------------------------------------------------------------------
/redpipe-cdi/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | redpipe-cdi
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 | org.eclipse.m2e.core.maven2Builder
15 |
16 |
17 |
18 |
19 |
20 | org.eclipse.jdt.core.javanature
21 | org.eclipse.m2e.core.maven2Nature
22 |
23 |
24 |
--------------------------------------------------------------------------------
/redpipe-cdi/.settings/org.eclipse.core.resources.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | encoding//src/main/java=UTF-8
3 | encoding//src/main/resources=UTF-8
4 | encoding//src/test/java=UTF-8
5 | encoding//src/test/resources=UTF-8
6 | encoding/
=UTF-8
7 |
--------------------------------------------------------------------------------
/redpipe-cdi/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
3 | org.eclipse.jdt.core.compiler.compliance=1.8
4 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
5 | org.eclipse.jdt.core.compiler.release=disabled
6 | org.eclipse.jdt.core.compiler.source=1.8
7 |
--------------------------------------------------------------------------------
/redpipe-cdi/.settings/org.eclipse.m2e.core.prefs:
--------------------------------------------------------------------------------
1 | activeProfiles=
2 | eclipse.preferences.version=1
3 | resolveWorkspaceProjects=true
4 | version=1
5 |
--------------------------------------------------------------------------------
/redpipe-cdi/src/main/java/net/redpipe/cdi/App.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.cdi;
2 |
3 | /**
4 | * Hello world!
5 | *
6 | */
7 | public class App
8 | {
9 | public static void main( String[] args )
10 | {
11 | System.out.println( "Hello World!" );
12 | }
13 | }
14 |
--------------------------------------------------------------------------------
/redpipe-cdi/src/main/java/net/redpipe/cdi/CdiGlobalProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.cdi;
2 |
3 | import javax.enterprise.context.ApplicationScoped;
4 | import javax.enterprise.inject.Produces;
5 |
6 | import io.vertx.core.json.JsonObject;
7 | import io.vertx.reactivex.core.Vertx;
8 | import io.vertx.reactivex.core.eventbus.EventBus;
9 | import net.redpipe.engine.core.AppGlobals;
10 |
11 | @ApplicationScoped
12 | public class CdiGlobalProvider {
13 |
14 | @Produces
15 | public EventBus bus() {
16 | return AppGlobals.get().getVertx().eventBus();
17 | }
18 |
19 | @Produces
20 | public Vertx vertx() {
21 | return AppGlobals.get().getVertx();
22 | }
23 |
24 | // Required by CDI/Vertx
25 | @Produces
26 | public io.vertx.core.Vertx coreVertx() {
27 | return vertx().getDelegate();
28 | }
29 |
30 | @Produces
31 | public JsonObject config() {
32 | return AppGlobals.get().getConfig();
33 | }
34 |
35 | @Produces
36 | public AppGlobals appGlobals() {
37 | return AppGlobals.get();
38 | }
39 | }
40 |
--------------------------------------------------------------------------------
/redpipe-cdi/src/main/resources/META-INF/beans.xml:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/FroMage/redpipe/0aff891d6befdf0dcc2bdbfda22262cdf82ac66f/redpipe-cdi/src/main/resources/META-INF/beans.xml
--------------------------------------------------------------------------------
/redpipe-cdi/src/main/resources/META-INF/services/net.redpipe.engine.spi.Plugin:
--------------------------------------------------------------------------------
1 | net.redpipe.cdi.CdiPlugin
2 |
--------------------------------------------------------------------------------
/redpipe-cdi/src/test/java/net/redpipe/cdi/CdiResource.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.cdi;
2 |
3 | import javax.enterprise.context.ApplicationScoped;
4 | import javax.enterprise.event.Observes;
5 | import javax.inject.Inject;
6 | import javax.ws.rs.GET;
7 | import javax.ws.rs.Path;
8 | import javax.ws.rs.core.Context;
9 | import javax.ws.rs.core.Response;
10 |
11 | import org.jboss.weld.vertx.VertxConsumer;
12 | import org.jboss.weld.vertx.VertxEvent;
13 |
14 | import io.reactivex.Single;
15 | import io.vertx.core.json.JsonObject;
16 | import io.vertx.reactivex.core.Vertx;
17 |
18 | @ApplicationScoped
19 | @Path("test")
20 | public class CdiResource {
21 |
22 | @Inject
23 | Vertx vertx;
24 |
25 | @Inject
26 | JsonObject config;
27 |
28 | @Path("injection")
29 | @GET
30 | public Response testGlobalInjection() {
31 | if(vertx != null && config != null
32 | // force CDI loading
33 | && vertx.toString() != null && config.toString() != null)
34 | return Response.ok().build();
35 | return Response.serverError().build();
36 | }
37 |
38 | @GET
39 | public Single test(@Context Vertx vertx) {
40 | return vertx.eventBus()
41 | .rxSend("echo.address", "hello")
42 | .map(msg -> {
43 | System.err.println("Got reply: "+msg.body());
44 | return Response.ok(msg.body()).build();
45 | });
46 | }
47 |
48 | void echoConsumer(@Observes @VertxConsumer("echo.address") VertxEvent event) {
49 | System.err.println("Got event: "+event.getMessageBody());
50 | event.setReply(event.getMessageBody()+" response from event bus");
51 | }
52 | }
53 |
--------------------------------------------------------------------------------
/redpipe-cdi/src/test/resources/META-INF/beans.xml:
--------------------------------------------------------------------------------
1 |
7 |
8 |
--------------------------------------------------------------------------------
/redpipe-engine/.classpath:
--------------------------------------------------------------------------------
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 |
--------------------------------------------------------------------------------
/redpipe-engine/.project:
--------------------------------------------------------------------------------
1 |
2 |
3 | redpipe-engine
4 |
5 |
6 |
7 |
8 |
9 | org.eclipse.jdt.core.javabuilder
10 |
11 |
12 |
13 |
14 | org.eclipse.m2e.core.maven2Builder
15 |
16 |
17 |
18 |
19 |
20 | org.eclipse.jdt.core.javanature
21 | org.eclipse.m2e.core.maven2Nature
22 |
23 |
24 |
--------------------------------------------------------------------------------
/redpipe-engine/.settings/org.eclipse.jdt.core.prefs:
--------------------------------------------------------------------------------
1 | eclipse.preferences.version=1
2 | org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
3 | org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate
4 | org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8
5 | org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
6 | org.eclipse.jdt.core.compiler.compliance=1.8
7 | org.eclipse.jdt.core.compiler.debug.lineNumber=generate
8 | org.eclipse.jdt.core.compiler.debug.localVariable=generate
9 | org.eclipse.jdt.core.compiler.debug.sourceFile=generate
10 | org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
11 | org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
12 | org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
13 | org.eclipse.jdt.core.compiler.release=disabled
14 | org.eclipse.jdt.core.compiler.source=1.8
15 |
--------------------------------------------------------------------------------
/redpipe-engine/.settings/org.eclipse.m2e.core.prefs:
--------------------------------------------------------------------------------
1 | activeProfiles=
2 | eclipse.preferences.version=1
3 | resolveWorkspaceProjects=true
4 | version=1
5 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/context/AppGlobalsContextProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.context;
2 |
3 | import io.reactiverse.reactivecontexts.core.ContextProvider;
4 | import net.redpipe.engine.core.AppGlobals;
5 |
6 | public class AppGlobalsContextProvider implements ContextProvider {
7 |
8 | @Override
9 | public AppGlobals install(AppGlobals state) {
10 | return AppGlobals.set(state);
11 | }
12 |
13 | @Override
14 | public void restore(AppGlobals previousState) {
15 | AppGlobals.set(previousState);
16 | }
17 |
18 | @Override
19 | public AppGlobals capture() {
20 | return AppGlobals.get();
21 | }
22 | }
23 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/core/MainResource.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.core;
2 |
3 | import java.lang.annotation.Documented;
4 | import java.lang.annotation.ElementType;
5 | import java.lang.annotation.Retention;
6 | import java.lang.annotation.RetentionPolicy;
7 | import java.lang.annotation.Target;
8 |
9 | @Documented
10 | @Retention(RetentionPolicy.RUNTIME)
11 | @Target(ElementType.TYPE)
12 | public @interface MainResource {
13 |
14 | }
15 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/core/Mode.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.core;
2 |
3 | public enum Mode {
4 | DEV, PROD;
5 | }
6 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/db/SQLUtil.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.db;
2 |
3 | import io.reactivex.Completable;
4 | import io.reactivex.Single;
5 | import io.vertx.reactivex.ext.sql.SQLConnection;
6 | import net.redpipe.engine.core.AppGlobals;
7 | import rx.functions.Func1;
8 |
9 |
10 | public class SQLUtil {
11 | public static Single getConnection(){
12 | return AppGlobals.get().getDbConnection();
13 | }
14 |
15 | public static Single doInConnection(Func1 super SQLConnection, ? extends Single> func){
16 | return Single.defer(() -> {
17 | Single connection = getConnection();
18 | return connection.flatMap(conn -> {
19 | return func.call(conn).doAfterTerminate(() -> {
20 | conn.close();
21 | });
22 | });
23 | });
24 | }
25 |
26 | public static Completable doInConnectionCompletable(Func1 super SQLConnection, ? extends Completable> func){
27 | return Completable.defer(() -> {
28 | Single connection = getConnection();
29 | return connection.flatMapCompletable(conn -> {
30 | return func.call(conn).doAfterTerminate(() -> {
31 | conn.close();
32 | });
33 | });
34 | });
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/dispatcher/PluginRequestDispatcher.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.dispatcher;
2 |
3 | import java.io.IOException;
4 | import java.util.List;
5 |
6 | import org.jboss.resteasy.core.SynchronousDispatcher;
7 | import org.jboss.resteasy.plugins.server.embedded.SecurityDomain;
8 | import org.jboss.resteasy.plugins.server.vertx.RequestDispatcher;
9 | import org.jboss.resteasy.spi.HttpRequest;
10 | import org.jboss.resteasy.spi.HttpResponse;
11 | import org.jboss.resteasy.spi.ResteasyProviderFactory;
12 | import net.redpipe.engine.spi.Plugin;
13 |
14 | import io.vertx.core.Context;
15 | import io.vertx.core.http.HttpServerRequest;
16 | import io.vertx.core.http.HttpServerResponse;
17 |
18 | public class PluginRequestDispatcher extends RequestDispatcher {
19 |
20 | private List plugins;
21 |
22 | public PluginRequestDispatcher(SynchronousDispatcher dispatcher, ResteasyProviderFactory providerFactory,
23 | SecurityDomain domain, List plugins) {
24 | super(dispatcher, providerFactory, domain);
25 | this.plugins = plugins;
26 | }
27 |
28 | @Override
29 | public void service(Context context, HttpServerRequest req, HttpServerResponse resp, HttpRequest vertxReq,
30 | HttpResponse vertxResp, boolean handleNotFound) throws IOException {
31 | service(0, context, req, resp, vertxReq, vertxResp, handleNotFound);
32 | }
33 |
34 | private void service(int i, Context context, HttpServerRequest req, HttpServerResponse resp, HttpRequest vertxReq,
35 | HttpResponse vertxResp, boolean handleNotFound) throws IOException {
36 | if(i < plugins.size())
37 | plugins.get(i).aroundRequest(vertxReq, () -> service(i+1, context, req, resp, vertxReq, vertxResp, handleNotFound));
38 | else
39 | super.service(context, req, resp, vertxReq, vertxResp, handleNotFound);
40 | }
41 | }
42 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/dispatcher/VertxHttpResponseWithWorkaround.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.dispatcher;
2 |
3 | import javax.ws.rs.core.Response.Status;
4 |
5 | import org.jboss.resteasy.plugins.server.vertx.VertxHttpResponse;
6 | import org.jboss.resteasy.spi.ResteasyProviderFactory;
7 |
8 | import io.vertx.core.http.HttpHeaders;
9 | import io.vertx.core.http.HttpMethod;
10 | import io.vertx.core.http.HttpServerResponse;
11 |
12 | public class VertxHttpResponseWithWorkaround extends VertxHttpResponse {
13 |
14 | private HttpServerResponse response;
15 |
16 | public VertxHttpResponseWithWorkaround(HttpServerResponse response, ResteasyProviderFactory providerFactory) {
17 | super(response, providerFactory);
18 | this.response = response;
19 | }
20 |
21 | public VertxHttpResponseWithWorkaround(HttpServerResponse response, ResteasyProviderFactory providerFactory,
22 | HttpMethod method) {
23 | super(response, providerFactory, method);
24 | this.response = response;
25 | }
26 |
27 | @Override
28 | public void prepareChunkStream() {
29 | super.prepareChunkStream();
30 |
31 | // fix bugs in superclass
32 | if(isWithoutBody()) {
33 | response.setChunked(false);
34 | response.headersEndHandler(h -> {
35 | response.headers().remove(HttpHeaders.CONTENT_LENGTH);
36 | response.headers().remove(HttpHeaders.CONTENT_TYPE);
37 | });
38 | }
39 | }
40 |
41 | private boolean isWithoutBody() {
42 | int status = response.getStatusCode();
43 | return (status >= 100 && status < 200)
44 | || status == Status.NO_CONTENT.getStatusCode()
45 | || status == Status.NOT_MODIFIED.getStatusCode();
46 | }
47 | }
48 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/mail/Mailer.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.mail;
2 |
3 | import io.reactivex.Completable;
4 |
5 | public interface Mailer {
6 |
7 | Completable send(Mail email);
8 |
9 | }
10 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/mail/MockMailer.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.mail;
2 |
3 | import java.util.HashMap;
4 | import java.util.LinkedList;
5 | import java.util.List;
6 | import java.util.Map;
7 | import java.util.Optional;
8 |
9 | import io.reactivex.Completable;
10 | import io.reactivex.Single;
11 | import io.vertx.reactivex.core.buffer.Buffer;
12 |
13 | public class MockMailer implements Mailer {
14 |
15 | private Map> sentMails = new HashMap<>();
16 |
17 | public MockMailer() {
18 | System.err.println("new MockMailer "+System.identityHashCode(this));
19 | }
20 |
21 | @Override
22 | public Completable send(Mail email) {
23 | Single> htmlRender = email.renderHtml().map(buffer -> Optional.of(buffer)).toSingle(Optional.empty());
24 | Single textRender = email.renderText();
25 | return Single.zip(textRender, htmlRender, (text, html) -> {
26 | send(email, text, html.orElse(null));
27 | return Completable.complete();
28 | }).flatMapCompletable(c -> c);
29 | }
30 |
31 | private void send(Mail email, Buffer text, Buffer html) {
32 | SentMail sentMail = new SentMail(email, text.toString(), html != null ? html.toString() : null);
33 | if (email.to != null) {
34 | for (String to : email.to) {
35 | send(sentMail, to);
36 | }
37 | }
38 | if (email.cc != null) {
39 | for (String to : email.cc) {
40 | send(sentMail, to);
41 | }
42 | }
43 | if (email.bcc != null) {
44 | for (String to : email.bcc) {
45 | send(sentMail, to);
46 | }
47 | }
48 | }
49 |
50 | private void send(SentMail sentMail, String to) {
51 | List mails = sentMails.get(to);
52 | if (mails == null) {
53 | mails = new LinkedList<>();
54 | sentMails.put(to, mails);
55 | }
56 | mails.add(sentMail);
57 | }
58 |
59 | public List getMailsSentTo(String address) {
60 | return sentMails.get(address);
61 | }
62 |
63 | public static class SentMail {
64 |
65 | public final String text;
66 | public final String html;
67 | public final Mail email;
68 |
69 | public SentMail(Mail email, String text, String html) {
70 | this.email = email;
71 | this.text = text;
72 | this.html = html;
73 | }
74 |
75 | }
76 |
77 | }
78 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/BufferBodyWriter.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.io.IOException;
4 | import java.io.OutputStream;
5 | import java.lang.annotation.Annotation;
6 | import java.lang.reflect.Type;
7 |
8 | import javax.ws.rs.WebApplicationException;
9 | import javax.ws.rs.core.MediaType;
10 | import javax.ws.rs.core.MultivaluedMap;
11 | import javax.ws.rs.ext.MessageBodyWriter;
12 | import javax.ws.rs.ext.Provider;
13 |
14 | import io.vertx.reactivex.core.buffer.Buffer;
15 |
16 | @Provider
17 | public class BufferBodyWriter implements MessageBodyWriter{
18 |
19 | @Override
20 | public boolean isWriteable(Class> type, Type genericType, Annotation[] annotations, MediaType mediaType) {
21 | return type == Buffer.class;
22 | }
23 |
24 | @Override
25 | public void writeTo(Buffer buffer, Class> type, Type genericType, Annotation[] annotations, MediaType mediaType,
26 | MultivaluedMap httpHeaders, OutputStream entityStream)
27 | throws IOException, WebApplicationException {
28 | for(int i=0;i {
15 |
16 | @Override
17 | public Response toResponse(Throwable exception) {
18 | StringWriter writer = new StringWriter();
19 | PrintWriter printWriter = new PrintWriter(writer);
20 | exception.printStackTrace(printWriter);
21 | // FIXME: this should really end up in a template.
22 | String text =
23 | ""+
24 | " Error: "+exception.getMessage()+""+
25 | " Error: "+exception.getMessage()+"
"+
26 | " "+writer.toString()+
27 | "
";
28 | if(exception instanceof WebApplicationException) {
29 | Response ret = ((WebApplicationException) exception).getResponse();
30 | // FIXME: probably we don't want to ignore exception entities for exceptions not from resteasy?
31 | return Response.status(ret.getStatus()).entity(text).type(MediaType.TEXT_HTML).build();
32 | }
33 | return Response.status(Status.INTERNAL_SERVER_ERROR).entity(text).type(MediaType.TEXT_HTML).build();
34 | }
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/FileResource.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.io.File;
4 | import java.io.IOException;
5 |
6 | import javax.ws.rs.PathParam;
7 | import javax.ws.rs.core.Response;
8 | import javax.ws.rs.core.Response.Status;
9 |
10 | public abstract class FileResource {
11 | public Response getFile(@PathParam("path") String path) throws IOException{
12 | // TODO: add caching support with precondition
13 | File root = new File("src/main/resources/webroot");
14 | File f = new File(root, path);
15 | // FIXME: check that this is enough
16 | if(!f.getCanonicalPath().startsWith(root.getCanonicalPath()+"/"))
17 | return Response.status(404).build();
18 | if(f.isDirectory())
19 | return Response.ok("Folder "+path).build();
20 | if(!f.exists())
21 | return Response.status(Status.NOT_FOUND).build();
22 | return Response.ok(f).build();
23 | }
24 | }
25 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/JsonObjectBodyReader.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.io.IOException;
4 | import java.io.InputStream;
5 | import java.lang.annotation.Annotation;
6 | import java.lang.reflect.Type;
7 |
8 | import javax.ws.rs.WebApplicationException;
9 | import javax.ws.rs.core.MediaType;
10 | import javax.ws.rs.core.MultivaluedMap;
11 | import javax.ws.rs.ext.MessageBodyReader;
12 | import javax.ws.rs.ext.Provider;
13 |
14 | import org.apache.commons.io.IOUtils;
15 |
16 | import io.vertx.core.json.JsonObject;
17 |
18 | @Provider
19 | public class JsonObjectBodyReader implements MessageBodyReader{
20 |
21 | @Override
22 | public boolean isReadable(Class> type, Type genericType, Annotation[] annotations, MediaType mediaType) {
23 | return type == JsonObject.class;
24 | }
25 |
26 | @Override
27 | public JsonObject readFrom(Class type, Type genericType, Annotation[] annotations, MediaType mediaType,
28 | MultivaluedMap httpHeaders, InputStream entityStream)
29 | throws IOException, WebApplicationException {
30 | byte[] byteArray = IOUtils.toByteArray(entityStream);
31 | // FIXME: encoding
32 | return new JsonObject(new String(byteArray, "utf-8"));
33 | }
34 |
35 |
36 | }
37 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/JsonObjectBodyWriter.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.io.IOException;
4 | import java.io.OutputStream;
5 | import java.lang.annotation.Annotation;
6 | import java.lang.reflect.Type;
7 |
8 | import javax.ws.rs.WebApplicationException;
9 | import javax.ws.rs.core.MediaType;
10 | import javax.ws.rs.core.MultivaluedMap;
11 | import javax.ws.rs.ext.MessageBodyWriter;
12 | import javax.ws.rs.ext.Provider;
13 |
14 | import io.vertx.core.json.JsonObject;
15 |
16 | @Provider
17 | public class JsonObjectBodyWriter implements MessageBodyWriter{
18 |
19 | @Override
20 | public boolean isWriteable(Class> type, Type genericType, Annotation[] annotations, MediaType mediaType) {
21 | return type == JsonObject.class;
22 | }
23 |
24 | @Override
25 | public long getSize(JsonObject t, Class> type, Type genericType, Annotation[] annotations, MediaType mediaType) {
26 | return t.encode().length();
27 | }
28 |
29 | @Override
30 | public void writeTo(JsonObject t, Class> type, Type genericType, Annotation[] annotations, MediaType mediaType,
31 | MultivaluedMap httpHeaders, OutputStream entityStream)
32 | throws IOException, WebApplicationException {
33 | // TODO: encoding
34 | entityStream.write(t.encode().getBytes("utf-8"));
35 | }
36 |
37 | }
38 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/PermissionInjector.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.lang.annotation.Annotation;
4 | import java.lang.reflect.Type;
5 |
6 | import javax.ws.rs.ext.Provider;
7 |
8 | import org.jboss.resteasy.spi.ContextInjector;
9 | import org.jboss.resteasy.spi.ResteasyProviderFactory;
10 |
11 | import io.vertx.rxjava.ext.auth.User;
12 | import io.vertx.rxjava.ext.web.RoutingContext;
13 | import net.redpipe.engine.security.HasPermission;
14 | import rx.Single;
15 |
16 | @Provider
17 | public class PermissionInjector implements ContextInjector, Boolean>{
18 |
19 | @Override
20 | public Single resolve(Class extends Single> rawType, Type genericType,
21 | Annotation[] annotations) {
22 | for (Annotation annotation : annotations) {
23 | if(annotation.annotationType() == HasPermission.class) {
24 | RoutingContext ctx = ResteasyProviderFactory.getContextData(RoutingContext.class);
25 | User user = ctx.user();
26 | if(user == null)
27 | return Single.just(false);
28 | return user.rxIsAuthorised(((HasPermission) annotation).value());
29 | }
30 | }
31 | return null;
32 | }
33 |
34 | }
35 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/RxVertxProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.io.IOException;
4 |
5 | import javax.annotation.Priority;
6 | import javax.servlet.ServletContext;
7 | import javax.ws.rs.container.ContainerRequestContext;
8 | import javax.ws.rs.container.ContainerRequestFilter;
9 | import javax.ws.rs.container.PreMatching;
10 | import javax.ws.rs.ext.Provider;
11 |
12 | import org.jboss.resteasy.spi.ResteasyProviderFactory;
13 |
14 | import io.vertx.core.Vertx;
15 | import io.vertx.core.http.HttpServerRequest;
16 | import io.vertx.core.http.HttpServerResponse;
17 | import net.redpipe.engine.core.AppGlobals;
18 |
19 | @Priority(0)
20 | @Provider
21 | @PreMatching
22 | public class RxVertxProvider implements ContainerRequestFilter {
23 |
24 | @Override
25 | public void filter(ContainerRequestContext requestContext) throws IOException {
26 | Vertx vertx = ResteasyProviderFactory.getContextData(io.vertx.core.Vertx.class);
27 | HttpServerRequest req = ResteasyProviderFactory.getContextData(HttpServerRequest.class);
28 | HttpServerResponse resp = ResteasyProviderFactory.getContextData(HttpServerResponse.class);
29 |
30 | // rx2
31 | ResteasyProviderFactory.pushContext(io.vertx.reactivex.core.Vertx.class,
32 | io.vertx.reactivex.core.Vertx.newInstance(vertx));
33 | ResteasyProviderFactory.pushContext(io.vertx.reactivex.core.http.HttpServerRequest.class,
34 | io.vertx.reactivex.core.http.HttpServerRequest.newInstance(req));
35 | ResteasyProviderFactory.pushContext(io.vertx.reactivex.core.http.HttpServerResponse.class,
36 | io.vertx.reactivex.core.http.HttpServerResponse.newInstance(resp));
37 | // rx1
38 | ResteasyProviderFactory.pushContext(io.vertx.rxjava.core.Vertx.class,
39 | io.vertx.rxjava.core.Vertx.newInstance(vertx));
40 | ResteasyProviderFactory.pushContext(io.vertx.rxjava.core.http.HttpServerRequest.class,
41 | io.vertx.rxjava.core.http.HttpServerRequest.newInstance(req));
42 | ResteasyProviderFactory.pushContext(io.vertx.rxjava.core.http.HttpServerResponse.class,
43 | io.vertx.rxjava.core.http.HttpServerResponse.newInstance(resp));
44 |
45 | ResteasyProviderFactory.pushContext(ServletContext.class, AppGlobals.get().getGlobal(ServletContext.class));
46 | }
47 |
48 | }
49 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/resteasy/SQLConnectionInjector.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.resteasy;
2 |
3 | import java.lang.annotation.Annotation;
4 | import java.lang.reflect.Type;
5 |
6 | import javax.ws.rs.ext.Provider;
7 |
8 | import org.jboss.resteasy.spi.ContextInjector;
9 |
10 | import io.reactivex.Single;
11 | import io.vertx.reactivex.ext.sql.SQLConnection;
12 | import net.redpipe.engine.core.AppGlobals;
13 |
14 | @Provider
15 | public class SQLConnectionInjector implements ContextInjector, SQLConnection>{
16 |
17 | @Override
18 | public Single resolve(Class extends Single> rawType, Type genericType,
19 | Annotation[] annotations) {
20 | return AppGlobals.get().getDbConnection();
21 | }
22 |
23 | }
24 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/rxjava/CompletableProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.rxjava;
2 |
3 | import rx.Completable;
4 | import rx.Subscription;
5 | import org.jboss.resteasy.spi.AsyncResponseProvider;
6 |
7 | import javax.ws.rs.core.Response;
8 | import java.util.concurrent.CompletableFuture;
9 | import java.util.concurrent.CompletionStage;
10 |
11 | public class CompletableProvider implements AsyncResponseProvider {
12 |
13 | private static class CompletableAdaptor extends CompletableFuture
14 | {
15 | private Subscription subscription;
16 |
17 | public CompletableAdaptor(Completable observable)
18 | {
19 | this.subscription = observable.subscribe(this::completeEmpty, this::completeExceptionally);
20 | }
21 |
22 | @Override
23 | public boolean cancel(boolean mayInterruptIfRunning)
24 | {
25 | subscription.unsubscribe();
26 | return super.cancel(mayInterruptIfRunning);
27 | }
28 |
29 | void completeEmpty() {
30 | super.complete(Response.status(204).build());
31 | }
32 |
33 | }
34 |
35 | @Override
36 | public CompletionStage> toCompletionStage(Completable asyncResponse) {
37 | return new CompletableAdaptor(asyncResponse);
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/rxjava2/CompletableProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.rxjava2;
2 |
3 | import io.reactivex.Completable;
4 | import io.reactivex.disposables.Disposable;
5 | import org.jboss.resteasy.spi.AsyncResponseProvider;
6 |
7 | import javax.ws.rs.core.Response;
8 | import java.util.concurrent.CompletableFuture;
9 | import java.util.concurrent.CompletionStage;
10 |
11 | public class CompletableProvider implements AsyncResponseProvider {
12 |
13 | private static class CompletableAdaptor extends CompletableFuture
14 | {
15 | private Disposable subscription;
16 |
17 | public CompletableAdaptor(Completable observable)
18 | {
19 | this.subscription = observable.subscribe(this::completeEmpty, this::completeExceptionally);
20 | }
21 |
22 | @Override
23 | public boolean cancel(boolean mayInterruptIfRunning)
24 | {
25 | subscription.dispose();
26 | return super.cancel(mayInterruptIfRunning);
27 | }
28 |
29 | void completeEmpty() {
30 | super.complete(Response.status(204).build());
31 | }
32 |
33 | }
34 |
35 | @Override
36 | public CompletionStage> toCompletionStage(Completable asyncResponse) {
37 | return new CompletableAdaptor(asyncResponse);
38 | }
39 |
40 | }
41 |
--------------------------------------------------------------------------------
/redpipe-engine/src/main/java/net/redpipe/engine/rxjava2/MaybeProvider.java:
--------------------------------------------------------------------------------
1 | package net.redpipe.engine.rxjava2;
2 |
3 | import io.reactivex.Maybe;
4 | import io.reactivex.disposables.Disposable;
5 | import org.jboss.resteasy.spi.AsyncResponseProvider;
6 |
7 | import javax.ws.rs.core.Response;
8 | import java.util.concurrent.CompletableFuture;
9 | import java.util.concurrent.CompletionStage;
10 |
11 | public class MaybeProvider implements AsyncResponseProvider> {
12 |
13 | private static class MaybeAdaptor extends CompletableFuture