File tree 1 file changed +12
-0
lines changed
fable/include/fable/schema
1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -348,6 +348,12 @@ class Box : public Interface {
348
348
349
349
// ------------------------------------------------------------------------- //
350
350
351
+ /* *
352
+ * The Base class implements the Interface partially and is meant to cover
353
+ * the most commonly used types.
354
+ *
355
+ * See most of the other schema types for how it is used.
356
+ */
351
357
template <typename CRTP>
352
358
class Base : public Interface {
353
359
public:
@@ -397,6 +403,12 @@ class Base : public Interface {
397
403
}
398
404
399
405
protected:
406
+ /* *
407
+ * Validate whether `c` is of the correct type.
408
+ *
409
+ * This method is provided for an implementation to call in its `validate()`
410
+ * implementation. It is not called automatically.
411
+ */
400
412
void validate_type (const Conf& c) const {
401
413
if (c->type () != type_) {
402
414
if (c->type () == JsonType::number_unsigned && type_ == JsonType::number_integer) {
You can’t perform that action at this time.
0 commit comments