Impl Wrap for EntryHeader

This commit is contained in:
Matthias Beyer 2017-01-20 15:26:36 +01:00
parent f362cbdd6d
commit 46eb02c120
1 changed files with 8 additions and 2 deletions

View File

@ -211,13 +211,19 @@ pub mod store {
wrappable_struct!(EntryHeader, EntryHeaderWrapper, ENTRY_HEADER_WRAPPER); wrappable_struct!(EntryHeader, EntryHeaderWrapper, ENTRY_HEADER_WRAPPER);
class!(REntryHeader); class!(REntryHeader);
impl Wrap for EntryHeader {
fn wrap(self) -> AnyObject {
Class::from_existing("REntryHeader").wrap_data(self, &*ENTRY_HEADER_WRAPPER)
}
}
methods!( methods!(
REntryHeader, REntryHeader,
itself, itself,
fn r_entry_header_new() -> AnyObject { fn r_entry_header_new() -> AnyObject {
Class::from_existing("REntryHeader") EntryHeader::new().wrap()
.wrap_data(EntryHeader::new(), &*ENTRY_HEADER_WRAPPER)
} }
fn r_entry_header_insert(spec: RString, obj: AnyObject) -> Boolean { fn r_entry_header_insert(spec: RString, obj: AnyObject) -> Boolean {