aboutsummaryrefslogtreecommitdiff
path: root/src/urls
diff options
context:
space:
mode:
authorMelody Horn / boringcactus <melody@boringcactus.com>2021-06-12 21:06:06 -0600
committerMelody Horn / boringcactus <melody@boringcactus.com>2021-06-12 21:06:06 -0600
commit582124d59afa438e2cb88cc024d6b19232236e1e (patch)
tree6b1bc48d5e3a405434f4900c7e20daf0d186de5a /src/urls
parentfcc13328ff82326d25e39504732701b27f894e22 (diff)
downloadtosin-582124d59afa438e2cb88cc024d6b19232236e1e.tar.gz
tosin-582124d59afa438e2cb88cc024d6b19232236e1e.zip
stub out basic implementation
Diffstat (limited to 'src/urls')
-rw-r--r--src/urls/mod.rs16
1 files changed, 16 insertions, 0 deletions
diff --git a/src/urls/mod.rs b/src/urls/mod.rs
new file mode 100644
index 0000000..1acf186
--- /dev/null
+++ b/src/urls/mod.rs
@@ -0,0 +1,16 @@
+use crate::http::{Request, Response};
+
+pub type View = fn(Request) -> Response;
+
+pub enum Path {
+ View {
+ url: &'static str,
+ view: View,
+ name: &'static str,
+ },
+
+ Include {
+ url: &'static str,
+ content: &'static [Path],
+ },
+}