Lines Matching refs:T

262         template<typename T, typename S, int I, class F> friend struct C2GlobalParam;
263 template<typename T, typename S, int I, class F> friend struct C2PortParam; // for kDir*
264 template<typename T, typename S, int I, class F> friend struct C2StreamParam; // for kDir*
620 template<typename T, class B=typename std::remove_extent<T>::type>
621 inline _C2FieldId(T* offset) in _C2FieldId()
642 template<typename R, typename T, typename U, typename B=typename std::remove_extent<R>::type>
643 inline _C2FieldId(U *, R T::* pm) in _C2FieldId()
652 template<typename R, typename T, typename B=typename std::remove_extent<R>::type>
653 inline _C2FieldId(R T::* pm) in _C2FieldId()
654 : _mOffset((uint32_t)(uintptr_t)(&(((T*)0)->*pm))), in _C2FieldId()
728 template<typename S, typename T>
729 inline C2ParamField(S* param, T* offset) in C2ParamField()
731 _mFieldId((T*)((uintptr_t)offset - (uintptr_t)param)) {} in C2ParamField()
733 template<typename S, typename T>
734 inline static C2ParamField Make(S& param, T& offset) { in Make()
735 return C2ParamField(param.index(), (uintptr_t)&offset - (uintptr_t)&param, sizeof(T)); in Make()
753 template<typename R, typename T, typename U>
754 inline C2ParamField(U *p, R T::* pm) : _mIndex(p->index()), _mFieldId(p, pm) { } in C2ParamField()
838 template<typename T> const T &ref() const;
863 template<typename T, bool = std::is_enum<T>::value>
865 using U = typename std::underlying_type<T>::type; in TypeFor()
870 template<typename T, bool B = std::is_enum<T>::value>
872 return TypeFor<T, B>(); in typeFor()
876 template<typename T>
877 C2Value(T value) : _mType(typeFor<T>()), _mValue(value) { } in C2Value()
883 template<typename T>
884 inline bool get(T *value) const { in get()
885 if (_mType == typeFor<T>()) { in get()
886 *value = _mValue.ref<T>(); in get()
1004 template<typename T, class B=typename std::remove_extent<T>::type>
1005 inline C2FieldDescriptor(const T* offset, const char *name) in C2FieldDescriptor()
1007 _mExtent(std::is_array<T>::value ? std::extent<T>::value : 1), in C2FieldDescriptor()
1022 template<typename T, typename S, class B=typename std::remove_extent<T>::type>
1023 inline C2FieldDescriptor(S*, T S::* field, const char *name) in C2FieldDescriptor()
1025 _mExtent(std::is_array<T>::value ? std::extent<T>::value : 1), in C2FieldDescriptor()
1078 template<typename T,
1079 class=typename std::enable_if<std::is_enum<T>::value>::type>
1080 inline static type_t GetType(T*) { in GetType()
1081 typename std::underlying_type<T>::type underlying(0); in GetType()
1086 template<typename T,
1087 class=decltype(T::CORE_INDEX + 1), class=decltype(T::FieldList())>
1088 inline static type_t GetType(T*) { in GetType()
1089 static_assert(!std::is_base_of<C2Param, T>::value, "cannot use C2Params as fields"); in GetType()
1090 return (type_t)(T::CORE_INDEX | STRUCT_FLAG); in GetType()
1149 template<typename T>
1150 inline C2StructDescriptor(T*)
1151 : C2StructDescriptor(T::CORE_INDEX, T::FieldList()) { }
1212 template<typename T>
1213 inline C2ParamDescriptor(bool isRequired, C2StringLiteral name, const T*)
1214 : _mIndex(T::PARAM_TYPE),
1564 template<typename T>
1565 C2FieldSupportedValues(T min, T max, T step = T(std::is_floating_point<T>::value ? 0 : 1))
1567 range{min, max, step, (T)1, (T)1} { }
1569 template<typename T>
1570 C2FieldSupportedValues(T min, T max, T num, T den) :
1572 range{min, max, (T)0, num, den} { }
1574 template<typename T>
1575 C2FieldSupportedValues(T min, T max, T step, T num, T den)
1580 template<typename T>
1581 C2FieldSupportedValues(bool flags, std::initializer_list<T> list)
1583 range{(T)0, (T)0, (T)0, (T)0, (T)0} {
1584 for (T value : list) {
1590 template<typename T>
1591 C2FieldSupportedValues(bool flags, const std::vector<T>& list)
1593 range{(T)0, (T)0, (T)0, (T)0, (T)0} {
1594 for(T value : list) {
1602 template<typename T, typename E=decltype(C2FieldDescriptor::namedValuesFor(*(T*)0))>
1603 C2FieldSupportedValues(bool flags, const T*)
1605 range{(T)0, (T)0, (T)0, (T)0, (T)0} {
1606 C2FieldDescriptor::NamedValuesType named = C2FieldDescriptor::namedValuesFor(*(T*)0);