Skip to main content

Module tree

Module tree 

Source
Expand description

Changing the tree of folders and feeds, and a reader’s settings.

A level of the tree (the top, or the inside of a folder) holds folders and feeds in one order. Whenever a level changes, its nodes are numbered anew from 1, so positions never run out of room between two neighbors. Changes to one account’s tree happen one after the other: each locks the account.

The rules of the tree itself (no folder inside itself, at most five levels) are the database’s; see the trigger in the first migration.

Structs§

Created 🔒
The answer to making something: the number it got.
FeedInfo
What the server knows of a feed and how it is fetched, for a reader to pass on to whoever helps with it. Nothing in it is about other accounts.
Move 🔒
Where a node goes, seen from the node it is dropped on, as in the interface’s own model of the tree.
NewAgent 🔒
What PUT /api/feeds/{id}/agent reads.
NewFolder 🔒
What POST /api/folders reads. It answers with Created.
Rename 🔒
What PATCH /api/folders/{id} and PATCH /api/feeds/{id} read. A subscription without a title of its own goes by its feed’s.

Enums§

Drop 🔒
The side of the node it is dropped on that a node lands on: before it, after it or, for a folder, inside it.
FetchAgent 🔒
Who a feed is fetched as: as rueder, or as a browser, for sites that turn readers like rueder away.
Node
A folder or a subscription, as the tree’s changes name them.

Constants§

MAX_FEEDS
How many feeds an account can subscribe to. Every one of them is fetched for as long as somebody reads it.
MAX_FEEDS_IN_FOLDER
How many feeds one folder, or the top level, can hold.
MAX_FOLDERS
How many folders an account can have.
MAX_SETTINGS
The largest settings of an account, in bytes of JSON.
MAX_TITLE
The longest name of a folder or a subscription, in characters.

Functions§

add_folder 🔒
A new, empty folder at the end of its level.
bad 🔒
end_of 🔒
The position after the last node of a level.
feed_info
What the server knows of a feed: with reader, only if that account reads it; without, of any feed, for the operator.
info 🔒
What the server knows of a feed the account reads and how it is fetched: its number, its addresses, as what and when it was fetched and why that failed, for a message to support.
level 🔒
The nodes of one level in their order. Where positions are equal, folders come first, then the older node.
move_node 🔒
Moves a folder or a feed: before or after another node, or into a folder at its end. A folder does not go into itself, and folders nest at most five levels deep.
parent_of 🔒
Where a node is: None if the account has no such node, else its folder.
remove_folder 🔒
Takes a folder out. What was in it moves to where the folder was.
rename_feed 🔒
Gives a subscription a name of the reader’s own, or, without one, the feed’s name back.
rename_folder 🔒
Gives a folder another title.
renumber 🔒
Numbers the nodes of a level from 1, in this order.
room_for_feed 🔒
Whether a folder, or the top level, can take one more feed.
room_for_subscription 🔒
Whether the account can subscribe to one more feed.
routes
rule 🔒
What the database says when a change breaks a rule of the tree becomes an answer the reader can do something with.
set_agent 🔒
Says as what a feed is fetched: as rueder, or as a browser for sites that turn rueder away. The feed is one for all who read it, so this holds for all of them, and rueder passes for a browser in the name of the whole server: only an admin who reads it says it. The next fetch comes at once.
set_settings 🔒
Replaces the settings. What is in them is the interface’s business; the server only keeps them, within a size.
settings 🔒
The reader’s settings, as the interface last stored them: the same on every device.
title 🔒
A name as it is stored, or why it cannot be one.
types 🔒
The types this module sends and reads, for the frontend.
unsubscribe 🔒
Ends a subscription, and with it what the reader read, starred and labelled there. The feed and its articles stay for whoever else reads it.
Built on 2026-11-24 from commit 92441b9 of FionaPreroll/rueder.