File: str-helper.h

package info (click to toggle)
scummvm 2.9.0%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: trixie
  • size: 450,268 kB
  • sloc: cpp: 4,297,604; asm: 28,322; python: 12,901; sh: 11,219; java: 8,477; xml: 7,843; perl: 2,633; ansic: 2,465; yacc: 1,670; javascript: 1,020; makefile: 933; lex: 578; awk: 275; objc: 82; sed: 11; php: 1
file content (23 lines) | stat: -rw-r--r-- 619 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#ifndef TEST_COMMON_HELPER_H
#define TEST_COMMON_HELPER_H

#include "common/str.h"

namespace CxxTest
{
    CXXTEST_TEMPLATE_INSTANTIATION
    class ValueTraits<const Common::String &>
    {
        ValueTraits &operator=( const ValueTraits & );
		Common::String _str;

    public:
        ValueTraits( const Common::String &value ) : _str( value ) {}
        ValueTraits( const ValueTraits &other ) : _str( other._str ) {}
        const char *asString( void ) const { return _str.c_str(); }
    };
	CXXTEST_COPY_CONST_TRAITS( Common::String &);
	CXXTEST_COPY_TRAITS( Common::String, const Common::String &);
}

#endif