FiberVISH 0.2
Fish - The Fiber Bundle API for the Vish Visualization Shell
TypedCreationPreferences.hpp
1#ifndef __FISH_BONE_TYPEDCREATIONPREFERENCES_HPP
2#define __FISH_BONE_TYPEDCREATIONPREFERENCES_HPP
3
4#include "fishboneDllApi.h"
5
6#include <ocean/plankton/VCreationPreferences.hpp>
7#include <field/FiberType.hpp>
8#include <meta/LIST.hpp>
9
10namespace Wizt
11{
12
28{
29public:
32
36 int getAcceptTypes(Fiber::TypeList_t&AcceptedFields) const
37 {
38 return AcceptTypes(AcceptedFields);
39 }
40
44 virtual int AcceptTypes(Fiber::TypeList_t&AcceptedFields) const = 0;
45};
46
47
51template <class ...T>
53{
54public:
57
58 int AcceptTypes(Fiber::TypeList_t&AcceptedFields) const override
59 {
60 Fiber::AcceptType<T...> accept(AcceptedFields);
61 return 1;
63 }
64};
68template <class ...T>
70{
71public:
74
75 int AcceptTypes(Fiber::TypeList_t&AcceptedFields) const override
76 {
77 Fiber::AcceptType<T...> accept(AcceptedFields);
78 return 1;
80 }
81};
82
83#if 0
88template <class T, class NEXT>
89class TypedCreationPreferences<META::LIST<T, NEXT> > : public TypedCreationPreferences<NEXT>
90{
91public:
92 TypedCreationPreferences() {}
93 ~TypedCreationPreferences() {}
94
95 int AcceptTypes(Fiber::TypeList_t&AcceptedFields) const override
96 {
97 Fiber::AcceptType<T> XXX(AcceptedFields);
98 return TypedCreationPreferences<NEXT>::AcceptTypes(AcceptedFields)+1;
99 }
100};
101
102template <class T>
103class TypedCreationPreferences<META::LIST<T> > : public TypedCreationPreferencesBase
104{
105public:
106 int AcceptTypes(Fiber::TypeList_t&AcceptedFields) const override
107 {
108 Fiber::AcceptType<T> XXX(AcceptedFields);
109 return 1;
110 }
111};
112#endif
113
114} // namespace Wizt
115
116#endif /* __FISH_BONE_TYPEDCREATIONPREFERENCES_HPP */
An iterator with an optional DataCreator, which is just a class to intercept creation of data along a...
Definition CreativeIterator.hpp:34
Base class for Fiber-specific creation preferences that know how to deal with types.
Definition TypedCreationPreferences.hpp:28
int getAcceptTypes(Fiber::TypeList_t &AcceptedFields) const
Virtual function that defines which field types are acceptable here for this creation preferences.
Definition TypedCreationPreferences.hpp:36
virtual int AcceptTypes(Fiber::TypeList_t &AcceptedFields) const =0
Virtual function that defines which field types are acceptable here for this creation preferences.
int AcceptTypes(Fiber::TypeList_t &AcceptedFields) const override
Virtual function that defines which field types are acceptable here for this creation preferences.
Definition TypedCreationPreferences.hpp:75
Fiber-specific creation preferences that know how to deal with types.
Definition TypedCreationPreferences.hpp:53
int AcceptTypes(Fiber::TypeList_t &AcceptedFields) const override
Virtual function that defines which field types are acceptable here for this creation preferences.
Definition TypedCreationPreferences.hpp:58
note: cannot derive from FloatingSkeletonRenderer as long as independent base class TriangleRenderer ...
A template helper class to provide an easier syntax for allowing certain field types to be accepted b...
Definition FiberType.hpp:267
A set of types.
Definition FiberType.hpp:213