We do not need boxes here

This commit is contained in:
Matthias Beyer 2016-03-04 21:18:04 +01:00
parent 679865464b
commit 2c544382a1

View file

@ -14,14 +14,14 @@ pub trait NonMutableHookDataAccessor : Send + Sync {
fn access(&self, &FileLockEntry) -> HookResult<()>;
}
pub enum HookDataAccessor {
StoreIdAccess(Box<StoreIdAccessor>),
MutableAccess(Box<MutableHookDataAccessor>),
NonMutableAccess(Box<NonMutableHookDataAccessor>),
pub enum HookDataAccessor<'a> {
StoreIdAccess(&'a StoreIdAccessor),
MutableAccess(&'a MutableHookDataAccessor),
NonMutableAccess(&'a NonMutableHookDataAccessor),
}
pub trait HookDataAccessorProvider {
fn accessor(&self) -> Box<HookDataAccessor>;
fn accessor(&self) -> HookDataAccessor;
}