Function SkipWhitespace

Summary

#include <include/rapidjson/reader.h>

(1) template <typename InputStream>
    void SkipWhitespace(InputStream &is)

(2) const char * SkipWhitespace(const char *p, const char *end)

(3) template <>
    void SkipWhitespace(InsituStringStream &is)

(4) template <>
    void SkipWhitespace(StringStream &is)

(5) template <>
    void SkipWhitespace(EncodedInputStream< UTF8<>, MemoryStream > &is)

Function overload

Synopsis

#include <include/rapidjson/reader.h>

template <typename InputStream>
void SkipWhitespace(InputStream &is)

Description

Skip the JSON white spaces in a stream.

Parameters

is - A input stream for skipping white spaces.

Note
This function has SSE2/SSE4.2 specialization.

Mentioned in

Source

Lines 265-273 in include/rapidjson/reader.h.

template<typename InputStream>
void SkipWhitespace(InputStream& is) {
    internal::StreamLocalCopy<InputStream> copy(is);
    InputStream& s(copy.s);

    typename InputStream::Ch c;
    while ((c = s.Peek()) == ' ' || c == '\n' || c == '\r' || c == '\t')
        s.Take();
}

Synopsis

#include <include/rapidjson/reader.h>

const char * SkipWhitespace(const char *p, const char *end)

Description

No description yet.

Mentioned in

Source

Lines 275-279 in include/rapidjson/reader.h.

inline const char* SkipWhitespace(const char* p, const char* end) {
    while (p != end && (*p == ' ' || *p == '\n' || *p == '\r' || *p == '\t'))
        ++p;
    return p;
}

Synopsis

#include <include/rapidjson/reader.h>

template <>
void SkipWhitespace(InsituStringStream &is)

Description

Template function specialization for InsituStringStream.

Mentioned in

Source

Lines 505-507 in include/rapidjson/reader.h.

template<> inline void SkipWhitespace(InsituStringStream& is) {
    is.src_ = const_cast<char*>(SkipWhitespace_SIMD(is.src_));
}

Synopsis

#include <include/rapidjson/reader.h>

template <>
void SkipWhitespace(StringStream &is)

Description

Template function specialization for StringStream.

Mentioned in

Source

Lines 510-512 in include/rapidjson/reader.h.

template<> inline void SkipWhitespace(StringStream& is) {
    is.src_ = SkipWhitespace_SIMD(is.src_);
}

Synopsis

#include <include/rapidjson/reader.h>

template <>
void SkipWhitespace(EncodedInputStream< UTF8<>, MemoryStream > &is)

Description

No description yet.

Mentioned in

Source

Lines 514-516 in include/rapidjson/reader.h.

template<> inline void SkipWhitespace(EncodedInputStream<UTF8<>, MemoryStream>& is) {
    is.is_.src_ = SkipWhitespace_SIMD(is.is_.src_, is.is_.end_);
}





Add Discussion as Guest

Log in