Matthias Beyer
0155fea4c1
Impl Display for StoreLinkConsistencyErrorCustomData
2017-06-06 19:04:53 +02:00
Matthias Beyer
13b24cb397
Impl StoreLinkConsistentExt::check_link_consistency()
2017-06-06 19:04:53 +02:00
Matthias Beyer
83647e52a0
Add trait to extend store for link consistency check
...
This commit adds the error infrastructure as well as the trait for
extensing the `Store` type with a function to do a link consistency
check over _all_ entries in the store.
The functionality is not implemented yet.
2017-06-06 19:04:53 +02:00
Matthias Beyer
365f9eb237
Fix: Link::exists() must return Result<bool> now
2017-04-22 11:58:14 +02:00
Matthias Beyer
f225aec9da
Add Link::get_store_id() helper function
2017-04-21 21:08:56 +02:00
Matthias Beyer
6b821f7b28
Add wrapper for Link::to_str() -> StoreId::to_str()
2017-04-21 21:08:56 +02:00
Matthias Beyer
c550325711
Add Link::exists() -> StoreId::exists() wrapper
2017-04-21 21:08:56 +02:00
Matthias Beyer
633f999d54
Add new trait function to add annotated links
...
With this new trait function, one can add annotated links to the
entries.
There's no support yet for removing these links.
2017-04-21 21:08:56 +02:00
Matthias Beyer
8de5bf93be
Add support for new link type in return-value parsing
2017-04-21 21:08:56 +02:00
Matthias Beyer
21d758d635
Add with_base() wrapper for tests
2017-04-21 21:08:56 +02:00
Matthias Beyer
87ee509dc0
Prepare for annotations implementation
...
This patch changes the `libimagentrylink` internals to use a
enum { Id(StoreId), Annotated(StoreId, String) }
as Link type.
In this patch, changes were made to be able to compile the code, but
tests might fail and other crates might fail as well.
2017-04-21 21:08:56 +02:00
Matthias Beyer
725848713b
libimagentrylink: Remove EntryHeader type, use toml::Value
2017-02-05 13:10:39 +01:00
Matthias Beyer
f1c1a1f9be
Eliminate EntryHeader type
...
Therefor introduce the "Header" trait which is implemented on Value for
backwards compatibility.
Make the default_header() function publicly available as
Entry::default_header()
2017-02-05 13:10:38 +01:00
Matthias Beyer
e4e5fafce2
Make fn pub
2016-10-20 14:11:47 +02:00
Matthias Beyer
7806cf34c1
Refactor FilterCompareLinkCountIter into FilterLinksIter
2016-10-20 14:11:47 +02:00
Matthias Beyer
19b60c3776
Refactor Filter{More,Less}ThanIter into FilterCompareLinkCountIter
2016-10-19 14:34:11 +02:00
Matthias Beyer
d54666894d
Add FilterMoreThanIter
2016-10-19 14:34:11 +02:00
Matthias Beyer
c55ad42e59
Rewrite FilterUnlinkedIter to a FilterLessThanIter
2016-10-19 14:34:11 +02:00
Matthias Beyer
1e008f26a2
Add FilterUnlinkedIter
2016-10-19 14:34:11 +02:00
Matthias Beyer
3e7f245278
Rename: RemoveUnlinkedIter -> DeleteUnlinkedIter
2016-10-19 14:34:10 +02:00
Matthias Beyer
efce42b394
Remove DeleteIter
2016-10-19 14:34:10 +02:00
Matthias Beyer
0eda8e2d04
Initial add iterators for link library
2016-10-19 14:34:10 +02:00
Matthias Beyer
a796de322a
Fix bug: Links were swapped
2016-10-15 11:36:25 +02:00
Matthias Beyer
b64eae9654
Add multi-link test
2016-10-15 11:35:01 +02:00
Matthias Beyer
6d31913321
Fix bug: We have to compare StoreId objects without their base
2016-10-15 11:24:42 +02:00
Matthias Beyer
9c29bf19da
Add debugging output
2016-10-15 11:24:14 +02:00
Matthias Beyer
4e2bcf7d58
Add env-logger for test logging
2016-10-15 11:23:31 +02:00
Matthias Beyer
36b77f4e38
Add test for linking+unlinking
2016-10-15 11:23:30 +02:00
Matthias Beyer
d27c8ced34
Add first internal-linking test
2016-10-15 11:23:30 +02:00
Matthias Beyer
b70564f2ce
Change InternalLinker to return iterator objects
2016-10-14 13:27:06 +02:00
Matthias Beyer
2db79ada71
libimagentrylink: Add copyright notice to all files
2016-10-01 17:35:06 +02:00
Matthias Beyer
40014051ec
Bugfix: unique()ing the list of links
...
That should happen _after_ they are all in the same format.
This commit introduces overhead, as we clone() each string here for
comparison and that should clearly be fixed.
Though the bug-fix is more important at this point.
2016-09-06 15:30:26 +02:00
Matthias Beyer
46bf387fc3
Make internal linking only have store-relative links
2016-08-31 09:20:09 +02:00
Matthias Beyer
3e4b0e4bb8
Rewrite internal link handling, returning Result<_> rather than Option<_>
2016-08-31 09:20:09 +02:00
Matthias Beyer
522d73e6df
Fix libimagentrylink::{error, internal}::* for new StoreId interface
2016-08-28 18:41:55 +02:00
Matthias Beyer
5935d43f09
Replace map(unwrap()) with fold()
2016-08-03 11:30:23 +02:00
Matthias Beyer
41bf063a71
Replace map(unwrap()) with fold()
2016-08-03 11:29:38 +02:00
Matthias Beyer
80491ff0b7
Replace map(unwrap()) with fold()
2016-08-03 11:27:26 +02:00
Matthias Beyer
f46e8ac597
Replace unwrap with try!()
2016-08-03 11:27:25 +02:00
Matthias Beyer
29be4029da
Replace complex unwrapping with big match block
2016-06-11 06:50:58 +02:00
Matthias Beyer
98b39bbfa8
Use IntoError to have less noise in the error construction code
2016-05-27 10:38:35 +02:00
Matthias Beyer
394b90f038
libimagentrylink: Refactor code with is_match!() macro
2016-05-23 21:43:20 +02:00
Andre Bogus
981707c9c9
more style adaptations
...
again following clippy
2016-05-13 22:27:53 +02:00
Matthias Beyer
5d2950b7df
libimagentrylink: Replace .err().unwrap() with .unwrap_err()
2016-04-20 21:45:27 +02:00
Matthias Beyer
33aa56019f
libimaglink -> libimagentrylink
2016-04-17 12:22:13 +02:00