Skip to content

Commit

Permalink
Merge pull request #37 from ihrwein/f/boxed-clone
Browse files Browse the repository at this point in the history
F/boxed clone
  • Loading branch information
ihrwein committed Jul 23, 2015
2 parents 7574759 + 674ca5a commit 9f0235a
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 2 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
@@ -1,6 +1,6 @@
[package]
name = "actiondb"
version = "0.2.0"
version = "0.2.1"
authors = ["Tibor Benke <tibor.benke@balabit.com>"]

[[bin]]
Expand Down
2 changes: 1 addition & 1 deletion src/bin/adbtool.rs
Expand Up @@ -10,7 +10,7 @@ use actiondb::matcher::Factory;
use log::{LogLevelFilter};
use actiondb::utils::logger::StdoutLogger;

const VERSION: &'static str = "0.2.0";
const VERSION: &'static str = "0.2.1";
const AUTHOR: &'static str = "Tibor Benke <tibor.benke@balabit.com>";
const APPNAME: &'static str = "adbtool";

Expand Down
1 change: 1 addition & 0 deletions src/matcher/matcher/mod.rs
Expand Up @@ -7,4 +7,5 @@ pub mod builder;
pub trait Matcher: fmt::Debug {
fn parse<'a, 'b>(&'a self, text: &'b str) -> Option<MatchResult<'a, 'b>>;
fn add_pattern(&mut self, pattern: Pattern);
fn boxed_clone(&self) -> Box<Matcher>;
}
3 changes: 3 additions & 0 deletions src/matcher/trie/matcher.rs
Expand Up @@ -10,4 +10,7 @@ impl Matcher for ParserTrie {
fn add_pattern(&mut self, pattern: Pattern) {
self.insert(pattern);
}
fn boxed_clone(&self) -> Box<Matcher> {
Box::new(self.clone())
}
}

0 comments on commit 9f0235a

Please sign in to comment.