Added list of types to readme.
the build was successful
Details
the build was successful
Details
This commit is contained in:
parent
4614cfba0c
commit
4e8c44a4ba
37
README.md
37
README.md
|
@ -6,9 +6,6 @@ JSON. You can then put that JSON into easy to use classes.
|
|||
|
||||
**The ABI will be unstable in versions < 1.0.0**
|
||||
|
||||
**Beginning with 0.30.0, all IDs are `const string` instead of
|
||||
`uint_fast64_t` as required by the Mastodon API. Sorry for the inconvenience.**
|
||||
|
||||
# Breaking API changes
|
||||
|
||||
I'm currently rewriting key parts of this library. The new API will be
|
||||
|
@ -22,7 +19,8 @@ releases, please.**
|
|||
# Usage
|
||||
|
||||
The HTML reference can be generated with `build_doc.sh`, if doxygen is
|
||||
installed. It is also available at [doc.schlomp.space/mastodon-cpp/](https://doc.schlomp.space/mastodon-cpp/annotated.html).
|
||||
installed. It is also available at
|
||||
[doc.schlomp.space/mastodon-cpp/](https://doc.schlomp.space/mastodon-cpp/annotated.html).
|
||||
There are [examples](https://schlomp.space/tastytea/mastodon-cpp/src/branch/master/examples)
|
||||
in `examples/`.
|
||||
|
||||
|
@ -74,6 +72,37 @@ A project consisting of one file can be compiled as follows:
|
|||
g++ -std=c++14 -lmastodon-cpp example.cpp
|
||||
```
|
||||
|
||||
## List of types
|
||||
|
||||
Learn more at <https://doc.schlomp.space/mastodon-cpp/namespaceMastodon.html>
|
||||
and <https://doc.schlomp.space/mastodon-cpp/namespaceMastodon_1_1Easy.html>.
|
||||
|
||||
### Return types
|
||||
|
||||
* `Mastodon::return_call`: Contains the response from `Mastodon::API` calls.
|
||||
* `Mastodon::Easy::return_entity`: Contains the response from
|
||||
`Mastodon::Easy::API` calls that return a single `Mastodon::Easy::Entity`.
|
||||
* `Mastodon::Easy::return_entities_vector`: Contains the response from
|
||||
`Mastodon::Easy::API` calls that return multiple `Mastodon::Easy::Entity`.
|
||||
|
||||
### Other types
|
||||
|
||||
* `Mastodon::param`: A single parameter to an `Mastodon::API` call. Normally you
|
||||
don't need this.
|
||||
* `Mastodon::parameters`: All parameters to an `Mastodon::API` call.
|
||||
* `Mastodon::http_method`: HTTP method of an `Mastodon::API` call.
|
||||
* `Mastodon::Easy::event_type`: Event types returned in streams.
|
||||
* `Mastodon::Easy::visibility_type`: Describes the visibility of a post.
|
||||
* `Mastodon::Easy::attachment_type`: Describes the type of attachment.
|
||||
* `Mastodon::Easy::card_type`: Describes the type of card.
|
||||
* `Mastodon::Easy::notification_type`: The type of the notification.
|
||||
* `Mastodon::Easy::stream_event`: Type and data of an events returned in
|
||||
streams.
|
||||
* `Mastodon::Easy::alert_type`: Type for a single alert.
|
||||
* `Mastodon::Easy::alerts`: Vector of alert_type, used for push subscribstions.
|
||||
* `Mastodon::Easy::time`: Type for time, can be converted to `time_point` and
|
||||
`string`.
|
||||
|
||||
## Error codes
|
||||
|
||||
| Code | Explanation |
|
||||
|
|
|
@ -47,9 +47,8 @@ using std::uint16_t;
|
|||
namespace Mastodon
|
||||
{
|
||||
/*!
|
||||
* @brief Child of Mastodon::API with abstract methods.
|
||||
*
|
||||
* @since before 0.100.0
|
||||
* @brief Collection of things that make it easier to interface with server
|
||||
* software that implements the Mastodon API.
|
||||
*/
|
||||
namespace Easy
|
||||
{
|
||||
|
@ -127,7 +126,7 @@ namespace Easy
|
|||
const std::vector<stream_event> parse_stream(const std::string &streamdata);
|
||||
|
||||
/*!
|
||||
* @brief Interface to the Mastodon API, easy version.
|
||||
* @brief Child of Mastodon::API with abstract methods.
|
||||
*
|
||||
* Provides convenient functions to deal with the responses you get.
|
||||
*/
|
||||
|
|
|
@ -31,7 +31,7 @@ namespace Mastodon
|
|||
namespace Easy
|
||||
{
|
||||
/*!
|
||||
* @brief Describes the event type
|
||||
* @brief Describes the event type returned in streams.
|
||||
*
|
||||
* @since before 0.11.0
|
||||
*/
|
||||
|
@ -45,7 +45,7 @@ namespace Easy
|
|||
};
|
||||
|
||||
/*!
|
||||
* @brief Describes visibility of toots.
|
||||
* @brief Describes visibility of posts.
|
||||
*
|
||||
* @since before 0.11.0
|
||||
*/
|
||||
|
|
|
@ -45,6 +45,10 @@ using std::uint8_t;
|
|||
* @example example02_stream.cpp
|
||||
*/
|
||||
|
||||
/*!
|
||||
* @brief Collection of things to interface with server software that
|
||||
* implements the Mastodon API.
|
||||
*/
|
||||
namespace Mastodon
|
||||
{
|
||||
/*!
|
||||
|
|
|
@ -80,7 +80,7 @@ namespace Mastodon
|
|||
} parameters;
|
||||
|
||||
/*!
|
||||
* @brief HTTP methods.
|
||||
* @brief HTTP methods. Used in API calls.
|
||||
*
|
||||
* @since 0.100.0
|
||||
*/
|
||||
|
|
Reference in New Issue