Move copyright notices down the title in docs

Otherwise Docusaurus can't see the document's title
parent eb2aa7f2
---
title: Asynchronous HTTP programming
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,10 +9,6 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
title: Asynchronous HTTP programming
---
Interfaces provided by Pistaches are _asynchronous_ and _non-blocking_. Asynchronous programming allows for code to continue executing even if the result of a given call is not available yet. Calls that provide an asynchronous interface are referred to _asynchronous calls_.
An example of such a call is the `send()` function provided by the `ResponseWriter` interface. This function returns the number of bytes written to the socket file descriptor associated to the connection. However, instead of returning directly the value to the caller and thus blocking the caller, it wraps the value into a component called a `Promise`.
......
---
title: Headers
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,10 +9,6 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
title: Headers
---
## Overview
Inspired by the [Rust](https://www.rust-lang.org) eco-system and [Hyper](https://hyper.rs), HTTP headers are represented as _type-safe_ plain objects. Instead of representing headers as a pair of `(key: string, value: value)`, the choice has been made to represent them as plain objects. This greatly reduces the risk of typo errors that can not catched by the compiler with plain old strings.
......
---
id: http-handler
title: HTTP handler
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,11 +10,6 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
id: http-handler
title: HTTP handler
---
Requests that are received by Pistache are handled by a special class called `Http::Handler`. This class declares a bunch of virtual methods that can be overriden to handle special events that occur on the socket and/or connection.
The `onRequest()` function must be overriden. This function is called whenever Pistache received data and correctly parsed it as an HTTP request.
......
---
title: Getting started
slug: /
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,11 +10,6 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
title: Getting started
slug: /
---
Pistache is a web framework written in Modern C++ that focuses on performance and provides an elegant and asynchronous API.
```cpp
......
---
title: REST description
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,8 +9,4 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
title: REST description
---
Documentation writing for this part is still in progress, please refer to the [rest_description](https://github.com/pistacheio/pistache/blob/master/examples/rest_description.cc) example.
---
title: Routing
---
<!--
SPDX-FileCopyrightText: 2016 Mathieu Stefani
SPDX-FileCopyrightText: 2021 Andrea Pappacoda
......@@ -5,10 +9,6 @@ SPDX-FileCopyrightText: 2021 Andrea Pappacoda
SPDX-License-Identifier: Apache-2.0
-->
---
title: Routing
---
HTTP routing consists of binding an HTTP route to a C++ callback. A special component called an HTTP router will be in charge of dispatching HTTP requests to the right C++ callback. A route is composed of an HTTP verb associated to a resource:
```javascript
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment