diff options
Diffstat (limited to 'src/mongo/db/ops/field_checker.h')
-rw-r--r-- | src/mongo/db/ops/field_checker.h | 50 |
1 files changed, 25 insertions, 25 deletions
diff --git a/src/mongo/db/ops/field_checker.h b/src/mongo/db/ops/field_checker.h index 544ea131074..772034d4773 100644 --- a/src/mongo/db/ops/field_checker.h +++ b/src/mongo/db/ops/field_checker.h @@ -32,28 +32,28 @@ namespace mongo { - class FieldRef; - - namespace fieldchecker { - - /** - * Returns OK if all the below conditions on 'field' are valid: - * + Non-empty - * + Does not start or end with a '.' - * Otherwise returns a code indicating cause of failure. - */ - Status isUpdatable(const FieldRef& field); - - /** - * Returns true, the position 'pos' of the first $-sign if present in 'fieldRef', and - * how many other $-signs were found in 'count'. Otherwise return false. - * - * Note: - * isPositional assumes that the field is updatable. Call isUpdatable() above to - * verify. - */ - bool isPositional(const FieldRef& fieldRef, size_t* pos, size_t* count = NULL); - - } // namespace fieldchecker - -} // namespace mongo +class FieldRef; + +namespace fieldchecker { + +/** + * Returns OK if all the below conditions on 'field' are valid: + * + Non-empty + * + Does not start or end with a '.' + * Otherwise returns a code indicating cause of failure. + */ +Status isUpdatable(const FieldRef& field); + +/** + * Returns true, the position 'pos' of the first $-sign if present in 'fieldRef', and + * how many other $-signs were found in 'count'. Otherwise return false. + * + * Note: + * isPositional assumes that the field is updatable. Call isUpdatable() above to + * verify. + */ +bool isPositional(const FieldRef& fieldRef, size_t* pos, size_t* count = NULL); + +} // namespace fieldchecker + +} // namespace mongo |