diff options
Diffstat (limited to 'src/mongo/db/field_ref.h')
-rw-r--r-- | src/mongo/db/field_ref.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/mongo/db/field_ref.h b/src/mongo/db/field_ref.h index 51b3f642985..70bb97cf587 100644 --- a/src/mongo/db/field_ref.h +++ b/src/mongo/db/field_ref.h @@ -53,7 +53,7 @@ namespace mongo { public: FieldRef(); - explicit FieldRef(const StringData& path); + explicit FieldRef(StringData path); /** * Field parts accessed through getPart() calls no longer would be valid, after the @@ -64,13 +64,13 @@ namespace mongo { /** * Builds a field path out of each field part in 'dottedField'. */ - void parse(const StringData& dottedField); + void parse(StringData dottedField); /** * Sets the 'i-th' field part to point to 'part'. Assumes i < size(). Behavior is * undefined otherwise. */ - void setPart(size_t i, const StringData& part); + void setPart(size_t i, StringData part); /** * Returns the 'i-th' field part. Assumes i < size(). Behavior is undefined otherwise. @@ -103,7 +103,7 @@ namespace mongo { /** * Compares the full dotted path represented by this FieldRef to other */ - bool equalsDottedField( const StringData& other ) const; + bool equalsDottedField( StringData other ) const; /** * Return 0 if 'this' is equal to 'other' lexicographically, -1 if is it less than or @@ -137,7 +137,7 @@ namespace mongo { /** * Parses 'path' into parts. */ - void _parse(const StringData& path); + void _parse(StringData path); /** Converts the field part index to the variable part equivalent */ size_t getIndex(size_t i) const { return i-kReserveAhead; } @@ -146,7 +146,7 @@ namespace mongo { * Returns the new number of parts after appending 'part' to this field path. It * assumes that 'part' is pointing to an internally allocated area. */ - size_t appendPart(const StringData& part); + size_t appendPart(StringData part); /** * Re-assemble _dotted from components, including any replacements in _replacements, |