YetAnotherForum
Welcome Guest Search | Active Topics | Log In | Register

SQRat : binding abstract classes
JonHodgson
#1 Posted : Saturday, June 11, 2016 10:43:09 AM(UTC)
Rank: Member

Groups: Registered
Joined: 5/19/2016(UTC)
Posts: 15
Location: UK

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
Hi,

My class hierarchy includes, not surprisingly, abstract classes.

These don't work in an SQRat::Table::Bind function, because they cannot be instantiated.

Now it's not the end of the world, I can work around it, by binding the first non abstract classes in the tree as seperate base classes, but that's going to make the binding code a bit ugly, having to repeat the binding of functions declared in abstract base classes.

So I'm wondering if there is a "proper" way to do it in SQRat?

regards

Jon
JonHodgson
#2 Posted : Wednesday, June 15, 2016 7:16:44 AM(UTC)
Rank: Member

Groups: Registered
Joined: 5/19/2016(UTC)
Posts: 15
Location: UK

Thanks: 0 times
Was thanked: 0 time(s) in 0 post(s)
Answering my own question... just set the allocator to

Sqrat::NoConstructor

WHy I didn't think of this before is beyond me, especially as I've already written my own constructor for another class tree!

Anyway I found this out minutes after posting the question, but couldn't post a follow up because the first post needed to be cleared by a moderator.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Clean Slate theme by Jaben Cargman (Tiny Gecko)
Powered by YAF 1.9.4 | YAF © 2003-2010, Yet Another Forum.NET
This page was generated in 0.078 seconds.