summaryrefslogtreecommitdiffstats
path: root/libimagbookmark
diff options
context:
space:
mode:
authorMatthias Beyer <mail@beyermatthias.de>2016-07-08 00:27:45 +0200
committerMatthias Beyer <mail@beyermatthias.de>2016-07-08 00:27:45 +0200
commit9231cf5fb7765d88b5d005683e27f009472edb97 (patch)
tree637e6e50ab7f4e95f76d046e3fd21977664e7a74 /libimagbookmark
parentee51de088a8d958048650082714f65428d41b012 (diff)
Add interface for working with BookmarkCollection
Oh my god I'm so drunk right now. It's 0030 and I had dinner at around 1800 yesterday and then I just drank like... two Mate and maybe 1L of water... and now I drank 0.33L beer and I'm drunk as fuck... just wanted to share. I hope this commit still makes sense... I'm not sure, I should definitively review this tomorrow. So... maybe I can do some more. Btw., I just saw "The Martian" - the movie, you know. Oh my god, I love Matt Damon - I think he's a really nice actor, actually. I probably shouldn't put this into the commit message, I know... Just wanted to have some fun here.. sorry.
Diffstat (limited to 'libimagbookmark')
-rw-r--r--libimagbookmark/src/collection.rs22
1 files changed, 20 insertions, 2 deletions
diff --git a/libimagbookmark/src/collection.rs b/libimagbookmark/src/collection.rs
index b1def1d7..b0ed38de 100644
--- a/libimagbookmark/src/collection.rs
+++ b/libimagbookmark/src/collection.rs
@@ -18,10 +18,12 @@ use libimagstore::storeid::IntoStoreId;
use libimagstore::store::FileLockEntry;
use libimagentrylink::external::ExternalLinker;
use libimagentrylink::internal::InternalLinker;
-use libimagentrylink::internal::Link;
+use libimagentrylink::internal::Link as StoreLink;
use libimagerror::into::IntoError;
use url::Url;
+use link::Link;
+
pub struct BookmarkCollection<'a> {
fle: FileLockEntry<'a>,
store: &'a Store,
@@ -82,7 +84,7 @@ impl<'a> BookmarkCollection<'a> {
self.fle.get_external_links(&self.store).map_err_into(BEK::LinkError)
}
- pub fn link_entries(&self) -> Result<Vec<Link>> {
+ pub fn link_entries(&self) -> Result<Vec<StoreLink>> {
use libimagentrylink::external::is_external_link_storeid;
self.fle
@@ -91,5 +93,21 @@ impl<'a> BookmarkCollection<'a> {
.map_err_into(BEK::StoreReadError)
}
+ pub fn add_link(&self, l: Link) -> Result<()> {
+ unimplemented!()
+ }
+
+ pub fn get_link(&self, l: Link) -> Result<Link> {
+ unimplemented!()
+ }
+
+ pub fn get_links_matching(&self, r: Regex) -> Result<Link> {
+ unimplemented!()
+ }
+
+ pub fn remove_link(&self, l: Link) -> Result<()> {
+ unimplemented!()
+ }
+
}